From an Integrand to a Derivative
An indefinite integral turns an integrand into a function, but its derivative at a particular point depends on more than simply reading off the integrand’s assigned value there. For piecewise constant and piecewise continuous integrands, the calculation is concrete: integrate separately on each interval, differentiate those formulas, and compare one-sided behavior at every breakpoint. This also makes it possible to distinguish points where the ordinary derivative exists from points where only a one-sided derivative is available.
Throughout, let \(a<b\) be real numbers and use the finite, complete measure space \(([a,b],\mathcal{L}_{[a,b]},m)\), where \(\mathcal{L}_{[a,b]}\) is the Lebesgue sigma-algebra restricted to \([a,b]\) and \(m\) is Lebesgue measure. The integrands below are real-valued and Lebesgue integrable. Define the integral-defined function \(F:[a,b]\to\mathbb{R}\) by
At an interior point \(c\in(a,b)\), \(F'(c)\) means the ordinary two-sided derivative. At \(a\) and \(b\), we use the right derivative \(F'_+(a)\) and the left derivative \(F'_-(b)\), respectively. The earlier result on differentiating an indefinite Lebesgue integral states that if \(g\in L^1(m)\), then \(F'(x)=g(x)\) for \(m\)-almost every \(x\in(a,b)\). The calculations here make the derivative behavior explicit for piecewise continuous integrands, including the exceptional breakpoints.
The Breakpoint Rule
Proof. The assumptions make \(g\) measurable and bounded on each of the finitely many subintervals, so \(g\in L^1(m)\) on \([a,b]\). If \(x\) is in the interior of one partition interval, \(g\) is continuous at \(x\). For \(h\ne0\) small enough that \(x+h\) remains in that interval, the definition of \(F\) gives
Given \(\varepsilon>0\), continuity supplies \(\delta>0\) such that \(|g(t)-g(x)|<\varepsilon\) when \(|t-x|<\delta\). For \(0<|h|<\delta\), including \(h<0\), the oriented integral therefore satisfies
Thus the difference quotient tends to \(g(x)\). Now let \(c\) be an interior partition point. For \(h>0\), the same quotient is the average of \(g\) over \([c,c+h]\), and it tends to \(g(c+)\). Indeed, for any \(\varepsilon>0\), the definition of the right-hand limit gives \(|g(t)-g(c+)|<\varepsilon\) for \(t>c\) sufficiently close to \(c\), so the average differs from \(g(c+)\) by at most \(\varepsilon\). For \(h<0\), it is the average over \([c+h,c]\) and tends to \(g(c-)\), by the same estimate from the left. The two-sided derivative exists exactly when these one-sided limits agree, and its value is then their common value. The argument at \(a\) uses positive \(h\), and the argument at \(b\) uses negative \(h\), proving the endpoint formulas. The integral over a singleton is zero, so the assigned value \(g(c)\) at a partition point does not enter either one-sided quotient. \(\square\)
This proposition gives a practical rule: integrate the formula on each open interval and match the resulting integral pieces at the breakpoints. The integral-defined function is continuous there, even when its derivative is not. A finite set of breakpoints has Lebesgue measure zero, so any failures of differentiability among these points do not conflict with the almost-everywhere differentiation result.
Worked Calculations
Worked Example: A Piecewise Constant Integrand
On \([0,4]\) with Lebesgue measure, let \(g=1\) on \([0,1)\), \(g=-2\) on \([1,3)\), and \(g=3\) on \([3,4]\). Find \(F(x)=\int_0^x g(t)\,dt\), its derivatives, and its endpoint derivatives. The values assigned at the breakpoints are taken from these intervals; changing them would not change any integral.
For \(0\le x\le1\), the interval of integration has constant integrand \(1\), giving \(F(x)=x\). For \(1\le x\le3\), split at \(1\): the first interval contributes \(1\), and the next contributes \(-2(x-1)\). Thus \(F(x)=1-2(x-1)=3-2x\). For \(3\le x\le4\), the accumulated integral through \(3\) is \(1-2(3-1)=-3\). The final interval contributes \(3(x-3)\), so \(F(x)=-3+3(x-3)=3x-12\). Therefore
The formulas agree at the joins: at \(1\), both give \(1\); at \(3\), both give \(-3\). Their derivatives on the open intervals are \(1,-2,3\), respectively. At \(1\), the left and right derivatives are \(1\) and \(-2\), so \(F'(1)\) does not exist. At \(3\), they are \(-2\) and \(3\), so \(F'(3)\) does not exist. The endpoint derivatives are \(F'_+(0)=1\) and \(F'_-(4)=3\).
Check: The total integral is \(1\cdot1+(-2)\cdot2+3\cdot1=1-4+3=0\). The formula gives \(F(4)=3\cdot4-12=0\), as required.
Worked Example: A Jump Between Continuous Pieces
On \([0,2]\), define \(g(x)=2x\) for \(0\le x<1\), \(g(1)=17\), and \(g(x)=4-x\) for \(1<x\le2\). Compute the integral-defined function and decide whether it is differentiable at \(1\).
For \(0\le x\le1\), the value at \(1\) does not affect the integral, and
For \(1\le x\le2\), split the integral at \(1\). The first contribution is \(\int_0^1 2t\,dt=1\), so
At \(x=1\), the second expression gives \(4-\tfrac12-\tfrac52=1\), matching the first. The left derivative at \(1\) is \(2\), while the right derivative is \(4-1=3\). Hence \(F'(1)\) does not exist. In particular, the assigned value \(g(1)=17\) is not the derivative there. At the endpoints, \(F'_+(0)=0\) and \(F'_-(2)=4-2=2\).
Check: Directly summing the two interval integrals gives \(\int_0^1 2t\,dt=1\) and \(\int_1^2(4-t)\,dt=[4t-t^2/2]_1^2=6-\tfrac72=\tfrac52\). Their sum is \(\tfrac72\). The formula also gives \(F(2)=8-2-\tfrac52=\tfrac72\).
Worked Example: Equal One-Sided Limits, Different Point Value
On \([0,2]\), let \(g(x)=x\) when \(x\ne1\), and let \(g(1)=7\). Find \(F\) and its derivative at \(1\).
Changing a bounded integrand at the singleton \(\{1\}\) does not change its Lebesgue integral, because \(m(\{1\})=0\). Thus for every \(x\in[0,2]\),
For \(x\ne1\), differentiation gives \(F'(x)=x\), and at the breakpoint the one-sided limits of \(g\) are both \(1\). Directly, for \(h\ne0\) sufficiently small,
Therefore \(F'(1)=1\), not \(g(1)=7\). Check: the derivative of the single formula \(x^2/2\) is \(x\), which also gives \(1\) at \(x=1\).
Common Mistake: Using the Assigned Value at a Jump
A tempting but incorrect calculation is to assert \(F'(c)=g(c)\) at every point. The second example shows why: \(g(1)=17\), but the right difference quotient tends to \(3\), while the left one tends to \(2\). Since these limits differ, there is no two-sided derivative. The third example shows the other failure of this shortcut: a point value of \(7\) can coexist with a derivative of \(1\), because a single point contributes nothing to the integral.
The correct procedure is to use the integral’s difference quotient. At an interior point \(c\), positive increments average the integrand just to the right of \(c\), and negative increments average it just to the left. When both one-sided limits exist, equality of those limits is precisely the condition for the ordinary derivative to exist. At an endpoint, only increments directed into the interval are available, so the appropriate derivative is one-sided.
How the Calculation Fits the Almost-Everywhere Result
For a piecewise continuous real-valued function on a finite interval, the hypotheses of the earlier indefinite-integral differentiation result hold: such a function is measurable and integrable, and its integral-defined function satisfies \(F'=g\) \(m\)-almost everywhere. The breakpoint calculation adds pointwise detail. On every open interval of continuity, the derivative exists and equals the integrand. At a breakpoint, the derivative exists exactly when the two one-sided limits match; the value assigned at the point itself is immaterial. Since there are only finitely many breakpoints, the exceptional set described by this calculation is finite and therefore has measure zero.
When solving a particular problem, make a partition that contains every change in the formula for \(g\). Compute each accumulated integral using the contributions from all preceding intervals, then check that adjacent expressions agree at their common endpoint. Differentiate each piece on its interval, and at every interior partition point compare the left and right derivatives. Finally, report one-sided endpoint derivatives rather than an ordinary two-sided derivative there. These checks prevent both arithmetic errors in accumulated constants and conceptual errors about jumps.
Check Your Understanding
For each problem, distinguish ordinary derivatives at interior points from one-sided derivatives at endpoints.
- On \([0,3]\), let \(g=2\) on \([0,1)\) and \(g=-1\) on \([1,3]\). Find \(F(x)=\int_0^xg(t)\,dt\), and determine whether \(F'(1)\) exists.
- Suppose a piecewise continuous integrand has one-sided limits \(g(c-)=4\) and \(g(c+)=4\) at an interior partition point \(c\), but its assigned value \(g(c)\) is \(-9\). What is \(F'(c)\), and why?
- On \([0,2]\), let \(g(x)=3x\) for \(x\ne1\) and \(g(1)=0\). Compute \(F\) and \(F'(1)\).
- For \(F(x)=\int_a^xg(t)\,dt\), explain why the derivative at \(a\) is a right derivative and identify the value it equals when \(g\) has a finite right-hand limit.
- Give the exact condition, in terms of one-sided limits, for a two-sided derivative at an interior breakpoint to exist.