Commit | Line | Data |
---|---|---|
05dda90f C |
1 | .TH SIN 3M "19 January 1983" |
2 | .SH NAME | |
3 | sin, cos, tan, asin, acos, atan, atan2 \- trigonometric functions | |
4 | .SH SYNOPSIS | |
5 | .nf | |
6 | .B #include <math.h> | |
7 | .PP | |
8 | .B double sin(x) | |
9 | .B double x; | |
10 | .PP | |
11 | .B double cos(x) | |
12 | .B double x; | |
13 | .PP | |
14 | .B double asin(x) | |
15 | .B double x; | |
16 | .PP | |
17 | .B double acos(x) | |
18 | .B double x; | |
19 | .PP | |
20 | .B double atan(x) | |
21 | .B double x; | |
22 | .PP | |
23 | .B double atan2(x, y) | |
24 | .B double x, y; | |
25 | .fi | |
26 | .SH DESCRIPTION | |
27 | .I Sin, cos | |
28 | and | |
29 | .I tan | |
30 | return trigonometric functions of radian arguments. | |
31 | The magnitude of the argument should be checked | |
32 | by the caller to make sure the result is meaningful. | |
33 | .PP | |
34 | .I Asin | |
35 | returns the arc sin in the range \-\(*p/2 to \(*p/2. | |
36 | .PP | |
37 | .I Acos | |
38 | returns the arc cosine in the range 0 to \(*p. | |
39 | .PP | |
40 | .I Atan | |
41 | returns the arc tangent of | |
42 | .I x | |
43 | in the range \-\(*p/2 to \(*p/2. | |
44 | .PP | |
45 | .I Atan2 | |
46 | returns the arc tangent of | |
47 | .I x/y | |
48 | in the range \-\(*p to \(*p. | |
49 | .SH DIAGNOSTICS | |
50 | Arguments of magnitude greater than 1 cause | |
51 | .I asin | |
52 | and | |
53 | .I acos | |
54 | to return value 0; | |
55 | .I errno | |
56 | is set to EDOM. The value of | |
57 | .I tan | |
58 | at its singular points is a huge number, and | |
59 | .I errno | |
60 | is set to ERANGE. | |
61 | .SH BUGS | |
62 | The value of | |
63 | .I tan | |
64 | for arguments greater than about 2**31 is garbage. |