OSDN Git Service

Update draft pages
[linuxjm/LDP_man-pages.git] / draft / man3 / nextafter.3
index 15e8ee4..e2d62c8 100644 (file)
 .\" Copyright 2002 Walter Harms (walter.harms@informatik.uni-oldenburg.de)
 .\" and Copyright 2008, Linux Foundation, written by Michael Kerrisk
 .\"     <mtk.manpages@gmail.com>
+.\"
+.\" %%%LICENSE_START(GPL_NOVERSION_ONELINE)
 .\" Distributed under GPL
+.\" %%%LICENSE_END
+.\"
 .\" Based on glibc infopages
 .\"
+.\"*******************************************************************
+.\"
+.\" This file was generated with po4a. Translate the source file.
+.\"
+.\"*******************************************************************
+.\"
 .\" Japanese Version Copyright (c) 2003 Akihiro MOTOKI all rights reserved.
 .\" Translated Mon Jan 27 2003 by Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
 .\" Updated 2008-09-18, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
 .\"
-.\"WORD:       mantissa        ²¾¿ôÉô
-.\"WORD:       normalized      Àµµ¬²½¤µ¤ì¤¿
-.\"WORD:       subnormal       ÈóÀµµ¬²½¤Î
-.\"
-.TH NEXTAFTER 3 2010-09-20 "GNU" "Linux Programmer's Manual"
-.\"O .SH NAME
-.\"O nextafter, nextafterf, nextafterl, nexttoward, nexttowardf, nexttowardl \-
-.\"O floating-point number manipulation
-.SH Ì¾Á°
+.TH NEXTAFTER 3 2013\-09\-02 GNU "Linux Programmer's Manual"
+.SH 名前
 nextafter, nextafterf, nextafterl, nexttoward, nexttowardf, nexttowardl \-
-ÉâÆ°¾®¿ôÅÀ¿ô¤ÎÁàºî
-.\"O .SH SYNOPSIS
-.SH ½ñ¼°
-.B #include <math.h>
+浮動小数点数の操作
+.SH 書式
+\fB#include <math.h>\fP
 .sp
-.BI "double nextafter(double " x ", double " y );
+\fBdouble nextafter(double \fP\fIx\fP\fB, double \fP\fIy\fP\fB);\fP
 .br
-.BI "float nextafterf(float " x ", float " y );
+\fBfloat nextafterf(float \fP\fIx\fP\fB, float \fP\fIy\fP\fB);\fP
 .br
-.BI "long double nextafterl(long double " x ", long double " y );
+\fBlong double nextafterl(long double \fP\fIx\fP\fB, long double \fP\fIy\fP\fB);\fP
 .sp
-.BI "double nexttoward(double " x ", long double " y );
+\fBdouble nexttoward(double \fP\fIx\fP\fB, long double \fP\fIy\fP\fB);\fP
 .br
-.BI "float nexttowardf(float " x ", long double " y );
+\fBfloat nexttowardf(float \fP\fIx\fP\fB, long double \fP\fIy\fP\fB);\fP
 .br
-.BI "long double nexttowardl(long double " x ", long double " y );
+\fBlong double nexttowardl(long double \fP\fIx\fP\fB, long double \fP\fIy\fP\fB);\fP
 .sp
-.\"O Link with \fI\-lm\fP.
-\fI\-lm\fP ¤Ç¥ê¥ó¥¯¤¹¤ë¡£
+\fI\-lm\fP でリンクする。
 .sp
 .in -4n
-.\"O Feature Test Macro Requirements for glibc (see
-.\"O .BR feature_test_macros (7)):
-glibc ¸þ¤±¤Îµ¡Ç½¸¡ºº¥Þ¥¯¥í¤ÎÍ×·ï
-.RB ( feature_test_macros (7)
-»²¾È):
+glibc 向けの機能検査マクロの要件 (\fBfeature_test_macros\fP(7)  参照):
 .in
 .sp
 .ad l
-.BR nextafter ():
+\fBnextafter\fP():
 .RS 4
-_BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE\ >=\ 500 ||
-_XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTENDED ||
-_ISOC99_SOURCE ||
-_POSIX_C_SOURCE\ >=\ 200112L;
+_BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE\ >=\ 500 || _XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTENDED || _ISOC99_SOURCE || _POSIX_C_SOURCE\ >=\ 200112L;
 .br
-or
-.I cc\ -std=c99
+or \fIcc\ \-std=c99\fP
 .RE
 .br
-.BR nextafterf (),
-.BR nextafterl ():
+\fBnextafterf\fP(), \fBnextafterl\fP():
 .RS 4
-_BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE ||
-_POSIX_C_SOURCE\ >=\ 200112L;
+_BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE
+|| _POSIX_C_SOURCE\ >=\ 200112L;
 .br
