A178381 Number of paths of length n starting at initial node of the path graph P_9.
1, 1, 2, 3, 6, 10, 20, 35, 70, 125, 250, 450, 900, 1625, 3250, 5875, 11750, 21250, 42500, 76875, 153750, 278125, 556250, 1006250, 2012500, 3640625, 7281250, 13171875, 26343750, 47656250, 95312500, 172421875, 344843750
Offset: 0
Examples
G.f. = 1 + x + 2*x^2 + 3*x^3 + 6*x^4 + 10*x^5 + 20*x^6 + 35*x^7 + 70*x^8 + ...
Links
- G. C. Greubel, Table of n, a(n) for n = 0..1000
- Johann Cigler, Some remarks and conjectures related to lattice paths in strips along the x-axis, arXiv:1501.04750 [math.CO], 2015-2016.
- Nachum Dershowitz, Between Broadway and the Hudson, arXiv:2006.06516 [math.CO], 2020.
- Eric Weisstein's World of Mathematics, Trigonometric Identities.
- Index entries for linear recurrences with constant coefficients, signature (0,5,0,-5).
Crossrefs
Programs
-
Magma
m:=50; R
:=PowerSeriesRing(Integers(), m); Coefficients(R!((1+x-3*x^2-2*x^3+x^4)/(1-5*x^2+5*x^4))); // G. C. Greubel, Sep 18 2018 -
Maple
with(GraphTheory): P:=9: G:=PathGraph(P): A:= AdjacencyMatrix(G): nmax:=36; for n from 0 to nmax do B(n):=A^n; a(n):=add(B(n)[1,k],k=1..P); od: seq(a(n),n=0..nmax); r := j -> (-1)^(j/10) - (-1)^(1-j/10): a := k -> add((2 + r(j))*r(j)^k, j in [1, 3, 5, 7, 9])/10: seq(simplify(a(n)), n=0..30); # Peter Luschny, Sep 18 2020
-
Mathematica
CoefficientList[Series[(1+x-3*x^2-2*x^3+x^4)/(1-5*x^2+5*x^4), {x,0,50}], x] (* G. C. Greubel, Sep 18 2018 *)
-
PARI
x='x+O('x^50); Vec((1+x-3*x^2-2*x^3+x^4)/(1-5*x^2+5*x^4)) \\ G. C. Greubel, Sep 18 2018
Formula
G.f.: (1+x-3*x^2-2*x^3+x^4)/(1-5*x^2+5*x^4).
a(n) = 5*a(n-2) - 5*a(n-4) for n>=5 with a(0)=1, a(1)=1, a(2)=2, a(3)=3 and a(4)=6.
G.f.: 1 / (1 - x / (1 - x / (1 + x / (1 + x / (1 - x / (1 - x / (1 + x / (1 + x)))))))). - Michael Somos, Feb 08 2015
Comments