TITLE: How to solve $n < 2^{n/8}$ for $n$?
QUESTION [10 upvotes]: This is from an exercise (1.2.2) in introduction to algorithms that I'm working on privately.
To find at what point a $n \lg n$ function will run faster than a $n^2$ function I need to figure out for what value $n$
$8n^2 > 64n \lg n$
(with lg here being the binary log)
after some elementary simplification we get
$n > 8\lg n$
Playing around with properties of log I can further get this to
$n^8 < 2^n$
or
$n < 2^{n/8}$
While I'm sure it's something very elementary I've lost somewhere over the years, after checking out a few logarithm tutorials I'm just not finding how to get any further on this.
Any help with solving for $n$ would be appreciated.

REPLY [8 votes]: The Lambert $W$ function can be used to solve equations of the form $p^{ax+b} = cx+d.$  In fact, the Wikipedia page gives the solution to $n = 2^{n/8}$ to be
$$n = \frac{-8}{\ln 2} W\left(\frac{-\ln 2}{8}\right).$$
Via Mathematica, which implements the $W$ function as ProductLog, this comes out to be 43.5592 (although you have to take the lower branch of the $W$ function), in agreement with the Newton iteration solution Theo Buehler mentions.