cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A076844 a(1) = a(2) = a(3) = 1; a(n) = (a(n-1) + a(n-2) + 1)/a(n-3) (for n>3).

Original entry on oeis.org

1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1, 1, 1, 3, 5, 9, 5, 3, 1
Offset: 1

Views

Author

N. J. A. Sloane, Nov 21 2002

Keywords

Comments

Any sequence a(1),a(2),a(3),... defined by the recurrence a(n) = (a(n-1) + a(n-2) + 1)/a(n-3) (for n>3) has period 8. - James Propp, Nov 20 2002. This is the 8-cycle discovered by H. Todd - see Lyness, Note 1847. - N. J. A. Sloane, Jul 19 2020

Crossrefs

Programs

  • Maple
    a := 1; b := 1; c := 1; f := proc(n) option remember; global a,b,c; if n=1 then RETURN(a); fi; if n=2 then RETURN(b); fi; if n=3 then RETURN(c); fi; RETURN((f(n-1)+f(n-2)+1)/f(n-3)); end;
  • Mathematica
    nxt[{a_,b_,c_}]:={b,c,(b+c+1)/a}; Transpose[NestList[nxt,{1,1,1},110]][[1]] (* or *) PadRight[{},110,{1,1,1,3,5,9,5,3}] (* Harvey P. Dale, Jan 13 2015 *)
    LinearRecurrence[{0, 0, 0, 0, 0, 0, 0, 1},{1, 1, 1, 3, 5, 9, 5, 3},105] (* Ray Chandler, Aug 25 2015 *)

A076843 Denominators of sequence of fractions defined by a(1) = a(2) = 1; for n > 2, a(n) = (a(n-1)+a(n-2)+1)/a(n-2).

Original entry on oeis.org

1, 1, 1, 1, 1, 5, 15, 27, 261, 2059, 53321, 3826345, 599717165, 344730727333, 4379034727152233, 1299571503802595847199, 9181632264980134793594508931, 32308854341042109701936418652172579113, 67117797048843876734329361265492957492346044762131
Offset: 1

Views

Author

N. J. A. Sloane, Nov 21 2002

Keywords

Examples

			1, 1, 3, 5, 3, 9/5, 29/15, 71/27, 751/261, 5095/2059, 117707/53321, ...
		

Crossrefs

Programs

  • 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; RETURN((f(n-1)+f(n-2)+1)/f(n-2)); end;
  • Mathematica
    Denominator[RecurrenceTable[{a[1]==a[2]==1,a[n]==(a[n-1]+a[n-2]+1)/ a[n-2]},a,{n,20}]] (* Harvey P. Dale, Jul 20 2014 *)
Showing 1-2 of 2 results.