4.6.30 \(\left (1-x^2\right ) y'(x)=-x^2+y(x)+1\)

ODE
\[ \left (1-x^2\right ) y'(x)=-x^2+y(x)+1 \] ODE Classification

[_linear]

Book solution method
Linear ODE

Mathematica
cpu = 0.18262 (sec), leaf count = 54

\[\left \{\left \{y(x)\to \frac {\sqrt {x+1} \left (\sqrt {1-x^2}-2 \sin ^{-1}\left (\frac {\sqrt {1-x}}{\sqrt {2}}\right )+c_1\right )}{\sqrt {1-x}}\right \}\right \}\]

Maple
cpu = 0.017 (sec), leaf count = 35

\[\left [y \left (x \right ) = \frac {\left (\sqrt {-\left (1+x \right )^{2}+2 x +2}+\arcsin \left (x \right )+\textit {\_C1} \right ) \left (1+x \right )}{\sqrt {-x^{2}+1}}\right ]\] Mathematica raw input

DSolve[(1 - x^2)*y'[x] == 1 - x^2 + y[x],y[x],x]

Mathematica raw output

{{y[x] -> (Sqrt[1 + x]*(Sqrt[1 - x^2] - 2*ArcSin[Sqrt[1 - x]/Sqrt[2]] + C[1]))/S
qrt[1 - x]}}

Maple raw input

dsolve((-x^2+1)*diff(y(x),x) = 1-x^2+y(x), y(x))

Maple raw output

[y(x) = ((-(1+x)^2+2*x+2)^(1/2)+arcsin(x)+_C1)*(1+x)/(-x^2+1)^(1/2)]