83.28.3 problem 3

Internal problem ID [19289]
Book : A Text book for differentional equations for postgraduate students by Ray and Chaturvedi. First edition, 1958. BHASKAR press. INDIA
Section : Chapter VII. Exact differential equations and certain particular forms of equations. Exercise VII (B) at page 106
Problem number : 3
Date solved : Thursday, March 13, 2025 at 02:12:18 PM
CAS classification : [[_2nd_order, _quadrature]]

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

Maple. Time used: 0.002 (sec). Leaf size: 14
ode:=diff(diff(y(x),x),x)*cos(x)^2 = 1; 
dsolve(ode,y(x), singsol=all);
 
\[ y \left (x \right ) = -\ln \left (\cos \left (x \right )\right )+c_{1} x +c_{2} \]
Mathematica. Time used: 0.005 (sec). Leaf size: 17
ode=D[y[x],{x,2}]*Cos[x]^2==1; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to c_2 x-\log (\cos (x))+c_1 \]
Sympy. Time used: 12.105 (sec). Leaf size: 110
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(cos(x)**2*Derivative(y(x), (x, 2)) - 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {2 \left (C_{1} + C_{2} x\right ) \left (\tan ^{2}{\left (\frac {x}{2} \right )} - 1\right ) \cos {\left (x \right )} - \left (\log {\left (\tan {\left (\frac {x}{2} \right )} - 1 \right )} + \log {\left (\tan {\left (\frac {x}{2} \right )} + 1 \right )}\right ) \left (\cos {\left (x \right )} - 1\right ) \left (\tan ^{2}{\left (\frac {x}{2} \right )} - 1\right ) + 2 \left (\log {\left (\frac {2}{\cos {\left (x \right )} + 1} \right )} \tan ^{2}{\left (\frac {x}{2} \right )} - \log {\left (\frac {2}{\cos {\left (x \right )} + 1} \right )} + \log {\left (\tan {\left (\frac {x}{2} \right )} - 1 \right )} + \log {\left (\tan {\left (\frac {x}{2} \right )} + 1 \right )}\right ) \cos {\left (x \right )}}{2 \left (\tan ^{2}{\left (\frac {x}{2} \right )} - 1\right ) \cos {\left (x \right )}} \]