login
A122522
a(n) = a(n - 2) + a(n - 8), with a(1) = ... = a(8) = 1.
5
1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 7, 7, 10, 10, 14, 14, 19, 19, 26, 26, 36, 36, 50, 50, 69, 69, 95, 95, 131, 131, 181, 181, 250, 250, 345, 345, 476, 476, 657, 657, 907, 907, 1252, 1252, 1728, 1728, 2385, 2385, 3292, 3292, 4544, 4544, 6272, 6272, 8657, 8657
OFFSET
1,9
FORMULA
G.f.: x*(1+x)/(1 - x^2 - x^8). - G. C. Greubel, May 01 2017
MATHEMATICA
Rest@CoefficientList[Series[x*(1+x)/(1-x^2-x^8), {x, 0, 70}], x] (* G. C. Greubel, May 01 2017 *)
PROG
(PARI) my(x='x+O('x^70)); Vec(x*(1+x)/(1-x^2-x^8)) \\ G. C. Greubel, May 01 2017
(Magma) [n le 8 select 1 else Self(n-2) +Self(n-8): n in [1..70]]; // G. C. Greubel, Oct 24 2024
(SageMath)
@CachedFunction # a = A122522
def a(n): return 1 if n<9 else a(n-2) + a(n-8)
[a(n) for n in range(1, 71)] # G. C. Greubel, Oct 24 2024
CROSSREFS
Cf. A003269.
Sequence in context: A185328 A210718 A027191 * A227614 A236473 A029030
KEYWORD
nonn,easy,less,changed
AUTHOR
Roger L. Bagula, Sep 16 2006
EXTENSIONS
Edited by N. J. A. Sloane, Sep 17 2006
STATUS
approved