OFFSET
1,1
COMMENTS
Agrees with sequence A002061 (n^2-n+1 = central polygonal numbers) starting with sixth term.
LINKS
FORMULA
a(n) = n^2 + 7*n + 13. - Charles R Greathouse IV, Aug 10 2010
From Elmo R. Oliveira, Apr 21 2026: (Start)
G.f.: x*(21 - 32*x + 13*x^2)/(1 - x)^3.
E.g.f.: -13 + (13 + 8*x + x^2)*exp(x).
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). (End)
MATHEMATICA
Array[#^2 + 7 # + 13 &, 48] (* Michael De Vlieger, Aug 05 2020 *)
(* Alternative: *)
LinearRecurrence[{3, -3, 1}, {21, 31, 43}, 50] (* Harvey P. Dale, Apr 29 2022 *)
PROG
(PARI) a(n)=n^2+7*n+13 \\ Charles R Greathouse IV, Jun 17 2017
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Patrick De Geest, Sep 15 1998
EXTENSIONS
Offset 1 from Alois P. Heinz, Aug 05 2020
STATUS
approved
