Bernoulli type differential equation Please, tell me how you could solve the problem
$xy'(x)=a-x+by(x)^2,a>0,b>0$
I tried Bernoulli replacement $z(x)=1/y(x)$, however, this does not lead to success.
On the other hand, Wolfram Mathematica solves it and gives a cumbersome solution:
https://www.wolframalpha.com/input/?i=x+y%27%5Bx%5D+%3D%3D+a+-+x+%2B+b+y%5Bx%5D%5E2
 A: $$y'=\frac{a}{x}-1+\frac{b}{x}y^2$$
The usual method to solve this Riccati equation is the change of function
$$y(x)=-\frac{x}{b}\frac{u'(x)}{u(x)}$$
$$y'=-\frac{1}{b}\frac{u'}{u}-\frac{x}{b}\frac{u''}{u}+\frac{x}{b}\frac{u'^2}{u^2}=\frac{a}{x}-1+\frac{b}{x}\left(-\frac{x}{b}\frac{u'}{u}\right)^2$$
After simplification :
$$-\frac{1}{b}\frac{u'}{u}-\frac{x}{b}\frac{u''}{u}=\frac{a}{x}-1$$
$$x^2u''+xu'+b(a-x)u=0$$
This is an ODE of Bessel kind (on generalized form). To reduce it to the standard form see Eqs.(6-7) in https://mathworld.wolfram.com/BesselDifferentialEquation.html
$$u(x)=c_1\text{I}_{2i\sqrt{ab}}\left(2\sqrt{bx}\right)+c_2\text{I}_{-2i\sqrt{ab}}\left(2\sqrt{bx}\right)$$
$\text{I}_\nu(X)$ is the modified Bessl function of first kind : https://mathworld.wolfram.com/ModifiedBesselFunctionoftheFirstKind.html
Differentiating for $u'(x)$ and $\quad y(x)=-\frac{x}{b}\frac{u'(x)}{u(x)}\quad$ leads to the same cumbersome solution already given by WolfrafAlpha.
If it is for practical application, better use numerical methods of solving instead of analytical.
