Skip Menu |

This queue is for tickets about the Algorithm-CurveFit CPAN distribution.

Report information
The Basics
Id: 118695
Status: new
Priority: 0/
Queue: Algorithm-CurveFit

Owner: Nobody in particular
Requestors: ppisar [...]

Bug Information
Severity: (no value)
Broken in: 1.05
Fixed in: (no value)

Subject: t/02bad_deriv.t fails on little-endian PPC: Can't call method "element" on an undefined value
Download (untitled) / with headers
text/plain 1.4k
The t/02bad_deriv.t test fails for me on little-endian 64-bit PowerPC: Can't call method "element" on an undefined value at /builddir/build/BUILD/Algorithm-CurveFit-1.05/blib/lib/Algorithm/ line 217. # Looks like your test exited with 255 before it could output anything. t/02bad_deriv.t .. Dubious, test returned 255 (wstat 65280, 0xff00) Failed 13/13 subtests The code is: # solve my $LR = $matrix->decompose_LR(); my ( $dim, $x, $B ) = $LR->solve_LR($vector); # extract parameter modifications and test for convergence my $last = 1; foreach my $pno ( 1 .. @parameters ) { → my $dlambda = $x->element( $pno, 1 ); It looks like $x matrix returned by solve_LR() is undef. Math::MatrixReal::solve_LR() documentation reads: The method returns a list of three items if a solution exists or an empty list otherwise (!). Therefore, you should always use this method like this: if ( ($dim,$x_vec,$base) = $LR->solve_LR($b_vec) ) { # do something with the solution... } else { # do something with the fact that there is no solution... } The Algorightm::CurveFit code does not handle this case when the solution does not exist. I don't understand the code good enough to say where the bug is, if it's possible to reach the unsolvable case or if this is some bug in underneath mathematical functions failing in the PowePC architecture.

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to