OFFSET
1,1
COMMENTS
Starting number is: 2, 6, 4, 25, 10, 14, 45, 91, 78, 40, 150, 135, 126, 8, 104, 20, 212, 86, 87, 65, 340, 604, 894, 341, 123, 105, 345, 1810, ..., . - Robert G. Wilson v, Sep 22 2007
LINKS
EXAMPLE
23 is the home prime of both 6 and 23, thus a(2) = 23; 211 is the home prime of 6, 22 and 211, thus a(3) = 211.
MATHEMATICA
t = Table[0, {28}]; f[n_] := FromDigits@ Flatten[ IntegerDigits@ Table[ #[[1]], { #[[2]] }] & /@ FactorInteger@n, 2]; h[n_] := NestWhileList[f@# &, n, !PrimeQ@# &, 1, 28]; Do[ a = h@n; If[ t[[Length@a]] == 0, t[[Length@a]] = a[[ -1]]; Print[{Length@a, n, a[[ -1]]}]], {n, 2, 2500}]; t (* Robert G. Wilson v, Sep 22 2007 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
William Lindgren (william.lindgren(AT)sru.edu) & Robert G. Wilson v, Sep 30 2007
STATUS
approved