www.delorie.com/djgpp/doc/libc/libc_729.html | search |
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
#include <math.h> void sincos(double *cosine, double *sine, double x); |
This function computes the cosine and the sine of x in a single
call, and stores the results in the addresses pointed to by cosine
and sine, respectively. Since the function exploits a machine
instruction that computes both cosine and sine simultaneously, it is
faster to call sincos
than to call cos
and sin
for
the same argument.
If the absolute value of x is finite but greater than or equal to
2^63, the value stored in *cosine is 1 and the value stored
in *sine is 0 (since for arguments that large each bit of the
mantissa is more than Pi
). If the value of x is infinite
or NaN
, NaN
is stored in both *cosine and
*sine, and errno
is set to EDOM
.
None.
ANSI/ISO C | No |
POSIX | No |
webmaster donations bookstore | delorie software privacy |
Copyright © 2004 by DJ Delorie | Updated Apr 2004 |