74.4.52 problem 52

Internal problem ID [15866]
Book : INTRODUCTORY DIFFERENTIAL EQUATIONS. Martha L. Abell, James P. Braselton. Fourth edition 2014. ElScAe. 2014
Section : Chapter 2. First Order Equations. Exercises 2.2, page 39
Problem number : 52
Date solved : Thursday, March 13, 2025 at 06:55:02 AM
CAS classification : [_separable]

\begin{align*} y^{\prime }&=\frac {\sin \left (x \right )}{\cos \left (y\right )+1} \end{align*}

With initial conditions

\begin{align*} y \left (0\right )&=0 \end{align*}

Maple. Time used: 0.251 (sec). Leaf size: 12
ode:=diff(y(x),x) = sin(x)/(cos(y(x))+1); 
ic:=y(0) = 0; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = \operatorname {RootOf}\left (-1+\cos \left (x \right )+\sin \left (\textit {\_Z} \right )+\textit {\_Z} \right ) \]
Mathematica. Time used: 0.244 (sec). Leaf size: 19
ode=D[y[x],x]==Sin[x]/(Cos[y[x]]+1); 
ic={y[0]==0}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \text {InverseFunction}[\text {$\#$1}+\sin (\text {$\#$1})\&][1-\cos (x)] \]
Sympy. Time used: 1.395 (sec). Leaf size: 12
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(Derivative(y(x), x) - sin(x)/(cos(y(x)) + 1),0) 
ics = {y(0): 0} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} + \sin {\left (y{\left (x \right )} \right )} + \cos {\left (x \right )} = 1 \]