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

A064545
Lesser of two consecutive primes such that n*p + q is a perfect square, p < q.
2
17, 7, 2, 23, 23, 17, 449, 13, 773, 7, 2, 1201, 41, 19, 66821, 13, 8191, 2477, 7, 66191, 113, 19, 2, 331, 8209, 27583, 89, 47, 433, 17, 1534751, 37, 2081, 113, 7, 7057, 263, 43, 2, 37, 41737, 4441, 13, 318023, 17, 43, 43801, 71, 23, 7, 11941, 23, 4231, 293
OFFSET
1,1
LINKS
EXAMPLE
a(1)=17 because 1*17 + 19 = 36, a square. a(2)=7 because 2*7 + 11 = 25 a square.
MATHEMATICA
Do[k = 1; While[ !IntegerQ[ Sqrt[ n*Prime[k] + Prime[k + 1]]], k++ ]; Print[ Prime[k]], {n, 1, 100} ]
PROG
(PARI) ps(n, k) = k*prime(n)+prime(n+1) k=1; for(n=1, 10^6, if(issquare(ps(n, k)), print1(prime(n), " "); k++; n=0))
(PARI) ps(m, n)= { n*prime(m) + prime(m + 1) } { n=0; default(primelimit, 4294965247); for (n=1, 100, m=1; while (!issquare(ps(m, n)), m++); write("b064545.txt", n, " ", prime(m)) ) } \\ Harry J. Smith, Sep 18 2009
CROSSREFS
Cf. A064543.
Sequence in context: A040276 A166211 A086763 * A114032 A107807 A075710
KEYWORD
nonn
AUTHOR
Jason Earls, Oct 08 2001
EXTENSIONS
More terms from Robert G. Wilson v, Oct 09 2001
STATUS
approved