I was reading on product log and came upon a website which discusses how to solve equations in the form of $we^w=k$.
Given I have the equation:
$$5+a-6e^{\frac a2}=0$$
How do I solve for $a$ using the Lambert $W$ function? The website contains some tips:
So the pattern is to manipulate the equation into $ze^z=k$ where $k$ does not contain the variable. From there, $W(k) = z$, and we can solve it because the variable is in $z$
I can rewrite the equation above into something below, such that the RHS does not contain $a$:
$$a-6e^{\frac a2}=-5$$
However, I am stuck in transforming the LHS into the form $ze^z$. Wolfram tells me that the answer should be: $$a=-2W_n\Big(-\frac{3}{e^{\frac52}}\Big)-5 \ \ \mathbb{for} \ n \in \ \mathbb{Z}$$
Additionally, what is the significance of $n$ in $W_n$? How is it used?
Let $-2x = 5+a$ which gives $$ -2x=6e^{\frac {-5-2x}{2}} = 6e^{\frac {-5}{2}}e^{-x} $$ or $$ xe^{x}= -3e^{\frac {-5}{2}} $$ which is solved by $$x=W\Big(-\frac{3}{e^{\frac52}}\Big)$$ and retransformed into $$a=-5 - 2W\Big(-\frac{3}{e^{\frac52}}\Big)$$
The $n$ in $W_n$ indices the branch of $W$, i.e. there are several solutions. An illustration is here (from Wikipedia)