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.

A002217 Starting with n, repeatedly calculate the sum of prime factors (with repetition) of the previous term, until reaching 0 or a fixed point: a(n) is the number of terms in the resulting sequence.

This page as a plain text file.
%I A002217 M0150 N0060 #44 Feb 16 2025 08:32:25
%S A002217 2,1,1,1,1,2,1,3,3,2,1,2,1,4,4,4,1,4,1,4,3,2,1,4,3,5,4,2,1,3,1,3,5,2,
%T A002217 3,3,1,4,5,2,1,3,1,5,2,4,1,2,5,3,5,2,1,2,5,2,3,2,1,3,1,6,2,3,5,5,1,4,
%U A002217 6,5,1,3,1,6,2,2,5,5,1,2,3,2,1,5,3,3,4,2,1,2,5,5,3,6,5,2,1,5,2,5,1,3,1,2,5
%N A002217 Starting with n, repeatedly calculate the sum of prime factors (with repetition) of the previous term, until reaching 0 or a fixed point: a(n) is the number of terms in the resulting sequence.
%D A002217 N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
%D A002217 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
%H A002217 T. D. Noe and Christian N. K. Anderson, <a href="/A002217/b002217.txt">Table of n, a(n) for n = 1..10000</a> (first 1000 terms are from T. D. Noe)
%H A002217 Christian N. K. Anderson, <a href="/A002217/a002217.txt">n, the fixed point, a(n), and the trajectories</a> for n = 1..10000.
%H A002217 M. Lal, <a href="http://dx.doi.org/10.1090/S0025-5718-1969-0242765-9">Iterates of a number-theoretic function</a>, Math. Comp., 23 (1969), 181-183.
%H A002217 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/SumofPrimeFactors.html">Sum of Prime Factors</a>
%e A002217 20 -> 2+2+5 = 9 -> 3+3 = 6 -> 2+3 = 5, so a(20) = length of sequence {20,9,6,5} = 4.
%t A002217 sopfr[n_] := Times @@@ FactorInteger[n] // Total;
%t A002217 a[1] = 2; a[n_] := Length[ FixedPointList[sopfr, n]] - 1;
%t A002217 Array[a, 105] (* _Jean-François Alcover_, Feb 09 2018 *)
%Y A002217 Cf. A001414 (sum of prime factors of n), A029908 (fixed point that is reached).
%K A002217 nonn
%O A002217 1,1
%A A002217 _N. J. A. Sloane_
%E A002217 More terms and better description from _Reinhard Zumkeller_, Apr 08 2003
%E A002217 Incorrect comment removed by _Harvey P. Dale_, Aug 16 2011