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.

A308818 a(n) = a(a(n-1) mod n) + a(a(n-2) mod n) with a(0)=2 and a(1)=3.

Original entry on oeis.org

2, 3, 5, 7, 10, 7, 13, 15, 22, 23, 12, 6, 15, 18, 13, 25, 41, 37, 10, 22, 17, 40, 47, 40, 81, 38, 22, 53, 85, 134, 51, 29, 156, 215, 23, 47, 46, 35, 69, 98, 144, 81, 108, 116, 102, 37, 47, 37, 72, 75, 85, 104, 217, 111, 10, 15, 37, 60, 40, 147, 197, 51, 110
Offset: 0

Views

Author

Arran Ireland, Jun 26 2019

Keywords

Comments

a(0) and a(1) are chosen to be the smallest starting numbers greater than 1 that are believed to result in a sequence that doesn't cycle.
Empirical observation of the first 10^8 terms suggests that the sequence doesn't enter a cycle.
Conjectures: (i) This sequence doesn't enter a cycle. (ii) There is an integer greater than 1 that can never appear in this sequence.

Examples

			a(2) = a(a(2-1) mod 2) + a(a(2-2) mod 2) = a(a(1) mod 2) + a(a(0) mod 2) = a(3 mod 2) + a(2 mod 2) = a(1) + a(0) = 3 + 2 = 5.
		

Crossrefs

Cf. A000027 (if a(0)=1 and a(1)=2).

Programs

  • Python
    a = [2, 3]
    for n in range(2, 10**4 + 3):
        a.append(a[(a[n - 1] % n)] + a[(a[n - 2] % n)])
        print((n - 2), ",", a[n - 2], sep="")