]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man3/fmin.3
a64l.3, addseverity.3, argz_add.3, cabs.3, cacos.3, cacosh.3, canonicalize_file_name...
[thirdparty/man-pages.git] / man3 / fmin.3
1 .\" Copyright 2002 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
2 .\" and Copyright 2008, Linux Foundation, written by Michael Kerrisk
3 .\" <mtk.manpages@gmail.com>
4 .\" %%%LICENSE_START(GPL_NOVERSION_ONELINE)
5 .\" Distributed under GPL
6 .\" %%%LICENSE_END
7 .\"
8 .TH FMIN 3 2010-09-20 "" "Linux Programmer's Manual"
9 .SH NAME
10 fmin, fminf, fminl \- determine minimum of two floating-point numbers
11 .SH SYNOPSIS
12 .B #include <math.h>
13 .sp
14 .BI "double fmin(double " x ", double " y );
15 .br
16 .BI "float fminf(float " x ", float " y );
17 .br
18 .BI "long double fminl(long double " x ", long double " y );
19 .sp
20 Link with \fI\-lm\fP.
21 .sp
22 .in -4n
23 Feature Test Macro Requirements for glibc (see
24 .BR feature_test_macros (7)):
25 .in
26 .sp
27 .ad l
28 .BR fmin (),
29 .BR fminf (),
30 .BR fminl ():
31 .RS 4
32 _XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE ||
33 _POSIX_C_SOURCE\ >=\ 200112L;
34 .br
35 or
36 .I cc\ -std=c99
37 .RE
38 .ad
39 .SH DESCRIPTION
40 These functions the lesser value of
41 .I x
42 and
43 .IR y .
44 .SH RETURN VALUE
45 These functions return the minimum of
46 .I x
47 and
48 .IR y .
49
50 If one argument is a NaN, the other argument is returned.
51
52 If both arguments are NaN, a NaN is returned.
53 .SH ERRORS
54 No errors occur.
55 .SH VERSIONS
56 These functions first appeared in glibc in version 2.1.
57 .SH CONFORMING TO
58 C99, POSIX.1-2001.
59 .SH SEE ALSO
60 .BR fmax (3)