login
A153976
a(n) = n^3 + (n+2)^3.
5
8, 28, 72, 152, 280, 468, 728, 1072, 1512, 2060, 2728, 3528, 4472, 5572, 6840, 8288, 9928, 11772, 13832, 16120, 18648, 21428, 24472, 27792, 31400, 35308, 39528, 44072, 48952, 54180, 59768, 65728, 72072, 78812, 85960, 93528, 101528, 109972, 118872, 128240
OFFSET
0,1
FORMULA
For n>3, a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4). - Harvey P. Dale, Aug 02 2011
G.f.: 4*( 2-x+2*x^2 ) / (x-1)^4 . - R. J. Mathar, Apr 11 2016
a(n) = 4*A229183(n+1). - R. J. Mathar, Apr 11 2016
MATHEMATICA
f[n_]:=n^3; lst={}; Do[AppendTo[lst, (f[n]+f[n+2])], {n, 0, 6!}]; lst
Array[#^3+(#+2)^3&, 40, 0] (* or *) LinearRecurrence[{4, -6, 4, -1}, {8, 28, 72, 152}, 40] (* Harvey P. Dale, Aug 02 2011 *)
PROG
(Magma) [n^3+(n+2)^3: n in [0..60]]; // Vincenzo Librandi, Apr 26 2011
(Python)
def a(n): return n**3 + (n+2)**3
print([a(n) for n in range(40)]) # Michael S. Branicky, Aug 28 2021
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
Offset changed from 1 to 0 by Vincenzo Librandi, Apr 26 2011
STATUS
approved