Edith Gross wrote:
[ ... arbitrary precision math ]
Thx. It may be funny, but it seems to me, that there is no such
library (or they are not free).
There are quite a few that are free in one fashion or another. Some
that I've used include:
MIRACL:
http://indigo.ie/~mscott/
Not quite the speed demon they claim it to be, but easy to use.
Free for non-commercial types of uses.
NTL:
http://www.shoup.net/ntl/
Big integer capability is more or less a side-item here, but it's
quite fast and works nicely nonetheless. Distributed under GPL.
GMP: ftp://ftp.gnu.org/gnu/gmp/ (and many others)
Quite fast. Builds easily on Linux, with some difficulty with
MinGW, and AFAIK, not at all with any non-GNU compiler.
Distributed under GPL.
apfloat:
http://www.apfloat.org/apfloat/
I've used it only a little, but so far it's been the fastest I've
tried. Both portable and compiler-specific versions for Borland,
VC++ and GNU are available. The version specifically for VC++ also
requires MASM (which you may already have). Freeware.
Both NTL and apfloat provide high-precision floating point in addition
to the usual large integers. MIRACL doesn't provide floating point but
does support rational numbers (i.e. ratios of two large integers) which
give many of the same capabilities. If you require it to be completely
free, apfloat is the obvious choice here. If you can live with its
licensing, I'd probably go for NTL instead -- I find it easier to use
(though that may be partly because I've used it a lot more).