View Single Post
Old 2019-09-29, 12:35   #14
axn
 
axn's Avatar
 
Jun 2003

121D16 Posts
Default

Quote:
Originally Posted by CRGreathouse View Post
This is the test code I used while composing the above posts to generate numbers of the OP's form; I wonder if it's similar to your code, axn?
Similar-ish, but less sophisticated. I hardcoded the sizes, and didn't bother with getting exact bit-lengths (so randomprime(2^1024) and random(2^2048)). Also for q, I started at random point and walked along an AP until an appropriate prime is found.

The only additional thing is the use of setrand.
axn is online now   Reply With Quote