23.3.144 problem 146

Internal problem ID [5858]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Part II. Chapter 3. THE DIFFERENTIAL EQUATION IS LINEAR AND OF SECOND ORDER, page 311
Problem number : 146
Date solved : Friday, October 03, 2025 at 01:44:28 AM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} a \tan \left (x \right )^{2} y-2 \cot \left (2 x \right ) y^{\prime }+y^{\prime \prime }&=0 \end{align*}
Maple. Time used: 0.091 (sec). Leaf size: 35
ode:=a*tan(x)^2*y(x)-2*cot(2*x)*diff(y(x),x)+diff(diff(y(x),x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = c_1 \cos \left (x \right )^{1+\sqrt {-a +1}}+c_2 \cos \left (x \right )^{1-\sqrt {-a +1}} \]
Mathematica. Time used: 0.48 (sec). Leaf size: 42
ode=a*Tan[x]^2*y[x] - 2*Cot[2*x]*D[y[x],x] + D[y[x],{x,2}] == 0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \cos ^{1-\sqrt {1-a}}(x) \left (c_2 \cos ^{2 \sqrt {1-a}}(x)+c_1\right ) \end{align*}
Sympy
from sympy import * 
x = symbols("x") 
a = symbols("a") 
y = Function("y") 
ode = Eq(a*y(x)*tan(x)**2 + Derivative(y(x), (x, 2)) - 2*Derivative(y(x), x)/tan(2*x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -(a*y(x)*tan(x)**2 + Derivative(y(x), (x, 2)))*tan(2*x)/2 + Deri