63.1.104 problem 151

Internal problem ID [15544]
Book : DIFFERENTIAL and INTEGRAL CALCULUS. VOL I. by N. PISKUNOV. MIR PUBLISHERS, Moscow 1969.
Section : Chapter 8. Differential equations. Exercises page 595
Problem number : 151
Date solved : Thursday, October 02, 2025 at 10:19:44 AM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

\begin{align*} y^{\prime \prime }-y&=2+5 x \end{align*}
Maple. Time used: 0.003 (sec). Leaf size: 19
ode:=diff(diff(y(x),x),x)-y(x) = 5*x+2; 
dsolve(ode,y(x), singsol=all);
 
\[ y = {\mathrm e}^{-x} c_2 +{\mathrm e}^{x} c_1 -2-5 x \]
Mathematica. Time used: 0.008 (sec). Leaf size: 24
ode=D[y[x],{x,2}]-y[x]==5*x+2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -5 x+c_1 e^x+c_2 e^{-x}-2 \end{align*}
Sympy. Time used: 0.037 (sec). Leaf size: 17
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-5*x - y(x) + Derivative(y(x), (x, 2)) - 2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} e^{- x} + C_{2} e^{x} - 5 x - 2 \]