Does my "Prime Factor Look-and-Say" sequence always end?

I'm trying to create a challenge for PP&CG where the object will be to find the longest sequence in a given time, but I'm worried that there may be an infinite sequence that will ruin things.

The sequence is similar to the Look-and-say sequence, but using the prime factors (in increasing order) of the previous term for the current. When the current term is prime, the sequence stops. For example, if the first term is 15, you get:

15       = one 3, one 5  (1 3 1 5)
1315     = one 5, one 263 (1 5 1 263)
151263   = two 3s, five 7s (2 3 5 7)
2357     = prime, stop sequence

So, starting with 15 gives a four-term series. Starting with any prime gives a one-term series.

Additionally, if a sequence revisits a number, it stops (counting the revisited number only once). I don't know if there are any cyclic sequences, but that's there to prevent it.

Each number I've tried so far (manually) eventually terminates, but I'm not confident that it holds for any starting term. Is there any simple insight I'm missing that would show (or disprove) that for every (positive) starting number the sequence will be finite? I don't care if it's absurdly long, just not infinite.


Solution 1:

Starting with $8$ I get $32, 52, 22113, 5317113, 131167110613, \ldots$ and the sequence shows no sign of ending. At some point the numbers get so big that factoring becomes very slow. My program gave up when trying to factor $$ 231331170111602782603539242084011491005276716148307683565573944963714969597915443$$

EDIT: Let $x_k$ be the sequence of numbers obtained in this process. If $x_k = p_1 \cdots p_m$ has $n$ digits, the factors $p_1, \ldots, p_m$ have between $n$ and $n+m-1$ digits together (i.e. if $10^{d_j-1} \le p_j < 10^{d_j}$ and $s = d_1 + \ldots + d_m$ we have $10^{s-m} \le x < 10^s$), and (if the $p_j$ are distinct) the next number $x_{k+1}$ has between $n+m$ and $n + 2m-1$ digits. Numbers that are not squarefree reduce this somewhat. Typically, a number with $n$ digits has roughly $\log n$ distinct prime factors. So we should expect the number of digits in $x_k$ not to grow much more than linearly, maybe at most something like $k \log(k)$. The probability of a random integer of this size being prime is something like $\dfrac{1}{k \log(k)}$. Since $\sum_k \dfrac{1}{k \log(k)}$ diverges, we should expect to eventually encounter a prime. However, this is only a heuristic argument, not a proof, and that sum diverges extremely slowly, so given that we have reached an $81$-digit number without finding a prime the number of steps needed might well be enormous.

Here is a plot of the number of digits in $x_k$ for $k = 0 \ldots 20$ with $x_0 = 8$.

enter image description here

EDIT: Actually there was the bug in my code (I forgot that Maple does not always list the factors in numerical order), so the number 231331... above was wrong. But the plot should be correct. The $90$-digit $x_{20}$ is $$ \small 143314611607153852459854993120121438819369187408718398556398062751481672397689379055730183$$