14.1.1 problem 1

Internal problem ID [2472]
Book : Differential equations and their applications, 4th ed., M. Braun
Section : Chapter 1. First order differential equations. Section 1.2. Linear equations. Excercises page 9
Problem number : 1
Date solved : Sunday, March 30, 2025 at 12:02:26 AM
CAS classification : [_separable]

\begin{align*} y^{\prime }+y \cos \left (t \right )&=0 \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 11
ode:=diff(y(t),t)+y(t)*cos(t) = 0; 
dsolve(ode,y(t), singsol=all);
 
\[ y = c_1 \,{\mathrm e}^{-\sin \left (t \right )} \]
Mathematica. Time used: 0.03 (sec). Leaf size: 19
ode=D[y[t],t]+y[t]*Cos[t]==0; 
ic={}; 
DSolve[{ode,ic},y[t],t,IncludeSingularSolutions->True]
 
\begin{align*} y(t)\to c_1 e^{-\sin (t)} \\ y(t)\to 0 \\ \end{align*}
Sympy. Time used: 0.234 (sec). Leaf size: 8
from sympy import * 
t = symbols("t") 
y = Function("y") 
ode = Eq(y(t)*cos(t) + Derivative(y(t), t),0) 
ics = {} 
dsolve(ode,func=y(t),ics=ics)
 
\[ y{\left (t \right )} = C_{1} e^{- \sin {\left (t \right )}} \]