OSDN Git Service

(split) LDP v3.30, v3.31 の定型的な変更内容を反映。
[linuxjm/LDP_man-pages.git] / draft / man3 / fdim.3
1 .\" Copyright 2003 Walter Harms, Andries Brouwer
2 .\" and Copyright 2008, Linux Foundation, written by Michael Kerrisk
3 .\"     <mtk.manpages@gmail.com>
4 .\" Distributed under GPL.
5 .\"
6 .\" Japanese Version Copyright (c) 2004-2005 Yuichi SATO
7 .\"         all rights reserved.
8 .\" Translated Sat Jul 24 10:14:17 JST 2004
9 .\"         by Yuichi SATO <ysato444@yahoo.co.jp>
10 .\" Updated & Modified Mon Jan 10 08:17:08 JST 2005 by Yuichi SATO
11 .\" Updated 2008-09-16, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
12 .\"
13 .TH FDIM 3 2010-09-20 "" "Linux Programmer's Manual"
14 .\"O .SH NAME
15 .SH Ì¾Á°
16 .\"O fdim, fdimf, fdiml \- positive difference
17 fdim, fdimf, fdiml \- Àµ¤Îº¹Ê¬¤ò·×»»¤¹¤ë
18 .\"O .SH SYNOPSIS
19 .SH ½ñ¼°
20 .B #include <math.h>
21 .sp
22 .BI "double fdim(double " x ", double " y );
23 .br
24 .BI "float fdimf(float " x ", float " y );
25 .br
26 .BI "long double fdiml(long double " x ", long double " y );
27 .sp
28 .\"O Link with \fI\-lm\fP.
29 \fI-lm\fP ¤Ç¥ê¥ó¥¯¤¹¤ë¡£
30 .sp
31 .in -4n
32 .\"O Feature Test Macro Requirements for glibc (see
33 .\"O .BR feature_test_macros (7)):
34 glibc ¸þ¤±¤Îµ¡Ç½¸¡ºº¥Þ¥¯¥í¤ÎÍ×·ï
35 .RB ( feature_test_macros (7)
36 »²¾È):
37 .in
38 .sp
39 .ad l
40 .BR fdimf (),
41 .BR fdiml ():
42 .RS 4
43 _XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE ||
44 _POSIX_C_SOURCE\ >=\ 200112L;
45 .br
46 or
47 .I cc\ -std=c99
48 .RE
49 .ad
50 .\"O .SH DESCRIPTION
51 .SH ÀâÌÀ
52 .\"O These functions return the positive difference, max(\fIx\fP-\fIy\fP,0),
53 .\"O between their arguments.
54 ¤³¤ì¤é¤Î´Ø¿ô¤Ï¡¢Æó¤Ä¤Î°ú¤­¿ô´Ö¤ÎÀµ¤Îº¹Ê¬ max(\fIx\fP-\fIy\fP,0) ¤òÊÖ¤¹¡£
55 .\"O .SH RETURN VALUE
56 .SH ÊÖ¤êÃÍ
57 .\"O On success, these functions return the positive difference.
58 À®¸ù¤¹¤ë¤È¡¢¤³¤ì¤é¤Î´Ø¿ô¤ÏÀµ¤Îº¹Ê¬¤òÊÖ¤¹¡£
59
60 .\"O If
61 .\"O .I x
62 .\"O or
63 .\"O .I y
64 .\"O is a NaN, a NaN is returned.
65 .I x
66 ¤«
67 .I y
68 ¤¬ NaN ¤Î¾ì¹ç¡¢NaN ¤¬ÊÖ¤µ¤ì¤ë¡£
69
70 .\"O If the result overflows,
71 .\"O a range error occurs,
72 .\"O and the functions return
73 .\"O .BR HUGE_VAL ,
74 .\"O .BR HUGE_VALF ,
75 .\"O or
76 .\"O .BR HUGE_VALL ,
77 .\"O respectively.
78 ·ë²Ì¤¬¥ª¡¼¥Ð¡¼¥Õ¥í¡¼¤¹¤ë¾ì¹ç¡¢ÈÏ°Ï¥¨¥é¡¼¤¬È¯À¸¤·¡¢
79 ³Æ´Ø¿ô¤Ï¤½¤ì¤¾¤ì
80 .BR HUGE_VAL ,
81 .BR HUGE_VALF ,
82 .B HUGE_VALL
83 ¤òÊÖ¤¹¡£
84 .\"O .SH ERRORS
85 .SH ¥¨¥é¡¼
86 .\"O See
87 .\"O .BR math_error (7)
88 .\"O for information on how to determine whether an error has occurred
89 .\"O when calling these functions.
90 ¤³¤ì¤é¤Î´Ø¿ô¤ò¸Æ¤Ó½Ð¤·¤¿ºÝ¤Ë¥¨¥é¡¼¤¬È¯À¸¤·¤¿¤«¤ÎȽÄêÊýË¡¤Ë¤Ä¤¤¤Æ¤Î¾ðÊó¤Ï
91 .BR math_error (7)
92 ¤ò»²¾È¤Î¤³¤È¡£
93 .PP
94 .\"O The following errors can occur:
95 °Ê²¼¤Î¥¨¥é¡¼¤¬È¯À¸¤¹¤ë²ÄǽÀ­¤¬¤¢¤ë¡£
96 .TP
97 .\"O Range error: result overflow
98 ÈÏ°Ï¥¨¥é¡¼ (range error)¡¢¥ª¡¼¥Ð¡¼¥Õ¥í¡¼¤Î¾ì¹ç
99 .\" .I errno
100 .\" is set to
101 .\" .BR ERANGE .
102 .\"O An overflow floating-point exception
103 .\"O .RB ( FE_OVERFLOW )
104 .\"O is raised.
105 ¥ª¡¼¥Ð¡¼¥Õ¥í¡¼ÉâÆ°¾®¿ôÅÀÎã³°
106 .RB ( FE_OVERFLOW )
107 ¤¬¾å¤¬¤ë¡£
108 .PP
109 .\"O These functions do not set
110 .\"O .IR errno .
111 ¤³¤ì¤é¤Î´Ø¿ô¤Ï
112 .I errno
113 ¤òÀßÄꤷ¤Ê¤¤¡£
114 .\" FIXME . Is it intentional that these functions do not set errno?
115 .\" Bug raised: http://sources.redhat.com/bugzilla/show_bug.cgi?id=6796
116 .\"O .SH VERSIONS
117 .SH ¥Ð¡¼¥¸¥ç¥ó
118 .\"O These functions first appeared in glibc in version 2.1.
119 ¤³¤ì¤é¤Î´Ø¿ô¤Ï glibc ¥Ð¡¼¥¸¥ç¥ó 2.1 ¤Ç½é¤á¤ÆÅо줷¤¿¡£
120 .\"O .SH "CONFORMING TO"
121 .SH ½àµò
122 C99, POSIX.1-2001.
123 .\"O .SH "SEE ALSO"
124 .SH ´ØÏ¢¹àÌÜ
125 .BR fmax (3)