28.2.51 problem 51

Internal problem ID [4494]
Book : Differential equations for engineers by Wei-Chau XIE, Cambridge Press 2010
Section : Chapter 4. Linear Differential Equations. Page 183
Problem number : 51
Date solved : Tuesday, March 04, 2025 at 06:49:03 PM
CAS classification : [[_3rd_order, _linear, _nonhomogeneous]]

\begin{align*} y^{\prime \prime \prime }-3 y^{\prime \prime }+4 y&=12 \,{\mathrm e}^{2 x}+4 \,{\mathrm e}^{3 x} \end{align*}

Maple. Time used: 0.007 (sec). Leaf size: 38
ode:=diff(diff(diff(y(x),x),x),x)-3*diff(diff(y(x),x),x)+4*y(x) = 12*exp(2*x)+4*exp(3*x); 
dsolve(ode,y(x), singsol=all);
 
\[ y \left (x \right ) = \frac {\left (18 x^{2}+\left (9 c_3 -12\right ) x +9 c_{2} +4\right ) {\mathrm e}^{2 x}}{9}+{\mathrm e}^{-x} c_{1} +{\mathrm e}^{3 x} \]
Mathematica. Time used: 0.094 (sec). Leaf size: 44
ode=D[y[x],{x,3}]-3*D[y[x],{x,2}]+4*y[x]==12*Exp[2*x]+4*Exp[3*x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to e^{2 x} \left (2 x^2+\left (-\frac {4}{3}+c_3\right ) x+\frac {4}{9}+c_2\right )+e^{3 x}+c_1 e^{-x} \]
Sympy. Time used: 0.151 (sec). Leaf size: 26
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(4*y(x) - 4*exp(3*x) - 12*exp(2*x) - 3*Derivative(y(x), (x, 2)) + Derivative(y(x), (x, 3)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{3} e^{- x} + \left (C_{1} + x \left (C_{2} + 2 x\right )\right ) e^{2 x} + e^{3 x} \]