80.1.14 problem 14 (a)

Internal problem ID [21132]
Book : A Textbook on Ordinary Differential Equations by Shair Ahmad and Antonio Ambrosetti. Second edition. ISBN 978-3-319-16407-6. Springer 2015
Section : Chapter 1. First order linear differential equations. Excercise 1.5 at page 13
Problem number : 14 (a)
Date solved : Thursday, October 02, 2025 at 07:09:41 PM
CAS classification : [[_linear, `class A`]]

\begin{align*} x^{\prime }&=x+2 t \end{align*}
Maple. Time used: 0.001 (sec). Leaf size: 13
ode:=diff(x(t),t) = x(t)+2*t; 
dsolve(ode,x(t), singsol=all);
 
\[ x = -2 t -2+{\mathrm e}^{t} c_1 \]
Mathematica. Time used: 0.05 (sec). Leaf size: 16
ode=D[x[t],t]==x[t]+2*t; 
ic={}; 
DSolve[{ode,ic},x[t],t,IncludeSingularSolutions->True]
 
\begin{align*} x(t)&\to -2 t+c_1 e^t-2 \end{align*}
Sympy. Time used: 0.065 (sec). Leaf size: 12
from sympy import * 
t = symbols("t") 
x = Function("x") 
ode = Eq(-2*t - x(t) + Derivative(x(t), t),0) 
ics = {} 
dsolve(ode,func=x(t),ics=ics)
 
\[ x{\left (t \right )} = C_{1} e^{t} - 2 t - 2 \]