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.

A071578 Number of iterations of Pi(n) needed to reach 1, where Pi(x) denotes the number of primes <= x.

This page as a plain text file.
%I A071578 #16 Sep 20 2024 15:37:40
%S A071578 0,1,2,2,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,
%T A071578 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,
%U A071578 5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5
%N A071578 Number of iterations of Pi(n) needed to reach 1, where Pi(x) denotes the number of primes <= x.
%F A071578 a(n) = a(Pi(n))+1.
%F A071578 a(n) = A060197(n) - 2. - _Filip Zaludek_, Dec 10 2016
%t A071578 Table[Length[NestWhileList[PrimePi[#]&,n,#!=1&]]-1,{n,110}] (* _Harvey P. Dale_, Dec 24 2018 *)
%o A071578 (PARI) for(n=2,150,s=n; t=0; while(s!=1,t++; s=sum(i=2,s,isprime(i)); if(s==1,print1(t,","); ); ))
%Y A071578 Cf. A000720.
%K A071578 easy,nonn
%O A071578 1,3
%A A071578 _Benoit Cloitre_, May 31 2002