# Not sure about the derivative of the integral

Call me stupid, but I would like to know whether my understanding is okay:

$$\frac{d}{dx}\left(\int_0^x f(s)ds\right)=\frac{d}{dx}F(x)=f(x)$$

-
Fundamental theorem of analyis. –  Mike Feb 4 at 16:20
This is correct (assuming that $f$ is sufficiently smooth, such as being continuous). The intuition is that, roughly, $F(x+\delta) = \int_0^{x+\delta} f = \int_0^x f + \int_x^{x+\delta} f = F(x) + \int_x^{x+\delta} f$, and for small $\delta$, $\int_x^{x+\delta} f \approx f(x) \delta$. –  copper.hat Feb 4 at 16:21

I didn't find this at all intuitive until very recently when I worked through the following to get happy with it. Start with definition of a derivative

$$\frac{dg}{dx} = \lim_{h\to0} \frac{g(x+h)-g(h)}{h}$$

then

$$\frac{d}{dx}\int_0^xf(s)\;ds =\lim_{h\to0} \;\left[\frac{\int_0^{x+h}f(s)\;ds\;-\;\int_0^{x}f(s)\;ds}{h}\right]$$

$$= \lim_{h\to0} \;\left[\frac{\int_x^{x+h}f(s)\;ds}{h}\right]$$

$$= \lim_{h\to0} \;\left[\frac{f(x) h + O(h^2)}{h}\right]$$

$$= \lim_{h\to0}\; [f(x) + O(h)]$$

$$=f(x)$$

This is the Fundamental Theorem of Calculus. There is a sequence of Khan Academy videos on this starting here.

-
What the intuition behind the $O(h^2)$ term in the third line of the second equation? –  Dave S Feb 4 at 16:55
@DaveS It means $\int_x^{x+h}f(s)ds = f(x)h$ to first order. –  TooTone Feb 4 at 17:01
This is precisely the Fundamental Theorem of Calculus. And $f(x)$ should be continuous on some closed interval.