xref: /original-bsd/lib/libm/common_source/acos.3 (revision 4ee49cc0)
1.\" Copyright (c) 1991, 1993
2.\"	The Regents of the University of California.  All rights reserved.
3.\"
4.\" %sccs.include.redist.man%
5.\"
6.\"     @(#)acos.3	8.1 (Berkeley) 06/04/93
7.\"
8.Dd
9.Dt ACOS 3
10.Os
11.Sh NAME
12.Nm acos
13.Nd arc cosine function
14.Sh SYNOPSIS
15.Fd #include <math.h>
16.Ft double
17.Fn acos "double x"
18.Sh DESCRIPTION
19The
20.Fn acos
21function computes the principal value of the arc cosine of
22.Fa x .
23A domain error occurs for arguments not in the range [-1, +1].
24For a discussion of error due to roundoff, see
25.Xr math 3 .
26.Sh RETURN VALUES
27The
28.Fn acos
29function returns the arc cosine in the range
30.Bq 0 , \*(Pi
31radians.
32On the
33.Tn VAX
34and
35.Tn Tahoe ,
36if:
37.Bd -unfilled -offset indent
38.Pf \&| Ns Ar x Ns \&| > 1 ,
39.Ed
40.Pp
41.Fn acos x
42sets the global variable
43.Va errno
44to
45.Dv EDOM
46and a reserved operand fault is generated.
47.Sh SEE ALSO
48.Xr sin 3 ,
49.Xr cos 3 ,
50.Xr tan 3 ,
51.Xr asin 3 ,
52.Xr atan 3 ,
53.Xr atan2 3 ,
54.Xr sinh 3 ,
55.Xr cosh 3 ,
56.Xr tanh 3 ,
57.Xr math 3 ,
58.Sh STANDARDS
59The
60.Fn acos
61function conforms to
62.St -ansiC .
63