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.

A220139 The highest value of the Collatz iteration (3x+1) starting at a(n-1) + 1, with a(1) = 1.

Original entry on oeis.org

1, 2, 16, 52, 160, 9232, 27700, 83104, 599056, 1797172, 5391520, 38862808, 131161984, 393485956, 1180457872, 3541373620, 10624120864, 87327950740, 261983852224, 785951556676, 2357854670032, 7553654536192, 22660963608580, 67982890825744, 203948672477236
Offset: 1

Views

Author

T. D. Noe, Jan 02 2013

Keywords

Comments

The length of the trajectory of a(n) is A220140(n).

Examples

			The Collatz trajectory of 2 + 1 is (3, 10, 5, 16, 8, 4, 2, 1). Hence, a(3) = 16. The trajectory of 16 + 1 is (17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1). Hence, a(4) = 52.
		

Crossrefs

Cf. A070165 (trajectory of n).

Programs

  • Mathematica
    Collatz[n_] := NestWhileList[If[EvenQ[#], #/2, 3 # + 1] &, n, # > 1 &]; c = {1}; t = {}; Do[AppendTo[t, Max[c]]; c = Collatz[t[[-1]] + 1], {30}]; t