OFFSET
1,1
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
EXAMPLE
a(1)=2 because 2 is a prime and semiprime(2)=6<(only one prime 7)<9=semiprime(2+1),
a(2)=13 because 13 is a prime and semiprime(13)=35<(only one prime 37)<38=semiprime(13+1).
PROG
(PARI) list(lim)=my(lm=1.1*lim*log(lim)/log(log(lim)), v=List(), u=List(), t); forprime(p=2, sqrt(lm), t=p; forprime(q=p, lm\t, listput(v, t*q))); v=vecsort(Vec(v)); forprime(p=2, lim, t=0; for(k=v[p]+1, v[p+1]-1, if(isprime(k)&&t++>1, break)); if(t==1, listput(u, p))); v=0; Vec(u) \\ Charles R Greathouse IV, Sep 11 2011
CROSSREFS
KEYWORD
nonn,less
AUTHOR
Juri-Stepan Gerasimov, Sep 11 2011
EXTENSIONS
Sequence corrected by Charles R Greathouse IV, Sep 11 2011
STATUS
approved