Sophie

Sophie

distrib > Fedora > 14 > x86_64 > by-pkgid > e3d62627d1d1aab7ab1be2dd7f65a872 > files > 241

ecl-10.4.1-1.fc14.x86_64.rpm

<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>Chapter&#160;6.&#160;Numbers</title><link rel="stylesheet" href="ecl.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.75.2"><link rel="home" href="index.html" title="The ECL manual"><link rel="up" href="pt01.html" title="Part&#160;I.&#160;Standards"><link rel="prev" href="ch05.html" title="Chapter&#160;5.&#160;Packages"><link rel="next" href="ch06s02.html" title="6.2.&#160;Random-States"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter&#160;6.&#160;Numbers</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch05.html">Prev</a>&#160;</td><th width="60%" align="center">Part&#160;I.&#160;Standards</th><td width="20%" align="right">&#160;<a accesskey="n" href="ch06s02.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter&#160;6.&#160;Numbers"><div class="titlepage"><div><div><h2 class="title"><a name="sec.ansi.numbers"></a>Chapter&#160;6.&#160;Numbers</h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="ch06.html#sec.ansi.number-types">6.1. Numeric types</a></span></dt><dt><span class="section"><a href="ch06s02.html">6.2. Random-States</a></span></dt></dl></div><div class="section" title="6.1.&#160;Numeric types"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="sec.ansi.number-types"></a>6.1.&#160;Numeric types</h2></div></div></div><p><span class="application">ECL</span> supports all of the Common Lisp numeric tower, which is shown
  in <a class="xref" href="ch06.html#table.ansi.numbers" title="Table&#160;6.1.&#160;Numeric types in ECL">Table&#160;6.1</a>. The details, however, depend both
  on the platform on which <span class="application">ECL</span> runs and on the configuration which was
  chosen when building <span class="application">ECL</span>.</p><div class="table"><a name="table.ansi.numbers"></a><p class="title"><b>Table&#160;6.1.&#160;Numeric types in <span class="application">ECL</span></b></p><div class="table-contents"><table summary="Numeric types in ECL" border="1"><colgroup><col><col></colgroup><thead><tr><th>Type</th><th>Description</th></tr></thead><tbody><tr><td><span class="type">FIXNUM</span></td><td>Signed integer with a number of bits given by
      <code class="varname">SI::FIXNUM-BITS</code>, fit in a machine word.</td></tr><tr><td><span class="type">BIGNUM</span></td><td>Arbitrary size integers, only limited by amount of memory.</td></tr><tr><td><span class="type">RATIO</span></td><td>Arbitrary size rational number, made up of two integers.</td></tr><tr><td><span class="type">SINGLE-FLOAT</span></td><td>32-bits IEEE floating point number.</td></tr><tr><td><span class="type">DOUBLE-FLOAT</span></td><td>64-bits IEEE floating point number.</td></tr><tr><td><span class="type">SHORT-FLOAT</span></td><td>Either equivalent to SINGLE-FLOAT, or a 29-bit immediate floating
      point number.</td></tr><tr><td><span class="type">LONG-FLOAT</span></td><td>Either equivalent to DOUBLE-FLOAT, or a 96/128 bits IEEE floating
      point number.</td></tr><tr><td><span class="type">RATIONAL</span></td><td>An alias for <span class="type">(OR INTEGER RATIO)</span></td></tr><tr><td><span class="type">FLOAT</span></td><td>An alias for <span class="type">(OR SINGLE-FLOAT DOUBLE-FLOAT SHORT-FLOAT
      LONG-FLOAT)</span></td></tr><tr><td><span class="type">REAL</span></td><td>An alias for <span class="type">(OR REAL INTEGER FLOAT)</span></td></tr><tr><td><span class="type">COMPLEX</span></td><td>Complex number made of two real numbers of the above mentioned
      types.</td></tr></tbody></table></div></div><br class="table-break"><p>In general, the size of a <span class="type">FIXNUM</span> is determined by the
  word size of a machine, which ranges from 32 to 64 bits. Integers larger
  than this are implemented using the <a class="ulink" href="http://www.swox.com/gmp/" target="_top">GNU Multiprecision library</a>. Rationals
  are implemented using two integers, without caring whether they are fixnum
  or not. Floating point numbers include at least the two IEEE types of 32 and
  64 bits respectively. In machines where it is supported, it is possible to
  associate the lisp <span class="type">LONG-FLOAT</span> with the machine type <span class="type">long
  double</span> whose size ranges from 96 to 128 bits, and which are a bit
  slower. Finally, in 32-bit architectures it is also possible to associate
  the type <span class="type">SHORT-FLOAT</span> with a 29-bits floating point number that
  takes up no memory.</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch05.html">Prev</a>&#160;</td><td width="20%" align="center"><a accesskey="u" href="pt01.html">Up</a></td><td width="40%" align="right">&#160;<a accesskey="n" href="ch06s02.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter&#160;5.&#160;Packages&#160;</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">&#160;6.2.&#160;Random-States</td></tr></table></div></body></html>