Solve a differential equation $(e^x+2\ln y)ydx+xdy=0$

calculusordinary differential equations

Solve the following differential equation:
$$
(e^x+2\ln y)ydx+xdy=0
$$

It is clear that the equation is not exact. So, I tried to express $y'$:
$$
\begin{aligned}
e^xy+2y\ln y+xy'=0\iff
\begin{cases}
\left[
\begin{aligned}
&y\equiv0\\
&y\equiv e^{-{1/2}}
\end{aligned}
\right. \ \ \text{if}\ \ x=0\\
y'=-\frac{e^x}{x}\cdot y-\frac{1}{x}\cdot2y\ln y\ \ \ \text{otherwise}
\end{cases}
\end{aligned}
$$

The problem is that the differential equation seems to be non-linear, and I don't know the ways of solving those. Maybe there's an easier way of solving the initial differential equation?

Best Answer

Maybe there's an easier way of solving the initial differential equation? Yes. This equation becomes exact if you mutliply by integrating factor $$\mu (x,y)=\dfrac x y$$


$$(e^x+2\ln y)ydx+xdy=0$$ Divide by $y$ note that $ d(\ln y )=\dfrac {dy}{y}$ $$(e^x+2\ln y)dx+xd \ln y=0$$ Substitute $u= \ln y$ $$(e^x+2u)dx+xdu=0$$ Multiply by $x$: $$xe^xdx+2uxdx+x^2du=0$$ $$xe^xdx+d(ux^2)=0$$ Integrate. $$xe^x-e^x+x^2 \ln y =C$$