Internal problem ID [7146]
Book: Own collection of miscellaneous problems
Section: section 2.0
Problem number: 10.
ODE order: 2.
ODE degree: 1.
CAS Maple gives this as type [[_2nd_order, _linear, _nonhomogeneous]]
\[ \boxed {y^{\prime \prime }-x y^{\prime }-y x=x^{3}} \]
✓ Solution by Maple
Time used: 0.141 (sec). Leaf size: 211
dsolve(diff(y(x),x$2)-x*diff(y(x),x)-x*y(x)-x^3=0,y(x), singsol=all)
\[ y \left (x \right ) = \frac {\sqrt {2}\, {\mathrm e}^{-x} \left (x +2\right ) \left (\int x^{3} {\mathrm e}^{-\frac {x \left (x +2\right )}{2}} \left (i \pi \,{\mathrm e}^{-2} \left (x +2\right ) \operatorname {erf}\left (\frac {i \sqrt {2}\, \left (x +2\right )}{2}\right )+\sqrt {2}\, \sqrt {\pi }\, {\mathrm e}^{\frac {x \left (x +4\right )}{2}}\right )d x \right )+i \sqrt {2}\, \left (x +2\right ) x \,\operatorname {erf}\left (\frac {i \sqrt {2}\, \left (x +2\right )}{2}\right ) \pi \left (x^{2}+x +2\right ) {\mathrm e}^{-\frac {\left (x +2\right )^{2}}{2}}-2 \sqrt {2}\, \pi \,{\mathrm e}^{\frac {\left (x +1\right )^{2}}{2}} \operatorname {erf}\left (\frac {\sqrt {2}\, \left (x +1\right )}{2}\right )-2 \left (x +2\right ) \pi ^{\frac {3}{2}} \left (i {\mathrm e}^{-\frac {3}{2}-x} \operatorname {erf}\left (\frac {\sqrt {2}\, \left (x +1\right )}{2}\right )-{\mathrm e}^{-2-x} c_{1} \right ) \operatorname {erf}\left (\frac {i \sqrt {2}\, \left (x +2\right )}{2}\right )-2 i {\mathrm e}^{\frac {x \left (x +2\right )}{2}} \pi \sqrt {2}\, c_{1} +2 \left ({\mathrm e}^{-x} \left (x +2\right ) c_{2} +x^{3}+x^{2}+2 x \right ) \sqrt {\pi }}{2 \sqrt {\pi }} \]
✓ Solution by Mathematica
Time used: 6.619 (sec). Leaf size: 453
DSolve[y''[x]-x*y'[x]-x*y[x]-x^3==0,y[x],x,IncludeSingularSolutions -> True]
\[ y(x)\to \frac {1}{2} e^{-\frac {1}{2} (x+2)^2} \left (2 \sqrt {2} e^{\frac {x^2}{2}+x+2} (x+2) \int _1^x\left (\frac {e^{K[1]} K[1]^3}{\sqrt {2}}-\frac {1}{2} e^{-\frac {1}{2} K[1]^2-K[1]-2} \sqrt {\pi } \text {erfi}\left (\frac {\sqrt {(K[1]+2)^2}}{\sqrt {2}}\right ) K[1]^3 \sqrt {(K[1]+2)^2}\right )dK[1]-2 \text {erf}\left (\frac {x+1}{\sqrt {2}}\right ) \left (\sqrt {2 \pi } e^{x^2+3 x+\frac {5}{2}}-\pi e^{\frac {1}{2} (x+1)^2} \sqrt {(x+2)^2} \text {erfi}\left (\frac {\sqrt {(x+2)^2}}{\sqrt {2}}\right )\right )-\sqrt {2 \pi } \sqrt {(x+2)^2} x^3 \text {erfi}\left (\frac {\sqrt {(x+2)^2}}{\sqrt {2}}\right )-\sqrt {2 \pi } \sqrt {(x+2)^2} x^2 \text {erfi}\left (\frac {\sqrt {(x+2)^2}}{\sqrt {2}}\right )-\sqrt {2 \pi } c_2 e^{\frac {x^2}{2}+x+2} \sqrt {(x+2)^2} \text {erfi}\left (\frac {\sqrt {(x+2)^2}}{\sqrt {2}}\right )-2 \sqrt {2 \pi } \sqrt {(x+2)^2} x \text {erfi}\left (\frac {\sqrt {(x+2)^2}}{\sqrt {2}}\right )+2 e^{\frac {1}{2} (x+2)^2} x^3+2 e^{\frac {1}{2} (x+2)^2} x^2+2 \sqrt {2} c_1 e^{\frac {x^2}{2}+x+2} x+4 \sqrt {2} c_1 e^{\frac {x^2}{2}+x+2}+2 c_2 e^{x^2+3 x+4}+4 e^{\frac {1}{2} (x+2)^2} x\right ) \]