arctan
Description
Calculate the arctangent of each element, that is, 1/tan(x).
Mandatory Input Parameters
Parameter |
Type |
Description |
|---|---|---|
x |
array_like |
Input array or scalar |
Optional Input Parameters
Return Value
Type |
Description |
|---|---|
ndarray/scalar |
Arctangent of each element, in radians. The value range of the real part is [–π/2, π/2]. |
Examples
>>> import numpy as np >>> np.pi / 4 0.7853981633974483 >>> np.tan([0., np.pi / 4]) array([0., 1.]) >>> >>> np.arctan([0., 1.]) array([0. , 0.78539816]) >>>
Parent topic: Basic Operation Functions