date and time created 91/04/16 14:59:05 by bostic
[unix-history] / usr / src / usr.bin / pascal / libpc / ATAN.c
CommitLineData
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
9static char sccsid[] = "@(#)ATAN.c 1.3 (Berkeley) %G%";
10#endif /* not lint */
3c8fe971
KM
11
12#include <math.h>
13extern int errno;
14
15double
16ATAN(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}