A154254 a(n) = 9*n^2 - 8*n + 2.
2, 3, 22, 59, 114, 187, 278, 387, 514, 659, 822, 1003, 1202, 1419, 1654, 1907, 2178, 2467, 2774, 3099, 3442, 3803, 4182, 4579, 4994, 5427, 5878, 6347, 6834, 7339, 7862, 8403, 8962, 9539, 10134, 10747, 11378, 12027, 12694, 13379, 14082, 14803, 15542, 16299, 17074, 17867
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..10000
- Index entries for linear recurrences with constant coefficients, signature (3,-3,1).
Programs
-
Magma
I:=[2, 3, 22]; [n le 3 select I[n] else 3*Self(n-1)-3*Self(n-2)+1*Self(n-3): n in [1..50]]; // Vincenzo Librandi, Jan 29 2012
-
Mathematica
LinearRecurrence[{3, -3, 1}, {2, 3, 22}, 50] (* Vincenzo Librandi, Jan 30 2012 *)
-
PARI
a(n)=9*n^2-8*n+2 \\ Charles R Greathouse IV, Dec 27 2011
Formula
From Vincenzo Librandi, Jan 30 2012: (Start)
G.f.: (2 - 3*x + 19*x^2)/(1-x)^3.
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). (End)
E.g.f.: exp(x)*(2 + x + 9*x^2). - Elmo R. Oliveira, Oct 19 2024
Extensions
7662 replaced by 7862 by R. J. Mathar, Jan 07 2009
Edited by Charles R Greathouse IV, Jul 25 2010
Comments