[go: up one dir, main page]

login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A076841
a(1) = a(2) = 1; a(n) = (a(n-1)+1)/a(n-2) (for n>2, n odd), (a(n-1)^3+1)/a(n-2) (for n>2, n even).
3
1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2, 9, 5, 14, 3, 2, 1, 1, 2
OFFSET
1,3
COMMENTS
Any sequence a(1),a(2),a(3),... defined by the recurrence a(n) = (a(n-1)+1)/a(n-2) (for n>2, n odd), (a(n-1)^3+1)/a(n-2) (for n>2, n even) has period 8. The theory of cluster algebras currently being developed by Fomin and Zelevinsky gives a context for these facts, but it doesn't really explain them in an elementary way. - James Propp, Nov 20, 2002
MAPLE
a := 1; b := 1; f := proc(n) option remember; global a, b; if n=1 then RETURN(a); fi; if n=2 then RETURN(b); fi; if n mod 2 = 1 then RETURN((f(n-1)+1)/f(n-2)); fi; RETURN((f(n-1)^3+1)/f(n-2)); end;
MATHEMATICA
LinearRecurrence[{0, 0, 0, 0, 0, 0, 0, 1}, {1, 1, 2, 9, 5, 14, 3, 2}, 99] (* Ray Chandler, Aug 25 2015 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Nov 21 2002
STATUS
approved