OFFSET
1,1
REFERENCES
C. Kimberling, Fractal sequences and interspersions, Ars Combinatoria, vol. 45 p 157 1997.
LINKS
Chai Wah Wu, Table of n, a(n) for n = 1..900
C. Kimberling, Interspersions
MATHEMATICA
g[ n_Integer ] := (k = n + PrimePi[ n ] + 1; While[ k - PrimePi[ k ] - 1, k++ ]; k); NestList[ g, 3, 45 ]
With[{comps=Complement[Range[80000], Prime[Range[PrimePi[80000]]]]}, NestList[comps[[#+1]]&, 3, 50]] (* Harvey P. Dale, Mar 17 2012 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved