2.1.1 Problem 1

2.1.1.1 Solved using first_order_ode_exact
2.1.1.2 Solved using first_order_ode_abel_second_kind_case_5
2.1.1.3 Solved using first_order_ode_abel_second_kind_solved_by_converting_to_first_kind
2.1.1.4 Maple
2.1.1.5 Mathematica
2.1.1.6 Sympy

Internal problem ID [4076]
Book : Differential equations, Shepley L. Ross, 1964
Section : 2.4, page 55
Problem number : 1
Date solved : Thursday, January 29, 2026 at 09:34:50 AM
CAS classification : [_rational, [_Abel, `2nd type`, `class B`]]

2.1.1.1 Solved using first_order_ode_exact

1.203 (sec)

Entering first order ode exact solver

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

To solve an ode of the form

\begin{equation} M\left ( x,y\right ) +N\left ( x,y\right ) \frac {dy}{dx}=0\tag {A}\end{equation}
We assume there exists a function \(\phi \left ( x,y\right ) =c\) where \(c\) is constant, that satisfies the ode. Taking derivative of \(\phi \) w.r.t. \(x\) gives
\[ \frac {d}{dx}\phi \left ( x,y\right ) =0 \]
Hence
\begin{equation} \frac {\partial \phi }{\partial x}+\frac {\partial \phi }{\partial y}\frac {dy}{dx}=0\tag {B}\end{equation}
Comparing (A,B) shows that
\begin{align*} \frac {\partial \phi }{\partial x} & =M\\ \frac {\partial \phi }{\partial y} & =N \end{align*}

But since \(\frac {\partial ^{2}\phi }{\partial x\partial y}=\frac {\partial ^{2}\phi }{\partial y\partial x}\) then for the above to be valid, we require that

\[ \frac {\partial M}{\partial y}=\frac {\partial N}{\partial x}\]
If the above condition is satisfied, then the original ode is called exact. We still need to determine \(\phi \left ( x,y\right ) \) but at least we know now that we can do that since the condition \(\frac {\partial ^{2}\phi }{\partial x\partial y}=\frac {\partial ^{2}\phi }{\partial y\partial x}\) is satisfied. If this condition is not satisfied then this method will not work and we have to now look for an integrating factor to force this condition, which might or might not exist. The first step is to write the ODE in standard form to check for exactness, which is
\[ M(x,y) \mathop {\mathrm {d}x}+ N(x,y) \mathop {\mathrm {d}y}=0 \tag {1A} \]
Therefore
\begin{align*} \left (x^{2}+2 x y\right )\mathop {\mathrm {d}y} &= \left (-5 x y -4 y^{2}-1\right )\mathop {\mathrm {d}x}\\ \left (5 x y +4 y^{2}+1\right )\mathop {\mathrm {d}x} + \left (x^{2}+2 x y\right )\mathop {\mathrm {d}y} &= 0 \tag {2A} \end{align*}

Comparing (1A) and (2A) shows that

\begin{align*} M(x,y) &= 5 x y +4 y^{2}+1\\ N(x,y) &= x^{2}+2 x y \end{align*}

The next step is to determine if the ODE is is exact or not. The ODE is exact when the following condition is satisfied

\[ \frac {\partial M}{\partial y} = \frac {\partial N}{\partial x} \]
Using result found above gives
\begin{align*} \frac {\partial M}{\partial y} &= \frac {\partial }{\partial y} \left (5 x y +4 y^{2}+1\right )\\ &= 5 x +8 y \end{align*}

And

\begin{align*} \frac {\partial N}{\partial x} &= \frac {\partial }{\partial x} \left (x^{2}+2 x y\right )\\ &= 2 x +2 y \end{align*}

Since \(\frac {\partial M}{\partial y} \neq \frac {\partial N}{\partial x}\), then the ODE is not exact. Since the ODE is not exact, we will try to find an integrating factor to make it exact. Let

\begin{align*} A &= \frac {1}{N} \left (\frac {\partial M}{\partial y} - \frac {\partial N}{\partial x} \right ) \\ &=\frac {1}{x \left (x +2 y \right )}\left ( \left ( 5 x +8 y\right ) - \left (2 x +2 y \right ) \right ) \\ &=\frac {3}{x} \end{align*}

