OFFSET
1,2
COMMENTS
The only triangular numbers T such that T-1 is a (positive) prime are 3 and 6.
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..10000
FORMULA
a(n) = A055469(n) - 1. - Joerg Arndt, Jun 19 2021
MATHEMATICA
Select[Accumulate[Range[200]], PrimeQ[#+1]&] (* Harvey P. Dale, Nov 08 2011 *)
PROG
(Python)
from sympy import isprime
def T(n): return n*(n+1)//2
def ok(T): return isprime(T+1)
print(list(filter(ok, (T(n) for n in range(175))))) # Michael S. Branicky, Jun 18 2021
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Zak Seidov, May 30 2007
STATUS
approved