# Why do we need continuity of a partial derivative to differentiate under an integral?

I essentially need to prove Leibniz's Rule for differentiation under an integral: given a continuous function $f(x,y)$ and a continuous partial $\frac{\partial f}{\partial y}$ prove that if $G(y) = \int_a^b f(t,y) \, dt$ then $G'(y) = \int_a^b \frac{\partial f}{\partial y}(t,y) dt$.

There are lots of proofs for this online, but I can't quite understand why they require the partial derivative to be continuous. As far as I can see, I need to prove that

$$\lim_{h \to 0} \frac{G(y+h)-G(y)}{h} = \lim_{h \to 0} \int_a^b \frac{f(t,y+h)-f(t,y)}{h} dt = \int_a^b \frac{\partial f}{\partial y}(t,y) dt$$ which, using the epsilon-delta definition of the limit means that I want to show that for any fixed $\epsilon$ I can find a $\delta > 0$ such that as long as $h < \delta$ $$\left| \int_a^b \frac{f(t,y+h)-f(t,y)}{h} - \frac{\partial f}{\partial y}(t,y) dt \right| < \epsilon$$ At this point most of the proofs I've seen turn to the Mean Value Theorem, and then make use of the continuity assumption, but doesn't the existence of $\frac{\partial f}{\partial y}$ mean that $$\lim_{h \to 0} \frac{f(t,y+h)-f(t,y)}{h} = \frac{\partial f}{\partial y}$$ which means it's relatively easy to select a relevant $\delta$ without having to turn to continuity? Sorry if that was overly verbose, and thanks for any help!!

-
The $\delta$ depends on $y$ so how are you gonna choose? –  azarel Apr 14 '12 at 5:58

In general, you cannot interchange the limit and the integral. That is, in general $$\lim_{h \to 0} \frac{f(t,y+h)-f(t,y)}{h} = \frac{\partial f}{\partial y},\quad a\le t\le b,\tag1$$ does not imply $$\lim_{h \to 0} \int_a^b\frac{f(t,y+h)-f(t,y)}{h}\,dt=\int_a^b \frac{\partial f}{\partial y}\,dt.\tag2$$ When you choose $\delta$ in (1), it will depend on $t$.