Try to find a solution of the following differential equation: $y'=y^2-y/x - 1/x^2$
I see that it is of Riccati type: $ y'=f(x)*y+g(x)*y^2+h(x)$ with $g(x)=1, f(x)=-1/2, h(x)=-1/x^2 $
In my lecture we discuss: "Solving this equation is only possible if a particular solution $ y_p(t)$ is known and then the transformation $z= \frac{1}{y-y_p(t)}$ yields the linear equation $z' = - (f(x) + 2 y_p(x) g(x))*z- g(x).$"
So $ y_p (x) =1/x$ is a particular solution.
Then i do the transformation with $z= \frac{1}{y - \frac{1}{x}}$ like in the lecture and get: $ z' = \frac{z}{x} - \frac{2z}{x}-1 $ (I´m sure it´s right because it fit´s with the notation in the lecture for the general case. So i don´t write hear the calculation)
Which is $ z'=-\frac{z}{x} -1 $. I get a linear equation. The homogeneous equation of it $ z'= -\frac{z}{x} $ has the general solution $C*1/x$. So the solution of the differential equation is: $\phi(x)=C*1/x + 1/x = Const* 1/x$.
Is this correct?
Considering $$y'=y^2-\frac y x -\frac 1 {x^2}$$ I started with $y=\frac z x$ , $y'=\frac{z'}{x}-\frac{z}{x^2}$. This makes $$x z'-z^2+1=0$$ which is separable writing $$\frac x {x'}-z^2+1=0$$ that is to say $$\frac {x'} x=\frac 1 {z^2-1}=\frac{1}{2 (z-1)}-\frac{1}{2 (z+1)}$$ Integrating both sides leads to $$c x=\frac{\sqrt{z-1}}{\sqrt{z+1}}$$ that is to say $$z=-\frac{1+c x^2}{cx^2-1}\implies y=-\frac{1+c x^2}{x(cx^2-1)}$$ Setting $c=0$ leads to $y=\frac 1x$ as a particular solution.