12.1.6 problem 3(a)

Internal problem ID [1524]
Book : Elementary differential equations with boundary value problems. William F. Trench. Brooks/Cole 2001
Section : Chapter 1, Introduction. Section 1.2 Page 14
Problem number : 3(a)
Date solved : Saturday, March 29, 2025 at 10:57:37 PM
CAS classification : [_quadrature]

\begin{align*} y^{\prime }&=-x \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 11
ode:=diff(y(x),x) = -x; 
dsolve(ode,y(x), singsol=all);
 
\[ y = -\frac {x^{2}}{2}+c_1 \]
Mathematica. Time used: 0.002 (sec). Leaf size: 15
ode=D[y[x],x] == -x; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to -\frac {x^2}{2}+c_1 \]
Sympy. Time used: 0.104 (sec). Leaf size: 8
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x + Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} - \frac {x^{2}}{2} \]