OFFSET
0,4
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
INRIA Algorithms Project, Encyclopedia of Combinatorial Structures 468
Index entries for linear recurrences with constant coefficients, signature (1,0,2).
FORMULA
G.f.: (1-x)/(1 - x - 2*x^3)
a(n) = a(n-1) + 2*a(n-3), with a(0)=1, a(1)=0, a(2)=0.
a(n) = Sum_{alpha = RootOf(-1+x+2*x^3)} (-1/29)*(1 - 10*alpha + 3*alpha^2)*alpha^(-1-n).
a(n) = Sum_{k=1..floor((n-1)/2)} binomial(n-1-2*k, k-1)*2^k, n>=1. - Taras Goy, Sep 18 2019
MAPLE
spec := [S, {S=Sequence(Prod(Z, Z, Union(Z, Z), Sequence(Z)))}, unlabeled]: seq(combstruct[count](spec, size=n), n=0..20);
MATHEMATICA
CoefficientList[Series[(1-x)/(1-x-2x^3), {x, 0, 50}], x] (*or*) LinearRecurrence[ {1, 0, 2}, {1, 0, 0}, 50] (* Vladimir Joseph Stephan Orlovsky, Jan 28 2012 *)
PROG
(PARI) my(x='x+O('x^50)); Vec((1-x)/(1-x-2*x^3)) \\ G. C. Greubel, May 09 2019
(Magma) R<x>:=PowerSeriesRing(Integers(), 50); Coefficients(R!( (1-x)/(1-x-2*x^3) )); // G. C. Greubel, May 09 2019
(Sage) ((1-x)/(1-x-2*x^3)).series(x, 50).coefficients(x, sparse=False) # G. C. Greubel, May 09 2019
(GAP) a:=[1, 0, 0];; for n in [4..50] do a[n]:=a[n-1]+2*a[n-3]; od; a; # G. C. Greubel, May 09 2019
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
encyclopedia(AT)pommard.inria.fr, Jan 25 2000
EXTENSIONS
More terms from James A. Sellers, Jun 05 2000
STATUS
approved