index.html revision 219
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<html lang="en">
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<head>
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<title>GNU MP 4.3.2</title>
1676b20a55b53c04a6a4cbbc453863ca975f2491cwebb<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<meta name="description" content="How to install and use the GNU multiple precision arithmetic library, version 4.3.2.">
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<meta name="generator" content="makeinfo 4.8">
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<link title="Top" rel="start" href="index.html#Top">
1676b20a55b53c04a6a4cbbc453863ca975f2491cwebb<link rel="up" href="http://gmplib.org/index.html#dir" title="(dir)">
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<link rel="prev" href="http://gmplib.org/index.html#dir" title="(dir)">
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<link rel="next" href="http://gmplib.org/manual-4.3.2/Copying.html#Copying" title="Copying">
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!--
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhemThis manual describes how to install and use the GNU multiple precision
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbarithmetic library, version 4.3.2.
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbCopyright 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbPermission is granted to copy, distribute and/or modify this document under
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbthe terms of the GNU Free Documentation License, Version 1.3 or any later
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbversion published by the Free Software Foundation; with no Invariant Sections,
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhemwith the Front-Cover Texts being ``A GNU Manual'', and with the Back-Cover
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbTexts being ``You have freedom to copy and modify this GNU Manual, like GNU
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbsoftware''. A copy of the license is included in
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu*Note GNU Free Documentation License::.-->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<meta http-equiv="Content-Style-Type" content="text/css">
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<style type="text/css"><!--
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu pre.display { font-family:inherit }
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem pre.format { font-family:inherit }
6b8112f310d1c9bae8b0b9f2fb1aa85bfedc2457cwebb pre.smalldisplay { font-family:inherit; font-size:smaller }
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb pre.smallformat { font-family:inherit; font-size:smaller }
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu pre.smallexample { font-size:smaller }
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb pre.smalllisp { font-size:smaller }
6b8112f310d1c9bae8b0b9f2fb1aa85bfedc2457cwebb span.sc { font-variant:small-caps }
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb span.roman { font-family:serif; font-weight:normal; }
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu span.sansserif { font-family:sans-serif; font-weight:normal; }
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem--></style>
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu</head>
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<body>
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<div class="node">
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<p>
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<a name="Top"></a>
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhemNext:&nbsp;<a rel="next" accesskey="n" href="http://gmplib.org/manual-4.3.2/Copying.html#Copying">Copying</a>,
36de3346306c17768d6c2e284df34581c4cd0e67cmarquPrevious:&nbsp;<a rel="previous" accesskey="p" href="http://gmplib.org/index.html#dir">(dir)</a>,
36de3346306c17768d6c2e284df34581c4cd0e67cmarquUp:&nbsp;<a rel="up" accesskey="u" href="http://gmplib.org/index.html#dir">(dir)</a>
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<hr>
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb</div>
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<h2 class="unnumbered">GNU MP</h2>
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb <p>This manual describes how to install and use the GNU multiple precision
36de3346306c17768d6c2e284df34581c4cd0e67cmarquarithmetic library, version 4.3.2.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem <p>Copyright 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb <p>Permission is granted to copy, distribute and/or modify this document under
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhemthe terms of the GNU Free Documentation License, Version 1.3 or any later
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebbversion published by the Free Software Foundation; with no Invariant Sections,
36de3346306c17768d6c2e284df34581c4cd0e67cmarquwith the Front-Cover Texts being &ldquo;A GNU Manual&rdquo;, and with the Back-Cover
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarquTexts being &ldquo;You have freedom to copy and modify this GNU Manual, like GNU
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhemsoftware&rdquo;. A copy of the license is included in
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<a href="http://gmplib.org/manual-4.3.2/GNU-Free-Documentation-License.html#GNU-Free-Documentation-License">GNU Free Documentation License</a>.
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu <pre class="sp">
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem</pre>
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Don't bother with contents for html, the menus seem adequate. -->
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<ul class="menu">
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="1" href="http://gmplib.org/manual-4.3.2/Copying.html#Copying">Copying</a>: GMP Copying Conditions (LGPL).
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="2" href="http://gmplib.org/manual-4.3.2/Introduction-to-GMP.html#Introduction-to-GMP">Introduction to GMP</a>: Brief introduction to GNU MP.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="3" href="http://gmplib.org/manual-4.3.2/Installing-GMP.html#Installing-GMP">Installing GMP</a>: How to configure and compile the GMP library.
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<li><a accesskey="4" href="http://gmplib.org/manual-4.3.2/GMP-Basics.html#GMP-Basics">GMP Basics</a>: What every GMP user should know.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="5" href="http://gmplib.org/manual-4.3.2/Reporting-Bugs.html#Reporting-Bugs">Reporting Bugs</a>: How to usefully report bugs.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="6" href="http://gmplib.org/manual-4.3.2/Integer-Functions.html#Integer-Functions">Integer Functions</a>: Functions for arithmetic on signed integers.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="7" href="http://gmplib.org/manual-4.3.2/Rational-Number-Functions.html#Rational-Number-Functions">Rational Number Functions</a>: Functions for arithmetic on rational numbers.
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<li><a accesskey="8" href="http://gmplib.org/manual-4.3.2/Floating_002dpoint-Functions.html#Floating_002dpoint-Functions">Floating-point Functions</a>: Functions for arithmetic on floats.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a accesskey="9" href="http://gmplib.org/manual-4.3.2/Low_002dlevel-Functions.html#Low_002dlevel-Functions">Low-level Functions</a>: Fast functions for natural numbers.
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<li><a href="http://gmplib.org/manual-4.3.2/Random-Number-Functions.html#Random-Number-Functions">Random Number Functions</a>: Functions for generating random numbers.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a href="http://gmplib.org/manual-4.3.2/Formatted-Output.html#Formatted-Output">Formatted Output</a>: <code>printf</code> style output.
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<li><a href="http://gmplib.org/manual-4.3.2/Formatted-Input.html#Formatted-Input">Formatted Input</a>: <code>scanf</code> style input.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a href="http://gmplib.org/manual-4.3.2/C_002b_002b-Class-Interface.html#C_002b_002b-Class-Interface">C++ Class Interface</a>: Class wrappers around GMP types.
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<li><a href="http://gmplib.org/manual-4.3.2/BSD-Compatible-Functions.html#BSD-Compatible-Functions">BSD Compatible Functions</a>: All functions found in BSD MP.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a href="http://gmplib.org/manual-4.3.2/Custom-Allocation.html#Custom-Allocation">Custom Allocation</a>: How to customize the internal allocation.
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<li><a href="http://gmplib.org/manual-4.3.2/Language-Bindings.html#Language-Bindings">Language Bindings</a>: Using GMP from other languages.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a href="http://gmplib.org/manual-4.3.2/Algorithms.html#Algorithms">Algorithms</a>: What happens behind the scenes.
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<li><a href="http://gmplib.org/manual-4.3.2/Internals.html#Internals">Internals</a>: How values are represented behind the scenes.
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<li><a href="http://gmplib.org/manual-4.3.2/Contributors.html#Contributors">Contributors</a>: Who brings you this library?
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a href="http://gmplib.org/manual-4.3.2/References.html#References">References</a>: Some useful papers and books to read.
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<li><a href="http://gmplib.org/manual-4.3.2/GNU-Free-Documentation-License.html#GNU-Free-Documentation-License">GNU Free Documentation License</a>
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<li><a href="http://gmplib.org/manual-4.3.2/Concept-Index.html#Concept-Index">Concept Index</a>
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<li><a href="http://gmplib.org/manual-4.3.2/Function-Index.html#Function-Index">Function Index</a>
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb</ul>
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- @m{T,N} is $T$ in tex or @math{N} otherwise. This is an easy way to give -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- different forms for math in tex and info. Commas in N or T don't work, -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- but @C{} can be used instead. \, works in info but not in tex. -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- @ms{V,N} is $V_N$ in tex or just vn otherwise. This suits simple -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- subscripts like @ms{x,0}. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- @nicode{S} is plain S in info, or @code{S} elsewhere. This can be used -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- when the quotes that @code{} gives in info aren't wanted, but the -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- fontification in tex or html is wanted. Doesn't work as @nicode{'\\0'} -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- though (gives two backslashes in tex). -->
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<!-- @nisamp{S} is plain S in info, or @samp{S} elsewhere. This can be used -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- when the quotes that @samp{} gives in info aren't wanted, but the -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- fontification in tex or html is wanted. -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- Usage: @GMPtimes{} -->
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<!-- Give either \times or the word "times". -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- Usage: @GMPmultiply{} -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- Give * in info, or nothing in tex. -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- Usage: @GMPabs{x} -->
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<!-- Give either |x| in tex, or abs(x) in info or html. -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- Usage: @GMPfloor{x} -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- Give either \lfloor x\rfloor in tex, or floor(x) in info or html. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: @GMPceil{x} -->
36de3346306c17768d6c2e284df34581c4cd0e67cmarqu<!-- Give either \lceil x\rceil in tex, or ceil(x) in info or html. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Math operators already available in tex, made available in info too. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- For example @bmod{} can be used in both tex and info. -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- New math operators. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- @abs{} can be used in both tex and info, or just \abs in tex. -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- @cross{} is a \times symbol in tex, or an "x" in info. In tex it works -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- inside or outside $ $. -->
6b8112f310d1c9bae8b0b9f2fb1aa85bfedc2457cwebb<!-- @times{} made available as a "*" in info and html (already works in tex). -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: @W{text} -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- Like @w{} but working in math mode too. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: \GMPdisplay{text} -->
6b8112f310d1c9bae8b0b9f2fb1aa85bfedc2457cwebb<!-- Put the given text in an @display style indent, but without turning off -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- paragraph reflow etc. -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- Usage: \GMPhat -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- A new \hat that will work in math mode, unlike the texinfo redefined -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- version. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: \GMPraise{text} -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- For use in a $ $ math expression as an alternative to "^". This is good -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- for @code{} in an exponent, since there seems to be no superscript font -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- for that. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: @texlinebreak{} -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- A line break as per @*, but only in tex. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: @maybepagebreak -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Allow tex to insert a page break, if it feels the urge. -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- Normally blocks of @deftypefun/funx are kept together, which can lead to -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- some poor page break positioning if it's a big block, like the sets of -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- division functions etc. -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Usage: @GMPreftop{info,title} -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- Usage: @GMPpxreftop{info,title} -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- Like @ref{} and @pxref{}, but designed for a reference to the top of a -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu<!-- document, not a particular section. The TeX output for plain @ref insists -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- on printing a particular section, GMPreftop gives just the title. -->
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem<!-- The texinfo manual recommends putting a likely section name in references -->
a33ac0418e3968dbc79f5ba81cbb91d10b1ea7d5cwebb<!-- like this, eg. "Introduction", but it seems better to just give the title. -->
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu</body></html>
ac2de0b006739c10b0ab8917e9c470200c06ee2dcmarqu
ffa7844cc8f2e13c7a1bdc47997e94d85e2f9354sokhem