78.13.11 problem 1 (k)

Internal problem ID [18254]
Book : DIFFERENTIAL EQUATIONS WITH APPLICATIONS AND HISTORICAL NOTES by George F. Simmons. 3rd edition. 2017. CRC press, Boca Raton FL.
Section : Chapter 3. Second order linear equations. Section 18. The Method of Undetermined Coefficients. Problems at page 132
Problem number : 1 (k)
Date solved : Thursday, March 13, 2025 at 11:51:13 AM
CAS classification : [[_2nd_order, _missing_y]]

\begin{align*} y^{\prime \prime }+y^{\prime }&=10 x^{4}+2 \end{align*}

Maple. Time used: 0.003 (sec). Leaf size: 36
ode:=diff(diff(y(x),x),x)+diff(y(x),x) = 10*x^4+2; 
dsolve(ode,y(x), singsol=all);
 
\[ y = -{\mathrm e}^{-x} c_{1} -120 x^{2}+40 x^{3}-10 x^{4}+2 x^{5}+242 x +c_{2} \]
Mathematica. Time used: 0.111 (sec). Leaf size: 40
ode=D[y[x],{x,2}] +D[y[x],x]==10*x^4+2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to 2 x^5-10 x^4+40 x^3-120 x^2+242 x-c_1 e^{-x}+c_2 \]
Sympy. Time used: 0.147 (sec). Leaf size: 32
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-10*x**4 + Derivative(y(x), x) + Derivative(y(x), (x, 2)) - 2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} + C_{2} e^{- x} + 2 x^{5} - 10 x^{4} + 40 x^{3} - 120 x^{2} + 242 x \]