Debian Codegraph @

upstream/debian-unstable/man3/atan.3

raw
1 '\" t
2 .\" Copyright 1993, David Metcalfe <[email protected]>
3 .\" Copyright, the authors of the Linux man-pages project
4 .\"
5 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
6 .\"
7 .TH atan 3 2026-02-08 "Linux man-pages 6.18"
8 .SH NAME
9 atan, atanf, atanl \- arc tangent function
10 .SH LIBRARY
11 Math library
12 .RI ( libm ,\~ \-lm )
13 .SH SYNOPSIS
14 .nf
15 .B #include <math.h>
16 .P
17 .BI "double atan(double " x );
18 .BI "float atanf(float " x );
19 .BI "long double atanl(long double " x );
20 .P
21 .fi
22 .RS -4
23 Feature Test Macro Requirements for glibc (see
24 .BR feature_test_macros (7)):
25 .RE
26 .P
27 .BR atanf (),
28 .BR atanl ():
29 .nf
30 _ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L
31 || /* Since glibc 2.19: */ _DEFAULT_SOURCE
32 || /* glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE
33 .fi
34 .SH DESCRIPTION
35 These functions calculate the principal value of the arc tangent of
36 .IR x ;
37 that is the value whose tangent is
38 .IR x .
39 .SH RETURN VALUE
40 On success,
41 these functions return the principal value of the arc tangent of
42 .I x
43 in radians;
44 the return value is in the range [\-pi/2,\ pi/2].
45 .P
46 If
47 .I x
48 is a NaN, a NaN is returned.
49 .P
50 If
51 .I x
52 is +0 (\-0),
53 +0 (\-0) is returned.
54 .P
55 If
56 .I x
57 is positive infinity (negative infinity), +pi/2 (\-pi/2) is returned.
58 .\"
59 .\" POSIX.1-2001 documents an optional range error for subnormal x;
60 .\" glibc 2.8 does not do this.
61 .SH ERRORS
62 No errors occur.
63 .SH ATTRIBUTES
64 For an explanation of the terms used in this section, see
65 .BR attributes (7).
66 .TS
67 allbox;
68 lbx lb lb
69 l l l.
70 Interface Attribute Value
71 T{
72 .na
73 .nh
74 .BR atan (),
75 .BR atanf (),
76 .BR atanl ()
77 T} Thread safety MT-Safe
78 .TE
79 .SH STANDARDS
80 C11, POSIX.1-2008.
81 .SH HISTORY
82 C99, POSIX.1-2001.
83 .P
84 The variant returning
85 .I double
86 also conforms to
87 SVr4, 4.3BSD, C89.
88 .SH SEE ALSO
89 .BR acos (3),
90 .BR asin (3),
91 .BR atan2 (3),
92 .BR carg (3),
93 .BR catan (3),
94 .BR cos (3),
95 .BR sin (3),
96 .BR tan (3)