A319128 Interleave n*(3*n - 2), 3*n^2 + n - 1, n=0,0,1,1, ... .
0, -1, 1, 3, 8, 13, 21, 29, 40, 51, 65, 79, 96, 113, 133, 153, 176, 199, 225, 251, 280, 309, 341, 373, 408, 443, 481, 519, 560, 601, 645, 689, 736, 783, 833, 883, 936, 989, 1045, 1101, 1160, 1219, 1281, 1343, 1408, 1473, 1541, 1609, 1680, 1751
Offset: 0
Links
- Colin Barker, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (2,0,-2,1).
Programs
-
GAP
Flat(List([0..30],n->[3*n^2-2*n,3*n^2+n-1])); # Muniru A Asiru, Sep 19 2018
-
Maple
seq(op([3*n^2-2*n,3*n^2+n-1]),n=0..30); # Muniru A Asiru, Sep 19 2018
-
Mathematica
LinearRecurrence[{2, 0, -2, 1}, {0, -1, 1, 3 }, 40] (* Stefano Spezia, Sep 16 2018 *)
-
PARI
concat(0, Vec(-x*(1 - 3*x - x^2) / ((1 - x)^3*(1 + x)) + O(x^40))) \\ Colin Barker, Sep 14 2018
Formula
a(n+1) = a(n) + (6*n^2 - 3*(-1)^n - 1)/4, n=0,1,2, ... , a(0) = 0.
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4), n>3.
From Colin Barker, Sep 14 2018: (Start)
G.f.: -x*(1 - 3*x - x^2) / ((1 - x)^3*(1 + x)).
a(n) = (-4*n + 3*n^2) / 4 for n even.
a(n) = (-3 - 4*n + 3*n^2) / 4 for n odd.
(End)
a(n) = (-3 + 3*(-1)^n - 8*n + 6*n^2)/8. - Colin Barker, Sep 14 2018
E.g.f.: (x*(3*x - 1)*cosh(x) + (3*x^2 - x - 3)*sinh(x))/4. - Stefano Spezia, Mar 15 2020
Comments