Math-Prime-Util icon indicating copy to clipboard operation
Math-Prime-Util copied to clipboard

Perl (XS) module implementing prime number utilities, including sieves

Results 28 Math-Prime-Util issues
Sort by recently updated
recently updated
newest added

I recently saw your project Math Prime Util GMP on GitHub. I want to inquire about the principle of the algorithm 'lucas sequence'. Could you provide me with a **pseudocode**?...

``` % $PERL -MMath::Prime::Util=sqrtmod -wle 'print sqrtmod(4, 8) // "undef"' undef % MPU_NO_XS=1 $PERL -MMath::Prime::Util=sqrtmod -wle 'print sqrtmod(4, 8) // "undef"' 2 % ``` Spotted "if 8|n 'a' must =...

Iterating over k-almost primes in a given range [A,B], when A and B are quite large, seems to be quite slow. But it can be made much faster! :) Example:...

I'm writing code to fork multiple processes, each of which will test one number - anything from a primality test to a full factorization. Other than loading MPU and MPUG,...

I'd really love to see a release with some of the bugfixes and new features. What can I do to help make that happen? I have a lot of experience...

A first stab at removing M::P::U’s dependency on XS. This implements a fallback so that it tries Bytes::Random::Secure first, then falls back to B::R::S::Tiny. Maybe B::R::S::Tiny should be a requirement?...

Using perl-5.34.0 with MPU-0.73. ``` % perl -MMath::GMP -MMath::Prime::Util=trial_factor -wle ' $x = Math::GMP->new(3)**91; print for trial_factor($x) ' 1937805869 2724724103 % ``` In `factor.c` I note that trial_factor takes a...

[cpan-testers](http://matrix.cpantesters.org/?dist=Math-Prime-Util+0.73) is showing all fails for perl-5.35.8 and .9. I'm not sure, but "Wstat 24" may mean that it received: ``` #define SIGXCPU 24 /* CPU time limit exceeded. */...

Hi. I tested the latest GitHub commit of `Math::Prime::Util` on a 32-bit Android phone, using the [Termux](https://termux.com/) environment and the `clang` compiler. Unfortunately, some tests failed: ![1-almost-primes](https://user-images.githubusercontent.com/614513/159677142-95d2cd57-e983-4a90-9f4b-bc906ebc9e74.jpg) ![2-semiprime](https://user-images.githubusercontent.com/614513/159677168-8c7023c1-bf4d-4b50-95af-482630e56b44.jpg) ![3-chinese](https://user-images.githubusercontent.com/614513/159677184-1cc678bb-a275-4755-b062-4f266ef60d45.jpg) ![4-lucky](https://user-images.githubusercontent.com/614513/159677209-8d7463f8-c4dd-4a12-8ec5-371bd76f42ae.jpg)...

A correspondent wanted to run some of my code on a Windows machine, and after running into problems with a first attempt based around WSL managed to get further (at...