1 .\" Copyright 2002 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
2 .\" Distributed under GPL, 2002-07-27 Walter Harms
3 .\" and Copyright 2008, Linux Foundation, written by Michael Kerrisk
4 .\" <mtk.manpages@gmail.com>
6 .TH SINCOS 3 2008-08-11 "GNU" "Linux Programmer's Manual"
8 sincos, sincosf, sincosl \- calculate sin and cos simultaneously
11 .BR "#define _GNU_SOURCE" " /* See feature_test_macros(7) */"
14 .BI "void sincos(double " x ", double *" sin ", double *" cos );
16 .BI "void sincosf(float " x ", float *" sin ", float *" cos );
18 .BI "void sincosl(long double " x ", long double *" sin ", long double *" cos );
23 Several applications need sine and cosine of the same angle
25 This function computes both at the same time, and stores the results in
40 is positive infinity or negative infinity,
41 a domain error occurs, and
47 These functions return
52 for information on how to determine whether an error has occurred
53 when calling these functions.
55 The following errors can occur:
57 Domain error: \fIx\fP is an infinity
61 An invalid floating-point exception
65 These functions do not set
67 .\" FIXME . Is it intentional that these functions do not set errno?
68 .\" sin() and cos() also don't set errno; bugs have been raised for
71 These functions first appeared in glibc in version 2.1.
73 This function is a GNU extension.
78 .BR feature_test_macros (7)