6
$\begingroup$

I am trying to solve: $$8n^2=64 n\log(n)$$

I factored out $8n$ and was left with

$$n = 8 \log n$$

but I do not know how to proceed from here, I checked the solution on Wolfram Alpha, and they were able to simplify it down to:

enter image description here

which is approximately:

enter image description here

how where they able to get to this point ?

$\endgroup$
3
  • 2
    $\begingroup$ You have to use the Lambert W-Function $\endgroup$
    – E.O.
    Dec 23, 2013 at 21:39
  • $\begingroup$ For the sake of completeness, don't forget that except for those two solutions, the original problem $8n^2=64n\log n$ has also solution $n=0$, since (simply speaking) "$0\log 0 = 0$". $\endgroup$
    – pisoir
    Feb 6, 2014 at 23:53
  • $\begingroup$ possible duplicate of How to solve $n < 2^{n/8}$ for $n$? $\endgroup$
    – bain
    Sep 29, 2015 at 19:24

2 Answers 2

11
$\begingroup$

Your equation does not have a closed form in terms of standard functions you come across in school, but it does have a solution in terms of the Lambert W-function $W(z)$. The defining equation for $W(z)$ is $$z=W(z)e^{W(z)}$$ We want to rearrange your equation into something similar so we get $$\begin{align*}n&=8\log n \\ \longrightarrow\hspace{10mm}\frac n8&=\log n \\ \longrightarrow\hspace{7mm} e^{\frac n8}&=n \\ \longrightarrow\hspace{12mm} 1&=ne^{-\frac n8} \\ \longrightarrow\hspace{5mm} -\frac18&=-\frac n8e^{-\frac n8} \\\end{align*}$$ Now $$Y=Xe^X\iff X=W(Y)$$ Thus we get $$\begin{align*}-\frac n8&=W\left(-\frac18\right)\\ n&=-8W\left(-\frac18\right)\end{align*}$$ To get decimal approximations, you can numerically evaluate $W$ for its different branches and you get the solutions wolfram alpha gave you.

$\endgroup$
4
$\begingroup$

Your equation, after your initial simplification, simply write

$$f(n) = n - 8 \log(n)$$

and you want $f(n)$ to be zero.

By inspection (or better plotting the function), you notice that you have two solutions, one close to $1,$ the other close to $26$. I shall admit here that you do not know about Lambert function (from very far away, this is not a crime!!). Then the solutions will be obtained numerically.

Since the function looks very well conditioned, Newton method is a very simple candidate for locating the roots as accurately as desired. Starting from a guess (let us name it $n_{old}$), the new estimate (let us name it $n_{new}$) is simply given by

$$n_{new} = n_{old} - f(n_{old}) / f'(n_{old})$$

and the process is repeated as long as the desired accuracy has not been reached.

For illustration purposes, I shall start the iterations at $n_{old} = 1$. The successive iterates are then: $1.14286, 1.15529, 1.15537$.
For this last value, the function $f(n)$ is $4.88805\times10^{-6}$; this is quite accurate and only three iterations have been required.

For the second solution, I shall start, on intent, quite far from the solution, say at $n_{old} = 15$. The successive iterates are then: $29.2809, 26.1639, 26.0935$.
For this last value, the function $f(n)$ is $1.00707\times10^{-5}$; this is quite accurate and only three iterations have been required.

$\endgroup$
1
  • $\begingroup$ @BlackAdder. Thanks for editing. I am almost blind and, beside plain ASCII, everything is hard to me (I do not see what I type). Moreover, ages is not of any help. Cheers. $\endgroup$ Dec 24, 2013 at 7:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.