# How to find out the solution of the differential equation?

Why we would get one of the solution of $\displaystyle\frac{dy}{dx}=\frac{2y}{x}+\cos(\frac{y}{x^2})$ as $y=[\displaystyle\frac{\pi}{2}+(2k+1)\pi]x^2$

-
Notice that $cos(y/x^2) = cos((2k + 3/2)\pi) = 0$. Then the rest follows because clearly $y' = 2y/x$. – user12014 Feb 22 '12 at 9:16
but why one who make cos(y/x 2 )to be o,i don't think we can solve ODE by making certain term 0.I would just like to solve it and find its solution.If i didn't give you the solution,how would you get the solutions? – Mathematics Feb 22 '12 at 9:32
is there such technique to solve ODE? – Mathematics Feb 22 '12 at 9:59

Let us put: $y=v(x).x^2$ (I hope this is an elementary intuition, which comes at first glance)
Then your ODE becomes $$x^2\frac{dv}{dx}=\cos v$$ Which has the solution $\tan \left(\frac{\pi}{4}+\frac{v}{2}\right)=e^{-\frac{1}{x}+c}$. To get your desired solution (which I should never think of, unless being asked) make both sides zero by taking $c=-\infty$.
yes, you can further simplify it as $\frac{1+\sin v}{\cos v}=\frac{(1+\sin v/2)^2}{1-\sin^2 v/2}=\frac{1+\sin v/2}{1-\sin v/2}=\frac{\tan \pi/4+\tan v/2}{1-\tan \pi/4.\tan v/2}=\tan(\pi/4+v/2)$. – Tapu Feb 22 '12 at 12:53
All I can say that $c$ is an arbitrary constant.... – Tapu Feb 23 '12 at 5:10