login
A294259
a(n) = n*(n^3 + 2*n^2 - 5*n + 10)/8.
2
0, 1, 4, 15, 43, 100, 201, 364, 610, 963, 1450, 2101, 2949, 4030, 5383, 7050, 9076, 11509, 14400, 17803, 21775, 26376, 31669, 37720, 44598, 52375, 61126, 70929, 81865, 94018, 107475, 122326, 138664, 156585, 176188, 197575, 220851, 246124, 273505, 303108, 335050, 369451
OFFSET
0,3
COMMENTS
a(n) is even for n in A047481.
Also, a(n) is divisible by 5 if and only if n belongs to A047218.
FORMULA
O.g.f.: x*(1 - x + 5*x^2 - 2*x^3)/(1 - x)^5.
E.g.f.: x*(8 + 8*x + 8*x^2 + x^3)*exp(x)/8.
a(n) = 5*a(n-1) - 10*a(n-2) + 10*a(n-3) - 5*a(n-4) + a(n-5) for n>4.
a(n) = 2*n + Sum_{i=0..n} i*(i^2 - 3)/2.
EXAMPLE
After 0:
1 = -(0) + (1);
4 = -(0 + 1) + (2 + 2*3/2);
15 = -(0 + 1 + 2) + (3 + 4 + 5 + 3*4/2);
43 = -(0 + 1 + 2 + 3) + (4 + 5 + 6 + 7 + 8 + 9 + 4*5/2);
100 = -(0 + 1 + 2 + 3 + 4) + (5 + 6 + 7 + 8 + ... + 14 + 5*6/2);
201 = -(0 + 1 + 2 + 3 + 4 + 5) + (6 + 7 + 8 + 9 + ... + 20 + 6*7/2), etc.
MAPLE
a := n -> n*(n*(n*(n+2)-5)+10)/8: seq(a(n), n=0..41); # Peter Luschny, Nov 06 2017
MATHEMATICA
Table[n (n^3 + 2 n^2 - 5 n + 10)/8, {n, 0, 50}]
LinearRecurrence[{5, -10, 10, -5, 1}, {0, 1, 4, 15, 43}, 50] (* Harvey P. Dale, Jan 08 2024 *)
PROG
(PARI) vector(50, n, n--; n*(n^3+2*n^2-5*n+10)/8)
(Sage) [n*(n^3+2*n^2-5*n+10)/8 for n in range(50)]
(Maxima) makelist(n*(n^3+2*n^2-5*n+10)/8, n, 0, 50);
(Magma) [n*(n^3+2*n^2-5*n+10)/8: n in [0..50]];
(GAP) List([0..50], n -> n*(n^3+2*n^2-5*n+10)/8);
CROSSREFS
Cf. A101374: the sums in the Example section end in squares.
Subsequence of A047207.
Sequence in context: A085567 A187928 A213498 * A240359 A282522 A329523
KEYWORD
nonn,easy
AUTHOR
Bruno Berselli, Oct 30 2017
STATUS
approved