Differentiating with respect to the limit of integration I'm confused about problems involving differentiation with respect to the limit of an integral, I just want to check that my understanding is correct.
For example, are the following statements correct? :
$$
\frac{d}{dx}\int_0^xs^2ds=x^2
$$
$$
\frac{d}{ds}\int_0^xs^2ds=\int_0^x2s~ds
$$
and by the product rule:
$$
\frac{d}{dx}\int_0^x~x~s^2ds=\int_0^xs^2~ds+x^3
$$
 A: There is a nice Wikipedia page on this: Differentiation under the integral sign.
Direct from that page we have $$\frac{\text{d}}{\text{d}x}\left( \int_{a(x)}^{b(x)}f(x,t)\text{d}t \right ) = f(x,b(x))b'(x)-f(x,a(x))a'(x)+\int_{a(x)}^{b(x)}f_x(x,t)\text{d}t.$$
Then for $f(x,t) = t^2$ we have $$\frac{\text{d}}{\text{d}x}\left( \int_{0}^{x}t^2\text{d}t \right ) = f(x,x)(1)-f(x,0)(0)+\int_{0}^{x}0\text{d}t\\=x^2(1) - 0 + 0 = x^2.$$
For $f(x,t)=xt^2$ we have $$\frac{\text{d}}{\text{d}x}\left( \int_{0}^{x}xt^2\text{d}t \right ) = f(x,x)(1)-f(x,0)(0)+\int_{0}^{x}t^2\text{d}t\\=x^3(1) - 0 + x^3/3 = \frac{4}{3}x^3.$$
A: In general;
$$\frac{\mathrm{d}}{\mathrm{d}x} \int_0^x f(t) \mathrm{d}t = f(x)$$
$$\frac{\mathrm{d}}{\mathrm{d}t}\int_0^x f(t) \mathrm{d}t = \color{red}{0}$$
Now let's spend some time on this as this is where you did a mistake. Note that $$y(?)=\int_0^x f(t) \mathrm{d}t$$ is a function of $x$!($?=x$)Why? Remember how you deal with definite integrals. You find an antiderivative, then substract the lower bound from the upper. Formalizing this, let's denote $F$ an antiderivative of $f$. Then $$\int_a^b f(x) \mathrm{d}x=F(b)-F(a)$$
If you do this with yours, what do you get? $F(x)-F(a)$. What does this mean? This means the result is a function of $x$. So what right? Well, what happens when you differentiate a function with respect to something it is not related? You treat it as a constant. What happens when you differentiate a constant? Well you get $0$. So, $$\frac{\mathrm{d}}{\mathrm{d}s} \int_0^x f(s) \mathrm{d}s =\frac{\mathrm{d}}{\mathrm{d}s} \left ( F(x)-F(0) \right ) =0$$
As for the third, your approach is dead-on. I don't know how you treated $x$ though. Since you're integrating wrt to $s$ you can treat $x$ as a constant and "pull it out of the integral".