-or
-.I cc\ -std=c99
+or \fIcc\ \-std=c99\fP
 .RE
 .br
-.BR nexttoward (),
-.BR nexttowardf (),
-.BR nexttowardl ():
+\fBnexttoward\fP(), \fBnexttowardf\fP(), \fBnexttowardl\fP():
 .RS 4
-_XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE ||
-_POSIX_C_SOURCE\ >=\ 200112L;
+_XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE || _POSIX_C_SOURCE\ >=\ 200112L;
 .br
-or
-.I cc\ -std=c99
+or \fIcc\ \-std=c99\fP
 .RE
 .ad b
-.\"O .SH DESCRIPTION
-.SH ÀâÌÀ
-.\"O The
-.\"O .BR nextafter ()
-.\"O functions return the next representable floating-point value following
-.\"O .I x
-.\"O in the direction of
-.\"O .IR y .
-.\"O If
-.\"O .I y
-.\"O is less than
-.\"O .IR x ,
-.\"O these functions will return the largest representable number less than
-.\"O .IR x .
-.BR nextafter ()
-´Ø¿ô·²¤Ï¡¢\fIy\fP ¤Ë¸þ¤«¤¦Êý¸þ¤Ç \fIx\fP ¤Î¤¹¤°¼¡¤ÎÉâÆ°¾®¿ôÅÀ¿ôɽ¸½¤òÊÖ¤¹¡£
-.I y
-¤¬
-.I x
-¤è¤ê¾®¤µ¤¤¾ì¹ç¡¢
-.I x
-¤è¤ê¾®¤µ¤¤ºÇÂç¤ÎÉâÆ°¾®¿ôÅÀɽ¸½¤ÎÃͤòÊÖ¤¹¡£
+.SH 説明
+関数 \fBnextafter\fP(), \fBnextafterf\fP(), \fBnextafterl\fP() は、\fIy\fP に向かう方向で \fIx\fP
+のすぐ次の浮動小数点数表現を返す。 \fIy\fP が \fIx\fP より小さい場合、 \fIx\fP より小さい最大の浮動小数点表現の値を返す。
 
-.\"O If \fIx\fP equals \fIy\fP, the functions return \fIy\fP.
-\fIx\fP ¤¬ \fIy\fP ¤ÈÅù¤·¤¤¾ì¹ç¡¢\fIy\fP ¤¬ÊÖ¤µ¤ì¤ë¡£
+\fIx\fP が \fIy\fP と等しい場合、\fIy\fP が返される。
 
-.\"O The
-.\"O .BR nexttoward ()
-.\"O functions do the same as the
-.\"O .BR nextafter ()
-.\"O functions, except that they have a
-.\"O .I "long double"
-.\"O second argument.
-.BR nexttoward ()
-´Ø¿ô·²¤Ï¡¢2 ÈÖÌܤΰú¤­¿ô¤¬
-.I long double
-·¿¤Ç¤¢¤ëÅÀ°Ê³°¡¢
-.BR nextafter ()
-´Ø¿ô·²¤ÈƱ¤¸¤Ï¤¿¤é¤­¤ò¤¹¤ë¡£
-.\"O .SH RETURN VALUE
-.SH ÊÖ¤êÃÍ
-.\"O On success,
-.\"O these functions return the next representable floating-point value after
-.\"O .I x
-.\"O in the direction of
-.\"O .IR y .
-À®¸ù¤¹¤ë¤È¡¢¤³¤ì¤é¤Î´Ø¿ô¤Ï \fIy\fP ¤Ë¸þ¤«¤¦Êý¸þ¤Ç \fIx\fP ¤Î
-¤¹¤°¼¡¤ÎÉâÆ°¾®¿ôÅÀ¿ôɽ¸½¤òÊÖ¤¹¡£
+関数 \fBnexttoward\fP(), \fBnexttowardf\fP(), \fBnexttowardl\fP() は、2 番目の引き数が \fIlong
+double\fP 型である点以外、 対応する \fBnextafter\fP() 関数と同じはたらきをする。
+.SH 返り値
+成功すると、これらの関数は \fIy\fP に向かう方向で \fIx\fP の すぐ次の浮動小数点数表現を返す。
 
-.\"O If
-.\"O .I x
-.\"O equals
-.\"O .IR y ,
-.\"O then
-.\"O .I y
-.\"O (cast to the same type as
-.\"O .IR x )
-.\"O is returned.
-.I x
-¤¬
-.I y
-¤ÈÅù¤·¤¤¾ì¹ç¡¢
-.RI ( x
-¤ÈƱ¤¸·¿¤Ë¥­¥ã¥¹¥È¤µ¤ì¤¿)
-.I y
-¤¬ÊÖ¤µ¤ì¤ë¡£
+\fIx\fP が \fIy\fP と等しい場合、 (\fIx\fP と同じ型にキャストされた)  \fIy\fP が返される。
 
