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.

A377957 The number of iterations of the map x -> x + A001065(x) if A009194(x) = 1, x -> x / A009194(x) otherwise, starting from n, until reaching 1.

This page as a plain text file.
%I A377957 #25 Nov 13 2024 17:20:44
%S A377957 0,8,7,6,2,1,5,4,8,3,9,8,7,6,3,14,3,2,5,4,13,10,10,9,14,8,8,1,4,3,13,
%T A377957 12,10,4,10,9,7,6,7,7,7,6,11,10,4,11,10,9,10,14,4,9,10,9,11,6,9,5,4,3,
%U A377957 15,14,11,14,9,10,6,5,11,11,11,10,9,8,15,6,6,8,9,8,12,8,9,8,10,12,5
%N A377957 The number of iterations of the map x -> x + A001065(x) if A009194(x) = 1, x -> x / A009194(x) otherwise, starting from n, until reaching 1.
%e A377957 For n = 2 there are a(2) = 8 iterations to reach 1: 2 -> 3 -> 4 -> 7 -> 8 -> 15 -> 5 -> 6 -> 1.
%e A377957 For n = 9 there are a(9) = 8 iterations to reach 1: 9 -> 13 -> 14 -> 7 -> 8 -> 15 -> 5 -> 6 -> 1.
%t A377957 f[n_] := Module[{s = DivisorSigma[1, n], g}, g = GCD[n, s]; If[g == 1, s, n/g]]; a[n_] := -1 + Length@ NestWhileList[f, n, # > 1 &]; Array[a, 100] (* _Amiram Eldar_, Nov 12 2024 *)
%Y A377957 Cf. A000203, A001065, A009194.
%K A377957 nonn
%O A377957 1,2
%A A377957 _Ctibor O. Zizka_, Nov 12 2024