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.

A375267 Number of iterations of the A375265 map to reach 1 starting from n, or -1 if 1 is never reached.

This page as a plain text file.
%I A375267 #19 Sep 03 2024 17:55:12
%S A375267 0,1,1,2,5,2,16,3,2,6,14,3,9,17,6,4,12,3,20,7,17,15,15,4,23,10,3,18,
%T A375267 18,7,106,5,15,13,13,4,21,21,10,8,109,18,29,16,7,16,104,5,24,24,13,11,
%U A375267 11,4,112,19,21,19,32,8,19,107,18,6,27,16,27,14,16,14,102
%N A375267 Number of iterations of the A375265 map to reach 1 starting from n, or -1 if 1 is never reached.
%H A375267 Paolo Xausa, <a href="/A375267/b375267.txt">Table of n, a(n) for n = 1..10000</a>
%H A375267 <a href="/index/3#3x1">Index entries for sequences related to 3x+1 (or Collatz) problem</a>.
%e A375267 a(10) = 6 because the trajectory 10 -> 5 -> 16 -> 8 -> 4 -> 2 -> 1 consists of 6 steps.
%t A375267 A375265[n_] := Which[Divisible[n, 3], n/3, Divisible[n, 2], n/2, True, 3*n + 1];
%t A375267 Array[Length[NestWhileList[A375265, #, # > 1 &]] - 1 &, 100]
%Y A375267 (Row lengths of A375266) - 1.
%Y A375267 Cf. A006577, A006666, A375280.
%K A375267 nonn,easy
%O A375267 1,4
%A A375267 _Paolo Xausa_, Aug 09 2024