83.26.1 problem 1

Internal problem ID [19254]
Book : A Text book for differentional equations for postgraduate students by Ray and Chaturvedi. First edition, 1958. BHASKAR press. INDIA
Section : Chapter VI. Homogeneous linear equations with variable coefficients. Exercise VI (C) at page 93
Problem number : 1
Date solved : Monday, March 31, 2025 at 07:03:22 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} x^{2} y^{\prime \prime }+y&=3 x^{2} \end{align*}

Maple. Time used: 0.003 (sec). Leaf size: 34
ode:=x^2*diff(diff(y(x),x),x)+y(x) = 3*x^2; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \sqrt {x}\, \sin \left (\frac {\sqrt {3}\, \ln \left (x \right )}{2}\right ) c_2 +\sqrt {x}\, \cos \left (\frac {\sqrt {3}\, \ln \left (x \right )}{2}\right ) c_1 +x^{2} \]
Mathematica. Time used: 0.078 (sec). Leaf size: 47
ode=x^2*D[y[x],{x,2}]+y[x]==3*x^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \sqrt {x} \left (x^{3/2}+c_1 \cos \left (\frac {1}{2} \sqrt {3} \log (x)\right )+c_2 \sin \left (\frac {1}{2} \sqrt {3} \log (x)\right )\right ) \]
Sympy. Time used: 0.243 (sec). Leaf size: 42
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), (x, 2)) - 3*x**2 + y(x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} \sqrt {x} \sin {\left (\frac {\sqrt {3} \log {\left (x \right )}}{2} \right )} + C_{2} \sqrt {x} \cos {\left (\frac {\sqrt {3} \log {\left (x \right )}}{2} \right )} + x^{2} \]