Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to solve $y = x \ln(y)$ for $y$ in terms of $x$. Wolfram Alpha kindly produces this plot with the solution, $y = -x W(-\frac{1}{x})$, where $W$ is the Lambert function.

y = x ln(y)

However, that only finds $y$ on the bottom "half" of the curve. How do I find $y$ for the top half?

share|cite|improve this question
You have to take another branch of it. If you use Plot[{-x LambertW[-1,-1/x],-x LambertW[0,-1/x]},{x,2.6,3.2}] you will see both parts (but Alpha for some reason splits it into two graphs; Mathematica should handle it correctly). – anon Oct 13 '11 at 1:25
@anon: Neat, I didn't know until now that LambertW[] can be used as an alias for ProductLog[]... :D – J. M. Oct 13 '11 at 1:29
@J.M. Yup. :) "Although undocumented, LambertW[k, z] autoevaluates to ProductLog[k, z] in Mathematica." – anon Oct 13 '11 at 1:54
up vote 3 down vote accepted

Here' you will want to use the other branch of the Lambert function, $W_{-1}(x)$. Recall that for $-1/e \le x < 0$, two of the infinitely many branches of the Lambert function take on real values: the principal branch $W(x)=W_0(x)$ and $W_{-1}(x)$. For $x \geq e$, then, your original expression can take the Lambert function to be any of those two real branches. Which branch to use would depend on your application, though...

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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