# How do you differentiate y= (2e^x) / (1+e^x) ?

Jun 10, 2018

$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{2 {e}^{x}}{1 + {e}^{x}} ^ 2$

#### Explanation:

First of all, we see that the function is written in the format of $y = \frac{u}{v}$. This is equivalent to the quotient rule where:

$y = \frac{u}{v}$, $\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{\left(\frac{\mathrm{du}}{\mathrm{dx}}\right) v - \left(\frac{\mathrm{dv}}{\mathrm{dx}}\right) u}{v} ^ 2$

Now, separate the numerator and the denominator to differentiate. The easiest thing to do when differentiating is to take the constant term out ($2$) as shown below.

$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{2 {e}^{x}}{1 + {e}^{x}}$
$2 \left(\frac{\mathrm{dy}}{\mathrm{dx}}\right) \frac{{e}^{x}}{1 + {e}^{x}}$

$u = {e}^{x}$
$\frac{\mathrm{du}}{\mathrm{dx}} = {e}^{x}$

$v = 1 + {e}^{x}$
$\frac{\mathrm{dv}}{\mathrm{dx}} = {e}^{x}$ (as the derivative of $1$ is $0$)

Apply quotient rule:

$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{\left(\frac{\mathrm{du}}{\mathrm{dx}}\right) v - \left(\frac{\mathrm{dv}}{\mathrm{dx}}\right) u}{v} ^ 2$
$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{\left({e}^{x}\right) \left(1 + {e}^{x}\right) - \left({e}^{x}\right) \left({e}^{x}\right)}{1 + {e}^{x}} ^ 2$
$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{{e}^{x} + {e}^{2} x - {e}^{2} x}{1 + {e}^{x}} ^ 2$
$\frac{\mathrm{dy}}{\mathrm{dx}} = {e}^{x} / {\left(1 + {e}^{x}\right)}^{2}$

Don't forget to multiply by the constant!

$\frac{\mathrm{dy}}{\mathrm{dx}} = 2 \left({e}^{x} / {\left(1 + {e}^{x}\right)}^{2}\right)$
$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{2 {e}^{x}}{1 + {e}^{x}} ^ 2$