atan

Calculates the arc tangent of x, returning a value ranging from -π/2 to π/2.

Special Values
xatan(x)invalid?
±0.0±0.0no
±∞NaNyes
  1. real atan(real x)
    @safe pure nothrow @nogc
    real
    atan
    (
    real x
    )
  2. double atan(double x)
  3. float atan(float x)

Examples

assert(isIdentical(atan(0.0), 0.0));
assert(atan(sqrt(3.0)).approxEqual(PI / 3));

Meta

Suggestion Box / Bug Report