OFFSET
1,2
COMMENTS
The domain of h is extended to include 1, with h(1) = 1 (as in Mathematica).
a(17) <= 51096502407. - Donovan Johnson, Dec 15 2013
EXAMPLE
h(6) = 3 - 2 = 1, and h(1) = 0, so a(2) = 6.
MATHEMATICA
z = 1000000; h[n_] := h[n] = FactorInteger[n][[-1, 1]] - FactorInteger[n][[1, 1]]; t[n_] := t[n] = Drop[FixedPointList[h, n], -2]; Table[t[n], {n, 1, z}]; a = Table[Length[t[n]], {n, 1, z}]; f[n_] := First[Flatten[Position[a, n]]]; g = Table[f[n], {n, 1, 10}]
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Clark Kimberling, Dec 11 2013
EXTENSIONS
a(11)-a(16) from Donovan Johnson, Dec 15 2013
STATUS
approved