7.5.29 problem 29

Internal problem ID [133]
Book : Elementary Differential Equations. By C. Henry Edwards, David E. Penney and David Calvis. 6th edition. 2008
Section : Chapter 1. First order differential equations. Section 1.6 (substitution and exact equations). Problems at page 72
Problem number : 29
Date solved : Saturday, March 29, 2025 at 04:35:06 PM
CAS classification : [`y=_G(x,y')`]

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

Maple. Time used: 0.012 (sec). Leaf size: 31
ode:=2*x*sin(y(x))*cos(y(x))*diff(y(x),x) = 4*x^2+sin(y(x))^2; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \arcsin \left (\sqrt {-x \left (c_1 -4 x \right )}\right ) \\ y &= -\arcsin \left (\sqrt {-x \left (c_1 -4 x \right )}\right ) \\ \end{align*}
Mathematica. Time used: 6.986 (sec). Leaf size: 41
ode=(2*x*Sin[y[x]]*Cos[y[x]])*D[y[x],x]==4*x^2+Sin[y[x]]^2; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to -\arcsin \left (2 \sqrt {x (x+2 c_1)}\right ) \\ y(x)\to \arcsin \left (2 \sqrt {x (x+2 c_1)}\right ) \\ \end{align*}
Sympy. Time used: 4.451 (sec). Leaf size: 80
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-4*x**2 + 2*x*sin(y(x))*cos(y(x))*Derivative(y(x), x) - sin(y(x))**2,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = \pi - \operatorname {asin}{\left (\sqrt {2} \sqrt {x \left (C_{1} + 2 x\right )} \right )}, \ y{\left (x \right )} = \operatorname {asin}{\left (\sqrt {2} \sqrt {x \left (C_{1} + 2 x\right )} \right )} + \pi , \ y{\left (x \right )} = - \operatorname {asin}{\left (\sqrt {2} \sqrt {x \left (C_{1} + 2 x\right )} \right )}, \ y{\left (x \right )} = \operatorname {asin}{\left (\sqrt {2} \sqrt {x \left (C_{1} + 2 x\right )} \right )}\right ] \]