89.21.4 problem 6

Internal problem ID [24776]
Book : A short course in Differential Equations. Earl D. Rainville. Second edition. 1958. Macmillan Publisher, NY. CAT 58-5010
Section : Chapter 10. Nonhomogeneous Equations: Operational methods. Exercises at page 154
Problem number : 6
Date solved : Thursday, October 02, 2025 at 10:47:55 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} y^{\prime \prime }+3 y^{\prime }-4 y&=20 \,{\mathrm e}^{-4 x} \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 20
ode:=diff(diff(y(x),x),x)+3*diff(y(x),x)-4*y(x) = 20*exp(-4*x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \left (c_2 \,{\mathrm e}^{5 x}+c_1 -4 x \right ) {\mathrm e}^{-4 x} \]
Mathematica. Time used: 0.014 (sec). Leaf size: 52
ode=D[y[x],{x,2}]+D[y[x],{x,1}]-4*y[x]== 20*Exp[-4*x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{2} e^{-4 x} \left (2 c_1 e^{-\frac {1}{2} \left (\sqrt {17}-7\right ) x}+2 c_2 e^{\frac {1}{2} \left (7+\sqrt {17}\right ) x}+5\right ) \end{align*}
Sympy. Time used: 0.137 (sec). Leaf size: 37
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-4*y(x) + Derivative(y(x), x) + Derivative(y(x), (x, 2)) - 20*exp(-4*x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} e^{\frac {x \left (-1 + \sqrt {17}\right )}{2}} + C_{2} e^{- \frac {x \left (1 + \sqrt {17}\right )}{2}} + \frac {5 e^{- 4 x}}{2} \]