[Math] Techniques to solve nonlinear first-order ODEs

differentialmathematicanonlinear systemordinary differential equations

I am trying to solve the following nonlinear ODE:

$$\frac{dy}{dx} = \frac{1}{x(ayx-b)},$$

where $a, b$ are constants and $a>0$. Moreover, you may assume that $b \neq 0$ if necessary.

This equation is part of a system of two differential equations I need to solve in order to use the explicit solution of this equation to solve for the second differential equation. Apart from already trying to solve it with usual methods, I've already tried solving it with Mathematica as well. However, Mathematica yields an implicit solution. Therefore, I am wondering if someone can refer me to some other methods for solving this type of ODE that will give me an explicit solution.

In case it might "ring a bell", the above ODE can be decomposed to be the following ODE through partial fraction decomposition (assuming I did it correctly):

$$\frac{dy}{dx} = -\frac{1}{b\,x} + \frac{a\,y}{b\,(a\,y\,x – b)} \iff dy = \frac{a\,y}{b\,(a\,y\,x – b)}\,dx -\frac{1}{b\,x}\,dx$$

Thank you in advance and any help will be greatly appreciated.

Best Answer

What I should do is to rewrite the differential equation as $$\frac{dx}{dy} = x(ayx-b)$$ which looks slightly better. Now, changing variable $x=\frac 1z$, the equation write $$\frac{dz}{dy}-b z+ay=0$$which looks much better. It is easy now to get $$z=\frac{a (1+b y)}{b^2}+c_1 e^{b y}$$ $$x=\frac{b^2}{a(1+ b y)+ c_1 e^{b y}}$$ Solving for $y$ appears, once more, Lambert function $$y=\frac{-a W\left(c_1 e^{\frac{b^2}{a x}}\right)-a+\frac{b^2}{x}}{a b}$$

Related Question