function
<cmath> <ctgmath>
atandouble atan (double x); float atanf (float x);long double atanl (long double x);
double atan (double x); float atan (float x);long double atan (long double x);
double atan (double x); float atan (float x);long double atan (long double x); double atan (T x); // additional overloads for integral types
Compute arc tangent
Returns the principal value of the arc tangent of x, expressed in radians.In trigonometrics, arc tangent is the inverse operation of tangent.
Notice that because of the sign ambiguity, the function cannot determine with certainty in which quadrant the angle falls only by its tangent value. See atan2 for an alternative that takes a fractional argument instead.
Header
<tgmath.h>provides a type-generic macro version of this function.
180/PI
degrees.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* atan example */
#include <stdio.h> /* printf */
#include <math.h> /* atan */
#define PI 3.14159265
int main ()
{
double param, result;
param = 1.0;
result = atan (param) * 180 / PI;
printf ("The arc tangent of %f is %f degrees\n", param, result );
return 0;
}
The arc tangent of 1.000000 is 45.000000 degrees.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4