Commit 27e91997 authored by gregor herrmann's avatar gregor herrmann

[svn-inject] Installing original source of libmath-bigint-perl (1.95)

parents
Please see <http://bloodgate.com/perl/bigint/benchmarks.html> for detailed and
up-todate benchmarks, as well as a program to generate them.
Known bugs:
* TODO BUGS:
+ implement test for the upgrading bug in bsub()
* NaN handling in comparisations slightly broken. See also [perl #33106].
* General:
+ BigInt can not the IEEE '-0'. Currently there are no plans to add this. If
you need it, please bug the author(s) about it.
* BigFloat:
+ comparing (<=> or == or !=) a BigFloat to a BigInt don't work yet
+ new is first running the entire number trough _split, then again the parts
to construct BigInts. Could be a bit more optimzed.
+ fdiv() using F (fallback) mode does not work properly in all cases of
local (aka $x's or $y's) A or P settings. Not definite test case yet, but
it might calculate not enough digits to satisfy the rounding needs.
* BigInt:
+ exponent on input is limited to a Perl int (bigger numbers won't fit
into your memory, anyway - use BigFloat)
+ doesn't have a mode akin to 'use integer;', e.g. it always emulates Perl
(this is solved partially by use bigint ;)
+ Handling of undef arguments is somewhat broken (no proper warnings)
+ eval('use...') and use Math::BigInt qw/:constant/ fail on Perl prior 5.6.0
This is likely an Exporter bug, and causes Math::BigInt to eval require on
earlier Perls when loading the core math lib. Thus the loading can fail
under older Perls on filesystems that can not cope with the
'Math/BigInt/Calc.pm'-style filenames.
###############################################################################
Mixing of classes does not always work like expected. "use bignum;",
"use bigint;" and "use bigrat;" should solve this problem for most cases.
Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!
Tels <http://bloodgate.com/>
This diff is collapsed.
I wish to thank the following people:
* Mark A. Biggar and Ilya for the original versions.
* Steffen Beyer for the discussions and ideas, and for Bit::Vector.
* Bruce Fields for spotting bugs.
* Mark Dickinson for spotting bugs.
* HH for listening to my boring explanations.
* Peter Prymmer for spotting the OS/390 problems with / 1e5
* Tom Phoenix for the discussions about factoring/primes/speed.
* John Peacock for pushing me to finish Math::BigInt::Calc.
* Benjamin Trott for the _split optimization and finding the bug in badd()
* Daniel Pfeiffer for v0.49
* Compaq for their TestDrive accounts and the admins managing them - this makes
testing on a large variety of platforms possible. Thanx!
* Sisyphus for the discussions and ideas
* Jarkko for the inf/NaN help and for beeing generally helpful and witty
* Creager, Robert S for pointing me towards the precision/accuracy bug and for
general asking questions and providing feedback
* Feztaa for the report that let to the discovery of the _rsft() bug in v1.61
He also deserves the mention as the first known user of bignum :)
* Tim Rushing for reporting the bsqrt() hang and giving me the chance to
improve BigInt/BigFloat.
* cpan@ali.as for reporting the floor() bug with 0.1412024 and providing a
fix and testcase - thanx!
* Stephen Ross for finding the -2 ** Y with odd Y bug
Special thanx must go to John Peacock and Tom Roche, both have helped me a lot
in developing the latest version, not only by cheerfully kicking my lazy butt
from time to time, but also by providing advice, bug-reports, suggestions and
nagging questions, as well as bearing with my countless ranting emails. So,
thank you very much!
Also I want to thank all the ever-busy people on p5p. You guys (and gals) rock!
List still not complete ;o)
Tels <http://bloodgate.com/>
This file contains a short description of what the goals of this project are,
building guidelines etc. This was born after discussions with John Peacock, who
provided helpfull feedback.
* KISS - Keep It Simple, Stupid!
* Favour correctness over speed
* Make your code maintable, so avoid Copy&Paste, unclear constructs, read-only
code and special hacks whenever possible
* Optimize more for the average case than the worst, while trying to avoid
performance hits for the worst case.
The average case is more for longer numbers than short, based on the
assumption that if you wanted to add 1 and 2 _fast_ together, you wouldn't
use BigInt nor Perl, now would you? ;)
(Or in other words: Time saved in one case of a large number may be
multitudes of what you can waste on a small number)
* Make subclassing as easy and painless as possible. This means clean
inheritance and overload section, no C&P code etc.
* Keep the interface as consistent and easy as possible.
Secondary goals:
* Make mixing of classes work, like in:
$x = Math::BigFloat->new(10);
$y = Math::BigInt->new(2);
$z = $x / $y; # $z = Math::BigFloat = 5
* Make auto-upgrading/downgrading work
See also BUGS.
Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!
Tels <http://bloodgate.com/>
This file contains all the changes and bugfixes from the original version of
BigInt/BigFloat to the rewritten one. For what has changed in the latest
version see NEW and for a complete list of changes see the file CHANGES.
v1.82:
general:
+ It is subsequent faster than the original in many places
+ Use more than 16 bit at a time, greater BASELEN for 64 bit systems
+ overload for things like +=
+ special operations like binc()
+ many optimizations and shortcuts in normal operations
+ Can use Math::BigInt lib => 'name'; for Pari, GMP, Bit::Vector or others
+ regression test suite greatly enhanced to cover more problematic cases
+ added example scripts (prime.pl, bigprimes.pl, hailstone.pl)
+ documentation fixed and greatly enhanced
+ BigInt is sub-classable with very little effort, see M::S or M::BF
+ subclasses of Math::BigInt know all the same methods, so that you can call
$x->some_method() without having to know which type of class $x is
+ added infinity handling
+ much better NaN handling
caveats:
+ bstr() and stringify now drop the leading '+' (to make overloaded cmp work
as expected when cmp'aring to scalars and other objects (read: bugfix)
+ due to the dropping of '+' the string sort order has changed. It is now
compatible to the way perl sorts it's strings.
+ spaces are no longer allowed in a number (but may precede or follow it)
!! You can always make a subclass and change all these things quite easily !!
input:
+ underscores are now valid between any two digits (in hex/binary input, too)
+ integers of the form 1E2, 1.23E2, 2.00 etc now valid for BigInt.pm, too
+ hexadecimal numbers of the form 0xabcdefABCDEF0123456789
+ binary numbers of the form 0b01010101101000001000100101
+ octal numbers can be input via from_oct()
output:
+ as_hex(), as_bin() and as_oct() for easier conversation between bases
bugs and buglets fixed over Mark's original:
+ 0**0 gave NaN instead of 1
+ -1**y gave -1 instead of +1 for even y
+ fsqrt() gave slightly wrong results (like for fsqrt(9))
+ +x/0 is now +inf, -x/0 is -inf (both were NaN), as well as other inf cases
+ mod/div for negative numbers were incompatible to Perl's way
+ added P. Prymmer's OS/390 '/1e5 vs *1e-5' patch w/o the performance snag
+ incorporated all the patches to the core modules by John Peacock
+ BigFloat::bxxx() works as well as BigFloat::fxxx()
+ Math::BigInt->new(10) / Math::BigFloat->new(2) returned NaN (ditto for
other subclasses of Math::BigInt)
+ $a = new Math::BigInt; creates now a +0, while "" still gives a NaN
This supresses all warnings on undef arguments. Wether this is better...
+ import() would always use "Math::BigInt" and clash with Exporter
+ use Math::BigInt qw(bneg); $a = bneg('1234'); etc did not work at all
+ $x->xxx() now modifies $x in all cases of modifiers and actually returns
the same $x (e.g. not a plain scalar or a different reference). All
testing routines leave $x alone. bpow(), bmod(), fround(), ffround() etc
were broken in this regard.
accuracy and precision:
+ there is now support for both accuracy (significant digits) and precision
(fixed number of digits after decimal point), which by default is off
+ objects/numbers now can have a local accuracy/precision
internal fixes:
+ uses a blessed hash ref instead scalar ref (easier subclassable)
+ my instead of local
+ use strict and -w
+ s/$[/0/ (after all, $[ = 1; in main does not effect this package)
+ $# partially removed ($#y is scalar @y -1, $#$y is scalar @$y-1 - ugh!)
+ added LICENSE section and file
new stuff:
+ MBF: :constant works now
+ MBI: :constant picks up binary and hexadecimal constants
+ brsft()/blsft() also can do other bases than 2
+ bacmp (acmp), because needed for more efficient add()
+ bzero(), bnan(), bone(), binf()
+ binc(), bdec(), bfac()
+ is_zero(), is_nan(), is_one(), is_odd(), is_even(), is_inf(), is_int()
+ digit(), length(), copy()
+ as_number() (alias: as_int()), as_hex(), as_bin()
+ is_positive(), is_negative() (alias: is_pos() and is_neg())
+ mantissa(), exponent(), parts(), sign()
+ bgcd() accepts now lists, blcm() (also accepts lists)
+ flog()/blog() for overloading of log()
+ fexp()/bexp() for overloading of exp()
+ round(accuracy,precision,mode) round to accuracy/precision using mode
+ MBF: fpow(), fmod(), fdiv() in list context (Thanx J. Peacock)
+ fpow() can now handle non-integer arguments, like in fpow(2.1 ** 0.2)
+ MBI: bsqrt()
+ bmodpow(), bmodinv() (Thanx John Borwick)
+ bfloor(), bceil(), broot()
+ CORE cos()/sin()/exp()/atan2() now work when passed BigInts or BigFloats
Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!
Tels <http://bloodgate.com/>
Rewrite project of Math::Big*
(C) Copyright ..--- ----- ----- .---- - ..--- by - . .-.. ... .-.-.-
Contains new version of Math::BigInt and Math::BigFloat as they are in the
Perl core from v5.8.0 onwards.
This rewritten version is mainly compatible, minus some bugfixes, and more
features and speed.
To test, unzip & untar package, then run
perl Makefile.PL
make
make test
make install # as root
These modules should be installed automatically into the Perl core, and not
into site-perl. You can check whether you get the old or new versions by doing
this:
perl -MMath::BigInt -le 'print "v$Math::BigInt::VERSION"'
If it prints undef or v0.01 you still got the old version. Delete the files
from the Perl core installation path manually, and make sure that you
delete all old versions, then try again to print the version from above.
For a quick reference on what has changed from the old versions, please see
CHANGES. HISTORY brings you a detailed history log of the rewrite.
In ./examples are some basic example scripts.
More information including HTMLified help and benchmark results are
available under:
http://bloodgate.com/perl/
Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!
Tels <http://bloodgate.com/>
This program is free software; you may redistribute it and/or modify it
under the same terms as Perl itself.
Tels <http://bloodgate.com/>
BENCHMARK
BUGS
CHANGES
CREDITS
examples/1000.txt
examples/bigprimes.pl
examples/hailstone.pl
examples/prime.pl
GOALS
HISTORY
inc/Module/Install.pm
inc/Module/Install/Base.pm
inc/Module/Install/Can.pm
inc/Module/Install/Fetch.pm
inc/Module/Install/Makefile.pm
inc/Module/Install/Metadata.pm
inc/Module/Install/Win32.pm
inc/Module/Install/WriteAll.pm
INSTALL
lib/Math/BigFloat.pm
lib/Math/BigInt.pm
lib/Math/BigInt/Calc.pm
lib/Math/BigInt/CalcEmu.pm
LICENSE
Makefile.PL
MANIFEST This list of files
MANIFEST.SKIP
META.yml
NEW
README
t/_e_math.t
t/alias.inc
t/bare_mbf.t
t/bare_mbi.t
t/bare_mif.t
t/big_pi_e.t
t/bigfltpm.inc
t/bigfltpm.t
t/bigintc.t
t/bigintpm.inc
t/bigintpm.t
t/bigints.t
t/biglog.t
t/bigroot.t
t/calling.t
t/config.t
t/const_mbf.t
t/constant.t
t/downgrade.t
t/inf_nan.t
t/isa.t
t/lib_load.t
t/Math/BigFloat/Subclass.pm
t/Math/BigInt/BareCalc.pm
t/Math/BigInt/Scalar.pm
t/Math/BigInt/Subclass.pm
t/mbf_ali.t
t/mbi_ali.t
t/mbi_rand.t
t/mbimbf.inc
t/mbimbf.t
t/nan_cmp.t
t/new_overloaded.t
t/pod.t
t/pod_cov.t
t/req_mbf0.t
t/req_mbf1.t
t/req_mbfa.t
t/req_mbfi.t
t/req_mbfn.t
t/req_mbfw.t
t/require.t
t/round.t
t/sub_ali.t
t/sub_mbf.t
t/sub_mbi.t
t/sub_mif.t
t/trap.t
t/upgrade.inc
t/upgrade.t
t/upgradef.t
t/use.t
t/use_lib1.t
t/use_lib2.t
t/use_lib3.t
t/use_lib4.t
t/use_mbfw.t
t/with_sub.t
TODO
SIGNATURE Public-key signature (added by MakeMaker)
.*\.tar\.gz
^blib.*
^\w+\.(html|txt|png|dot|pl|svg|old|bak|org)
^Makefile\z
^Makefile.(old|bak)\z
^MANIFEST.(old|bak)\z
^Math-BigInt-.*
pm_to_blib
\.git*
---
abstract: 'Arbitrary size integer/float math package'
author:
- 'Original code by Mark Biggar, overloaded interface by Ilya Zakharevich.'
- 'Tels <nospam-abuse@bloodgate.com>'
build_requires:
ExtUtils::MakeMaker: 6.42
Test::More: 0.62
configure_requires:
ExtUtils::MakeMaker: 6.42
distribution_type: module
generated_by: 'Module::Install version 1.00'
license: perl
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
version: 1.4
name: Math-BigInt
no_index:
directory:
- examples
- inc
- t
recommends:
Math::BigInt::FastCalc: 0.19
Math::BigInt::GMP: 1.24
Math::BigInt::Pari: 1.13
Math::BigRat: 0.22
bignum: 0.22
requires:
perl: 5.006002
resources:
license: http://dev.perl.org/licenses/
version: 1.95
# We need at least Perl 5.6
require 5.006002;
use strict;
# Load the Module::Install bundled in ./inc/
use inc::Module::Install;
# The name of your distribution
name 'Math-BigInt';
# Get most of the details from the primary module
all_from 'lib/Math/BigInt.pm';
requires 'perl' => 5.006002;
# See if old versions are installed, and if so, tell the user that
# upgrading them would make little fluffy kittens much happier:
my @checks;
check_minimum_version ('Math::BigInt::FastCalc' => 0.19);
check_minimum_version ('Math::BigInt::GMP' => 1.24);
check_minimum_version ('Math::BigInt::Pari' => 1.13);
check_minimum_version ('Math::BigRat' => 0.22);
check_minimum_version ('bignum' => 0.22);
if (@checks > 0)
{
print ("\n" . '*' x 70 . "\n Attention: After installing this package, you should also update:\n\n");
for my $n (@checks)
{
my $name = $n->[0]; while (length($name) < 24) { $name .= ' '; }
print " $name to at least v$n->[1]\t (you have v$n->[2])\n";
}
print "\n";
sleep(5);
};
build_requires 'Test::More' => 0.62;
install_as_core();
license 'perl';
author 'Tels <nospam-abuse@bloodgate.com>';
# Do not index these
no_index directory => 'examples';
sign;
# Generate the Makefile
WriteAll;
1;
sub check_minimum_version
{
my ($module, $version) = @_;
my $v; eval " require $module; \$v = \$${module}::VERSION;";
recommends $module, $version;
# if the module is installed, but outdated, add it to the requirements
if (defined $v && $v < $version)
{
push @checks, [ $module, $version, $v ];
}
}
This lists only the changes for the current release over the last version,
since HISTORY is now quite big:
* fix #34459: bsqrt() breaks on floats with enough digits (Thanx Niko Tyni!)
* fix #35238: batan2() does not handle inf/-inf properly
* fix #35162: MBI segfault (as_number(Math::BigRat())), Thanx Zsbán Ambrus!)
* fix #34822: Which library is used? (Thanx Mark Overmeer!)
##############################################################################
Please have Math::BigFloat->bone->bexp->bdiv(0) big amounts of fun.
Tels <http://bloodgate.com/perl>
Rewrite project of Math::BigInt, Math::BigFloat.
(C) Copyright ..--- ----- ----- .---- - ..--- by - . .-.. ... .-.-.-
This package contains completely rewritten versions of Math::BigInt and
Math::BigFloat.
To test, unzip & untar package, then run
perl Makefile.PL
make
make test
make install
See also ./examples for some example scripts.
See INSTALL for detailed help on installing these modules.
You can look on CPAN (http://search.cpan.org/) for modules that replace the
core math routines of Math::BigInt (look for Math::BigInt::BitVect, f.i.).
More information including HTMLified help are available under:
http://bloodgate.com/perl/ # project homepage
http://bloodgate.com/perl/benchmarks.html # benchmarks
Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!
Tels <http://bloodgate.com/>
This file contains message digests of all files listed in MANIFEST,
signed via the Module::Signature module, version 0.66.
To verify the content in this distribution, first make sure you have
Module::Signature installed, then type:
% cpansign -v
It will check each file's integrity, as well as the signature's
validity. If "==> Signature verified OK! <==" is not displayed,
the distribution may already have been compromised, and you should
not run its Makefile.PL or Build.PL.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
SHA1 f6ef98e8f3f6a4f670d569f279ef5a3c05c16d0c BENCHMARK
SHA1 2c6c3022349b6328c19aef613607c070900f06ec BUGS
SHA1 8a2876d6da2f90326e980d0ff723b01bdbb5a717 CHANGES
SHA1 f27c8bd98e754f96c9825fa6ce9f1244c93bdbe6 CREDITS
SHA1 bc2db74538d3acd53f71b5512a144fe18c253ecd GOALS
SHA1 c526ad20dce6fa315a49dfc41b4d27c40f2b6576 HISTORY
SHA1 c42565ad26cdf91502bacf19a4f7080e63c51fe2 INSTALL
SHA1 d6a6c30ee6d9ba6b9afab8bbf6a25e1b23c744e0 LICENSE
SHA1 026e832dbd861b316a4f914359cf5c13eed1cbc3 MANIFEST
SHA1 28e0843acbc175242b0744c7a2a5b2e9397489ee MANIFEST.SKIP
SHA1 d6439bf57471376c9733332ba5e50d97bdd038b1 META.yml
SHA1 b6542d9e43893cc2ffa79fe8884e5e5c1281699e Makefile.PL
SHA1 2ec9bfda86bb2073e9423e6a86bb6956c06ebb2f NEW
SHA1 481f5827752d2100914db1eaeb60bf0bbd13529e README
SHA1 6ae43bba2ee4f469ae9f43a916955caff273d41b TODO
SHA1 c2bbe82659480de8710b9e64a62d47b64dddd2d2 examples/1000.txt
SHA1 b88700764a8b78c904ed38e50db0286b76228132 examples/bigprimes.pl
SHA1 b57b118469a1a16e54d61206c5bd9077dbb2231a examples/hailstone.pl
SHA1 8ca42793d8769ec8d0928f11c30f38d96dd54efb examples/prime.pl
SHA1 7305dbe2904416e28decb05396988a5d51d578be inc/Module/Install.pm
SHA1 129960509127732258570c122042bc48615222e1 inc/Module/Install/Base.pm
SHA1 cf3356ed9a5bd2f732527ef9e7bc5ef4458c8a93 inc/Module/Install/Can.pm
SHA1 bf0a3e1977effc2832d7a813a76dce3f31b437b6 inc/Module/Install/Fetch.pm
SHA1 b721c93ca5bc9a6aa863b49af15f1b1de6125935 inc/Module/Install/Makefile.pm
SHA1 026cc0551a0ad399d195e395b46bdf842e115192 inc/Module/Install/Metadata.pm
SHA1 5457015ea5a50e93465bf2dafa29feebd547f85b inc/Module/Install/Win32.pm
SHA1 051e7fa8063908befa3440508d0584a2497b97db inc/Module/Install/WriteAll.pm
SHA1 0cc9d5d08fa9a786c09c97df3b5f46c408f929a9 lib/Math/BigFloat.pm
SHA1 da3d7366a5951720393e7393b21de1b5d8c56e7a lib/Math/BigInt.pm
SHA1 17ef736d12e4ac821f68e156a48ee9bfb273b99d lib/Math/BigInt/Calc.pm
SHA1 7c7a2c81a26dc1ca7602df1dd12798713d9a1b88 lib/Math/BigInt/CalcEmu.pm
SHA1 63d3ac167c2d98484f521ad9cbddbf306d33d8eb t/Math/BigFloat/Subclass.pm
SHA1 309c0d093884f29111225c2108a33f0e8e028759 t/Math/BigInt/BareCalc.pm
SHA1 62deb0b9e3bf94aaf12745207efa3d858f3b878e t/Math/BigInt/Scalar.pm
SHA1 27c1738a064e7f7bf91c762d411af447847c331c t/Math/BigInt/Subclass.pm
SHA1 a2014803baec5dbef46235f83411f76efa0efea7 t/_e_math.t
SHA1 0e725849a20e80bb1da796a7be40b69a958c8313 t/alias.inc
SHA1 55afc3574bff9a49f6f42622b83f6516e6240df9 t/bare_mbf.t
SHA1 2f18c703ef46afe813b9b8d68f43eca672fcfaab t/bare_mbi.t
SHA1 16793246cd5065cd487fcc62331651c5fc2cbabf t/bare_mif.t
SHA1 333a425247b4e276696210a6322b815a0f55f5ab t/big_pi_e.t
SHA1 f74b5dfb3963b770d376618a6431552e4631fb14 t/bigfltpm.inc
SHA1 9b0690a18d230b1a9a4a45f5a66460bca8c9cb4c t/bigfltpm.t
SHA1 787faf71d064690a0b499f605ba2d03c936e7e1b t/bigintc.t
SHA1 0d3d27246d89ad1eaca8ac1b9895866340ca7a57 t/bigintpm.inc
SHA1 77b20602f2f164be3d67d7fb8ee8e0bfe43f18d9 t/bigintpm.t
SHA1 cb07d195c20eb306088eeacccc2c7475f267446c t/bigints.t
SHA1 5bdf82ef7085b97caa496bfc71ab1fbfe48ef9e8 t/biglog.t
SHA1 da260b6e02b220868fc7b4c0f87569299402fbf7 t/bigroot.t
SHA1 52eac46ea148e3c83d78d316e7e3214a9f587365 t/calling.t
SHA1 c1f7b6840e772f2b6d4f8dbea4c28aaa675c9b17 t/config.t
SHA1 7c75531325efd55f15ef14e5ca22875d6d53e366 t/const_mbf.t
SHA1 b7891121243029ae078ca952205ce3d037b145d8 t/constant.t
SHA1 d5b1f2d01e954a8b0c41d51f79ec878a305cedf7 t/downgrade.t
SHA1 f1845e4a860999b704c3fdb20b6cb6c5d81024f0 t/inf_nan.t
SHA1 4ee46eecc74e97f27ef47b208576d179ab01cfb9 t/isa.t
SHA1 95d41431bb5147f2cd97d2f160c1ce220a365142 t/lib_load.t
SHA1 18071d0caf17979c5345baf7b296a1e95d8f9bf1 t/mbf_ali.t
SHA1 79fafec237d6f47d8a176c67418f94c708ed3fec t/mbi_ali.t
SHA1 2b9490eab4d5371b804a39fb16e77c6bd6bbd006 t/mbi_rand.t
SHA1 15e8efc09da6eac8669f3dd3bfd9c1a5f3d7fb42 t/mbimbf.inc
SHA1 d5508ab648eaaf51a99b2f85ccb9be5c1ef0f127 t/mbimbf.t
SHA1 a8e152beb9c0583cca8ba397ca2952cf456f107c t/nan_cmp.t
SHA1 852bfc6c25fa982e0c48e270277f091732d062e2 t/new_overloaded.t
SHA1 354878333fc3c489b3b6ab73c2923abe81e0ec73 t/pod.t
SHA1 84b0d1a2d1efd60947ca444e59124b05d44e2e2b t/pod_cov.t
SHA1 4c28c03a8e373c03a0246548394588855e4173b9 t/req_mbf0.t
SHA1 1317f0500ac902cff77d78ea92b2b72dbf188331 t/req_mbf1.t
SHA1 4ce690af449cd6382b1372d4bacacb2781e91574 t/req_mbfa.t
SHA1 f9a7cd852a68cda48482e7c85d27bccc3794dce5 t/req_mbfi.t
SHA1 49d78117c94e7406a63b0825ddee9a7e9fbc6a00 t/req_mbfn.t
SHA1 ef3834f63ddf05286de80b1d7bb1fb420e117183 t/req_mbfw.t
SHA1 1bbe72733abd2f580f94b6a147672f7671260149 t/require.t
SHA1 ad6cc6fe4bb93ae78db4eb7dcb96c95024b963d2 t/round.t
SHA1 9d51def046889bf20c6ac2a278f9b3f5f8e36025 t/sub_ali.t
SHA1 b0f1b46337df8b05212ada10205839c3f172071e t/sub_mbf.t
SHA1 0122fe4c9ecb58e68df90168b2952275c7253af9 t/sub_mbi.t
SHA1 317dd7564b180f5d7b14e4dac64ee90f42317baa t/sub_mif.t
SHA1 22c563a6879c94ce7c8eb72c645f2e374837c34e t/trap.t
SHA1 f8bf42aefd7fed875e4bc6f9e0d3b0f8bf574049 t/upgrade.inc
SHA1 6d12a4d44729cf096c4a22935484ffe72055aaf8 t/upgrade.t
SHA1 49183118717b8b90e498b6d7b1ac0aa0e4d85894 t/upgradef.t
SHA1 d58003dbb3ffb469dee56b8c93c5a6b3c353ddb7 t/use.t
SHA1 0c7c020cb79ae009a3a32b411f21a35153c6f776 t/use_lib1.t
SHA1 4959257dd52935cdfd17b132e11bcdb4e37752e9 t/use_lib2.t
SHA1 29606835c9d63a19075003429b00947b922ef144 t/use_lib3.t
SHA1 a5cc44a7e485828791696b2b27925e0d2855f883 t/use_lib4.t
SHA1 0c5f496ed66b02d0e118763c91862d84e3fb5629 t/use_mbfw.t
SHA1 b72b5652e970010503c5a6012397e53230d380d3 t/with_sub.t
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
iEYEARECAAYFAkyOpiUACgkQdC8qQo5jWl7I8ACfajegexfI2eo+qsN46PGAfNJU
N6sAoIXmyY3OzPJe5dzCqnmdnmEhxK+v
=89qz
-----END PGP SIGNATURE-----
See also various .pm files.
General:
* Copy on write (helps for $x = -$x; cases etc) (seems to make it slower :/
* run config() and die_on_nan() tests under Subclass.pm
Math::BigFloat:
* finish upgrading and downgrading
* ! bround()/bfround(): some bugs may lurk in there
* accuracy() & precision() maybe not finished (bnorm() in every op, testcases)
* do not reduce numbers in new(), rather do it in anything that outputs it
like bsstr(), bstr(), mantissa(), exponent() and parts(). Reducing the
number after each op is slow with a binary core math lib like BitVect.
* add bfract() that returns just the fractional part?
* tests for frsft() and flsft() with $n != 2
* blog() is still quite slow for non-integer results. See if we can reuse the
integer calculation somehow
* finish broot() by using different algorithmn
* hexadecimal integers work, but what about '0xABC.DEF'? Really needed?
Math::BigInt:
* finish 'upgrade'
* remove rounding overhead when no rounding is done, e.g. no $object has A nor
P and neither of bround(), bround(), accuracy() or precision() was called
* bround() is only used by MBF for -$scale = -$len, anyway. POD is wrong for
this, too
* overload of cos()/sin()/exp()/atan2() is too DWIM (should return BigInt or
BigFloat, not scalar) - also document it
* +5 % 0 or -5 % 0 == NaN (should it be something else?)
* certain shortcuts returning bzero(), bone() etc may not set the requested
rounding parameters, so that $x->foo($y,$a,$p,$r) may return $x without a
set $a or $p, thus failing later on:
use Test;
BEGIN { plan tests => 1; }
use Math::BigInt;
$x = Math::BigInt->bone();
$x->bsqrt(3,0,'odd'); # $x = 0, but _a is not 3!
ok ($x + '12345','12300'); # fails (12346 instead of 12300)
The shortcuts in code that return $x->bzero() or similiar things need to
do $x->bzero($a,$p); and this needs tests.
Update: Should now work for most things. Check for completeness.
Given the fact that we are be able to plug-in a much faster core-lib, the
following are pretty much ultra-low-priority:
Math::BigInt::Calc:
* look at div() for more speed (I have the hunch that the general _div()
routine does way too much work for normal div (e.g. when we don't need
the reminder). A simplified version could take care of this.
* alternative mul() method using shifts
* implement in Calc (and GMP etc) to calculate band(), bior(), bxor() for
negative inputs (_signed_or() etc)
* _root() doesn't scale too well
Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!
Tels <http://bloodgate.com/>
# The First 1,000 Primes
# (the 1,000th is 7919)
# For more information on primes see http://www.utm.edu/research/primes
2 3 5 7 11 13 17 19 23 29
31 37 41 43 47 53 59 61 67 71
73 79 83 89 97 101 103 107 109 113
127 131 137 139 149 151 157 163 167 173
179 181 191 193 197 199 211 223 227 229
233 239 241 251 257 263 269 271 277 281
283 293 307 311 313 317 331 337 347 349
353 359 367 373 379 383 389 397 401 409
419 421 431 433 439 443 449 457 461 463
467 479 487 491 499 503 509 521 523 541
547 557 563 569 571 577 587 593 599 601
607 613 617 619 631 641 643 647 653 659
661 673 677 683 691 701 709 719 727 733
739 743 751 757 761 769 773 787 797 809
811 821 823 827 829 839 853 857 859 863
877 881 883 887 907 911 919 929 937 941
947 953 967 971 977 983 991 997 1009 1013
1019 1021 1031 1033 1039 1049 1051 1061 1063 1069
1087 1091 1093 1097 1103 1109 1117 1123 1129 1151
1153 1163 1171 1181 1187 1193 1201 1213 1217 1223
1229 1231 1237 1249 1259 1277 1279 1283 1289 1291
1297 1301 1303 1307 1319 1321 1327 1361 1367 1373
1381 1399 1409 1423 1427 1429 1433 1439 1447 1451
1453 1459 1471 1481 1483 1487 1489 1493 1499 1511
1523 1531 1543 1549 1553 1559 1567 1571 1579 1583
1597 1601 1607 1609 1613 1619 1621 1627 1637 1657
1663 1667 1669 1693 1697 1699 1709 1721 1723 1733
1741 1747 1753 1759 1777 1783 1787 1789 1801 1811
1823 1831 1847 1861 1867 1871 1873 1877 1879 1889
1901 1907 1913 1931 1933 1949 1951 1973 1979 1987
1993 1997 1999 2003 2011 2017 2027 2029 2039 2053
2063 2069 2081 2083 2087 2089 2099 2111 2113 2129
2131 2137 2141 2143 2153 2161 2179 2203 2207 2213
2221 2237 2239 2243 2251 2267 2269 2273 2281 2287
2293 2297 2309 2311 2333 2339 2341 2347 2351 2357
2371 2377 2381 2383 2389 2393 2399 2411 2417 2423
2437 2441 2447 2459 2467 2473 2477 2503 2521 2531
2539 2543 2549 2551 2557 2579 2591 2593 2609 2617
2621 2633 2647 2657 2659 2663 2671 2677 2683 2687
2689 2693 2699 2707 2711 2713 2719 2729 2731 2741
2749 2753 2767 2777 2789 2791 2797 2801 2803 2819
2833 2837 2843 2851 2857 2861 2879 2887 2897 2903
2909 2917 2927 2939 2953 2957 2963 2969 2971 2999
3001 3011 3019 3023 3037 3041 3049 3061 3067 3079
3083 3089 3109 3119 3121 3137 3163 3167 3169 3181
3187 3191 3203 3209 3217 3221 3229 3251 3253 3257
3259 3271 3299 3301 3307 3313 3319 3323 3329 3331
3343 3347 3359 3361 3371 3373 3389 3391 3407 3413
3433 3449 3457 3461 3463 3467 3469 3491 3499 3511
3517 3527 3529 3533 3539 3541 3547 3557 3559 3571
3581 3583 3593 3607 3613 3617 3623 3631 3637 3643
3659 3671 3673 3677 3691 3697 3701 3709 3719 3727
3733 3739 3761 3767 3769 3779 3793 3797 3803 3821
3823 3833 3847 3851 3853 3863 3877 3881 3889 3907
3911 3917 3919 3923 3929 3931 3943 3947 3967 3989
4001 4003 4007 4013 4019 4021 4027 4049 4051 4057
4073 4079 4091 4093 4099 4111 4127 4129 4133 4139
4153 4157 4159 4177 4201 4211 4217 4219 4229 4231
4241 4243 4253 4259 4261 4271 4273 4283 4289 4297