login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A117761 Expansion of x*(1 + x^2 + x^4)/(1 - x - x^3 - x^5 - x^7). 1
0, 1, 1, 2, 3, 5, 8, 12, 20, 32, 51, 82, 131, 210, 336, 538, 862, 1380, 2210, 3539, 5667, 9075, 14532, 23271, 37265, 59674, 95559, 153023, 245043, 392399, 628367, 1006234, 1611330, 2580299, 4131955, 6616695, 10595627, 16967279, 27170507, 43509419 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,4
COMMENTS
Previous name: First entry of the vector (M^n)w, where M is the 7x7 matrix [[0,1,0,0,0,0,0], [0,0,1,0,0,0,0], [0,0,0,1,0,0,0], [0,0,0,0,1,0,0], [0,0,0,0,0,1,0], [0,0,0,0,0,0,1], [1,0,1,0,1,0,1]] and w is the column vector [0,1,1,2,3,5,8].
LINKS
FORMULA
a(n) = a(n-1) + a(n-3) + a(n-5) + a(n-7).
G.f.: (x + x^3 + x^5)/(1 - x - x^3 - x^5 - x^7). - Joel B. Lewis, Nov 14 2012
MAPLE
with(linalg): M:=matrix(7, 7, [0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 0, 1, 0, 1]):
w[0]:=matrix(7, 1, [0, 1, 1, 2, 3, 5, 8]): for n from 1 to 40 do
w[n]:=multiply(M, w[n-1]) od: seq(w[n][1, 1], n=0..40);
MATHEMATICA
M = {{0, 1, 0, 0, 0, 0, 0}, {0, 0, 1, 0, 0, 0, 0}, {0, 0, 0, 1, 0, 0, 0}, {0, 0, 0, 0, 1, 0, 0}, {0, 0, 0, 0, 0, 1, 0}, {0, 0, 0, 0, 0, 0, 1}, {1, 0, 1, 0, 1, 0, 1}};
w[1] = {0, 1, 1, 2, 3, 5, 8}; w[n_]:= w[n]= M.w[n-1];
A117761[n_]:= w[n][[1]];
Table[A117761[n], {n, 50}]
LinearRecurrence[{1, 0, 1, 0, 1, 0, 1}, {0, 1, 1, 2, 3, 5, 8}, 50] (* Harvey P. Dale, Oct 06 2017 *)
PROG
(Magma) R<x>:=PowerSeriesRing(Integers(), 50); [0] cat Coefficients(R!( x*(1+x^2+x^4)/(1-x-x^3-x^5-x^7) )); // G. C. Greubel, Jul 21 2023
(SageMath)
@CachedFunction
def a(n): # a = A117761
if n<8: return fibonacci(n) - int(n==7)
else: return a(n-1) + a(n-3) + a(n-5) + a(n-7)
[a(n) for n in range(51)] # G. C. Greubel, Jul 21 2023
CROSSREFS
Cf. A117760.
Sequence in context: A170805 A013984 A107479 * A274376 A018149 A152909
KEYWORD
nonn,easy
AUTHOR
Roger L. Bagula, Apr 14 2006
EXTENSIONS
Edited by N. J. A. Sloane, Apr 30 2006
New name from Joel B. Lewis, Nov 14 2012
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 11:35 EDT 2024. Contains 371912 sequences. (Running on oeis4.)