43.3.8 problem 8

Internal problem ID [8894]
Book : An introduction to Ordinary Differential Equations. Earl A. Coddington. Dover. NY 1961
Section : Chapter 1. Introduction– Linear equations of First Order. Page 45
Problem number : 8
Date solved : Tuesday, September 30, 2025 at 05:59:44 PM
CAS classification : [[_linear, `class A`]]

\begin{align*} y^{\prime }+2 y&=b \left (x \right ) \end{align*}
Maple. Time used: 0.001 (sec). Leaf size: 20
ode:=diff(y(x),x)+2*y(x) = b(x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \left (\int b \left (x \right ) {\mathrm e}^{2 x}d x +c_1 \right ) {\mathrm e}^{-2 x} \]
Mathematica. Time used: 0.027 (sec). Leaf size: 31
ode=D[y[x],x]+2*y[x]==b[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to e^{-2 x} \left (\int _1^xe^{2 K[1]} b(K[1])dK[1]+c_1\right ) \end{align*}
Sympy. Time used: 0.633 (sec). Leaf size: 26
from sympy import * 
x = symbols("x") 
y = Function("y") 
b = Function("b") 
ode = Eq(-b(x) + 2*y(x) + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ - \int b{\left (x \right )} e^{2 x}\, dx - \int \left (- 2 y{\left (x \right )} e^{2 x}\right )\, dx = C_{1} \]