# Proving :$\frac{\textrm{d}}{\textrm{d}x}\int^{g(x)}_{h(x)}f(t)\textrm{d}t =f(g(x))g'(x)-f(h(x))h'(x).$

How to prove that :

$$\frac{\textrm{d}}{\textrm{d}x}\int^{g(x)}_{h(x)}f(t)\textrm{d}t =f(g(x))g'(x)-f(h(x))h'(x).$$

-

Let us first assume that $f$ has a primitive, which we shall refer to as $F$. By the fundamental theorem of calculus, we have:

$$\int_{h(x)}^{g(x)}{f(t)\:dt}=F(g(x))-F(h(x))$$

By the chain rule, we have:

$$\frac{d}{dx}\left(f\circ g\right)=f'(g(x))g'(x)$$

As we know that $\frac{d}{dx}F(x)=f(x)$, we have:

$$\frac{d}{dx}\left(F(g(x))-F(h(x))\right)=F'(g(x))g'(x)-F'(h(x))h'(x)\\=f(g(x))g'(x)-f(h(x))h'(x)$$

Which means that:

$$\frac{d}{dt}\int_{h(x)}^{g(x)}f(t)\:dt=f'(g(x))g'(x)-f(h(x))h'(x)$$

Q.E.D.

-

Use the Fundamental Theorem of Calculus and the Chain Rule.

More informally, in order to find our definite integral, we find an antiderivative $F(t)$ of $f(t)$, and then "plug in." Our indefinite integral is equal to $$F(g(x))-F(h(x)).$$ Differentiate. We get $g'(x)F'(g(x))-h'(x)F'(h(x))$. But $F'(t)=f(t)$.

-

To add some variety to these answers, I propose to split the integral into two, by taking advantage of the additivity over disjoint unions of interval. What I mean is:

$$\frac{d}{dx}\left(\int\limits_{h(x)}^{g(x)}f(t)dt\right)=\frac{d}{dx}\left(\int\limits_{h(x)}^{x_0}f(t)dt+\int\limits_{x_0}^{g(x)}f(t)dt\right)=\frac{d}{dx}\left(\int\limits_{h(x)}^{x_0}f(t)dt\right)+\frac{d}{dx}\left(\int\limits_{x_0}^{g(x)}f(t)dt\right).$$

Then we swap the extremes of integration in the second integral and get a minus. Now, I assume we know how to calculate those derivatives, and to prove they are $f(g(x))g'(x)$ and $f(h(x))h'(x)$, for which you can still use the other answers. SO this approach is building on a simpler case: the one with one extreme fixed and the other one moving with $x$.

-