tail head cat sleep
QR code linking to this page

Manual Pages  — SINCOS

NAME

sincos, sincosf, sincosl – sine and cosine functions

CONTENTS

LIBRARY

Math Library (libm, -lm)

SYNOPSIS

#include <math.h>

void
sincos(double x, double *s, double *c);

void
sincosf(float x, float *s, float *c);

void
sincosl(long double x, long double *s, long double *c);

DESCRIPTION

The sincos(), sincosf(), and sincosl() functions compute the sine and cosine of x. Using these functions allows argument reduction to occur only once instead of twice with individual invocations of sin() and cos(). Like sin() and cos(), a large magnitude argument may yield a result with little or no significance.

RETURN VALUES

Upon returning from sincos(), sincosf(), and sincosl(), the memory pointed to by *s and *c are assigned the values of sine and cosine, respectively.

SEE ALSO

cos(3), sin(3)

HISTORY

These functions were added to FreeBSD 11.2 to aid in writing various complex function contained in ISO/IEC 9899:1999 ("ISO C99").


SINCOS (3) March 12, 2011

tail head cat sleep
QR code linking to this page


Please direct any comments about this manual page service to Ben Bullock. Privacy policy.

“ Our grievance is not just against Unix itself, but against the cult of Unix zealots who defend and nurture it. They take the heat, disease, and pestilence as givens, and, as ancient shamans did, display their wounds, some self-inflicted, as proof of their power and wizardry. We aim, through bluntness and humor, to show them that they pray to a tin god, and that science, not religion, is the path to useful and friendly technology. ”
— The Unix Haters' handbook