20050125, 20:43  #1 
67·73 Posts 
subsets of primes
Can anyone direct me to a prime number generator with the facility of listing subsets?
emanuelmarks@aol.com 
20050126, 01:43  #2 
3,343 Posts 
I don't know what you mean by a facility of listing subsets...but the equation y=x^2 + x + 17 will work to generate primes (not all of them in order, it skips some) up to a certain point, just don't ask me what that point is.

20050126, 08:10  #3 
Mar 2003
New Zealand
13×89 Posts 
The PARI/GP calculator might do what you want. For example to list each prime in the range 21000 which ends in a 7:
forprime(p=2,1000,if(p%10==7,print(p))) It is free software, or you can use the online version at http://modular.fas.harvard.edu/calc/. 
20050127, 00:37  #4 
Mar 2003
New Zealand
13·89 Posts 
It seems the online version of the GP calculator won't accept any input containing the % character, so the example above could be changed to
forprime(p=2,1000,if(gcd(p+3,10)==10,print(p))) Better to install the full version I think :) Last fiddled with by geoff on 20050127 at 00:51 
Thread Tools  
Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Mersenne Primes p which are in a set of twin primes is finite?  carpetpool  Miscellaneous Math  3  20170810 13:47 
Distribution of Mersenne primes before and after couples of primes found  emily  Math  34  20170716 18:44 
Product of consecuative terms in subsets of primes is 1 (mod ab)  carpetpool  Miscellaneous Math  1  20170225 16:08 
Spanning and subsets  jacko  Homework Help  2  20070911 16:44 
possible primes (real primes & poss.prime products)  troels munkner  Miscellaneous Math  4  20060602 08:35 