70.4.13 problem 13

Internal problem ID [18694]
Book : Differential equations. An introduction to modern methods and applications. James Brannan, William E. Boyce. Third edition. Wiley 2015
Section : Chapter 2. First order differential equations. Section 2.6 (Exact equations and integrating factors). Problems at page 100
Problem number : 13
Date solved : Thursday, October 02, 2025 at 03:21:32 PM
CAS classification : [[_homogeneous, `class A`], _exact, _rational, [_Abel, `2nd type`, `class A`]]

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

With initial conditions

\begin{align*} y \left (1\right )&=3 \\ \end{align*}
Maple. Time used: 0.121 (sec). Leaf size: 19
ode:=2*x-y(x)+(2*y(x)-x)*diff(y(x),x) = 0; 
ic:=[y(1) = 3]; 
dsolve([ode,op(ic)],y(x), singsol=all);
 
\[ y = \frac {x}{2}+\frac {\sqrt {-3 x^{2}+28}}{2} \]
Mathematica. Time used: 0.285 (sec). Leaf size: 22
ode=(2*x-y[x])+(2*y[x]-x)*D[y[x],x]==0; 
ic={y[1]==3}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{2} \left (\sqrt {28-3 x^2}+x\right ) \end{align*}
Sympy. Time used: 0.837 (sec). Leaf size: 17
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(2*x + (-x + 2*y(x))*Derivative(y(x), x) - y(x),0) 
ics = {y(1): 3} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {x}{2} + \frac {\sqrt {28 - 3 x^{2}}}{2} \]