OFFSET
1,2
LINKS
K. D. Bajpai, Table of n, a(n) for n = 1..10000
EXAMPLE
a(4)=9: T(9)+S(9)+1= 9/2*(9+1)+9^2+1= 127 which is prime.
a(5)=12: T(12)+S(12)+1= 12/2*(12+1)+12^2+1= 223 which is prime.
MAPLE
KD:= proc() local a, b, c, d; a:= n/2*(n+1)+n^2+1; if isprime(a) then RETURN(n): fi; end: seq(KD(), n=1..5000);
PROG
(PARI) v=List(); for(n=1, 10^5, if(isprime(n/2*(n+1)+n^2+1), listput(v, n))); Vec(v)
(PARI) is(n)=isprime(n*(3*n+1)/2+1) \\ Charles R Greathouse IV, Sep 24 2013
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
K. D. Bajpai, Sep 24 2013
STATUS
approved