83.37.8 problem 8

Internal problem ID [19374]
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 : 8
Date solved : Thursday, March 13, 2025 at 02:22:14 PM
CAS classification : [[_2nd_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime }-2 \tan \left (x \right ) y^{\prime }+5 y&=\sec \left (x \right ) {\mathrm e}^{x} \end{align*}

Maple. Time used: 0.013 (sec). Leaf size: 29
ode:=diff(diff(y(x),x),x)-2*tan(x)*diff(y(x),x)+5*y(x) = sec(x)*exp(x); 
dsolve(ode,y(x), singsol=all);
 
\[ y \left (x \right ) = \frac {\sec \left (x \right ) \left (7 \sin \left (\sqrt {6}\, x \right ) c_{2} +7 \cos \left (\sqrt {6}\, x \right ) c_{1} +{\mathrm e}^{x}\right )}{7} \]
Mathematica. Time used: 0.204 (sec). Leaf size: 56
ode=D[y[x],{x,2}]-2*Tan[x]*D[y[x],x]+5*y[x]==Sec[x]*Exp[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \frac {1}{84} \left (12 e^x+84 c_1 e^{-i \sqrt {6} x}-7 i \sqrt {6} c_2 e^{i \sqrt {6} x}\right ) \sec (x) \]
Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(5*y(x) - exp(x)/cos(x) - 2*tan(x)*Derivative(y(x), x) + Derivative(y(x), (x, 2)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -((5*y(x) + Derivative(y(x), (x, 2)))*cos(x) - exp(x))/(2*cos(x)*tan(x)) + Derivative(y(x), x) cannot be solved by the factorable group method