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”).

A202996
Least prime q such that prime(n)^2 - q^2 - 1 and prime(n)^2 - q^2 + 1 are twin primes or 0 if no solution.
1
0, 0, 0, 0, 7, 0, 7, 7, 17, 23, 19, 7, 19, 19, 11, 11, 11, 7, 19, 37, 7, 19, 23, 19, 13, 31, 29, 17, 7, 23, 29, 23, 59, 113, 19, 23, 31, 151, 19, 7, 23, 37, 73, 7, 19, 19, 41, 19, 7, 31, 53, 41, 17, 43, 11, 17, 59, 73, 19, 173, 23, 47, 19, 53, 11, 31, 19, 23
OFFSET
1,5
COMMENTS
Conjecture: a(n) > 0 for n > 6.
Conjecture: With Sq=sum of q for n=1 to N and Sp=sum of p(n) for n=1 to N, lim sup Sq/Sp = 0.
EXAMPLE
No solution for n=1 to 4 prime(n) = 2, 3, 5, 7.
For prime(5)=11, 11^2-7^2-1 = 71, 71 and 73 twin primes so q(5)=7.
No solution for prime(6)=13
For prime(7)=17, 17^2-7^2-1=239, 239 and 241 twin primes so q(7)=7.
PROG
(PARI) a(n)=my(p=prime(n)); forprime(q=2, p-1, if(isprime(p^2-q^2-1)&&isprime(p^2-q^2+1), return(q))); 0 \\ Charles R Greathouse IV, Dec 27 2011
CROSSREFS
Sequence in context: A011438 A321022 A216185 * A019597 A096444 A246918
KEYWORD
nonn
AUTHOR
Pierre CAMI, Dec 27 2011
STATUS
approved