# Find a general solution of the differential equation

## Homework Statement

Find a general solution of the differential equation.

$$(x+y)y' = x-y$$

## Homework Equations

$$v=x+y$$
$$y=v-x$$
$$y'=v'-1$$

## The Attempt at a Solution

So if I plug this back into the original equation;
$$v(v'-1)= x-y$$
How do I convert $$v=x+y$$ into $$x-y$$ so that I have only v's and x's? Do I have to make another substitution with x-y?

Hint:

Make the subst:

$$z = \frac{y}{x}$$
because your ode is a homogeneous equation:
$$y' = \frac{x - y}{x + y} = \frac{\frac{x - y}{x}}{\frac{x + y}{x}} = \frac{1 - y/x}{1 + y/x}$$

Treat z as a function of x. Exprss y in terms of x and z. Find the derivative w.r.t. x by using the chain rule. What do you get?

So it would be;

$$y=zx$$
$$y'= z+xz'$$
$$z+xz' =\frac {1-z}{1+z}$$

How do I isolate the z's and x's in order to integrate?

simplify:
$$\frac{1 - z}{1 + z} - z$$
You will get an ODE with separated variables x and z.