83.37.11 problem 11

Internal problem ID [19377]
Book : A Text book for differentional equations for postgraduate students by Ray and Chaturvedi. First edition, 1958. BHASKAR press. INDIA
Section : Chapter VIII. Linear equations of second order. Excercise VIII (B) at page 128
Problem number : 11
Date solved : Thursday, March 13, 2025 at 02:22:50 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} y^{\prime \prime }+2 n \cot \left (n x \right ) y^{\prime }+\left (m^{2}-n^{2}\right ) y&=0 \end{align*}

Maple. Time used: 0.006 (sec). Leaf size: 22
ode:=diff(diff(y(x),x),x)+2*n*cot(n*x)*diff(y(x),x)+(m^2-n^2)*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y \left (x \right ) = \csc \left (n x \right ) \left (c_{1} \sin \left (m x \right )+c_{2} \cos \left (m x \right )\right ) \]
Mathematica. Time used: 0.081 (sec). Leaf size: 43
ode=D[y[x],{x,2}]+2*n*Cot[n*x]*D[y[x],x]+(m^2-n^2)*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \frac {1}{2} e^{-i m x} \left (2 c_1-\frac {i c_2 e^{2 i m x}}{m}\right ) \csc (n x) \]
Sympy
from sympy import * 
x = symbols("x") 
m = symbols("m") 
n = symbols("n") 
y = Function("y") 
ode = Eq(2*n*Derivative(y(x), x)/tan(n*x) + (m**2 - n**2)*y(x) + Derivative(y(x), (x, 2)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE Derivative(y(x), x) - (-m**2*y(x) + n**2*y(x) - Derivative(y(x), (x, 2)))*tan(n*x)/(2*n) cannot be solved by the factorable group method