]> git.ipfire.org Git - thirdparty/man-pages.git/blame - man3/remquo.3
Added/updated glibc feature test macro requirements
[thirdparty/man-pages.git] / man3 / remquo.3
CommitLineData
fea681da
MK
1.\" Copyright 2002 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
2.\" Distributed under GPL
3.\" based on glibc infopages
4.\" polished, aeb
cc4615cc 5.TH REMQUO 3 2007-07-26 "GNU" "Linux Programmer's Manual"
fea681da 6.SH NAME
c13182ef 7remquo, remquof, remquol \- remainder and part of quotient
fea681da
MK
8.SH SYNOPSIS
9.nf
fea681da
MK
10.B #include <math.h>
11.sp
12.BI "double remquo(double " x ", double " y ", int *" quo );
d39541ec 13.br
fea681da 14.BI "float remquof(float " x ", float " y ", int *" quo );
d39541ec 15.br
fea681da 16.BI "long double remquol(long double " x ", long double " y ", int *" quo );
fea681da 17.fi
cc4615cc
MK
18.sp
19Link with \fI\-lm\fP.
20.sp
21.in -4n
22Feature Test Macro Requirements for glibc (see
23.BR feature_test_macros (7)):
24.in
25.sp
26.ad l
27.BR remquo (),
28.BR remquof (),
29.BR remquol ():
30_XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE; or
31.I cc\ -std=c99
32.ad b
fea681da
MK
33.SH DESCRIPTION
34These functions compute the remainder and part of the quotient
35upon division of
36.I x
37by
38.IR y .
39A few bits of the quotient are stored via the
40.I quo
c13182ef
MK
41pointer.
42The remainder is returned as function value.
fea681da
MK
43
44The value of the remainder is the same as that computed by the
45.BR remainder (3)
46function.
47
48The value stored via the
49.I quo
50pointer has the sign of
51.IR x / y
52and agrees with the quotient in at least the low order 3 bits.
53
54For example, remquo(29.0,3.0) returns \-1.0 and might store 2.
55Note that the actual quotient might not fit in an integer.
fea681da
MK
56.\" A possible application of this function might be the computation
57.\" of sin(x). Compute remquo(x, pi/2, &quo) or so.
58.\"
59.\" glibc, UnixWare: return 3 bits
60.\" MacOS 10: return 7 bits
61.SH "CONFORMING TO"
62C99
63.SH "SEE ALSO"
64.BR fmod (3),
65.BR logb (3),
cc4615cc 66.BR remainder (3)