Since \(A\) does not depend on \(y\), then it can be used to find an integrating factor. The integrating factor \(\mu \) is

\begin{align*} \mu &= e^{ \int A \mathop {\mathrm {d}x} } \\ &= e^{\int \frac {3}{x}\mathop {\mathrm {d}x} } \end{align*}

The result of integrating gives

\begin{align*} \mu &= e^{3 \ln \left (x \right ) } \\ &= x^{3} \end{align*}

\(M\) and \(N\) are multiplied by this integrating factor, giving new \(M\) and new \(N\) which are called \(\overline {M}\) and \(\overline {N}\) for now so not to confuse them with the original \(M\) and \(N\).

\begin{align*} \overline {M} &=\mu M \\ &= x^{3}\left (5 x y +4 y^{2}+1\right ) \\ &= \left (5 x y +4 y^{2}+1\right ) x^{3} \end{align*}

And

\begin{align*} \overline {N} &=\mu N \\ &= x^{3}\left (x^{2}+2 x y\right ) \\ &= x^{4} \left (x +2 y \right ) \end{align*}

Now a modified ODE is ontained from the original ODE, which is exact and can be solved. The modified ODE is

\begin{align*} \overline {M} + \overline {N} \frac { \mathop {\mathrm {d}y}}{\mathop {\mathrm {d}x}} &= 0 \\ \left (\left (5 x y +4 y^{2}+1\right ) x^{3}\right ) + \left (x^{4} \left (x +2 y \right )\right ) \frac { \mathop {\mathrm {d}y}}{\mathop {\mathrm {d}x}} &= 0 \end{align*}

The following equations are now set up to solve for the function \(\phi \left (x,y\right )\)

\begin{align*} \frac {\partial \phi }{\partial x } &= \overline {M}\tag {1} \\ \frac {\partial \phi }{\partial y } &= \overline {N}\tag {2} \end{align*}

Integrating (1) w.r.t. \(x\) gives

