62.24.3 problem Ex 3

Internal problem ID [12860]
Book : An elementary treatise on differential equations by Abraham Cohen. DC heath publishers. 1906
Section : Chapter VII, Linear differential equations with constant coefficients. Article 47. Particular integral. Page 100
Problem number : Ex 3
Date solved : Monday, March 31, 2025 at 07:22:56 AM
CAS classification : [[_3rd_order, _linear, _nonhomogeneous]]

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

Maple. Time used: 0.005 (sec). Leaf size: 32
ode:=diff(diff(diff(y(x),x),x),x)+3*diff(diff(y(x),x),x)+3*diff(y(x),x)+y(x) = 2*exp(-x)-x^2*exp(-x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = -\frac {{\mathrm e}^{-x} \left (x^{5}-60 c_2 \,x^{2}-20 x^{3}-60 c_3 x -60 c_1 \right )}{60} \]
Mathematica. Time used: 0.016 (sec). Leaf size: 41
ode=D[y[x],{x,3}]+3*D[y[x],{x,2}]+3*D[y[x],x]+y[x]==2*Exp[-x]-x^2*Exp[-x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \frac {1}{60} e^{-x} \left (-x^5+20 x^3+60 c_3 x^2+60 c_2 x+60 c_1\right ) \]
Sympy. Time used: 0.361 (sec). Leaf size: 22
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*exp(-x) + y(x) + 3*Derivative(y(x), x) + 3*Derivative(y(x), (x, 2)) + Derivative(y(x), (x, 3)) - 2*exp(-x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \left (C_{1} + x \left (C_{2} + x \left (C_{3} - \frac {x^{3}}{60} + \frac {x}{3}\right )\right )\right ) e^{- x} \]