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

NAME

6       lrint,  lrintf,  lrintl,  llrint,  llrintf,  llrintl - round to nearest
7       integer
8

SYNOPSIS

10       #include <math.h>
11
12       long int lrint(double x);
13       long int lrintf(float x);
14       long int lrintl(long double x);
15
16       long long int llrint(double x);
17       long long int llrintf(float x);
18       long long int llrintl(long double x);
19
20       Compile with -std=c99; link with -lm.
21

DESCRIPTION

23       These functions round their argument  to  the  nearest  integer  value,
24       using  the  current rounding direction.  If x is infinite or NaN, or if
25       the rounded value is outside the range of the return type, the  numeric
26       result  is unspecified.  A domain error may occur if the magnitude of x
27       is too large.
28

RETURN VALUE

30       The rounded integer value.
31

ERRORS

33       EDOM   The  magnitude  of  x  is  too  large  and  (math_errhandling  &
34              MATH_ERRNO) is non-zero.
35

CONFORMING TO

37       C99.
38

SEE ALSO

40       ceil(3), floor(3), lround(3), nearbyint(3), rint(3), round(3)
41
42
43
44                                  2001-05-31                          LRINT(3)
Impressum