\begin{align*} \int \frac {\partial \phi }{\partial x} \mathop {\mathrm {d}x} &= \int \overline {M}\mathop {\mathrm {d}x} \\ \int \frac {\partial \phi }{\partial x} \mathop {\mathrm {d}x} &= \int \left (5 x y +4 y^{2}+1\right ) x^{3}\mathop {\mathrm {d}x} \\ \tag{3} \phi &= y \,x^{5}+x^{4} y^{2}+\frac {1}{4} x^{4}+ f(y) \\ \end{align*}
Where \(f(y)\) is used for the constant of integration since \(\phi \) is a function of both \(x\) and \(y\). Taking derivative of equation (3) w.r.t \(y\) gives
\begin{align*} \tag{4} \frac {\partial \phi }{\partial y} &= x^{5}+2 x^{4} y+f'(y) \\ &=x^{4} \left (x +2 y \right )+f'(y) \\ \end{align*}
But equation (2) says that \(\frac {\partial \phi }{\partial y} = x^{4} \left (x +2 y \right )\). Therefore equation (4) becomes
\begin{equation} \tag{5} x^{4} \left (x +2 y \right ) = x^{4} \left (x +2 y \right )+f'(y) \end{equation}
Solving equation (5) for \( f'(y)\) gives
\[ f'(y) = 0 \]
Therefore
\[ f(y) = c_1 \]
Where \(c_1\) is constant of integration. Substituting this result for \(f(y)\) into equation (3) gives \(\phi \)
\[ \phi = y \,x^{5}+x^{4} y^{2}+\frac {1}{4} x^{4}+ c_1 \]
But since \(\phi \) itself is a constant function, then let \(\phi =c_2\) where \(c_2\) is new constant and combining \(c_1\) and \(c_2\) constants into the constant \(c_1\) gives the solution as
\[ c_1 = y \,x^{5}+x^{4} y^{2}+\frac {1}{4} x^{4} \]
Solving for \(y\) gives
\begin{align*} y &= \frac {-x^{3}-\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ y &= \frac {-x^{3}+\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ \end{align*}
Direction field \(5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\) Isoclines for \(5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\)

Summary of solutions found

\begin{align*} y &= \frac {-x^{3}-\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ y &= \frac {-x^{3}+\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ \end{align*}
Entering first order ode abel second kind solver
\begin{align*} 5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime }&=0 \\ \end{align*}
2.1.1.2 Solved using first_order_ode_abel_second_kind_case_5

0.375 (sec)

Abel first order ode of the second kind has the form

\begin{align} (y+ g)y' &= f_0 + f_1 y+ f_2 y^2 + f_3 y^3\tag {1} \end{align}

Comparing the given ode

\[ 5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0 \]
To the form in (1) shows that
\begin{align*} g &=\frac {x}{2}\\ f_0 &=-\frac {1}{2 x}\\ f_1 &=-{\frac {5}{2}}\\ f_2 &=-\frac {2}{x}\\ f_3 &=0 \end{align*}

When the condition \(f_1 = 2 f_2 g - g'\) is satisfied, then this ode has direct solution given by

\begin{align} y &= -g \pm \triangle \tag {2} \end{align}

Where

\begin{align} \triangle = U \sqrt { 2 \int { \frac {f_0+g g' - f_2 g^2}{U^2} \,dx}+ c_1 } \tag {3}\end{align}

And \(U\) is given by

\begin{align} U &= e^{\int {f_2 \,dx}} \tag {4}\end{align}

But \(f_1=-{\frac {5}{2}}\) and \(2 f_2 g - g'=-{\frac {5}{2}}\). Hence the condition is satisfied. Calcuating \(U\) from (4) gives

\begin{align*} U &= e^{\int {f_2 \,dx}}\\ U &= e^{\int {-\frac {2}{x}\,dx}}\\ U &= \frac {1}{x^{2}} \end{align*}

Substituting the above in (3) gives

\begin{align*} \triangle &= U \sqrt { 2 \int { \frac {f_0+g g' - f_2 g^2}{U^2} \,dx}+ c_1 }\\ &= \frac {1}{x^{2}}\sqrt { 2 \int { \frac {\left (-\frac {1}{2 x}\right )+\left (\frac {x}{2}\right ) \left ({\frac {1}{2}}\right ) - \left (-\frac {2}{x}\right ) \left (\frac {x^{2}}{4}\right )}{\frac {1}{x^{4}}} \,dx}+ c_1 }\\ &= \frac {\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \end{align*}

Hence from (2) the solution is

\begin{align*} y &= -g \pm \triangle \\ y &= -\frac {x}{2}+\frac {\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ y &= -\frac {x}{2}-\frac {\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ \end{align*}
Simplifying the above gives
\begin{align*} y &= \frac {-x^{3}+\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ y &= -\frac {x^{3}+\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ \end{align*}
Direction field \(5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\) Isoclines for \(5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\)

Summary of solutions found

\begin{align*} y &= \frac {-x^{3}+\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ y &= -\frac {x^{3}+\sqrt {x^{6}-x^{4}+4 c_1}}{2 x^{2}} \\ \end{align*}
2.1.1.3 Solved using first_order_ode_abel_second_kind_solved_by_converting_to_first_kind

1.334 (sec)

This is Abel second kind ODE, it has the form

\[ \left (y+g\right )y^{\prime }= f_0(x)+f_1(x) y +f_2(x)y^{2}+f_3(x)y^{3} \]
Comparing the above to given ODE which is
\begin{align*}5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\tag {1} \end{align*}

Shows that

\begin{align*} g &= \frac {x}{2}\\ f_0 &= -\frac {1}{2 x}\\ f_1 &= -{\frac {5}{2}}\\ f_2 &= -\frac {2}{x}\\ f_3 &= 0 \end{align*}

Applying transformation

\begin{align*} y&=\frac {1}{u(x)}-g \end{align*}

Results in the new ode which is Abel first kind

\begin{align*} u^{\prime }\left (x \right ) = -\frac {\left (3 x^{2}-2\right ) u \left (x \right )^{3}}{4 x}+\frac {2 u \left (x \right )}{x} \end{align*}

Which is now solved. Entering first order ode bernoulli solverIn canonical form, the ODE is

\begin{align*} u' &= F(x,u)\\ &= -\frac {\left (3 x^{2}-2\right ) u^{3}}{4 x}+\frac {2 u}{x} \end{align*}

This is a Bernoulli ODE.

\[ u' = \left (\frac {2}{x}\right ) u \left (x \right ) + \left (-\frac {3 x^{2}-2}{4 x}\right )u^{3} \tag {1} \]
The standard Bernoulli ODE has the form
\[ u' = f_0(x)u+f_1(x)u^n \tag {2} \]
Comparing this to (1) shows that
\begin{align*} f_0 &=\frac {2}{x}\\ f_1 &=-\frac {3 x^{2}-2}{4 x} \end{align*}

The first step is to divide the above equation by \(u^n \) which gives

\[ \frac {u'}{u^n} = f_0(x) u^{1-n} +f_1(x) \tag {3} \]
The next step is use the substitution \(v = u^{1-n}\) in equation (3) which generates a new ODE in \(v \left (x \right )\) which will be linear and can be easily solved using an integrating factor. Backsubstitution then gives the solution \(u(x)\) which is what we want.

This method is now applied to the ODE at hand. Comparing the ODE (1) With (2) Shows that

\begin{align*} f_0(x)&=\frac {2}{x}\\ f_1(x)&=-\frac {3 x^{2}-2}{4 x}\\ n &=3 \end{align*}

Dividing both sides of ODE (1) by \(u^n=u^{3}\) gives

\begin{align*} u'\frac {1}{u^{3}} &= \frac {2}{x \,u^{2}} -\frac {3 x^{2}-2}{4 x} \tag {4} \end{align*}

Let

\begin{align*} v &= u^{1-n} \\ &= \frac {1}{u^{2}} \tag {5} \end{align*}

Taking derivative of equation (5) w.r.t \(x\) gives

\begin{align*} v' &= -\frac {2}{u^{3}}u' \tag {6} \end{align*}

Substituting equations (5) and (6) into equation (4) gives

\begin{align*} -\frac {v^{\prime }\left (x \right )}{2}&= \frac {2 v \left (x \right )}{x}-\frac {3 x^{2}-2}{4 x}\\ v' &= -\frac {4 v}{x}+\frac {3 x^{2}-2}{2 x} \tag {7} \end{align*}

The above now is a linear ODE in \(v \left (x \right )\) which is now solved.

In canonical form a linear first order is

\begin{align*} v^{\prime }\left (x \right ) + q(x)v \left (x \right ) &= p(x) \end{align*}

Comparing the above to the given ode shows that

\begin{align*} q(x) &=\frac {4}{x}\\ p(x) &=\frac {3 x^{2}-2}{2 x} \end{align*}

The integrating factor \(\mu \) is

\begin{align*} \mu &= e^{\int {q\,dx}}\\ &= {\mathrm e}^{\int \frac {4}{x}d x}\\ &= x^{4} \end{align*}

The ode becomes

\begin{align*} \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}}\left ( \mu v\right ) &= \mu p \\ \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}}\left ( \mu v\right ) &= \left (\mu \right ) \left (\frac {3 x^{2}-2}{2 x}\right ) \\ \frac {\mathop {\mathrm {d}}}{ \mathop {\mathrm {d}x}} \left (v \,x^{4}\right ) &= \left (x^{4}\right ) \left (\frac {3 x^{2}-2}{2 x}\right ) \\ \mathrm {d} \left (v \,x^{4}\right ) &= \left (\frac {\left (3 x^{2}-2\right ) x^{3}}{2}\right )\, \mathrm {d} x \\ \end{align*}
Integrating gives
\begin{align*} v \,x^{4}&= \int {\frac {\left (3 x^{2}-2\right ) x^{3}}{2} \,dx} \\ &=\frac {1}{4} x^{6}-\frac {1}{4} x^{4} + c_2 \end{align*}

Dividing throughout by the integrating factor \(x^{4}\) gives the final solution

\[ v \left (x \right ) = \frac {\frac {1}{4} x^{6}-\frac {1}{4} x^{4}+c_2}{x^{4}} \]
The substitution \(v = u^{1-n}\) is now used to convert the above solution back to \(u \left (x \right )\) which results in
\[ \frac {1}{u \left (x \right )^{2}} = \frac {\frac {1}{4} x^{6}-\frac {1}{4} x^{4}+c_2}{x^{4}} \]
Simplifying the above gives
\begin{align*} \frac {1}{u \left (x \right )^{2}} &= \frac {x^{6}-x^{4}+4 c_2}{4 x^{4}} \\ \end{align*}
Solving for \(u \left (x \right )\) gives
\begin{align*} u \left (x \right ) &= -\frac {2 x^{2}}{\sqrt {x^{6}-x^{4}+4 c_2}} \\ u \left (x \right ) &= \frac {2 x^{2}}{\sqrt {x^{6}-x^{4}+4 c_2}} \\ \end{align*}
Now we transform the solution \(u \left (x \right ) = -\frac {2 x^{2}}{\sqrt {x^{6}-x^{4}+4 c_2}}\) to \(y\) using \(u \left (x \right )=\frac {1}{\frac {x}{2}+y}\) which gives
\[ y = -\frac {x^{3}+\sqrt {x^{6}-x^{4}+4 c_2}}{2 x^{2}} \]
Now we transform the solution \(u \left (x \right ) = \frac {2 x^{2}}{\sqrt {x^{6}-x^{4}+4 c_2}}\) to \(y\) using \(u \left (x \right )=\frac {1}{\frac {x}{2}+y}\) which gives
\[ y = \frac {-x^{3}+\sqrt {x^{6}-x^{4}+4 c_2}}{2 x^{2}} \]
Direction field \(5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\) Isoclines for \(5 y x +4 y^{2}+1+\left (x^{2}+2 y x \right ) y^{\prime } = 0\)

Summary of solutions found

\begin{align*} y &= \frac {-x^{3}+\sqrt {x^{6}-x^{4}+4 c_2}}{2 x^{2}} \\ y &= -\frac {x^{3}+\sqrt {x^{6}-x^{4}+4 c_2}}{2 x^{2}} \\ \end{align*}
2.1.1.4 Maple. Time used: 0.002 (sec). Leaf size: 59
ode:=5*y(x)*x+4*y(x)^2+1+(x^2+2*y(x)*x)*diff(y(x),x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\begin{align*} y &= \frac {-x^{3}-\sqrt {x^{6}-x^{4}-4 c_1}}{2 x^{2}} \\ y &= \frac {-x^{3}+\sqrt {x^{6}-x^{4}-4 c_1}}{2 x^{2}} \\ \end{align*}

Maple trace

Methods for first order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
trying 1st order linear 
trying Bernoulli 
trying separable 
trying inverse linear 
trying homogeneous types: 
trying Chini 
differential order: 1; looking for linear symmetries 
trying exact 
<- exact successful
 

Maple step by step

\[ \begin {array}{lll} & {} & \textrm {Let's solve}\hspace {3pt} \\ {} & {} & 5 x y \left (x \right )+4 y \left (x \right )^{2}+1+\left (x^{2}+2 x y \left (x \right )\right ) \left (\frac {d}{d x}y \left (x \right )\right )=0 \\ \bullet & {} & \textrm {Highest derivative means the order of the ODE is}\hspace {3pt} 1 \\ {} & {} & \frac {d}{d x}y \left (x \right ) \\ \bullet & {} & \textrm {Solve for the highest derivative}\hspace {3pt} \\ {} & {} & \frac {d}{d x}y \left (x \right )=\frac {-5 x y \left (x \right )-4 y \left (x \right )^{2}-1}{x^{2}+2 x y \left (x \right )} \end {array} \]
2.1.1.5 Mathematica. Time used: 0.455 (sec). Leaf size: 84
ode=(5*x*y[x]+4*y[x]^2+1)+(x^2+2*x*y[x])*D[y[x],x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to -\frac {x^5+\sqrt {x^3} \sqrt {x^7-x^5+4 c_1 x}}{2 x^4}\\ y(x)&\to -\frac {x}{2}+\frac {\sqrt {x^3} \sqrt {x^7-x^5+4 c_1 x}}{2 x^4} \end{align*}
2.1.1.6 Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(5*x*y(x) + (x**2 + 2*x*y(x))*Derivative(y(x), x) + 4*y(x)**2 + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
Timed Out
 
Python version: 3.12.3 (main, Aug 14 2025, 17:47:21) [GCC 13.3.0] 
Sympy version 1.14.0
 
classify_ode(ode,func=y(x)) 
 
('2nd_linear_bessel', '2nd_power_series_regular')