Commit | Line | Data |
---|---|---|
0d78ca85 KB |
1 | /*- |
2 | * Copyright (c) 1982 The Regents of the University of California. | |
3 | * All rights reserved. | |
4 | * | |
5 | * %sccs.include.redist.c% | |
6 | */ | |
3c8fe971 | 7 | |
0d78ca85 KB |
8 | #ifndef lint |
9 | static char sccsid[] = "@(#)ATAN.c 1.3 (Berkeley) %G%"; | |
10 | #endif /* not lint */ | |
3c8fe971 KM |
11 | |
12 | #include <math.h> | |
13 | extern int errno; | |
14 | ||
15 | double | |
16 | ATAN(value) | |
17 | double value; | |
18 | { | |
19 | double result; | |
20 | ||
21 | errno = 0; | |
22 | result = atan(value); | |
23 | if (errno != 0) { | |
24 | ERROR("Argument %e is out of the domain of atan\n", value); | |
3c8fe971 KM |
25 | } |
26 | return result; | |
27 | } |