40.2.18 problem 43

Internal problem ID [6596]
Book : Schaums Outline. Theory and problems of Differential Equations, 1st edition. Frank Ayres. McGraw Hill 1952
Section : Chapter 4. Equations of first order and first degree (Variable separable). Supplemetary problems. Page 22
Problem number : 43
Date solved : Sunday, March 30, 2025 at 11:11:18 AM
CAS classification : [_separable]

\begin{align*} 1+\left (-x^{2}+1\right ) \cot \left (y\right ) y^{\prime }&=0 \end{align*}

Maple. Time used: 0.005 (sec). Leaf size: 21
ode:=1+(-x^2+1)*cot(y(x))*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \arcsin \left (\frac {\sqrt {-x^{2}+1}\, c_1}{x +1}\right ) \]
Mathematica. Time used: 0.139 (sec). Leaf size: 27
ode=1+(1-x^2)*Cot[y[x]]*D[y[x],x]== 0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \arcsin \left (\frac {e^{c_1} \sqrt {1-x}}{\sqrt {x+1}}\right ) \]
Sympy. Time used: 0.520 (sec). Leaf size: 39
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((1 - x**2)*Derivative(y(x), x)/tan(y(x)) + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = \pi - \operatorname {asin}{\left (\frac {C_{1} \sqrt {x - 1}}{\sqrt {x + 1}} \right )}, \ y{\left (x \right )} = \operatorname {asin}{\left (\frac {C_{1} \sqrt {x - 1}}{\sqrt {x + 1}} \right )}\right ] \]