57.5.17 problem 3(e)

Internal problem ID [14372]
Book : A First Course in Differential Equations by J. David Logan. Third Edition. Springer-Verlag, NY. 2015.
Section : Chapter 1, First order differential equations. Section 1.4.1. Integrating factors. Exercises page 41
Problem number : 3(e)
Date solved : Thursday, October 02, 2025 at 09:34:12 AM
CAS classification : [_separable]

\begin{align*} \cos \left (\theta \right ) v^{\prime }+v&=3 \end{align*}
Maple. Time used: 0.002 (sec). Leaf size: 32
ode:=cos(theta)*diff(v(theta),theta)+v(theta) = 3; 
dsolve(ode,v(theta), singsol=all);
 
\[ v = \frac {\left (c_1 +6\right ) \cos \left (\frac {\theta }{2}\right )-c_1 \sin \left (\frac {\theta }{2}\right )}{\cos \left (\frac {\theta }{2}\right )+\sin \left (\frac {\theta }{2}\right )} \]
Mathematica. Time used: 0.045 (sec). Leaf size: 26
ode=Cos[theta]*D[v[theta],theta]+v[theta]==3; 
ic={}; 
DSolve[{ode,ic},v[theta],theta,IncludeSingularSolutions->True]
 
\begin{align*} v(\theta )&\to 3+c_1 e^{-2 \text {arctanh}\left (\tan \left (\frac {\theta }{2}\right )\right )}\\ v(\theta )&\to 3 \end{align*}
Sympy. Time used: 0.244 (sec). Leaf size: 22
from sympy import * 
theta = symbols("theta") 
v = Function("v") 
ode = Eq(v(theta) + cos(theta)*Derivative(v(theta), theta) - 3,0) 
ics = {} 
dsolve(ode,func=v(theta),ics=ics)
 
\[ v{\left (\theta \right )} = \frac {C_{1} \sqrt {\sin {\left (\theta \right )} - 1}}{\sqrt {\sin {\left (\theta \right )} + 1}} + 3 \]