亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? library_18.html

?? Glibc的中文手冊
?? HTML
?? 第 1 頁 / 共 2 頁
字號:
<!-- This HTML file has been created by texi2html 1.27
     from library.texinfo on 3 March 1994 -->

<TITLE>The GNU C Library - Low-Level Arithmetic Functions</TITLE>
<P>Go to the <A HREF="library_17.html" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_17.html">previous</A>, <A HREF="library_19.html" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_19.html">next</A> section.<P>
<H1><A NAME="SEC299" HREF="library_toc.html#SEC299" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_toc.html#SEC299">Low-Level Arithmetic Functions</A></H1>
<P>
This chapter contains information about functions for doing basic
arithmetic operations, such as splitting a float into its integer and
fractional parts.  These functions are declared in the header file
<TT>`math.h'</TT>.
<P>
<A NAME="IDX1294"></A>
<A NAME="IDX1295"></A>
<A NAME="IDX1296"></A>
<H2><A NAME="SEC300" HREF="library_toc.html#SEC300" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_toc.html#SEC300">"Not a Number" Values</A></H2>
<P>
The IEEE floating point format used by most modern computers supports
values that are "not a number".  These values are called <DFN>NaNs</DFN>.
"Not a number" values result from certain operations which have no
meaningful numeric result, such as zero divided by zero or infinity
divided by infinity.
<P>
One noteworthy property of NaNs is that they are not equal to
themselves.  Thus, <CODE>x == x</CODE> can be 0 if the value of <CODE>x</CODE> is a
NaN.  You can use this to test whether a value is a NaN or not: if it is
not equal to itself, then it is a NaN.  But the recommended way to test
for a NaN is with the <CODE>isnan</CODE> function (see section <A HREF="library_18.html#SEC301" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_18.html#SEC301">Predicates on Floats</A>).
<P>
Almost any arithmetic operation in which one argument is a NaN returns
a NaN.
<P>
<A NAME="IDX1297"></A>
<U>Macro:</U> double <B>NAN</B><P>
An expression representing a value which is "not a number".  This
macro is a GNU extension, available only on machines that support "not
a number" values--that is to say, on all machines that support IEEE
floating point.
<P>
You can use <SAMP>`#ifdef NAN'</SAMP> to test whether the machine supports
NaNs.  (Of course, you must arrange for GNU extensions to be visible,
such as by defining <CODE>_GNU_SOURCE</CODE>, and then you must include
<TT>`math.h'</TT>.)
<P>
<H2><A NAME="SEC301" HREF="library_toc.html#SEC301" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_toc.html#SEC301">Predicates on Floats</A></H2>
<A NAME="IDX1298"></A>
<P>
This section describes some miscellaneous test functions on doubles.
Prototypes for these functions appear in <TT>`math.h'</TT>.  These are BSD
functions, and thus are available if you define <CODE>_BSD_SOURCE</CODE> or
<CODE>_GNU_SOURCE</CODE>.
<P>
<A NAME="IDX1299"></A>
<U>Function:</U> int <B>isinf</B> <I>(double <VAR>x</VAR>)</I><P>
This function returns <CODE>-1</CODE> if <VAR>x</VAR> represents negative infinity,
<CODE>1</CODE> if <VAR>x</VAR> represents positive infinity, and <CODE>0</CODE> otherwise.
<P>
<A NAME="IDX1300"></A>
<U>Function:</U> int <B>isnan</B> <I>(double <VAR>x</VAR>)</I><P>
This function returns a nonzero value if <VAR>x</VAR> is a "not a number"
value, and zero otherwise.  (You can just as well use <CODE><VAR>x</VAR> !=
<VAR>x</VAR></CODE> to get the same result).
<P>
<A NAME="IDX1301"></A>
<U>Function:</U> int <B>finite</B> <I>(double <VAR>x</VAR>)</I><P>
This function returns a nonzero value if <VAR>x</VAR> is finite or a "not a
number" value, and zero otherwise.
<P>
<A NAME="IDX1302"></A>
<U>Function:</U> double <B>infnan</B> <I>(int <VAR>error</VAR>)</I><P>
This function is provided for compatibility with BSD.  The other
mathematical functions use <CODE>infnan</CODE> to decide what to return on
occasion of an error.  Its argument is an error code, <CODE>EDOM</CODE> or
<CODE>ERANGE</CODE>; <CODE>infnan</CODE> returns a suitable value to indicate this
with.  <CODE>-ERANGE</CODE> is also acceptable as an argument, and corresponds
to <CODE>-HUGE_VAL</CODE> as a value.
<P>
In the BSD library, on certain machines, <CODE>infnan</CODE> raises a fatal
signal in all cases.  The GNU library does not do likewise, because that
does not fit the ANSI C specification.
<P>
<STRONG>Portability Note:</STRONG> The functions listed in this section are BSD
extensions.
<P>
<A NAME="IDX1303"></A>
<H2><A NAME="SEC302" HREF="library_toc.html#SEC302" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_toc.html#SEC302">Absolute Value</A></H2>
<P>
These functions are provided for obtaining the <DFN>absolute value</DFN> (or
<DFN>magnitude</DFN>) of a number.  The absolute value of a real number
<VAR>x</VAR> is <VAR>x</VAR> is <VAR>x</VAR> is positive, -<VAR>x</VAR> if <VAR>x</VAR> is
negative.  For a complex number <VAR>z</VAR>, whose real part is <VAR>x</VAR> and
whose imaginary part is <VAR>y</VAR>, the absolute value is <CODE>sqrt
(<VAR>x</VAR>*<VAR>x</VAR> + <VAR>y</VAR>*<VAR>y</VAR>)</CODE>.
<A NAME="IDX1304"></A>
<A NAME="IDX1305"></A>
<P>
Prototypes for <CODE>abs</CODE> and <CODE>labs</CODE> are in <TT>`stdlib.h'</TT>;
<CODE>fabs</CODE> and <CODE>cabs</CODE> are declared in <TT>`math.h'</TT>.
<P>
<A NAME="IDX1306"></A>
<U>Function:</U> int <B>abs</B> <I>(int <VAR>number</VAR>)</I><P>
This function returns the absolute value of <VAR>number</VAR>.
<P>
Most computers use a two's complement integer representation, in which
the absolute value of <CODE>INT_MIN</CODE> (the smallest possible <CODE>int</CODE>)
cannot be represented; thus, <CODE>abs (INT_MIN)</CODE> is not defined.
<P>
<A NAME="IDX1307"></A>
<U>Function:</U> long int <B>labs</B> <I>(long int <VAR>number</VAR>)</I><P>
This is similar to <CODE>abs</CODE>, except that both the argument and result
are of type <CODE>long int</CODE> rather than <CODE>int</CODE>.
<P>
<A NAME="IDX1308"></A>
<U>Function:</U> double <B>fabs</B> <I>(double <VAR>number</VAR>)</I><P>
This function returns the absolute value of the floating-point number
<VAR>number</VAR>.
<P>
<A NAME="IDX1309"></A>
<U>Function:</U> double <B>cabs</B> <I>(struct { double real, imag; } <VAR>z</VAR>)</I><P>
The <CODE>cabs</CODE> function returns the absolute value of the complex
number <VAR>z</VAR>, whose real part is <CODE><VAR>z</VAR>.real</CODE> and whose
imaginary part is <CODE><VAR>z</VAR>.imag</CODE>.  (See also the function
<CODE>hypot</CODE> in section <A HREF="library_17.html#SEC294" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_17.html#SEC294">Exponentiation and Logarithms</A>.)  The value is:
<P>
<PRE>
sqrt (<VAR>z</VAR>.real*<VAR>z</VAR>.real + <VAR>z</VAR>.imag*<VAR>z</VAR>.imag)
</PRE>
<P>
<A NAME="IDX1310"></A>
<H2><A NAME="SEC303" HREF="library_toc.html#SEC303" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_toc.html#SEC303">Normalization Functions</A></H2>
<P>
The functions described in this section are primarily provided as a way
to efficiently perform certain low-level manipulations on floating point
numbers that are represented internally using a binary radix;
see section <A HREF="library_28.html#SEC488" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_28.html#SEC488">Floating Point Representation Concepts</A>.  These functions are required to
have equivalent behavior even if the representation does not use a radix
of 2, but of course they are unlikely to be particularly efficient in
those cases.
<A NAME="IDX1311"></A>
<P>
All these functions are declared in <TT>`math.h'</TT>.
<P>
<A NAME="IDX1312"></A>
<U>Function:</U> double <B>frexp</B> <I>(double <VAR>value</VAR>, int *<VAR>exponent</VAR>)</I><P>
The <CODE>frexp</CODE> function is used to split the number <VAR>value</VAR>
into a normalized fraction and an exponent.
<P>
If the argument <VAR>value</VAR> is not zero, the return value is <VAR>value</VAR>
times a power of two, and is always in the range 1/2 (inclusive) to 1
(exclusive).  The corresponding exponent is stored in
<CODE>*<VAR>exponent</VAR></CODE>; the return value multiplied by 2 raised to this
exponent equals the original number <VAR>value</VAR>.
<P>
For example, <CODE>frexp (12.8, &#38;exponent)</CODE> returns <CODE>0.8</CODE> and
stores <CODE>4</CODE> in <CODE>exponent</CODE>.
<P>
If <VAR>value</VAR> is zero, then the return value is zero and
zero is stored in <CODE>*<VAR>exponent</VAR></CODE>.
<P>
<A NAME="IDX1313"></A>
<U>Function:</U> double <B>ldexp</B> <I>(double <VAR>value</VAR>, int <VAR>exponent</VAR>)</I><P>
This function returns the result of multiplying the floating-point
number <VAR>value</VAR> by 2 raised to the power <VAR>exponent</VAR>.  (It can
be used to reassemble floating-point numbers that were taken apart
by <CODE>frexp</CODE>.)
<P>
For example, <CODE>ldexp (0.8, 4)</CODE> returns <CODE>12.8</CODE>.
<P>
The following functions which come from BSD provide facilities
equivalent to those of <CODE>ldexp</CODE> and <CODE>frexp</CODE>:
<P>
<A NAME="IDX1314"></A>
<U>Function:</U> double <B>scalb</B> <I>(double <VAR>value</VAR>, int <VAR>exponent</VAR>)</I><P>
The <CODE>scalb</CODE> function is the BSD name for <CODE>ldexp</CODE>.
<P>
<A NAME="IDX1315"></A>
<U>Function:</U> double <B>logb</B> <I>(double <VAR>x</VAR>)</I><P>
This BSD function returns the integer part of the base-2 logarithm of
<VAR>x</VAR>, an integer value represented in type <CODE>double</CODE>.  This is
the highest integer power of <CODE>2</CODE> contained in <VAR>x</VAR>.  The sign of
<VAR>x</VAR> is ignored.  For example, <CODE>logb (3.5)</CODE> is <CODE>1.0</CODE> and
<CODE>logb (4.0)</CODE> is <CODE>2.0</CODE>.
<P>
When <CODE>2</CODE> raised to this power is divided into <VAR>x</VAR>, it gives a
quotient between <CODE>1</CODE> (inclusive) and <CODE>2</CODE> (exclusive).
<P>
If <VAR>x</VAR> is zero, the value is minus infinity (if the machine supports
such a value), or else a very small number.  If <VAR>x</VAR> is infinity, the
value is infinity.
<P>
The value returned by <CODE>logb</CODE> is one less than the value that
<CODE>frexp</CODE> would store into <CODE>*<VAR>exponent</VAR></CODE>.
<P>
<A NAME="IDX1316"></A>
<U>Function:</U> double <B>copysign</B> <I>(double <VAR>value</VAR>, double <VAR>sign</VAR>)</I><P>
The <CODE>copysign</CODE> function returns a value whose absolute value is the
same as that of <VAR>value</VAR>, and whose sign matches that of <VAR>sign</VAR>.
This is a BSD function.
<P>
<A NAME="IDX1317"></A>
<A NAME="IDX1318"></A>
<A NAME="IDX1319"></A>
<H2><A NAME="SEC304" HREF="library_toc.html#SEC304" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_toc.html#SEC304">Rounding and Remainder Functions</A></H2>
<A NAME="IDX1320"></A>
<P>
The functions listed here perform operations such as rounding,
truncation, and remainder in division of floating point numbers.  Some
of these functions convert floating point numbers to integer values.
They are all declared in <TT>`math.h'</TT>.
<P>
You can also convert floating-point numbers to integers simply by
casting them to <CODE>int</CODE>.  This discards the fractional part,
effectively rounding towards zero.  However, this only works if the
result can actually be represented as an <CODE>int</CODE>---for very large
numbers, this is impossible.  The functions listed here return the
result as a <CODE>double</CODE> instead to get around this problem.
<P>
<A NAME="IDX1321"></A>
<U>Function:</U> double <B>ceil</B> <I>(double <VAR>x</VAR>)</I><P>
The <CODE>ceil</CODE> function rounds <VAR>x</VAR> upwards to the nearest integer,
returning that value as a <CODE>double</CODE>.  Thus, <CODE>ceil (1.5)</CODE>
is <CODE>2.0</CODE>.
<P>
<A NAME="IDX1322"></A>
<U>Function:</U> double <B>floor</B> <I>(double <VAR>x</VAR>)</I><P>
The <CODE>ceil</CODE> function rounds <VAR>x</VAR> downwards to the nearest
integer, returning that value as a <CODE>double</CODE>.  Thus, <CODE>floor
(1.5)</CODE> is <CODE>1.0</CODE> and <CODE>floor (-1.5)</CODE> is <CODE>-2.0</CODE>.
<P>
<A NAME="IDX1323"></A>
<U>Function:</U> double <B>rint</B> <I>(double <VAR>x</VAR>)</I><P>
This function rounds <VAR>x</VAR> to an integer value according to the
current rounding mode.  See section <A HREF="library_28.html#SEC489" tppabs="http://www.cs.utah.edu/dept/old/texinfo/glibc-manual-0.02/library_28.html#SEC489">Floating Point Parameters</A>, for
information about the various rounding modes.  The default
rounding mode is to round to the nearest integer; some machines
support other modes, but round-to-nearest is always used unless
you explicit select another.
<P>
<A NAME="IDX1324"></A>
<U>Function:</U> double <B>modf</B> <I>(double <VAR>value</VAR>, double *<VAR>integer_part</VAR>)</I><P>
This function breaks the argument <VAR>value</VAR> into an integer part and a
fractional part (between <CODE>-1</CODE> and <CODE>1</CODE>, exclusive).  Their sum
equals <VAR>value</VAR>.  Each of the parts has the same sign as <VAR>value</VAR>,
so the rounding of the integer part is towards zero.
<P>
<CODE>modf</CODE> stores the integer part in <CODE>*<VAR>integer_part</VAR></CODE>, and
returns the fractional part.  For example, <CODE>modf (2.5, &#38;intpart)</CODE>
returns <CODE>0.5</CODE> and stores <CODE>2.0</CODE> into <CODE>intpart</CODE>.
<P>
<A NAME="IDX1325"></A>
<U>Function:</U> double <B>fmod</B> <I>(double <VAR>numerator</VAR>, double <VAR>denominator</VAR>)</I><P>
This function computes the remainder of dividing <VAR>numerator</VAR> by
<VAR>denominator</VAR>.  Specifically, the return value is
<CODE><VAR>numerator</VAR> - <VAR>n</VAR> * <VAR>denominator</VAR></CODE>, where <VAR>n</VAR>
is the quotient of <VAR>numerator</VAR> divided by <VAR>denominator</VAR>, rounded
towards zero to an integer.  Thus, <CODE>fmod (6.5, 2.3)</CODE> returns
<CODE>1.9</CODE>, which is <CODE>6.5</CODE> minus <CODE>4.6</CODE>.
<P>
The result has the same sign as the <VAR>numerator</VAR> and has magnitude
less than the magnitude of the <VAR>denominator</VAR>.
<P>
If <VAR>denominator</VAR> is zero, <CODE>fmod</CODE> fails and sets <CODE>errno</CODE> to
<CODE>EDOM</CODE>.
<P>
<A NAME="IDX1326"></A>
<U>Function:</U> double <B>drem</B> <I>(double <VAR>numerator</VAR>, double <VAR>denominator</VAR>)</I><P>
The function <CODE>drem</CODE> is like <CODE>fmod</CODE> except that it rounds the
internal quotient <VAR>n</VAR> to the nearest integer instead of towards zero
to an integer.  For example, <CODE>drem (6.5, 2.3)</CODE> returns <CODE>-0.4</CODE>,

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲五月六月丁香激情| 欧美日韩国产片| 国产日韩亚洲欧美综合| 国产精品一区二区无线| 亚洲精品一区在线观看| 九色综合狠狠综合久久| 久久久久久久久久久久久女国产乱| 久久精品国产99国产| 欧美精品一区二区三区高清aⅴ| 国产一区高清在线| 中文字幕乱码亚洲精品一区| 91网站黄www| 亚洲444eee在线观看| 欧美成人精品1314www| 成人爽a毛片一区二区免费| 亚洲人成在线播放网站岛国| 欧美美女激情18p| 精品一二三四在线| 日韩伦理av电影| 欧美午夜片在线看| 激情综合亚洲精品| 一区二区三区精品久久久| 欧美剧情片在线观看| 国产乱码精品一品二品| 亚洲欧美国产77777| 91精品国产麻豆| 国产不卡在线视频| 亚洲一卡二卡三卡四卡五卡| 欧美v日韩v国产v| 91影院在线免费观看| 免费成人在线观看视频| 国产精品久久久久久福利一牛影视 | 丝袜美腿高跟呻吟高潮一区| 欧美电视剧在线看免费| 99久久免费国产| 免费观看日韩电影| 一区二区三区中文免费| 久久精品夜夜夜夜久久| 在线观看精品一区| 国产精品18久久久久久久久 | 欧美一区二区日韩| 不卡在线观看av| 久久国产精品72免费观看| 亚洲欧洲综合另类在线| 久久亚洲欧美国产精品乐播| 欧美三级日韩在线| 97久久精品人人做人人爽50路| 麻豆国产欧美日韩综合精品二区| 最新久久zyz资源站| 欧美videos中文字幕| 欧美日韩专区在线| 99精品在线观看视频| 国产美女一区二区三区| 日本va欧美va欧美va精品| 亚洲精品va在线观看| 国产日韩欧美精品一区| 日韩欧美电影一二三| 欧美日韩成人综合| 欧洲精品视频在线观看| www.成人在线| 成人少妇影院yyyy| 国产在线精品视频| 蜜臀久久99精品久久久久宅男| 亚洲一区二区三区精品在线| 国产精品夫妻自拍| 中文字幕乱码亚洲精品一区 | 99麻豆久久久国产精品免费 | 国产精品综合在线视频| 午夜成人免费电影| 午夜久久福利影院| 亚洲成在人线在线播放| 亚洲国产一区二区a毛片| 亚洲欧洲精品一区二区三区 | 91久久精品国产91性色tv| 99久久伊人精品| 成人av网站在线| 成人av动漫网站| 成年人国产精品| 成人av资源站| 99久精品国产| 欧美丝袜丝交足nylons| 欧美日本韩国一区二区三区视频| 欧美日韩大陆一区二区| 日韩一区二区电影网| 日韩一区二区在线看| 欧美一级电影网站| 久久综合色之久久综合| 国产日韩亚洲欧美综合| 成人欧美一区二区三区在线播放| 亚洲视频每日更新| 亚洲高清免费观看高清完整版在线观看| 亚洲一区自拍偷拍| 亚洲一区中文在线| 秋霞电影一区二区| 国产做a爰片久久毛片| 国产91精品一区二区麻豆亚洲| 国产成人aaaa| 91黄色激情网站| 欧美一区二区网站| 欧美精品一区二区三区一线天视频| 久久蜜桃香蕉精品一区二区三区| 中文一区在线播放| 一区二区三区在线免费| 日本午夜一区二区| 成人深夜在线观看| 欧美性受xxxx| 2014亚洲片线观看视频免费| 国产欧美日本一区视频| 亚洲综合视频网| 国产一区二区中文字幕| 色综合久久99| 日韩一级精品视频在线观看| 中文字幕的久久| 亚洲图片自拍偷拍| 国产电影一区在线| 欧美日韩综合不卡| 国产欧美日韩亚州综合| 亚洲国产精品视频| 国产一区二区精品久久| 欧美无砖砖区免费| 欧美经典三级视频一区二区三区| 亚洲精品中文在线| 国产一区二区三区免费| 欧美日韩国产系列| 国产精品美女久久久久久| 五月激情丁香一区二区三区| 国产suv精品一区二区883| 欧美三级电影在线看| 中文字幕av不卡| 美女一区二区久久| 欧美色图在线观看| 国产精品每日更新在线播放网址 | 看片网站欧美日韩| 日本大香伊一区二区三区| 精品少妇一区二区三区| 亚洲制服丝袜在线| 成人avav在线| 久久久精品影视| 久久精品国产免费看久久精品| 欧美午夜影院一区| 中文字幕日韩av资源站| 韩国一区二区三区| 欧美一区二区三区日韩| 亚洲制服丝袜在线| aa级大片欧美| 国产蜜臀97一区二区三区| 美美哒免费高清在线观看视频一区二区| 色综合久久综合| 中文字幕不卡三区| 粉嫩av一区二区三区粉嫩| 精品乱码亚洲一区二区不卡| 午夜一区二区三区在线观看| 色综合色狠狠综合色| 国产精品色在线观看| 国产呦精品一区二区三区网站| 777亚洲妇女| 五月婷婷激情综合| 欧美偷拍一区二区| 艳妇臀荡乳欲伦亚洲一区| 99久久精品免费看国产免费软件| 久久精品夜色噜噜亚洲a∨| 韩日av一区二区| 欧美精品一区二区不卡| 国内精品伊人久久久久av影院| 日韩欧美第一区| 国内精品在线播放| 久久久99免费| 国产高清一区日本| 欧美激情一区二区三区全黄| 国产真实乱偷精品视频免| 久久精品这里都是精品| 高清国产午夜精品久久久久久| 国产女同互慰高潮91漫画| 国产成人丝袜美腿| 一色屋精品亚洲香蕉网站| 色综合天天性综合| 亚洲综合一区二区三区| 精品视频在线免费观看| 丝袜诱惑亚洲看片| 精品国产青草久久久久福利| 国精品**一区二区三区在线蜜桃| 国产日韩v精品一区二区| 高清shemale亚洲人妖| 亚洲欧美在线视频| 欧美亚洲自拍偷拍| 日韩av在线发布| 久久久综合九色合综国产精品| 国产盗摄一区二区| ㊣最新国产の精品bt伙计久久| 色视频一区二区| 丝袜美腿亚洲色图| 国产日韩欧美制服另类| 91网站最新网址| 天天亚洲美女在线视频| 精品成人a区在线观看| 成人精品免费网站| 午夜精品福利一区二区蜜股av | 久久免费看少妇高潮| 99久久婷婷国产综合精品| 亚洲一区二区三区免费视频|