123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <html lang="en">
- <head>
- <title>Additional math library notes - avram - a virtual machine code interpreter</title>
- <meta http-equiv="Content-Type" content="text/html">
- <meta name="description" content="avram - a virtual machine code interpreter">
- <meta name="generator" content="makeinfo 4.13">
- <link title="Top" rel="start" href="index.html#Top">
- <link rel="up" href="math.html#math" title="math">
- <link rel="prev" href="math-library-exceptions.html#math-library-exceptions" title="math library exceptions">
- <link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
- <meta http-equiv="Content-Style-Type" content="text/css">
- <style type="text/css"><!--
- pre.display { font-family:inherit }
- pre.format { font-family:inherit }
- pre.smalldisplay { font-family:inherit; font-size:smaller }
- pre.smallformat { font-family:inherit; font-size:smaller }
- pre.smallexample { font-size:smaller }
- pre.smalllisp { font-size:smaller }
- span.sc { font-variant:small-caps }
- span.roman { font-family:serif; font-weight:normal; }
- span.sansserif { font-family:sans-serif; font-weight:normal; }
- --></style>
- </head>
- <body>
- <div class="node">
- <a name="Additional-math-library-notes"></a>
- <p>
- Previous: <a rel="previous" accesskey="p" href="math-library-exceptions.html#math-library-exceptions">math library exceptions</a>,
- Up: <a rel="up" accesskey="u" href="math.html#math">math</a>
- <hr>
- </div>
- <h4 class="subsection">D.11.5 Additional <code>math</code> library notes</h4>
- <p>Floating point exceptions such as division by zero are not
- specifically reported as exceptions, but invalid computations can be
- <a name="index-nan-777"></a>detected by the propagation of <code>nan</code> into the result, following
- standard conventions.
- <p>The C function <code>feclearexcept (FE_ALL_EXCEPT)</code> is called before
- <a name="index-feclearexcept-778"></a>every floating point operation so that no lingering exception flags
- can affect it.
- <p>There is no library predicate for exact comparison of floating point
- numbers, but none is required because the virtual machine's
- <code>compare</code> combinator will work on their representations as it
- <a name="index-compare-combinator-779"></a>will on any other data. The usual caveats apply with regard to
- comparing floating point numbers in the presence of roundoff error.
- </body></html>
|