login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A094757 Least positive k <= n such that n*pi(k) = k*pi(n), where pi(n) is the number of primes <= n (A000720). 4

%I #23 Dec 17 2019 09:43:10

%S 1,2,3,2,5,2,7,2,9,10,11,12,13,14,10,16,17,18,19,10,21,22,23,16,25,26,

%T 27,28,29,27,31,32,27,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,

%U 40,51,52,53,54,55,56,57,58,59,60,61,62,56,64,65,66,67,68,69,70,71,72

%N Least positive k <= n such that n*pi(k) = k*pi(n), where pi(n) is the number of primes <= n (A000720).

%C Conjecture: For every n there exists a k different from n (possibly k > n) such that n*pi(k) = k*pi(n).

%C From _David A. Corneth_, Nov 15 2019: (Start)

%C If n*pi(k) = k*pi(n) then n/pi(n) = k/pi(k). So to find terms, one can make a list of pairs (k/pi(k), k) and sort them.

%C Then if for two such pairs (m/pi(m), m) and (k/pi(k), k), m > k have the same first element, i.e., m/pi(m) = k/pi(k) then a(m) = k for the least k with that ratio.

%C _Amarnath Murthy_'s conjecture above is false. For n = 3 we have pi(n)/n = 2/3. For no other k we have pi(k)/k = 2/3. Therefore the conjecture is false. (End)

%H David A. Corneth, <a href="/A094757/b094757.txt">Table of n, a(n) for n = 1..10007</a>

%e a(15) = 10 as 15*pi(10) = 15*4 = 60 = 10*pi(15) = 10*6.

%e For k in {2, 4, 6, 8} we have pi(k)/k = 1/2 and for no k < 2 this holds. So for all these values a(k) = 2. - _David A. Corneth_, Nov 15 2019

%t Table[SelectFirst[Range[n], n PrimePi[#] == # PrimePi[n] &], {n, 72}] (* _Michael De Vlieger_, Dec 14 2019 *)

%o (PARI) {m=72;pi=vector(m,n,omega(n!));for(n=1,m,k=1;while(n*pi[k]!=k*pi[n],k++);print1(k,","))}

%o (PARI) first(n) = {n = nextprime(n); my(v = vector(n), t = -1, q = 1, res = vector(n), m); v[1] = [0, 1]; v[2] = [1/2, 2]; forprime(p = 2, n, t++; for(c = q, p - 1, v[c] = [t/c, c]; ); q = p ); v[n] = [t/n,n]; v = vecsort(v); res[1] = 1; for(i = 2, #v, if(v[i-1][1] != v[i][1], m = v[i][2]; ); res[v[i][2]] = m ); res } \\ _David A. Corneth_, Nov 15 2019

%Y Cf. A095299 for n such that a(n) < n.

%Y Cf. A000720, A094758, A094759.

%K nonn,easy

%O 1,2

%A _Amarnath Murthy_, May 30 2004

%E Edited and extended by _Klaus Brockhaus_, Jun 01 2004

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 16:45 EDT 2024. Contains 371989 sequences. (Running on oeis4.)