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.

A137417 Limiting sequence when we start with positive integers (A000027) and at step n >= 1 add to the term at position n + a(n) the value a(n).

Original entry on oeis.org

1, 3, 3, 4, 8, 9, 7, 12, 9, 10, 11, 12, 21, 21, 24, 16, 17, 27, 19, 42, 21, 33, 23, 36, 25, 26, 27, 28, 29, 30, 31, 48, 33, 72, 56, 36, 37, 57, 63, 40, 41, 63, 43, 44, 72, 69, 47, 48, 49, 75, 51, 78, 53, 81, 88, 84, 57, 87, 59, 126, 61, 135, 63, 64, 65, 99, 67, 68, 69, 70, 71
Offset: 1

Views

Author

Ctibor O. Zizka, Apr 16 2008

Keywords

Comments

At the vast majority of positions the term is changed at most once, but at some positions a change occurs twice. An example is position 20. In step 4 the term at position 4 + a(4) = 8 is changed to 8 + a(4) = 12; in step 8 the term at position 8 + a(8) = 20 is changed to 20 + a(8) = 32; in step 10 the term at position 10 + a(10) = 20 is changed to a(20) + a(10) = 32 + 10 = 42.
The first position where the term is changed three times is 3498. [Klaus Brockhaus, Apr 23 2008]
The first position where the term is changed four times is 1024914. [Rémy Sigrist, Mar 11 2017]

Crossrefs

Cf. A000027.

Programs

  • Mathematica
    Block[{a, nn = 71}, a = Range[Max[3, IntegerLength[nn]] nn]; Do[a[[n + a[[n]]]] = a[[n + a[[n]]]] + a[[n]], {n, nn}]; a[[1 ;; nn]] ] (* Michael De Vlieger, Jul 28 2021 *)

Extensions

Extended by Klaus Brockhaus, Apr 23 2008