cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A200815 Number of iterations of k -> d(k) until n reaches an odd prime.

Original entry on oeis.org

0, 1, 0, 2, 0, 2, 1, 2, 0, 3, 0, 2, 2, 1, 0, 3, 0, 3, 2, 2, 0, 3, 1, 2, 2, 3, 0, 3, 0, 3, 2, 2, 2, 2, 0, 2, 2, 3, 0, 3, 0, 3, 3, 2, 0, 3, 1, 3, 2, 3, 0, 3, 2, 3, 2, 2, 0, 4, 0, 2, 3, 1, 2, 3, 0, 3, 2, 3, 0, 4, 0, 2, 3, 3, 2, 3, 0, 3, 1, 2, 0, 4, 2, 2, 2, 3, 0
Offset: 3

Views

Author

Keywords

Comments

Csajbók and Kasza call this the tau-iteration length.

Examples

			d(10) = 4 and d(4) = 3, an odd prime, so a(10) = 2.
		

Crossrefs

Programs

  • Mathematica
    nop[n_]:=Length[NestWhileList[DivisorSigma[0,#]&,n,#<3 || CompositeQ[ #]&]]-1; Array[ nop,100,3] (* Harvey P. Dale, Nov 14 2020 *)
  • PARI
    a(n)=my(i);while(!isprime(n),i++;n=numdiv(n));i

Formula

a(n) <= pi(log_2(n)) = A000720(A000523(n)).
a(n) = A036459(n)-1 = A060937(n)-2, for n >= 3. - Antti Karttunen, Oct 06 2017