| Jean-Luc ARNAUD on Tue, 23 May 2023 12:44:41 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
| factor and factorint performances |
Hi everybody,
Playing with factor and factorint functions, I was amazed at their performances (compared to other Math libraries), until I tried to factorize 2^1003-1.The reason PARI is slow is that it does a primality test each time it finds a factor. Since the number is large with lots of factors, then it takes a long time. (about 90s for each factor). So it should finish in about 54 hours. If we expected that the number do not have prime factors larger than some bounds, we could just skip the primality test.
Could this be a solution? How would you do that?
TIA for your help.
-- Jean-Luc Arnaud