in reply to Re^2: Efficiently working with huge exponents (yeah)
in thread Efficiently working with huge exponents

Thanks to you both. While I'll probably just use Math::BigApprox for my current need, re-learning a little math never hurt anyone (much).

  • Comment on Re^3: Efficiently working with huge exponents (yeah)

Replies are listed 'Best First'.
Re^4: Efficiently working with huge exponents (yeah)
by syphilis (Archbishop) on Mar 22, 2015 at 01:14 UTC
    ... I'll probably just use Math::BigApprox for my current need ...

    When the original post first appeared, I didn't notice any mention of perfect precision *not* being desired. Was that part of the post always there ?
    Anyway, just to correct my original reply to cater for perfect precision *not* being required:
    perl -MMath::MPFR=:mpfr -le "Rmpfr_set_default_prec(28);print Math::MP +FR->new(2) ** 1024000;" 5.194693363e308254
    (In Math::MPFR, precision is specified in bits.)

    You *can* specify precision for your Math::BigFloat numbers, too - it's in the docs.

    Cheers,
    Rob
      When the original post first appeared, I didn't notice any mention of perfect precision *not* being desired. Was that part of the post always there ?

      Yes it was, and if it wasn't, I'd have clearly annotated the change.

      Thanks for the updated tip!