SciPy

This is documentation for an old release of SciPy (version 1.5.3). Read this page in the documentation of the latest stable release (version 1.15.1).

scipy.special.cotdg

scipy.special.cotdg(x, out=None) = <ufunc 'cotdg'>

Cotangent of the angle x given in degrees.

Parameters
xarray_like

Angle, given in degrees.

outndarray, optional

Optional output array for the function results.

Returns
scalar or ndarray

Cotangent at the input.

See also

sindg, cosdg, tandg

Examples

>>>
>>> import scipy.special as sc

It is more accurate than using cotangent directly.

>>>
>>> x = 90 + 180 * np.arange(3)
>>> sc.cotdg(x)
array([0., 0., 0.])
>>> 1 / np.tan(x * np.pi / 180)
array([6.1232340e-17, 1.8369702e-16, 3.0616170e-16])

Previous topic

scipy.special.tandg

Next topic

scipy.special.log1p