mpz_nextprime documentation

Sisyphus kalinabears at iinet.net.au
Wed Feb 2 18:32:16 CET 2005


keith.briggs at bt.com wrote:
> http://www.swox.com/gmp/manual/Number-Theoretic-Functions.html#Number%20Theoretic%20Functions:
> 
>>Set rop to the next prime greater than op. 
>>This function uses a probabilistic algorithm to identify primes. For practical purposes it's adequate, the chance of a composite passing will be extremely small. 
> 
> It would be nice if it told us if there's any chance of it missing a prime!
> 

In case you're wondering - there's no chance of it "missing a prime".

Cheers,
Rob



More information about the gmp-discuss mailing list