atan, atanl

De RAD Studio
Aller à : navigation, rechercher

Remonter à Math.h - Index


Header File

math.h

Category

Math Routines

Prototype

double atan(double x);

long double atanl(long double x);

Description

Calculates the arc tangent.

atan calculates the arc tangent of the input value.

atanl is the long double version; it takes a long double argument and returns a long double result.

Return Value

atan and atanl of a real argument return a value in the range -pi/2 to pi/2. Error handling for these functions can be modified through the functions _matherr and _matherrl.

Example



 #include <stdio.h>
 #include <math.h>
 int main(void)
 {
    double result;
    double x = 0.5;
    result = atan(x);
    printf("The arc tangent of %lf is %lf\n", x, result);
 return(0);
 }



Portability



POSIX Win32 ANSI C ANSI C++

atan

+

+

+

+

atanl

+

+

+