A298270 Triangular numbers that for some k are also the sum of the first k composites.
0, 10, 78, 153, 946, 177310, 450775, 13595505, 150988753, 4478601403, 5409300078, 5589152128, 76060335351, 248156250265, 1793751529485, 176149383165876, 187718592284301, 233626949305596, 11362376565228270, 18886935830647605, 1943937379018997076
Offset: 1
Keywords
Examples
10 is a term because 10 = 1 + 2 + 3 + 4 = 4 + 6.
Programs
-
Mathematica
Join[{0},Select[Accumulate[Select[Range[10^6],CompositeQ]],OddQ[Sqrt[8#+1]]&]] (* The program generates the first 14 terms of the sequence. *) (* Harvey P. Dale, Apr 20 2024 *)
-
PARI
lista(nn) = {my(s=0); forcomposite(n=0, nn, if(ispolygonal(s, 3), print1(s, ", ")); s += n; ); } \\ after Michel Marcus at A053767