File: CHANGES

package info (click to toggle)
math-bigint 1.56-1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 604 kB
  • ctags: 280
  • sloc: perl: 5,486; pascal: 3,000; makefile: 50
file content (88 lines) | stat: -rw-r--r-- 4,493 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
This file contains all the CHANGES and bugfixes from original BigInt/BigFloat
to the rewritten one. For a complete list of changes see HISTORY:

v1.55:

 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
 output:
  + as_hex() and as_bin() 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(), as_hex(), as_bin()
  + is_positive(), is_negative()
  + mantissa(), exponent(), parts(), sign()
  + bgcd() accepts now lists, blcm() (also accepts lists)
  + flog()/blog() for overloading of log()
  + 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()
  + bfloor(), bceil()

Please send me test-reports, your experiences with this and your ideas - I love
to hear about my work!

Tels <http://bloodgate.com/>