Integral of periodic function over the length of the period is the same everywhere

I am stuck on a question that involves the intergral of a periodic function. The question is phrased as follows:

Definition. A function is periodic with period $a$ if $f(x)=f(x+a)$ for all $x$.

Question. If $f$ is continuous and periodic with period $a$, then show that $$\int_{0}^{a}f(t)dt=\int_{b}^{b+a}f(t)dt$$ for all $b\in \mathbb{R}$.

I understand the equality, but I am having trouble showing that it is true for all $b$. I've tried writing it in different forms such as $F(a)=F(b+a)-F(b)$. This led me to the following, though I am not sure how this shows the equality is true for all $b$,

$$\int_{0}^{a}f(t)dt-\int_{b}^{b+a}f(t)dt=0$$ $$=F(a)-F(0)-F(b+a)-F(b)$$ $$=(F(b+a)-F(a))-F(b)$$ $$=\int_{a}^{b+a}f(t)dt-\int_{0}^{b+a}f(t)dt=0$$

So, this leaves me with

$$\int_{a}^{b+a}f(t)dt-\int_{0}^{b+a}f(t)dt=\int_{0}^{a}f(t)dt-\int_{b}^{b+a}f(t)dt$$

I feel I am close, and I've made myself a diagram of a sine function to visualize what each of the above integrals might describe, but the power to explain the above equality evades me.


Solution 1:

Let $H(x)=\int_x^{x+a}f(t)\,dt$. Then $$\frac{dH}{dx}=f(x+a)-f(x)=0.$$ It follows that $H(x)$ is constant. In particular, $H(b)=H(0)$.

Solution 2:

We have $$ \int_{0}^{a}f(t)\ dt+\int_{a}^{a+b}f(x)\ dx=\int_{0}^{b}f(y)\ dy+\int_{b}^{a+b}f(t)\ dt, $$ and setting $x=y-a$ turns the second integral into the third one.

Solution 3:

You have made various false steps in your four line block and should have ended up with $$\int_{a}^{b+a}f(t)dt-\int_{0}^{b}f(t)dt=0$$ but this does not take you much further forward.

Instead note that somewhere in the interval $[b, b+a]$ is an integer multiple of $a$, say $na$. Then using $f(t)=f(t+a)=f(t+na)$: $$\int_{b}^{b+a}f(t)dt = \int_{b}^{na}f(t)dt+\int_{na}^{b+a}f(t)dt = \int_{b+a}^{(n+1)a}f(t)dt+\int_{an}^{b+a}f(t)dt = \int_{na}^{(n+1)a}f(t)dt = \int_{0}^{a}f(t)dt.$$