

A212300


Median prime factor of 1..n.


3



2, 2, 2, 2, 2, 2, 3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 11, 7, 7, 7, 11, 7, 11, 11, 11, 11, 11
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,1


COMMENTS

Smallest prime p such that at least n/2 numbers up to n have no prime factors larger than p.
A246430(n) = smallest m such that a(m) = prime(n): a(A246430(n))=A000040(n).  Reinhard Zumkeller, Sep 01 2014


LINKS

Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
Eric Naslund, The median largest prime factor and the mean of omega(n) (2012)


FORMULA

a(n) = k * n^(1/sqrt(e)) * (1 + O(1/log n)), where k = 0.7738... = A212299. See Nashlund 2012 for further references and a more precise result (Theorem 8).


MATHEMATICA

a[1]=2; a[2]=2; a[n_] := NextPrime[Median[Table[FactorInteger[k][[1, 1]], {k, 1, n}]] + 1/2, 1]; ( Charles R Greathouse IV, Jun 12 2013 )


PROG

(PARI) a(n)=my(v=vector(n, u, u)); forprime(p=2, n+1, forstep(i=p, n, p, v[i]/=p^valuation(i, p)); if(sum(i=1, n, v[i]==1)>=n/2, return(p))) \\ Charles R Greathouse IV, Jun 12 2013
(Haskell)
a212300 n = a212300_list !! (n1)
a212300_list = f 1 (2 : a000040_list) [1] $ tail a006530_list where
f x ps'@(_ : ps@(_ : p : _)) gpfs (q : qs) =
y : f (x + 1) (if y == p then ps else ps') (q : gpfs) qs where
y = head [z  z < ps', length (filter (> z) gpfs) <= div x 2]
 Reinhard Zumkeller, Sep 01 2014


CROSSREFS

Cf. A212299.
Cf. A006530, A000040, A246430.
Sequence in context: A108128 A081326 A257071 * A165074 A273165 A095139
Adjacent sequences: A212297 A212298 A212299 * A212301 A212302 A212303


KEYWORD

nonn,nice


AUTHOR

Charles R Greathouse IV, Jul 03 2012


STATUS

approved



