So I'm on chapter $1$ of introduction to algorithms & at the end the book proposes a problem: here
The answers are there & I was able to work through most of them myself despite my lack of math skills by finding the inverse of the $f(n)$'s in the leftmost column. For instance, the $n^3$ has an inverse of $\sqrt[3]{n}$ but what is the inverse for $n \log_2 n$?
However, there is $n\log_2n = 1000000$ microseconds which I cannot figure out how to find the inverse of ($n = 62746$). I'm writing python code so that way I don't screw up my calculations as I move through the table but I have no idea how to find this.
I'm not very math savvy so if you use notation, can you please name it so I can google it?
If it's not possible to reverse engineer - can someone please explain how was $62746$ calculated for that row/column combination?
Thank you for your help.
Newton's Method http://en.wikipedia.org/wiki/Newton%27s_method is effective. To solve $f(x)=N$, start with a rough estimate, $x=a_0$, of the solution.
Then replace that estimate with $a_1=a_0-(f(a_0)-N)/f'(a_0))$, where $f'(x)$ is the derivative of $f(x)$. In this case, $f(x)=x\log_2x$, so $f'(x)=\log_2x+(1/\ln2)$.
A rough guess for the answer is $$a_0=\frac{N}{\log_2 N}$$
For your example, $$a_0=1000000/\log_21000000\approx50000\\ a_1=a_0-\frac{a_0\log_2 a_0-1000000}{(1/\ln2)+\log_2 a_0}=62873\\ a_2=a_1-\frac{a_1\log_2 a_1-1000000}{(1/\ln2)+\log_2 a_1}=62746$$