52.2.23 problem 24

Internal problem ID [10446]
Book : Second order enumerated odes
Section : section 2
Problem number : 24
Date solved : Tuesday, September 30, 2025 at 07:26:54 PM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} x y^{\prime \prime }-y^{\prime }+4 x^{3} y&=8 x^{3} \sin \left (x \right )^{2} \end{align*}
Maple. Time used: 0.005 (sec). Leaf size: 124
ode:=x*diff(diff(y(x),x),x)-diff(y(x),x)+4*x^3*y(x) = 8*x^3*sin(x)^2; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \sin \left (x^{2}\right ) c_2 +\cos \left (x^{2}\right ) c_1 +1-\cos \left (2 x \right )-\frac {\sqrt {2}\, \sqrt {\pi }\, \operatorname {FresnelC}\left (\frac {\sqrt {2}\, \left (-1+x \right )}{\sqrt {\pi }}\right ) \sin \left (x^{2}+1\right )}{2}+\frac {\sqrt {2}\, \sqrt {\pi }\, \operatorname {FresnelS}\left (\frac {\sqrt {2}\, \left (-1+x \right )}{\sqrt {\pi }}\right ) \cos \left (x^{2}+1\right )}{2}+\frac {\sqrt {2}\, \sqrt {\pi }\, \operatorname {FresnelC}\left (\frac {\sqrt {2}\, \left (1+x \right )}{\sqrt {\pi }}\right ) \sin \left (x^{2}+1\right )}{2}-\frac {\sqrt {2}\, \sqrt {\pi }\, \operatorname {FresnelS}\left (\frac {\sqrt {2}\, \left (1+x \right )}{\sqrt {\pi }}\right ) \cos \left (x^{2}+1\right )}{2} \]
Mathematica. Time used: 0.252 (sec). Leaf size: 72
ode=x*D[y[x],{x,2}]-D[y[x],x]+4*x^3*y[x]==8*x^3*Sin[x]^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \cos \left (x^2\right ) \int _1^x-4 K[1] \sin ^2(K[1]) \sin \left (K[1]^2\right )dK[1]+\sin \left (x^2\right ) \int _1^x4 \cos \left (K[2]^2\right ) K[2] \sin ^2(K[2])dK[2]+c_1 \cos \left (x^2\right )+c_2 \sin \left (x^2\right ) \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(4*x**3*y(x) - 8*x**3*sin(x)**2 + x*Derivative(y(x), (x, 2)) - Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -x*(4*x**2*y(x) - 8*x**2*sin(x)**2 + Derivative(y(x), (x, 2))) + Derivative(y(x), x) cannot be solved by the factorable group method