Arithmetic With Huge Numbers / Hexdeicmal

Hi, and welcome!

Please see the FAQ: What's a reproducible example (`reprex`) and how do I create one? Using a reprex, complete with representative data will attract quicker and more answers. That will reduce community reverse engineering desire disorder. :grin:

For the decimal question, I think the function is returning what it is supposed to, which is a precision of 1000 bits, not 1000 bytes representing digits.

#> 1 'mpfr' number of precision  1000   bits 
#> [1] 3.141592653589793115997963468544185161590576171875

Created on 2020-04-08 by the reprex package (v0.3.0)

For the second, I think you want to use

mpfr("7f2d36a2a0007f2d36a2a0007f2d36a2a0007f2d36a2a000", base=16)
#> 1 'mpfr' number of precision  192   bits 
#> [1] 3118361524223520784583964884878580812558070356334996529152

Created on 2020-04-08 by the reprex package (v0.3.0)

(Didn't have time to take it out to 10K on my puny Airbook)

1 Like