-.\"O If
-.\"O .I x
-.\"O or
-.\"O .I y
-.\"O is a NaN,
-.\"O a NaN is returned.
-.I x
-¤«
-.I y
-¤¬ NaN ¤Î¾ì¹ç¡¢NaN ¤¬ÊÖ¤µ¤ì¤ë¡£
+\fIx\fP か \fIy\fP が NaN の場合、NaN が返される。
 
-.\"O If
-.\"O .I x
-.\"O is finite,
-.I x
-¤¬Í­¸ÂÃͤÇ
 .\" e.g., DBL_MAX
-.\"O and the result would overflow,
-.\"O a range error occurs,
-.\"O and the functions return
-.\"O .BR HUGE_VAL ,
-.\"O .BR HUGE_VALF ,
-.\"O or
-.\"O .BR HUGE_VALL ,
-.\"O respectively, with the correct mathematical sign.
-·ë²Ì¤¬¥ª¡¼¥Ð¡¼¥Õ¥í¡¼¤¹¤ë¾ì¹ç¡¢
-ÈÏ°Ï¥¨¥é¡¼ (range error) ¤¬È¯À¸¤·¡¢
-³Æ´Ø¿ô¤Ï¤½¤ì¤¾¤ì
-.BR HUGE_VAL ,
-.BR HUGE_VALF ,
-.B HUGE_VALL
-¤òÊÖ¤¹¡£ÊÖ¤êÃͤˤϿô³ØŪ¤ËÀµ¤·¤¤Éä¹æ¤¬ÉÕÍ¿¤µ¤ì¤ë¡£
+\fIx\fP が有限値で 結果がオーバーフローする場合、 範囲エラー (range error) が発生し、 各関数はそれぞれ \fBHUGE_VAL\fP,
+\fBHUGE_VALF\fP, \fBHUGE_VALL\fP を返す。返り値には数学的に正しい符号が付与される。
 
-.\"O If
-.\"O .I x
-.\"O is not equal to
-.\"O .IR y ,
-.\"O and the correct function result would be subnormal, zero, or underflow,
-.\"O a range error occurs,
-.\"O and either the correct value (if it can be represented),
-.\"O or 0.0, is returned.
-.I x
-¤¬
-.I y
-¤ÈƱ¤¸¤Ç¤Ï¤Ê¤¯¡¢Àµ¤·¤¤´Ø¿ô¤Î·ë²Ì¤¬ÈóÀµµ¬²½¿ô¤«¥¼¥í¤«¥¢¥ó¥À¡¼¥Õ¥í¡¼¤Î¾ì¹ç¡¢
-ÈÏ°Ï¥¨¥é¡¼¤¬È¯À¸¤·¡¢
-(ɽ¸½²Äǽ¤Ê¾ì¹ç¤Ë¤Ï) Àµ¤·¤¤Ãͤ¬¡¢(¤½¤¦¤Ç¤Ê¤¤¾ì¹ç¤Ë¤Ï) 0.0 ¤¬ÊÖ¤µ¤ì¤ë¡£
-.\"O .SH ERRORS
-.SH ¥¨¥é¡¼
-.\"O See
-.\"O .BR math_error (7)
-.\"O for information on how to determine whether an error has occurred
-.\"O when calling these functions.
-¤³¤ì¤é¤Î´Ø¿ô¤ò¸Æ¤Ó½Ð¤·¤¿ºÝ¤Ë¥¨¥é¡¼¤¬È¯À¸¤·¤¿¤«¤ÎȽÄêÊýË¡¤Ë¤Ä¤¤¤Æ¤Î¾ðÊó¤Ï
-.BR math_error (7)
-¤ò»²¾È¤Î¤³¤È¡£
+\fIx\fP が \fIy\fP と同じではなく、正しい関数の結果が非正規化数かゼロかアンダーフローの場合、 範囲エラーが発生し、 (表現可能な場合には)
+正しい値が、(そうでない場合には) 0.0 が返される。
+.SH エラー
+これらの関数を呼び出した際にエラーが発生したかの判定方法についての情報は \fBmath_error\fP(7)  を参照のこと。
 .PP
-.\"O The following errors can occur:
-°Ê²¼¤Î¥¨¥é¡¼¤¬È¯À¸¤¹¤ë²ÄǽÀ­¤¬¤¢¤ë¡£
-.TP
-.\"O Range error: result overflow
-ÈÏ°Ï¥¨¥é¡¼: ·ë²Ì¤Î¥ª¡¼¥Ð¡¼¥Õ¥í¡¼
+以下のエラーが発生する可能性がある。
+.TP 
+範囲エラー (range error): 結果のオーバーフロー
 .\" e.g., nextafter(DBL_MAX, HUGE_VAL);
 .\" .I errno
 .\" is set to
 .\" .BR ERANGE .
