login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A103654
Primes which are the average of two successive semiprimes.
5
5, 53, 67, 89, 113, 131, 173, 211, 251, 293, 307, 337, 379, 409, 449, 487, 491, 499, 631, 683, 701, 727, 751, 769, 787, 919, 941, 953, 991, 1009, 1039, 1051, 1063, 1117, 1193, 1259, 1399, 1459, 1471, 1499, 1511, 1567, 1627, 1697, 1709, 1733, 1759, 1787, 1801
OFFSET
1,1
FORMULA
p=(q+r)/2, where q<p and r>p are two successive semiprimes closest to p.
EXAMPLE
a(3)=67 because 65 and 69 are two successive semiprimes closest to 67 and 67=(65+69)/2;a(333)=22679 because 22677 and 22691 are two successive semiprimes closest to 22679 and 22679=(22677+22681)/2.
PROG
(PARI) list(lim)=my(v=List(), u=v, t, lim2=lim+log(lim)^2); forprime(p=2, sqrt(lim2), t=p; forprime(q=p, lim2\t, listput(v, t*q))); v=vecsort(Vec(v)); for(i=2, #v, t=(v[i]+v[i-1])/2; if(denominator(t)==1&&isprime(t), if(t>lim, break, listput(u, t)))); Vec(u) \\ Charles R Greathouse IV, Oct 08 2012
CROSSREFS
Indices of these primes: A103655. Primes: A000040, semiprimes: A001358, number of primes between successive semiprimes: A088700, number of semiprimes between two successive primes: A103668.
Sequence in context: A045711 A090153 A188339 * A079385 A352690 A362252
KEYWORD
nonn
AUTHOR
Zak Seidov, Feb 12 2005
STATUS
approved