1FMOD(3)                    Linux Programmer's Manual                   FMOD(3)
2
3
4

NAME

6       fmod, fmodf, fmodl - floating-point remainder function
7

SYNOPSIS

9       #include <math.h>
10
11       double fmod(double x, double y);
12       float fmodf(float x, float y);
13       long double fmodl(long double x, long double y);
14
15       Link with -lm.
16

DESCRIPTION

18       The  fmod()  function  computes  the remainder of dividing x by y.  The
19       return value is x - n * y, where n is the quotient of x  /  y,  rounded
20       towards zero to an integer.
21

RETURN VALUE

23       The  fmod()  function returns the remainder, unless y is zero, when the
24       function fails and errno is set.
25

ERRORS

27       EDOM   The denominator y is zero.
28

CONFORMING TO

30       SVr4, 4.3BSD, C89.  The float and long double variants are C99 require‐
31       ments.
32

SEE ALSO

34       remainder(3)
35
36
37
38                                  2002-07-27                           FMOD(3)
Impressum