login
Number of primes greater than the greatest prime factor of n but not greater than n.
1

%I #9 Feb 21 2013 00:27:22

%S 0,0,0,1,0,1,0,3,2,1,0,3,0,2,3,5,0,5,0,5,4,3,0,7,6,3,7,5,0,7,0,10,6,4,

%T 7,9,0,4,6,9,0,9,0,9,11,5,0,13,11,12,8,9,0,14,11,12,8,6,0,14,0,7,14,

%U 17,12,13,0,12,10,15,0,18,0,9,18,13,16,15,0,19,20,9,0,19,16,9,13,18,0,21,18

%N Number of primes greater than the greatest prime factor of n but not greater than n.

%C a(n) = A000720(n) - A000720(A006530(n));

%C a(n) > 0 if and only if n is composite.

%o (PARI) a(n)=if(n>3,my(f=factor(n)[,1]);primepi(n)-primepi(f[#f]),0) \\ _Charles R Greathouse IV_, Feb 21 2013

%Y Cf. A083722, A079067.

%K nonn

%O 1,8

%A _Reinhard Zumkeller_, May 04 2003