A128815 Numbers n such that n-th and (n+2)th triangular numbers sum up to a prime.
1, 2, 4, 5, 7, 11, 13, 14, 16, 19, 20, 23, 26, 32, 37, 40, 49, 53, 56, 58, 61, 65, 68, 70, 74, 76, 77, 79, 88, 89, 98, 100, 104, 109, 110, 116, 118, 130, 137, 140, 142, 146, 149, 152, 154, 160, 161, 163, 166, 167, 172, 175, 187, 188, 191, 193, 202, 205, 208, 214, 217
Offset: 1
Keywords
Examples
7 is a term because 7*8/2+9*10/2=73 is prime; 11 is a term because 11*12/2+13*14/2=157 is prime.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
Crossrefs
Cf. A000217.
Programs
-
Maple
select(t -> isprime(3+3*t+t^2), [$1..10000]); # Robert Israel, May 19 2014
-
Mathematica
Select[Range[300],PrimeQ[3+3#+#^2]&] Position[Partition[Accumulate[Range[250]],3,1],?(PrimeQ[#[[1]]+ #[[3]]]&), 1,Heads->False]//Flatten (* _Harvey P. Dale, Sep 04 2017 *)
Comments