OFFSET
1,2
COMMENTS
Assuming that all numbers when replaced with the concatenation of their prime factors will eventually reach a prime (see A037274), this sequence will contain all positive integers. a(158) = 49 which currently has no known 'home prime' in the iterative sequence of prime factor replacements; see A056938.
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..200
Eric Weisstein's World of Mathematics, Home Prime.
EXAMPLE
a(5) = 22 as a(4) = 4 which has a factorization 4 = 2*2, so the concatenation of factors is '22'.
a(7) = 5 as a(6) = 211 which is prime, and 5 is the smallest number not yet appearing in the sequence.
a(14) = 31941 as a(13) = 2337 which has a factorization 2337 = 3*19*41, so the concatenation of factors is '31941'.
MATHEMATICA
nn = 43; c[_] = 0; a[1] = c[1] = u = 1; While[c[u] > 0, u++]; Do[If[CompositeQ[#], k = FromDigits@ Flatten@ Map[IntegerDigits[#] &, ConstantArray[##] & @@@ FactorInteger[#]], k = u] &@ a[i - 1]; Set[{a[i], c[k]}, {k, i}]; If[k == u, While[c[u] > 0, u++]], {i, 2, nn}]; Array[a, nn] (* Michael De Vlieger, Apr 12 2022 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Scott R. Shannon, Jan 21 2020
STATUS
approved
