Subject: | BigFloat batan(1.5) infinite loop |

Date: | Sat, 31 Aug 2013 06:23:41 +1000 |

To: | bug-Math-BigInt [...] rt.cpan.org |

From: | Kevin Ryde <user42 [...] zip.com.au> |

With Math::BigFloat 1.997 and recent debian i386 perl 5.14.2, the
program foo.pl below goes into an apparently infinite loop, where I
hoped it would print
batan=0.982793723...
There seems to be something doubtful where batan() notices abs($x) > 1
and inverts to 1/$x for the power series. If $x is an integer then $x>1
is noticed correctly, but if $x is not an integer then seems not.

#!/usr/bin/perl -w
use strict;
use Math::BigFloat;
my $x = Math::BigFloat->new(1.5);
$x->batan();
print "batan=$x\n";
exit 0;

--
Events jargon elucidated for the layman:
"Wedding package" -- twice the price and non-refundable.