# Failure of interchange of integral and derivative for $\exp(t-x)\mathbb I\{x\geq t\}.$

I have been reading Cramer's Mathematical Methods of Statistics where the author stated the assumptions needed to exchange derivative and integral for Lebesgue-Stieltjes integrations, namely:

If, for almost all $$(P)$$ values of $$x$$ in $$S$$ and for a fixed value of $$t,$$ the following conditions are satisfied:

$$(1)$$ The partial derivatives $$\frac{\partial g(x, t)}{\partial t}$$ exists,

$$(2)$$ We have $$\left\vert\frac{g(x, t+h)-g(x,t)}{h}\right\vert< G_2(x)$$ for $$0<|h| where $$h_0$$ is independent of $$x,$$ then $$u'(t) = \frac{\mathrm d}{\mathrm dt}\int_S g(x, t)~\mathrm dF(x) = \int_S\frac{\partial g(x,t)}{\partial t} ~\mathrm dF(x).$$

$$(2)$$ is essentially implying the existence of a real-valued integrable function $$G(x)$$ such that $$\left\vert\frac{\partial g(x,t)}{\partial t} \right\vert < G(x)$$ for all $$t.$$

Then author showed an example where

condition $$(2)$$ is not satisfied e.g. if we take $$F(x)= x$$ and $$S = (-\infty, \infty)$$ and $$g(x,t) = \begin{cases}e^{t-x}&\textrm{for}~x\geq t,\\ 0 &\textrm{for}~x< t.\end{cases}$$

He showed $$u(t) = \int_S g(x,t)~\mathrm dx = 1$$ and by application of the theorem $$u'(t) = 1,$$ "which is obviously false." He then concluded

The correct way of calculating $$u'(t)$$ is here, of course, to take account of the variable lower limit of the integral, thus obtaining $$u'(t) = \int_t^\infty e^{t-x}~\mathrm dx - 1 = 0.$$

Two questions:

$$\bullet$$ How is $$(2)$$ violated in this example? Isn't there any $$G_2(x)$$ that satisfies $$(2)$$? I mainly thought since the support of the function is dependent on $$t,$$ this would fail the interchange (this condition is one of the regularity conditions, generally used in regular statistical experiments) but the author didn't state such. Or could they be equivalent?

$$\bullet$$ How did he take into account the variable lower limit for calculating $$u'(t)$$? How did $$-1$$ appear in the last calculation?

Any hints would be appreciated.

• Pick $t$ equal to $x$, then $(g(x,t+h) - g(x,t))/h = (0 - 1)/h$. This is unbounded as $h \to 0^+.$ Aug 29, 2023 at 4:26
• Won't it be $(e^h-1) /h$ and not $(0-1) /h$? Aug 29, 2023 at 6:08
• I'm pretty sure you can, the Riemann integral exists, and if it does, it coincides with the Lebesgue integral. On inspection of the wikipedia link, it seems that basically all of the criteria for applying the theorem are fulfilled (switch t and x). It doesn't seem like being a lebesgue integral matters too much when you have such a smooth function Aug 31, 2023 at 0:41
• Thanks for all the comments. It is clearer to me now. So, it stands that if Lebesgue integral coincides with Riemann, we can check Leibniz rule. However, is there any general rule when there is variable limit for Lebesgue integral? Never found one, unlike in Riemann's case, where there is one for variable limit. Aug 31, 2023 at 0:48
• I don't know of one, but I think depending on your problem it might be easiest to derive it for that case. Note that the assumptions on $f_1,f_2,g$ in the wikipedia article ensure that the Riemann integral exists. Also, you should answer your own question and mark it as resolved :) Aug 31, 2023 at 1:06