login
A026635
a(n) = Sum_{i=0..n} Sum_{j=0..n} A026626(i,j).
17
1, 3, 8, 18, 40, 84, 174, 354, 716, 1440, 2890, 5790, 11592, 23196, 46406, 92826, 185668, 371352, 742722, 1485462, 2970944, 5941908, 11883838, 23767698, 47535420, 95070864, 190141754, 380283534, 760567096, 1521134220, 3042268470, 6084536970, 12169073972
OFFSET
0,2
FORMULA
G.f.: (1+x^4)/((1-x)*(1-2*x)*(1-x^2)). - Ralf Stephan, Apr 30 2004
From Colin Barker, Sep 29 2017: (Start)
a(n) = (17*2^n - 6*n - 9 + (-1)^n)/6 for n>0.
a(n) = 3*a(n-1) - a(n-2) - 3*a(n-3) + 2*a(n-4) for n>4. (End)
E.g.f.: (1/6)*(-3 -3*3+2*x)*exp(x) + 17*exp(2*x) + exp(-x)). - G. C. Greubel, Jun 21 2024
MATHEMATICA
LinearRecurrence[{3, -1, -3, 2}, {1, 3, 8, 18, 40}, 40] (* Harvey P. Dale, Jan 17 2024 *)
PROG
(PARI) Vec((1 + x^4) / ((1 - x)^2*(1 + x)*(1 - 2*x)) + O(x^40)) \\ Colin Barker, Sep 29 2017
(Magma) [n eq 0 select 1 else (17*2^n -6*n-9+(-1)^n)/6: n in [0..40]]; // G. C. Greubel, Jun 21 2024
(SageMath) [(17*2^n -6*n -9 +(-1)^n -3*int(n==0))/6 for n in range(41)] # G. C. Greubel, Jun 21 2024
KEYWORD
nonn,easy
STATUS
approved