A094855 Number of (s(0), s(1), ..., s(2n+1)) such that 0 < s(i) < 9 and |s(i) - s(i-1)| = 1 for i = 1,2,...,2n+1, s(0) = 4, s(2n+1) = 5.
1, 3, 10, 35, 124, 440, 1560, 5525, 19551, 69142, 244419, 863788, 3052100, 10782928, 38092457, 134560491, 475313762, 1678930611, 5930320300, 20946860064, 73987208296, 261331829501, 923052962407, 3260318517230, 11515766271219
Offset: 0
Links
- Michael De Vlieger, Table of n, a(n) for n = 0..1824
- Index entries for linear recurrences with constant coefficients, signature (7,-15,10,-1).
Programs
-
Maple
with(GraphTheory): G:=PathGraph(8): A:= AdjacencyMatrix(G): nmax:=24; for n from 0 to 2*nmax+2 do B(n):=A^n; a(n):=add(B(n)[1,k],k=1..8); od: seq(a(2*n+1),n=0..nmax); # Johannes W. Meijer, May 29 2010
-
Mathematica
LinearRecurrence[{7,-15,10,-1},{1,3,10,35},30] (* Harvey P. Dale, Jan 17 2022 *)
Formula
a(n) = (2/9)*Sum_{r=1..8} sin(4*r*Pi/9)*sin(5*r*Pi/9)*(2*cos(r*Pi/9))^(2n+1).
a(n) = 7*a(n-1) - 15*a(n-2) + 10*a(n-3) - a(n-4).
G.f.: (2*x-1)^2 / ( (x-1)*(x^3-9*x^2+6*x-1) ).
a(n) = A061551(2*n+1). - Johannes W. Meijer, May 29 2010
Comments