82.48.17 problem Ex. 17

Internal problem ID [18927]
Book : Introductory Course On Differential Equations by Daniel A Murray. Longmans Green and Co. NY. 1924
Section : Chapter VIII. End of chapter problems at page 107
Problem number : Ex. 17
Date solved : Monday, March 31, 2025 at 06:25:12 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} \sin \left (x \right )^{2} y^{\prime \prime }&=2 y \end{align*}

Maple. Time used: 0.118 (sec). Leaf size: 29
ode:=sin(x)^2*diff(diff(y(x),x),x) = 2*y(x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = -i \ln \left (\cos \left (2 x \right )+i \sin \left (2 x \right )\right ) c_2 \cot \left (x \right )+c_1 \cot \left (x \right )-2 c_2 \]
Mathematica. Time used: 0.39 (sec). Leaf size: 27
ode=Sin[x]*D[y[x],{x,2}]==2*y[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to (c_1+c_2) \text {HeunG}\left [-1,-4 i,0,0,1,0,e^{i x}\right ] \]
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-2*y(x) + sin(x)**2*Derivative(y(x), (x, 2)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : solve: Cannot solve -2*y(x) + sin(x)**2*Derivative(y(x), (x, 2))