A097139 Convolution of 5^n and floor(n/2).
0, 0, 1, 6, 32, 162, 813, 4068, 20344, 101724, 508625, 2543130, 12715656, 63578286, 317891437, 1589457192, 7947285968, 39736429848, 198682149249, 993410746254, 4967053731280, 24835268656410, 124176343282061, 620881716410316
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (6,-4,-6,5).
Crossrefs
Column k=5 of A368296.
Programs
-
Magma
[5^(n+1)/96 -n/8 -3/32 +(-1)^n/24: n in [0..30]]; // Vincenzo Librandi, Jun 25 2011
-
Maple
A097139 := proc(n) 5^(n+1)/96 -n/8 -3/32 +(-1)^n/24 ; end proc: # R. J. Mathar, Jan 08 2011
-
Mathematica
f[n_] := Floor[5^n/6]/4; Accumulate@ Array[f, 24, 0] a[n_] := a[n] = 6 a[n - 1] - 4 a[n - 2] - 6 a[n - 3] + 5 a[n - 4]; a[0] = a[1] = 0; a[2] = 1; a[3] = 6; Array[a, 24, 0] CoefficientList[ Series[x^2/((1 - x) (1 - 5 x) (1 - x^2)), {x, 0, 23}], x] (* Robert G. Wilson v, Jan 02 2011 *) LinearRecurrence[{6,-4,-6,5},{0,0,1,6},30] (* Harvey P. Dale, Mar 16 2019 *)
Formula
a(n) = 5^(n+1)/96 -n/8 -3/32 +(-1)^n/24. - R. J. Mathar, Jan 08 2011
G.f.: x^2/((1-x)*(1-5*x)*(1-x^2)).
a(n) = 6*a(n-1) - 4*a(n-2) - 6*a(n-3) + 5*a(n-4).
a(n) = Sum_{k=0..n} floor((n-k)/2)*4^k = Sum_{k=0..n} floor(k/2)*4^(n-k).
From Mircea Merca, Dec 27 2010: (Start)
4*a(n) = round((5*5^n-12*n-9)/24) = floor((5*5^n-12*n-5)/24) = ceiling((5*5^n-12*n-13)/24) = round((5*5^n-12*n-5)/24).
a(n) = a(n-2) + (5^(n-1)-1)/4, n>1. (End)
a(n) = (floor(5^(n+1)/24) - floor((n+1)/2))/4. - Seiichi Manyama, Dec 22 2023
Comments