1ab0b9960Sbostic /*- 2*33717ddfSbostic * Copyright (c) 1982, 1993 3*33717ddfSbostic * The Regents of the University of California. All rights reserved. 4ab0b9960Sbostic * 5ab0b9960Sbostic * %sccs.include.redist.c% 6ab0b9960Sbostic */ 7a50a5cdeSmckusick 8ab0b9960Sbostic #ifndef lint 9*33717ddfSbostic static char sccsid[] = "@(#)COS.c 8.1 (Berkeley) 06/06/93"; 10ab0b9960Sbostic #endif /* not lint */ 11a50a5cdeSmckusick 12a50a5cdeSmckusick #include <math.h> 13a50a5cdeSmckusick extern int errno; 14a50a5cdeSmckusick 15a50a5cdeSmckusick double COS(value)16a50a5cdeSmckusickCOS(value) 17a50a5cdeSmckusick double value; 18a50a5cdeSmckusick { 19a50a5cdeSmckusick double result; 20a50a5cdeSmckusick 21a50a5cdeSmckusick errno = 0; 22a50a5cdeSmckusick result = cos(value); 23a50a5cdeSmckusick if (errno != 0) { 24a50a5cdeSmckusick ERROR("Cannot compute cos(%e)\n", value); 25a50a5cdeSmckusick } 26a50a5cdeSmckusick return result; 27a50a5cdeSmckusick } 28