Solution to $e^{-\frac{x^2}{2}}\frac{1}{x} = y$ with Lambert W function

calculusexponential functionlambert-wspecial functions

Basically, I have the problem to need a solution for $e^{-\frac{x^2}{2}}\frac{1}{x} = y$ with $y\in (0,\infty)$. Due to continuity and $\lim_{x\to 0} e^{-\frac{x^2}{2}}\frac{1}{x} = \infty$ and $\lim_{x\to\infty} e^{-\frac{x^2}{2}}\frac{1}{x}$ there must be one, but I need the dependency of $y$.

The first thing I have done is the following:
$$e^{-\frac{x^2}{2}}\frac{1}{x} = y \Leftrightarrow e^{-\frac{x^2}{2}} = xy \Leftrightarrow -\frac{x^2} 2 = \log(x) + \log(y)$$

I am sorry for the next my next step but I did not know better:
Solving this with WolframAlpha gave the output
$$x = \sqrt{\operatorname W \left(\frac 1 {y^2} \right)}$$

Where $\operatorname W$ denotes the Lambert W function. However, putting this in the equation above, I was not able to compute the desired:

$$e^{-\frac{\operatorname W \left(\frac 1 {y^2} \right)}{2}} \frac{1}{\sqrt{\operatorname W \left(\frac 1 {y^2} \right)}} = \frac{1}{\sqrt{e^{\operatorname W \left( \frac 1 {y^2} \right)} \operatorname W \left( \frac 1 {y^2} \right)}} = \frac{1}{\sqrt{\frac 1 {y^2}}} = y$$

My question was: Is this the solution to the equation above and if so, how can I compute it? If not, how can I solve this, preferably in terms of the Lambert W function.

Best Answer

If we square both sides we get $$e^{-x^2}\frac1{x^2}=y^2$$ $$x^2e^{x^2}=\frac1{y^2}$$ $$x^2=W\Big(\frac1{y^2}\Big)$$ $$x=\sqrt{W\Big(\frac1{y^2}\Big)}$$