# Solving for $y$ in $y = x \ln(y)$

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.

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

-
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." mathworld.wolfram.com/LambertW-Function.html – anon Oct 13 '11 at 1:54

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...