Skip Menu |
 

This queue is for tickets about the Math-Primality CPAN distribution.

Report information
The Basics
Id: 85214
Status: open
Priority: 0/
Queue: Math-Primality

People
Owner: Nobody in particular
Requestors: DANAJ [...] cpan.org
Cc:
AdminCc:

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



Subject: is_aks_prime broken
Download (untitled) / with headers
text/plain 484b
This is fixed in the current github release. perl -MMath::Primality::AKS=:all -E 'say is_aks_prime("1405598103723853529388939745488223587751");' 1 perl -MMath::Primality=:all -E 'say is_prime("1405598103723853529388939745488223587751");' 0 perl -MMath::Prime::Util -E 'use bigint; say is_aks_prime(1405598103723853529388939745488223587751);' 0 factor.pl 1405598103723853529388939745488223587751 1405598103723853529388939745488223587751: 22167745667063210243 63407354308123817357
Download (untitled) / with headers
text/plain 725b
it's also on github and your first oneliner run against the code on github gives 0. https://github.com/leto/math--primality On Sun May 12 21:04:30 2013, DANAJ wrote: Show quoted text
> This is fixed in the current github release. > > perl -MMath::Primality::AKS=:all -E 'say > is_aks_prime("1405598103723853529388939745488223587751");' > 1 > > perl -MMath::Primality=:all -E 'say > is_prime("1405598103723853529388939745488223587751");' > 0 > > perl -MMath::Prime::Util -E 'use bigint; say > is_aks_prime(1405598103723853529388939745488223587751);' > 0 > > factor.pl 1405598103723853529388939745488223587751 > 1405598103723853529388939745488223587751: 22167745667063210243 > 63407354308123817357
-- Your bugs , they are afraid of me.
Download (untitled) / with headers
text/plain 357b
Maybe this wasn't the clearest ticket. The example number is a composite (shown the the factor one liner). Math::Primality version 0.08 on CPAN is broken -- it claims the number is prime (the one-liner returns 1). Math::Primality from github is not broken for this example. It correctly returns 0. Version 0.09 on github pretty much rewrote everything.


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

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.