"A is a multiple precision n-bit integer represented in radix r" What does this statement mean? In particular, what does A being a multiple precision n-bit integer mean? Please help. Thank you
Any number that looks like an integer in a source or data file is stored as an arbitrary-precision integer. The size of the integer is limited only by the available memory.
More specifically [100], a finite precision arithmetic is defined by four integer parameters: B, the base or radix, p, the number of digits in the mantissa, and l and u defining the exponent range: l ≤ e ≤ u. The precision of the machine is described by the real machine number eps.
GMP stands for the Gnu MultiPrecision Library. It is a popular library that gives us the ability to operate with arbitrary precision integers, rationals and floating point numbers: the add on MPFR library is useful for arbitrary precision floating point. The tutorial focusses on the C part of the library.
Generally, In languages like C/C++, the precision of integers is limited to 64-bit, but Python has built-in support for Arbitrary-precision integers. Since Python 3 there is no longer simple integer type, and all integers are represented as a bignum.
Let me answer my own question
if the processor is an X bit processor, any integer number that can be represented with in X bits ( ie, 0 to ((2^X)-1) for unsigned int's) it is a single precision numbers. If the integer needs to be represented using more than X bits, it is a multiple precision number. Usually any number is represented using bits that are a multiple of X, since an X bit processor has registers X bits wide, and if a number requires , for eg, 1 bit more than X, it still needs two X bit registers to be stored (hence such a number would be double precision)
Another example, a floating point number in C requires 4 bytes space. So something like
float x;
is a single precision floating point number
double x; requires twice the space of float, hence it is a double precision floating point number
(And if you believe this is wrong please leave your suggestions in the comments)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With