OFFSET
0,2
COMMENTS
1. Smallest triangular number T(k) (other than the trivial adjacent ones) such that T(n) + T(k) is a square. ( T(n-1) and T(n+1) are trivial triangular numbers such that T(n) +T(n-1) and T(n) + T(n+1) both are squares.) 0+1 = 1, 1+15 = 16, 3+ 78= 81, 6 + 190 = 196 etc. 2. (7n+5)-th triangular number. - Amarnath Murthy, Jun 20 2003
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..2000
Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
FORMULA
a(n) = (2 - 21*n + 49*n^2)/2.
G.f.: (1+6*x)^2/(1-x)^3.
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3); a(0)=1, a(1)=15, a(2)=78. - Harvey P. Dale, Aug 03 2012
MATHEMATICA
Table[(2-21n+49n^2)/2, {n, 0, 40}] (* or *) LinearRecurrence[{3, -3, 1}, {1, 15, 78}, 40] (* Harvey P. Dale, Aug 03 2012 *)
PROG
(Magma) [(2-21*n+49*n^2)/2: n in [0..50]]; // Vincenzo Librandi, Jun 18 2011
(PARI) a(n)=(2-21*n+49*n^2)/2 \\ Charles R Greathouse IV, Jun 17 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Mar 23 2003
STATUS
approved