# What is the solution to the Differential Equation e^(x+y)(dy/dx) = x with #y(0)=1?

Sep 17, 2017

$y = \ln \left(- x {e}^{x} - {e}^{x} + e + 1\right)$

#### Explanation:

We have:

${e}^{x + y} \left(\frac{\mathrm{dy}}{\mathrm{dx}}\right) = x$ with $y \left(0\right) = 1$ ..... [A]

We can rearrange the DIfferential Equation [A] as follows:

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

This is a First Order Separable Differential equation ad we now "seperate the variables" to get:

$\int \setminus {e}^{y} \setminus \mathrm{dy} = \int \setminus x {e}^{- x} \setminus \mathrm{dx}$ ..... [B]

The LHS integral is a standard result, and for the RHS| integral we would need to apply Integration By Parts:

Let $\left\{\begin{matrix}u & = x & \implies \frac{\mathrm{du}}{\mathrm{dx}} & = 1 \\ \frac{\mathrm{dv}}{\mathrm{dx}} & = {e}^{-} x & \implies v & = - {e}^{-} x\end{matrix}\right.$

Then plugging into the IBP formula:

$\int \setminus \left(u\right) \left(\frac{\mathrm{dv}}{\mathrm{dx}}\right) \setminus \mathrm{dx} = \left(u\right) \left(v\right) - \int \setminus \left(v\right) \left(\frac{\mathrm{du}}{\mathrm{dx}}\right) \setminus \mathrm{dx}$

gives us

$\int \setminus \left(x\right) \left({e}^{x}\right) \setminus \mathrm{dx} = \left(x\right) \left(- {e}^{-} x\right) - \int \setminus \left(- {e}^{-} x\right) \left(1\right) \setminus \mathrm{dx}$
$\therefore \int \setminus x {e}^{-} x \setminus \mathrm{dx} = - x {e}^{-} x - {e}^{-} x$

Using this result, we can now integrate [B] to get the General Solution:

${e}^{y} = - x {e}^{x} - {e}^{x} + C$

Using the initial condition $y \left(0\right) = 1$ we have:

${e}^{1} = - 0 {e}^{0} - {e}^{0} + C \implies C = e + 1$

Hence, the Particular Solution is:

${e}^{y} = - x {e}^{x} - {e}^{x} + e + 1$

And we can gain an explicit solution for [A] if we take Natural Logarithms:

$\ln \left({e}^{y}\right) = \ln \left(- x {e}^{x} - {e}^{x} + e + 1\right)$

So that finally:

$y = \ln \left(- x {e}^{x} - {e}^{x} + e + 1\right)$