-.\"O An overflow floating-point exception
-.\"O .RB ( FE_OVERFLOW )
-.\"O is raised.
-¥ª¡¼¥Ð¡¼¥Õ¥í¡¼ÉâÆ°¾®¿ôÅÀÎã³°
-.RB ( FE_OVERFLOW )
-¤¬¾å¤¬¤ë¡£
-.TP
-.\"O Range error: result is subnormal or underflows
-ÈÏ°Ï¥¨¥é¡¼: ·ë²Ì¤¬ÈóÀµµ¬²½¿ô¤«¥¢¥ó¥À¡¼¥Õ¥í¡¼
+オーバーフロー浮動小数点例外 (\fBFE_OVERFLOW\fP)  が上がる。
+.TP 
+範囲エラー: 結果が非正規化数かアンダーフロー
 .\" e.g., nextafter(DBL_MIN, 0.0);
 .\" .I errno
 .\" is set to
 .\" .BR ERANGE .
-.\"O An underflow floating-point exception
-.\"O .RB ( FE_UNDERFLOW )
-.\"O is raised.
-¥¢¥ó¥À¡¼¥Õ¥í¡¼ÉâÆ°¾®¿ôÅÀÎã³°
-.RB ( FE_UNDERFLOW )
-¤¬¾å¤¬¤ë¡£
+アンダーフロー浮動小数点例外 (\fBFE_UNDERFLOW\fP)  が上がる。
 .PP
-.\"O These functions do not set
-.\"O .IR errno .
-¤³¤ì¤é¤Î´Ø¿ô¤Ï
-.I errno
-¤òÀßÄꤷ¤Ê¤¤¡£
 .\" FIXME . Is it intentional that these functions do not set errno?
 .\" Bug raised: http://sources.redhat.com/bugzilla/show_bug.cgi?id=6799
-.\"O .SH "CONFORMING TO"
-.SH ½àµò
-C99, POSIX.1-2001.
-.\"O This function is defined in IEC 559 (and the appendix with
-.\"O recommended functions in IEEE 754/IEEE 854).
-¤³¤Î´Ø¿ô¤Ï IEC 559 ¤ÇÄêµÁ¤µ¤ì¤Æ¤¤¤ë¡£
-(¤Þ¤¿ IEEE 754/IEEE 854 ¤Ç¤ÏÉÕÏ¿¤Ç¿ä¾©´Ø¿ô¤È¤·¤ÆÄêµÁ¤µ¤ì¤Æ¤¤¤ë)
-.\"O .SH BUGS
-.SH ¥Ð¥°
-.\"O In glibc version 2.5 and earlier, these functions do not raise an underflow
-.\"O floating-point
-.\"O .RB ( FE_UNDERFLOW )
-.\"O exception when an underflow occurs.
-glibc ¥Ð¡¼¥¸¥ç¥ó 2.5 °ÊÁ°¤Ç¤Ï¡¢¥¢¥ó¥À¡¼¥Õ¥í¡¼¤¬È¯À¸¤·¤¿ºÝ¤Ë¡¢
-¤³¤ì¤é¤Î´Ø¿ô¤Ï¥¢¥ó¥À¡¼¥Õ¥í¡¼ÉâÆ°¾®¿ôÅÀÎã³°
-.RB ( FE_UNDERFLOW )
-¤ò¾å¤¬¤Ê¤¤¡£
-.\"O .SH "SEE ALSO"
-.SH ´ØÏ¢¹àÌÜ
-.BR nearbyint (3)
+これらの関数は \fIerrno\fP を設定しない。
+.SH 属性
+.SS "マルチスレッディング (pthreads(7) 参照)"
+関数 \fBnextafter\fP(), \fBnextafterf\fP(), \fBnextafterl\fP(), \fBnexttoward\fP(),
+\fBnexttowardf\fP(), \fBnexttowardl\fP() はスレッドセーフである。
+.SH 準拠
+C99, POSIX.1\-2001.  この関数は IEC 559 で定義されている (また IEEE 754/IEEE 854
+では付録で推奨関数として定義されている)。
+.SH バグ
+glibc バージョン 2.5 以前では、アンダーフローが発生した際に、 これらの関数はアンダーフロー浮動小数点例外 (\fBFE_UNDERFLOW\fP)
+を上がない。
+.SH 関連項目
+\fBnearbyint\fP(3)
+.SH この文書について
+この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.78 の一部
+である。プロジェクトの説明とバグ報告に関する情報は
+http://www.kernel.org/doc/man\-pages/ に書かれている。