# What is the general solution of the differential equation? :  xy dy/dx = x^2 - y^2

Sep 22, 2017

$y = \pm \sqrt{{x}^{2} / 2 - \frac{A}{x} ^ 2}$

#### Explanation:

We have:

$x y \frac{\mathrm{dy}}{\mathrm{dx}} = {x}^{2} - {y}^{2}$ ..... [A]

Note, that we cannot isolate terms in $x$ and $y$ alone so let us attempt some manipulation in an attempt to simplify the equation:

$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{{x}^{2} - {y}^{2}}{x y}$

$\therefore \frac{\mathrm{dy}}{\mathrm{dx}} = \frac{{x}^{2}}{x y} - \frac{{y}^{2}}{x y}$

$\therefore \frac{\mathrm{dy}}{\mathrm{dx}} = \frac{x}{y} - \frac{y}{x}$ ..... [B]

So Let us try a substitution, Let:

$v = \frac{y}{x} \implies y = v x \implies \frac{\mathrm{dy}}{\mathrm{dx}} = v + x \frac{\mathrm{dv}}{\mathrm{dx}}$

And substituting into the above DE [B], to eliminate $y$:

$v + x \frac{\mathrm{dv}}{\mathrm{dx}} = \frac{1}{v} - v$
$\therefore x \frac{\mathrm{dv}}{\mathrm{dx}} = \frac{1}{v} - 2 v$

$\therefore x \frac{\mathrm{dv}}{\mathrm{dx}} = \frac{1 - 2 {v}^{2}}{v}$

$\therefore \frac{v}{1 - 2 {v}^{2}} \frac{\mathrm{dv}}{\mathrm{dx}} = \frac{1}{x}$

Which has indeed helped as it has reduced the initial equation [A] to a separable equation, so we can now "seperate the variables" to get:

$\int \setminus \frac{v}{1 - 2 {v}^{2}} \setminus \mathrm{dv} = \int \setminus \frac{1}{x} \setminus \mathrm{dx}$
$\therefore - \frac{1}{4} \setminus \int \setminus \frac{- 4 v}{1 - 2 {v}^{2}} \setminus \mathrm{dv} = \int \setminus \frac{1}{x} \setminus \mathrm{dx}$

And this is trivial to integrate to get:

$- \frac{1}{4} \ln | 1 - 2 {v}^{2} | = \ln | x | + \ln C$
$\therefore - \frac{1}{4} \ln | 1 - 2 {v}^{2} | = \ln | C x |$
$\therefore \ln | 1 - 2 {v}^{2} | = \left(- 4\right) \ln | C x |$

$\therefore \ln | 1 - 2 {v}^{2} | = \ln | \frac{1}{C x} ^ 4 |$

And the due to the monotonicity of the logarithmic function we have:

$1 - 2 {v}^{2} = \frac{1}{C x} ^ 4$

And restoring the substitution we get:

$1 - 2 {\left(\frac{y}{x}\right)}^{2} = \frac{1}{C x} ^ 4$

Which is the General Solution of [A], and is we require an explicit solution; then:

$2 {\left(\frac{y}{x}\right)}^{2} = 1 - \frac{1}{C x} ^ 4$
$\therefore {y}^{2} / {x}^{2} = \frac{1}{2} - \frac{1}{2} \frac{1}{C x} ^ 4$

$\therefore {y}^{2} = {x}^{2} \left\{\frac{1}{2} - \frac{1}{2} \frac{1}{C x} ^ 4\right\}$

$\therefore {y}^{2} = {x}^{2} / 2 - \frac{A}{x} ^ 2$

$y = \pm \sqrt{{x}^{2} / 2 - \frac{A}{x} ^ 2}$