The Fourier series of an antiderivative of a real periodic function #f# can be determined from the Fourier series of #f# if the latter exists.
Suppose that #f# is a real #2\pi#-periodic function which is piecewise continuous on #\ivcc{-\pi}{\pi}# with Fourier series
\[s_f(x) = \frac{a_0}{2} + \sum_{n=1}^{\infty}\left(a_n\cos (nx)+b_n\sin( nx )\right)\]
The antiderivative #F(x) = \int_0^x f(t)\,\dd t# of #f# satisfies
\[ F(x) = \displaystyle\sum_{n=1}^{\infty} \frac{b_n}{n}+ \frac{a_0 x}{2} + \sum_{n=1}^{\infty} \frac{a_n \sin (nx) - b_n \cos (nx)}{n}\]
and # \sum_{n=1}^{\infty} \frac{b_n}{n} # is a real number.
The Fourier series #s_F# of the #2\pi#-periodic function whose value is #F(x)# for #x\in \ivco{-\pi}{\pi}# is given by
\[s_F(x) =\displaystyle\sum_{n=1}^{\infty} \frac{b_n}{n} +\sum_{n=1}^{\infty} \frac{-b_n\cos( nx) + (a_n - (-1)^{n} a_0) \sin (nx)}{n} \]
The definite integral of #f# on an interval #\ivcc{c}{d}# can be found by integrating the Fourier series of #f# term by term:
\[\int_c^d f(x) \dd x = \frac{a_0}{2}(d-c)+ \sum_{n=1}^{\infty} \frac{a_n(\sin (nd) - \sin( nc)) - b_n(\cos( nd) - \cos( nc))}{n} \]
Set
\[ G(x)=\int_0^x \left(f(t)-\frac{a_0}{2}\right) \dd t \]
This function is well defined since #f# is piecewise continuous on any closed interval. The antiderivative #F# of #f# with #F(0)=0# satisfies \[F(x)=\int_0^x f(t)\dd t = \frac{a_0\,x}{2}+G(x)\]
The function #G(x)# is differentiable and its derivative #f(x)-\frac{a_0}{2}# is piecewise continuous on #\ivcc{-\pi}{\pi}#. Moreover, it is #2\pi#-periodic since
\[\begin{array}{rcl}\displaystyle G(x+2\pi) &=& \displaystyle\int_0^{x+2\pi} \left(f(t)-\frac{a_0}{2}\right) \dd t \\ &&\phantom{xxx}\color{blue}{\text{function rule of }G}\\&=& \displaystyle\int_0^x \left(f(t)-\frac{a_0}{2}\right) \dd t +\int_x^{x+2\pi} \left(f(t)-\frac{a_0}{2}\right) \dd t \\ &&\phantom{xxx}\color{blue}{\text{property of definite integrals}}\\&=& G(x) + \displaystyle\int_{-\pi}^{\pi} \left(f(t)-\frac{a_0}{2} \right) \dd t \\&&\phantom{xxx}\color{blue}{\text{function rule of }G\text{, periodicity of }f\text{, and substitution rule of integrals}}\\&=& G(x) + \displaystyle\int_{-\pi}^{\pi} f(t) \dd t - \pi a_0 \\&&\phantom{xxx}\color{blue}{\text{Fundamental theorem of Calculus}}\\&=&G(x)\\&&\phantom{xxx}\color{blue}{\text{Euler formula for }a_0} \end{array}\]
Hence, Dirichlet's theorem gives that #G# admits a Fourier series. Let #A_0#, #A_1#, #B_1#, #A_2#, #B_2,\ldots# be the corresponding Fourier coefficients. Since #G# is differentiable, it is #G# is continuous, so its Fourier series converges to #G(x)# at every point #x#:
\[G(x) = \frac{A_0}{2} + \sum_{n=1}^{\infty}\left(A_n\cos( nx)+B_n\sin (nx)\right) \]
Since #G# is continuous, we can apply integration by parts for #n \geq 1#, as follows.
\[\begin{array}{rcl}\displaystyle A_n &=& \displaystyle\frac{1}{\pi} \int_{-\pi}^{\pi} G(x) \cos( nx) \dd x \\&&\phantom{xxx}\color{blue}{\text{Euler formula}}\\ &=& \displaystyle\frac{1}{\pi} \left. G(x) \frac{\sin (nx)}{n} \right|^{x=\pi}_{x=-\pi} - \frac{1}{\pi n} \int_{-\pi}^{\pi}G'(t) \sin (nt) \dd t \\&&\phantom{xxx}\color{blue}{\text{integration by parts}}\\&=& \displaystyle - \frac{1}{\pi n} \int_{-\pi}^{\pi} \left(f(t)-\frac{a_0}{2} \right) \sin (nt) \dd t \\&&\phantom{xxx}\color{blue}{\sin(k\pi) = 0\text{ for integers }k}\\&=&\displaystyle - \frac{1}{\pi n} \int_{-\pi}^{\pi} f(t) \sin (nt) \dd t + \frac{1}{\pi n} \int_{-\pi}^{\pi} \frac{a_0}{2} \sin (nt) \dd t \\&&\phantom{xxx}\color{blue}{ \text{linearity of integration}}\\&=&\displaystyle- \frac{1}{\pi n} \int_{-\pi}^{\pi} f(t) \sin (nt) \dd t \\&&\phantom{xxx}\color{blue}{\frac{a_0}{2}\sin(nt) \text{ is odd and interval is symmetric around zero}}\\&=&\displaystyle -\frac{b_n}{n} \\&&\phantom{xxx}\color{blue}{\text{Euler formula}}\end{array}\]
and, similarly, \( B_n=\frac{a_n}{n} \). Since #G# is continuous, its Fourier series converges to #G(x)# at every point #x#. As a consequence, #F# satisfies
\[F(x) =\displaystyle \frac{a_0 x}{2} +G(x)= \displaystyle \frac{a_0 x}{2} + \frac{A_0}{2} + \sum_{n=1}^{\infty} \frac{a_n \sin (nx) - b_n \cos (nx)}{n}\]
By evaluating this expression for #F(x)# at #x = d# and at #x=c# we obtain
\[\begin{array}{rcl}\displaystyle \int_c^d f(x) \dd x &=& F(d) - F(c) \\ &=&\displaystyle \frac{a_0}{2}(d-c)+ \sum_{n=1}^{\infty} \frac{a_n(\sin (nd) - \sin( nc)) - b_n(\cos( nd) - \cos( nd))}{n} \end{array}\]
which establishes the formula for the definite integral of #f#.
Substituting #x=0# in the above Fourier series for #F(x)#, we find \( 0=F(0) = \frac{A_0}{2} - \sum_{n=1}^{\infty} \frac{ b_n }{n}\), so
\[ \frac{A_0}{2} = \sum_{n=1}^{\infty} \frac{b_n}{n}\]
Thus, \[F(x) = \displaystyle \frac{a_0 x}{2} +\sum_{n=1}^{\infty} \frac{b_n}{n} + \sum_{n=1}^{\infty} \frac{a_n \sin (nx) - b_n \cos (nx)}{n}\]
This proves the first statement of the theorem.
By use of the Euler formulas, the Fourier series for the #2\pi#-periodic function determined by #\frac{x}{2}# on #\ivco{-\pi}{\pi}# is readily seen to be
\[ s_{\frac{x}{2} }=\sum_{n=1}^{\infty} (-1)^{n+1} \frac{\sin (nx)}{n} \]
Substituting these two expressions for #\frac{A_0}{2}# and #\frac{x}{2}# again in the Fourier series for the periodic function determined by #F#, we conclude that
\[\begin{array}{rcl}s_F(x) &=& \displaystyle a_0\cdot s_{ \frac{ x}{2} }+ \frac{A_0}{2} + \sum_{n=1}^{\infty} \frac{a_n \sin (nx) - b_n \cos (nx)}{n}\\ &=& \displaystyle\sum_{n=1}^{\infty} \frac{b_n}{n}+\sum_{n=1}^{\infty} \frac{-b_n\cos( nx) + (a_n - (-1)^{n} a_0) \sin (nx)}{n}\end{array} \]
This proves the indefinite integral formula of the theorem.
The antiderivative #F# of #f# is periodic if and only if #a_0=0#. This explains why the function #G# is used in the proof.
The Fourier series #s_F# corresponding to the antiderivative #F# of #f# converges to #F(x)# at every point #x# of #\ivoo{-\pi}{\pi}# since #F# (being differentiable) is continuous on #\ivoo{-\pi}{\pi}#.
Applying the theorem to a periodic piecewise smooth function #f# shows that the series \( \sum_{n=1}^\infty \frac{b_n}{n} \), being the constant of #s_F#, converges. This fact can be useful, for example, for ruling out at first glance that a series like
\[\sum_{n=2}^{\infty} \frac{\sin (nx)}{\log( n)} \]
can be the Fourier series of some piecewise smooth function; because
\[ \sum_{n=2}^{\infty} \frac{1}{n \log (n)} \]
diverges.
Let #f# be the #2\pi#-periodic function determined by \[f(x) = x^3\quad \text{ for }\quad x \in \ivco{-\pi}{\pi} \]
Its Fourier series is \[ \sum_{n=1}^{\infty}-{{\left(2\cdot \pi^2\cdot n^2-12\right)\cdot \left(-1\right)^{n}\cdot \sin \left(n\cdot x\right)}\over{n^3}} \]
Let #F# be the #2\pi#-periodic function determined by \[F(x) = \int_0^x f(t)\,\dd t\quad\text{ for }\quad x\in \ivco{-\pi}{\pi}\]
Which of the expressions is the Fourier series #s_F# of #F# for a suitable constant #C#?
#s_F(x) = C+\sum_{n=1}^{\infty}{{\left(2 \pi ^2 n ^2-12\right)\cdot \left(-1\right)^{n}\cdot \cos \left(n x \right)}\over{n^4}}#
By the theorem
Integration of Fourier series there is a constant #C# (in fact, #C = \sum_{n=1}^\infty \frac{b_n}{n}#) such that
\[\begin{array}{rcl}
s_F(x) & = &\displaystyle C + \sum_{n=1}^\infty \frac{-b_n\cos(nx)+(a_n-(-1)^na_0)\sin(nx)}{n} \\
\end{array}\]
The values of the Fourier coefficients #a_0=0#, #a_n=0#, #b_n=-{{\left(2\cdot \pi^2\cdot n^2-12\right)\cdot \left(-1\right)^{n}}\over{n^3}}# are known from the Fourier series of #f#, which is given.
Substituting these values gives the expression
\[ s_F(x)= C+\sum_{n=1}^{\infty}{{\left(2 \pi ^2 n ^2-12\right)\cdot \left(-1\right)^{n}\cdot \cos \left(n x \right)}\over{n^4}}\]
Using the known formulas \[\sum_{n=1}^{\infty}\frac{(-1)^n}{n^2} = -\frac{\pi^2}{12}\qquad \text{and }\qquad \sum_{n=1}^{\infty}\frac{(-1)^n}{n^4} = -\frac{7\pi^4}{720}\] we derive the value #C# as follows from the identity #C = \sum_{n=1}^\infty \frac{b_n}{n}#.
\[\begin{array}{rcl} C &=&\displaystyle \sum_{n=1}^\infty \frac{b_n}{n}\\
&=&\displaystyle -\sum_{n=1}^{\infty }{{{\left(2\cdot \pi^2\cdot n^2-12\right)\cdot \left(-1\right)^{n}}\over{n^4}}} \\
&=&\displaystyle \displaystyle -2\pi^2\sum_{n=1}^{\infty} \frac{(-1)^n}{n^2}+12\sum_{n=1}^{\infty} \frac{(-1)^n}{n^4}\\ &=& \displaystyle -2\pi^2\cdot\left(-\frac{\pi^2}{12}\right)+12\cdot\left(-\frac{ 7\pi^4}{720}\right)\\ &=&\displaystyle \frac{\pi^4}{20}
\end{array}\]
and so
\[\begin{array}{rcl}
s_F(x) & = &\displaystyle {{\pi^4}\over{20}}+\sum_{n=1}^{\infty}{{\left(2 \pi ^2 n ^2-12\right)\cdot \left(-1\right)^{n}\cdot \cos \left(n x \right)}\over{n^4}} \\
\end{array}\]