]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man3/fmin.3
stdarg.3: SEE ALSO: add vprintf(3), vscanf(3), vsyslog(3)
[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 .\"
5 .\" %%%LICENSE_START(GPL_NOVERSION_ONELINE)
6 .\" Distributed under GPL
7 .\" %%%LICENSE_END
8 .\"
9 .TH FMIN 3 2017-09-15 "" "Linux Programmer's Manual"
10 .SH NAME
11 fmin, fminf, fminl \- determine minimum of two floating-point numbers
12 .SH SYNOPSIS
13 .B #include <math.h>
14 .PP
15 .BI "double fmin(double " x ", double " y );
16 .br
17 .BI "float fminf(float " x ", float " y );
18 .br
19 .BI "long double fminl(long double " x ", long double " y );
20 .PP
21 Link with \fI\-lm\fP.
22 .PP
23 .in -4n
24 Feature Test Macro Requirements for glibc (see
25 .BR feature_test_macros (7)):
26 .in
27 .PP
28 .ad l
29 .BR fmin (),
30 .BR fminf (),
31 .BR fminl ():
32 .RS 4
33 _ISOC99_SOURCE || _POSIX_C_SOURCE\ >=\ 200112L
34 .RE
35 .ad
36 .SH DESCRIPTION
37 These functions return the lesser value of
38 .I x
39 and
40 .IR y .
41 .SH RETURN VALUE
42 These functions return the minimum of
43 .I x
44 and
45 .IR y .
46 .PP
47 If one argument is a NaN, the other argument is returned.
48 .PP
49 If both arguments are NaN, a NaN is returned.
50 .SH ERRORS
51 No errors occur.
52 .SH VERSIONS
53 These functions first appeared in glibc in version 2.1.
54 .SH ATTRIBUTES
55 For an explanation of the terms used in this section, see
56 .BR attributes (7).
57 .TS
58 allbox;
59 lbw24 lb lb
60 l l l.
61 Interface Attribute Value
62 T{
63 .BR fmin (),
64 .BR fminf (),
65 .BR fminl ()
66 T} Thread safety MT-Safe
67 .TE
68 .SH CONFORMING TO
69 C99, POSIX.1-2001, POSIX.1-2008.
70 .SH SEE ALSO
71 .BR fdim (3),
72 .BR fmax (3)