develooper Front page | perl.perl5.porters | Postings from May 2007

The State of BigNumber support in Perl

Thread Next
From:
Tels
Date:
May 23, 2007 10:01
Subject:
The State of BigNumber support in Perl
Message ID:
200705231907.11110@bloodgate.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Moin,

this is just a quick summary of the current situation and my todo:

* The module space is nearly complete, Perl has big integer, big float and
  big rational support (for quite some time I might add)
  Likewise, there are three pragams (bigint, bignum and bigrat) that
  enable you to use big numbers much more easier and naturally,
  including NaN and inf support.

The only thing missing is that the three pragmas need to be lexical so you 
can use "no bigint;" to selectively disable their magic.

* The functional interface is more or less complete, I have actually run out
  of ideas on what functions to add. Exception:

  bcos(), bsin() and batan2() (as well as bpi() to enable conversion between
  angles) need to be added, including overloading for cos(), sin() and
  atan2().

Possible further ideas include bmuladd() and maybe baddmul(). That however 
is scrapping the proverbial bottom of the BigBarrel.

* Math::BigRat and Math::BigInt::Lite need to be dusted off and teached
  about bexp() and bnok().

* The two libraries (GMP and Pari) are complete and functional, but they
  need to get the new code for calculating integer logs much faster (already
  done, unreleased, for GMP, needs to be done for Pari)

* I have some tricks in mind how to speed up math with very small numbers
  under GMP, but I am not sure if it is worth the effect. Benchmarks are
  currently done.

* The Benchmarks/Timeline on my page is about 3 years old and in dire need
  to be updated.

I am not sure how much of that I can accomplish this weekend, as there is 
also Devel::Size waiting to be debugged...

All the best,

Tels

- -- 
 Signed on Wed May 23 18:56:14 2007 with key 0x93B84C15.
 View my photo gallery: http://bloodgate.com/photos
 PGP key on http://bloodgate.com/tels.asc or per email.

 "Let me put this bluntly.  If we'd done Perl 6 on a schedule, you'd have
 it by now.  And it would be crap.  Perl 6 will be ready when all the
 inputs are there, and all the event-driven decision circuits have had a
 chance to make their decisions.  We're not the least bit afraid to slip
 our schedule, because we don't have a schedule.  We just have a plan."

  -- Larry Wall in 'The State of the Onion' 2002
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)

iQEVAwUBRlSQ33cLPEOTuEwVAQJOyQf/RgpR64CdOPhW2YcJPThcCFAQyY5AhNXl
6gqU1Qtxv5wP7AK3DtfBGZFSig0CfMnYLtW8F4XFa63iUm2e+UEG9K7gdeG2YO9J
zHj3TaN4vlbma/nu9Il43a8OwaUckIzrAPVWLOo2lSwv8kwwad82I3Hk5y1NIEKN
BWMaygluKZMDQT9vvHmhxsSsrZ9X2qRNsEuQ7Dev96T2BYo0vVMhNIr2G6zMEIXA
cRfCVqrI/DrnppfnWrWVWes8+nrI8/VVE5PPJIKnme+cjbUfi6Jk+8D05Q06BHr8
LzX7qeeq8tAMT32VDNTpaIModan13YaKPrxmh5MN+b1IMneAu7XKdQ==
=te6X
-----END PGP SIGNATURE-----

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About