# How do you find the first and second derivative of y=e^(-x^2)?

Apr 14, 2018

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

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = 4 {x}^{2} {e}^{- {x}^{2}} - 2 {e}^{- {x}^{2}}$

#### Explanation:

$y = {e}^{- {x}^{2}}$

$\frac{\mathrm{dy}}{\mathrm{dx}} = \frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right]$

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = \frac{d}{\mathrm{dx}} \left[\frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right]\right]$

let $u = - {x}^{2}$

$\frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right] = \frac{d}{\mathrm{du}} \left[{e}^{u}\right] \frac{d}{\mathrm{dx}} \left[- {x}^{2}\right]$

$\frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right] = {e}^{u} \times - 2 x$

$\frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right] = - 2 x {e}^{- {x}^{2}}$

--

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = \frac{d}{\mathrm{dx}} \left[- 2 x {e}^{- {x}^{2}}\right]$

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = \frac{d}{\mathrm{dx}} \left[- 2 x\right] {e}^{- {x}^{2}} + - 2 x \frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right]$

From earlier: $\frac{d}{\mathrm{dx}} \left[{e}^{- {x}^{2}}\right] = - 2 x {e}^{- {x}^{2}}$

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = \frac{d}{\mathrm{dx}} \left[- 2 x\right] {e}^{- {x}^{2}} + - 2 x \left(- 2 x {e}^{- {x}^{2}}\right)$

$\frac{d}{\mathrm{dx}} \left[- 2 x\right] = - 2$

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = - 2 {e}^{- {x}^{2}} + 4 {x}^{2} {e}^{- {x}^{2}}$

$\frac{{d}^{2} y}{{\mathrm{dx}}^{2}} = 4 {x}^{2} {e}^{- {x}^{2}} - 2 {e}^{- {x}^{2}}$