<s>[INST] Solve differential equation, $x'=x^2-2t^{-2}$ Solve differential equation:
$x'=x^2- \frac{2}{t^2}$
Maybe is it sth connected with homogeneous equation?
I have no idea how to solve it.
 [/INST] Let $x=\dfrac{1}{u}$ ,
Then $x'=-\dfrac{u'}{u^2}$
$\therefore-\dfrac{u'}{u^2}=\dfrac{1}{u^2}-\dfrac{2}{t^2}$
$u'=\dfrac{2u^2}{t^2}-1$
Let $v=\dfrac{u}{t}$ ,
Then $u=tv$
$u'=tv'+v$
$\therefore tv'+v=2v^2-1$
$tv'=2v^2-v-1$
$t\dfrac{dv}{dt}=(2v+1)(v-1)$
$\dfrac{dv}{(2v+1)(v-1)}=\dfrac{dt}{t}$
$\int\dfrac{dv}{(2v+1)(v-1)}=\int\dfrac{dt}{t}$
$\int\left(\dfrac{1}{3(v-1)}-\dfrac{2}{3(2v+1)}\right)dv=\int\dfrac{dt}{t}$
$\dfrac{\ln(v-1)-\ln(2v+1)}{3}=\ln t+c_1$
$\ln\dfrac{v-1}{2v+1}=3\ln t+c_2$
$\dfrac{v-1}{2v+1}=Ct^3$
$v=\dfrac{1+Ct^3}{1-2Ct^3}$
$\dfrac{1}{xt}=\dfrac{1+Ct^3}{1-2Ct^3}$
$x=\dfrac{1-2Ct^3}{t(1+Ct^3)}$
</s>