##### 4.6.20 $$x^2 y'(x)=a+b x^n+c x^2 y(x)^2$$

ODE
$x^2 y'(x)=a+b x^n+c x^2 y(x)^2$ ODE Classiﬁcation

[_rational, _Riccati]

Book solution method
Riccati ODE, Generalized ODE

Mathematica
cpu = 0.420048 (sec), leaf count = 1577

$\left \{\left \{y(x)\to \frac {-b^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}} n^{\frac {2 \sqrt {(1-4 a c) n^2}}{n^2}+1} \left (x^n\right )^{\frac {i \sqrt {4 a c-1}}{n}+1} J_{\frac {\sqrt {(1-4 a c) n^2}}{n^2}-1}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) \Gamma \left (\frac {n+\sqrt {1-4 a c}}{n}\right ) c^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}}+b^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}} n^{\frac {2 \sqrt {(1-4 a c) n^2}}{n^2}+1} \left (x^n\right )^{\frac {i \sqrt {4 a c-1}}{n}+1} J_{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+1}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) \Gamma \left (\frac {n+\sqrt {1-4 a c}}{n}\right ) c^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}}-b^{\frac {i \sqrt {4 a c-1}}{n}} n^{\frac {2 \sqrt {(1-4 a c) n^2}}{n^2}+1} \left (x^n\right )^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}} J_{\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) \Gamma \left (\frac {n+\sqrt {1-4 a c}}{n}\right ) c^{\frac {i \sqrt {4 a c-1}}{n}}-i b^{\frac {i \sqrt {4 a c-1}}{n}} \sqrt {4 a c-1} n^{\frac {2 \sqrt {(1-4 a c) n^2}}{n^2}+1} \left (x^n\right )^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}} J_{\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) \Gamma \left (\frac {n+\sqrt {1-4 a c}}{n}\right ) c^{\frac {i \sqrt {4 a c-1}}{n}}+b^{\frac {i \sqrt {4 a c-1}}{n}} n^{\frac {2 \sqrt {(1-4 a c) n^2}}{n^2}} \sqrt {(1-4 a c) n^2} \left (x^n\right )^{\frac {i \sqrt {4 a c-1}}{n}+\frac {1}{2}} J_{\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) \Gamma \left (\frac {n+\sqrt {1-4 a c}}{n}\right ) c^{\frac {i \sqrt {4 a c-1}}{n}}-b^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}} n^{\frac {2 i \sqrt {4 a c-1}}{n}} \left (-i \sqrt {4 a c-1} n+n+\sqrt {(1-4 a c) n^2}\right ) \left (x^n\right )^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+\frac {1}{2}} J_{-\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) c_1 \Gamma \left (1-\frac {\sqrt {1-4 a c}}{n}\right ) c^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}}-b^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+\frac {1}{2}} n^{\frac {2 i \sqrt {4 a c-1}}{n}+1} \left (x^n\right )^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+1} J_{-\frac {\sqrt {(1-4 a c) n^2}}{n^2}-1}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) c_1 \Gamma \left (1-\frac {\sqrt {1-4 a c}}{n}\right ) c^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+\frac {1}{2}}+b^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+\frac {1}{2}} n^{\frac {2 i \sqrt {4 a c-1}}{n}+1} \left (x^n\right )^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+1} J_{1-\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) c_1 \Gamma \left (1-\frac {\sqrt {1-4 a c}}{n}\right ) c^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}+\frac {1}{2}}}{2 c n x \sqrt {x^n} \left (b^{\frac {i \sqrt {4 a c-1}}{n}} c^{\frac {i \sqrt {4 a c-1}}{n}} n^{\frac {2 \sqrt {(1-4 a c) n^2}}{n^2}} J_{\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) \Gamma \left (\frac {n+\sqrt {1-4 a c}}{n}\right ) \left (x^n\right )^{\frac {i \sqrt {4 a c-1}}{n}}+b^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}} c^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}} n^{\frac {2 i \sqrt {4 a c-1}}{n}} J_{-\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\left (\frac {2 \sqrt {b} \sqrt {c} \sqrt {x^n}}{n}\right ) c_1 \Gamma \left (1-\frac {\sqrt {1-4 a c}}{n}\right ) \left (x^n\right )^{\frac {\sqrt {(1-4 a c) n^2}}{n^2}}\right )}\right \}\right \}$

Maple
cpu = 0.096 (sec), leaf count = 239

$\left [y \left (x \right ) = -\frac {\left (\sqrt {-4 c a +1}\, \textit {\_C1} +\textit {\_C1} \right ) \BesselY \left (\frac {\sqrt {-4 c a +1}}{n}, \frac {2 \sqrt {c b}\, x^{\frac {n}{2}}}{n}\right )-2 \sqrt {c b}\, x^{\frac {n}{2}} \BesselY \left (\frac {\sqrt {-4 c a +1}+n}{n}, \frac {2 \sqrt {c b}\, x^{\frac {n}{2}}}{n}\right ) \textit {\_C1} +\left (\sqrt {-4 c a +1}+1\right ) \BesselJ \left (\frac {\sqrt {-4 c a +1}}{n}, \frac {2 \sqrt {c b}\, x^{\frac {n}{2}}}{n}\right )-2 \BesselJ \left (\frac {\sqrt {-4 c a +1}+n}{n}, \frac {2 \sqrt {c b}\, x^{\frac {n}{2}}}{n}\right ) \sqrt {c b}\, x^{\frac {n}{2}}}{2 x c \left (\BesselY \left (\frac {\sqrt {-4 c a +1}}{n}, \frac {2 \sqrt {c b}\, x^{\frac {n}{2}}}{n}\right ) \textit {\_C1} +\BesselJ \left (\frac {\sqrt {-4 c a +1}}{n}, \frac {2 \sqrt {c b}\, x^{\frac {n}{2}}}{n}\right )\right )}\right ]$ Mathematica raw input

DSolve[x^2*y'[x] == a + b*x^n + c*x^2*y[x]^2,y[x],x]

Mathematica raw output

{{y[x] -> (-(b^(Sqrt[(1 - 4*a*c)*n^2]/n^2)*c^(Sqrt[(1 - 4*a*c)*n^2]/n^2)*n^(((2*
I)*Sqrt[-1 + 4*a*c])/n)*(n - I*Sqrt[-1 + 4*a*c]*n + Sqrt[(1 - 4*a*c)*n^2])*(x^n)
^(1/2 + Sqrt[(1 - 4*a*c)*n^2]/n^2)*BesselJ[-(Sqrt[(1 - 4*a*c)*n^2]/n^2), (2*Sqrt
[b]*Sqrt[c]*Sqrt[x^n])/n]*C[1]*Gamma[1 - Sqrt[1 - 4*a*c]/n]) - b^(1/2 + Sqrt[(1
- 4*a*c)*n^2]/n^2)*c^(1/2 + Sqrt[(1 - 4*a*c)*n^2]/n^2)*n^(1 + ((2*I)*Sqrt[-1 + 4
*a*c])/n)*(x^n)^(1 + Sqrt[(1 - 4*a*c)*n^2]/n^2)*BesselJ[-1 - Sqrt[(1 - 4*a*c)*n^
2]/n^2, (2*Sqrt[b]*Sqrt[c]*Sqrt[x^n])/n]*C[1]*Gamma[1 - Sqrt[1 - 4*a*c]/n] + b^(
1/2 + Sqrt[(1 - 4*a*c)*n^2]/n^2)*c^(1/2 + Sqrt[(1 - 4*a*c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