[go: up one dir, main page]

login
A210647
Least nonnegative m such that k(n) + k(m) is prime, where k(n) = n*(n+1)^2/2.
2
0, 1, 22, 2, 142, 1, 2, 10, 22, 1, 34, 10, 2, 37, 46, 6, 10, 1, 6, 46, 46, 1, 10, 106, 6, 1, 58, 2, 22, 7, 2, 58, 94, 3, 22, 10, 2, 1, 22, 2, 10, 16, 6, 82, 118, 4, 82, 10, 18, 1, 10, 2, 22, 1, 2, 10, 10, 4, 22, 58, 2, 19, 10, 2, 46, 1, 10, 70, 82, 3, 22, 34
OFFSET
1,3
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
MATHEMATICA
f[n_] := n (n + 1)^2/2; Table[k = 0; While[! PrimeQ[f[n] + f[k]], k++]; k, {n, 100}] (* T. D. Noe, Apr 03 2012 *)
PROG
(PARI) a(n)=my(K=n*(n+1)^2/2, m); while(!isprime(K+m*(m+1)^2/2), m++); m \\ Charles R Greathouse IV, Aug 03 2012
CROSSREFS
KEYWORD
nonn
AUTHOR
Gerasimov Sergey, Mar 27 2012
EXTENSIONS
Corrected by R. J. Mathar, Mar 31 2012
STATUS
approved