3
$\begingroup$

For example, I can solve: $x \log_2(x) = y$

$x \log_2(x) = x \log_e(x) / \log_e(2) = e^{\log_e(x)} \log_e(x) / \log_e(2)$

$e^{\log_e(x)} \log_e(x) = y\log_e(2)$

$e^{W(z)} W(z) = z$, where W(z) is the Lambert W-function

$log_e(x) = W(y\log_e(2))$

$x = e^{W(y\log_e(2))}$

But how to (find $x$) solve: $\frac{x}{\log_2(x)} = y$

Answer:

$$\displaystyle\begin{array}$x&=& \frac{1}{e^{W(ln(\frac{1}{2})^{1/y})}} = \frac{1}{e^{W(−ln(2)/y)}} \end{array}$$

$\endgroup$
5
  • $\begingroup$ What is $y$? Constant or variable? $\endgroup$
    – brick
    Jan 7, 2015 at 15:28
  • $\begingroup$ @brick $y$ is variable. $\endgroup$
    – Alex
    Jan 7, 2015 at 15:30
  • 3
    $\begingroup$ Hint: with $x:=\dfrac 1t\,$ you'll get a $\;t\,\log_2(t)=\cdots\;$ that you may solve the same way... $\endgroup$ Jan 7, 2015 at 15:47
  • 1
    $\begingroup$ @Raymond Manzoni Thank you. $1/{t\log_2(1/t)} = 1/{t(\log_2(1) - log_2(t))} = 1/{t\log_2(1) - t\log_2(t)} = y$, and because $log_2(1) = 0$ then I get: $t\log_2(t) = -1/y$. I.e.: $t = e^{W(- {{\log_e(2)}/y} )}$. And result: $x = 1 / {e^{W(- {{\ln(2)}/y} )}}$ $\endgroup$
    – Alex
    Jan 7, 2015 at 15:59
  • 1
    $\begingroup$ Glad it helped Alex. Note that $W(z)e^{W(z)}=z$ so that we have too $$e^{-W(z)}=\frac{W(z)}z=-\frac y{\ln(2)} W(-\ln(2)/y)$$ Note that the branches may provide two different answers as you may experiment with W. Alpha ($y=10$ in this example). Cheers, $\endgroup$ Jan 7, 2015 at 17:10

2 Answers 2

3
$\begingroup$

$$\begin{array}{rcl} \displaystyle\frac{x}{\log_2(x)}&=&y\\ \displaystyle\frac{x}{\ln(x)}&=&\displaystyle\frac{y}{\ln(2)}\\ \displaystyle\frac{\ln(x)}{x}&=&\displaystyle\frac{\ln(2)}{y}\\ \displaystyle\frac{-\ln(x)}{x}&=&\displaystyle-\frac{\ln(2)}{y}\\ \displaystyle\frac{1}{x}{\ln(\frac{1}{x})}&=&\displaystyle-\frac{1}{y}\ln(2)\\ \end{array}$$ Now, from Wikipedia, $W(t\ln(t))=\ln(t)$ so $$\begin{array}{rcl} \displaystyle W\biggl(\frac{1}{x}\ln\left(\frac{1}{x}\right)\biggr)&=&\displaystyle W\biggl(-\frac{1}{y}\ln(2)\biggr)\\ \displaystyle\ln\left(\frac{1}{x}\right)&=&\displaystyle W\biggl(-\frac{1}{y}\ln(2)\biggr)\\ \displaystyle\ln\left(x\right)&=&\displaystyle -W\biggl(-\frac{1}{y}\ln(2)\biggr)\\ \Rightarrow x&=&\displaystyle\mathrm{e}^{-W\biggl(-\frac{1}{y}\ln(2)\biggr)} \end{array}$$

$\endgroup$
6
  • 1
    $\begingroup$ The trouble here is that $$e^{\large{1/x\ln\left(1/x\right)}}=\left(\frac 1x\right)^{1/x}\not = \frac 1x\;e^{1/x}=e^{\large{1/x+\ln\left(1/x\right)}}$$ (see too OP's initial derivation in the comments). Sorry, $\endgroup$ Jan 7, 2015 at 22:23
  • $\begingroup$ @Raymond Manzoni Thanks you! Do you mean that there is a mistake from line 5 to 6? I.e. $$\displaystyle\begin{array}{rcl}\frac{1}{x}{\ln(\frac{1}{x})}&\Rightarrow& \frac{1}{x} {e}^{\frac{1}{x}}\end{array}$$ I.e. $$\displaystyle\begin{array}{rcl}e^{\frac{1}{x}{\ln(\frac{1}{x})}}&!=&\frac{1}{x}\mathrm{e}^{\frac{1}{x}}\end{array}$$ But my answer is correct? $$\displaystyle\begin{array}$x&= \frac{1}{e^{W(ln(\frac{1}{2})^{1/y})}} = \frac{1}{e^{W(−ln(2)/y)}} \end{array}$$ $\endgroup$
    – Alex
    Jan 9, 2015 at 10:42
  • 1
    $\begingroup$ Yes @Alex! (minimal verification: in the case $y=2$ trivial answers are $2$ and $4$). You are in fact encouraged to provide your correct result as an answer. Cheers, $\endgroup$ Jan 9, 2015 at 13:17
  • 1
    $\begingroup$ edited again, thanks! $\endgroup$
    – cjferes
    Jan 9, 2015 at 14:37
  • 2
    $\begingroup$ It looks better now @cjferes. Fine continuation, $\endgroup$ Jan 9, 2015 at 15:10
-1
$\begingroup$

Maple gives

$$x = - \frac{W(\ln(2^y))}{\ln(2^y)}$$

$\endgroup$
2
  • $\begingroup$ @orion The OP already defined the Lambert W function in his question. Defining $W$ once more is unnecessary. $\endgroup$ Jan 7, 2015 at 16:05
  • $\begingroup$ Thank you. But is this the same? $x = \frac{1}{e^{W(-ln(2)/y)}}$ $\endgroup$
    – Alex
    Jan 7, 2015 at 16:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .