OSDN Git Service

(split) Convert release and draft pages to UTF-8.
[linuxjm/LDP_man-pages.git] / draft / man3 / remquo.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 .\" Distributed under GPL
5 .\" based on glibc infopages
6 .\" polished, aeb
7 .\"
8 .\" Japanese Version Copyright (c) 2005 Yuichi SATO
9 .\" and Copyright (c) 2008 Akihiro MOTOKI
10 .\" Translated Tue Feb  1 06:39:08 JST 2005
11 .\"         by Yuichi SATO <ysato444@yahoo.co.jp>
12 .\" Updated 2008-09-16, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
13 .\"
14 .TH REMQUO 3 2010-09-20 "GNU" "Linux Programmer's Manual"
15 .\"O .SH NAME
16 .SH 名前
17 .\"O remquo, remquof, remquol \- remainder and part of quotient
18 remquo, remquof, remquol \- 商の一部と剰余を求める
19 .\"O .SH SYNOPSIS
20 .SH 書式
21 .nf
22 .B #include <math.h>
23 .sp
24 .BI "double remquo(double " x ", double " y ", int *" quo );
25 .br
26 .BI "float remquof(float " x ", float " y ", int *" quo );
27 .br
28 .BI "long double remquol(long double " x ", long double " y ", int *" quo );
29 .fi
30 .sp
31 .\"O Link with \fI\-lm\fP.
32 \fI\-lm\fP でリンクする。
33 .sp
34 .in -4n
35 .\"O Feature Test Macro Requirements for glibc (see
36 .\"O .BR feature_test_macros (7)):
37 glibc 向けの機能検査マクロの要件
38 .RB ( feature_test_macros (7)
39 参照):
40 .in
41 .sp
42 .ad l
43 .BR remquo (),
44 .BR remquof (),
45 .BR remquol ():
46 .RS 4
47 _XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE ||
48 _POSIX_C_SOURCE\ >=\ 200112L;
49 .br
50 or
51 .I cc\ -std=c99
52 .RE
53 .ad
54 .\"O .SH DESCRIPTION
55 .SH 説明
56 .\"O These functions compute the remainder and part of the quotient
57 .\"O upon division of
58 .\"O .I x
59 .\"O by
60 .\"O .IR y .
61 これらの関数は
62 .I x
63
64 .I y
65 で割ったときの商の一部と剰余を計算する。
66 .\"O A few bits of the quotient are stored via the
67 .\"O .I quo
68 .\"O pointer.
69 .\"O The remainder is returned as the function result.
70 商のいくつかのビットが
71 .I quo
72 ポインタを使って格納される。
73 剰余は関数の結果として返される。
74
75 .\"O The value of the remainder is the same as that computed by the
76 .\"O .BR remainder (3)
77 .\"O function.
78 剰余の値は
79 .BR remainder (3)
80 関数で計算されるものと同じである。
81
82 .\"O The value stored via the
83 .\"O .I quo
84 .\"O pointer has the sign of
85 .\"O .IR "x\ /\ y"
86 .\"O and agrees with the quotient in at least the low order 3 bits.
87 .I quo
88 ポインタを使って格納される値には、
89 .I "x\ /\ y"
90 の符号と最低でも商の下位 3 ビットが含まれる。
91
92 .\"O For example, \fIremquo(29.0,\ 3.0)\fP returns \-1.0 and might store 2.
93 .\"O Note that the actual quotient might not fit in an integer.
94 たとえば \fIremquo(29.0,\ 3.0)\fP は \-1.0 を返し、
95 (訳注: quo の指しているものには) 2 が格納される。
96 実際の商が整数値にならない点に注意すること。
97 .\"O .\" A possible application of this function might be the computation
98 .\"O .\" of sin(x). Compute remquo(x, pi/2, &quo) or so.
99 .\" この関数を利用するアプリケーションとしては、
100 .\" sin(x) の計算などがあるかもしれない。
101 .\" sin(x) では remquo(x, pi/2, &quo) などを計算する。
102 .\"
103 .\"O .\" glibc, UnixWare: return 3 bits
104 .\"O .\" MacOS 10: return 7 bits
105 .\" glibc, UnixWare: 3 ビットを返す。
106 .\" MacOS 10: 7 ビットを返す。
107 .\"O .SH RETURN VALUE
108 .SH 返り値
109 .\"O On success, these functions return the same value as
110 .\"O the analogous functions described in
111 .\"O .BR remainder (3).
112 成功すると、これらの関数は
113 .BR remainder (3)
114 に書かれている同様の関数と同じ値を返す。
115
116 .\"O If
117 .\"O .I x
118 .\"O or
119 .\"O .I y
120 .\"O is a NaN, a NaN is returned.
121 .I x
122
123 .I y
124 が NaN の場合、NaN が返される。
125
126 .\"O If
127 .\"O .I x
128 .\"O is an infinity,
129 .\"O and
130 .\"O .I y
131 .\"O is not a NaN,
132 .\"O a domain error occurs, and
133 .\"O a NaN is returned.
134 .I x
135 が無限大で
136 .I y
137 が NaN でない場合、
138 領域エラー (domain error) が発生し、NaN が返される。
139
140 .\"O If
141 .\"O .I y
142 .\"O is zero,
143 .\"O and
144 .\"O .I x
145 .\"O is not a NaN,
146 .\"O a domain error occurs, and
147 .\"O a NaN is returned.
148 .I y
149 がゼロで
150 .I x
151 が NaN でない場合、
152 領域エラー (domain error) が発生し、NaN が返される。
153 .\"O .SH ERRORS
154 .SH エラー
155 .\"O See
156 .\"O .BR math_error (7)
157 .\"O for information on how to determine whether an error has occurred
158 .\"O when calling these functions.
159 これらの関数を呼び出した際にエラーが発生したかの判定方法についての情報は
160 .BR math_error (7)
161 を参照のこと。
162 .PP
163 .\"O The following errors can occur:
164 以下のエラーが発生する可能性がある。
165 .TP
166 .\"O Domain error: \fIx\fP is an infinity or \fIy\fP is 0, \
167 .\"O and the other argument is not a NaN
168 領域エラー (domain error): \fIx\fP が無限大か \fIy\fP が 0 で、 \
169 他の引き数が NaN でない
170 .\" .I errno
171 .\" is set to
172 .\" .BR EDOM .
173 .\"O An invalid floating-point exception
174 .\"O .RB ( FE_INVALID )
175 .\"O is raised.
176 不正 (invalid) 浮動小数点例外
177 .RB ( FE_INVALID )
178 が上がる。
179 .PP
180 .\"O These functions do not set
181 .\"O .IR errno .
182 これらの関数は
183 .I errno
184 を設定しない。
185 .\" FIXME . Is it intentional that these functions do not set errno?
186 .\" Bug raised: http://sources.redhat.com/bugzilla/show_bug.cgi?id=6802
187 .\"O .SH VERSIONS
188 .SH バージョン
189 .\"O These functions first appeared in glibc in version 2.1.
190 これらの関数は glibc バージョン 2.1 で初めて登場した。
191 .\"O .SH "CONFORMING TO"
192 .SH 準拠
193 C99, POSIX.1-2001.
194 .\"O .SH "SEE ALSO"
195 .SH 関連項目
196 .BR fmod (3),
197 .BR logb (3),
198 .BR remainder (3)