Clock Edges Appendix

 The Fourier Series for a finite sum may be defined as:

    \begin{displaymath}\mathbb{F}_n(x) \; = \; a_o \, + \, \sum_{n=1}^N \left[\, A_n \, \text{cos}(nx) \, + \, B_n \, \text{sin}(nx) \, \right]\end{displaymath}


where n \, = \, 1, \, 2, \, ..., \, N
 
The coefficients are found to be:

    \begin{displaymath}\begin{align}a_o \; &= \; \frac{1}{2 \, \pi} \, \int_{-\pi}^{+\pi} \mathbb{F}_n(x) \, dx \quad \frac{1}{T} \, \int_{-T/2}^{+T/2} x(t) \, dt\\\\a_n \; &= \; \frac{1}{\pi} \, \int_{-\pi}^{+\pi} \mathbb{F}_n(x) \, cos(n \, x) \, dx \quad 1 \leq n \leq N \quad \frac{2}{T} \, \int_{-T/2}^{+T/2} x(t) \, cos\left(\frac{\, 2 \, \pi \, n \, t \,}{T}\right) \, dt \\\\b_n \; &= \; \frac{1}{\pi} \, \int_{-\pi}^{+\pi} \mathbb{F}_n(x) \, sin(n \, x) \, dx \quad 1 \leq n \leq N \quad -\frac{2}{T} \, \int_{-T/2}^{+T/2} x(t) \, sin\left(\frac{\, 2 \, \pi \, n \, t \,}{T}\right) \, dt\end{align}\end{displaymath}

 
For an amplitude-offset square wave, the function may be defined:

    \begin{displaymath}\[ f(x) = \left\{ \begin{array}{ll}0 & \mbox{if $-\pi \leq x < 0$};\\\pi & \mbox{if $0 \leq x \leq \pi$}.\end{array} \right. \]\end{displaymath}


where

    \begin{displaymath}\begin{align}a_o \; &= \; \frac{1}{2 \, \pi} \, \left( \, \int_{-\pi}^0 0 \, dx \, + \, \int_0^\pi 0 \, dx \, \right) \; = \; \frac{\pi}{2} \\\\a_n \; &= \; \int_0^\pi \pi \, cos(n \, x) \, dx \; = \; 0 \quad n \geq 1 \\\\b_n \; &= \; \int_0^\pi \pi \, sin(n \, x) \, dx \; = \; \frac{1}{n} \, \left[ \, 1 \, - \, cos(n \pi) \, \right] \; = \; \frac{1}{n} \, \left[ \, 1 \, - \, (-1)^n \, \right]\end{align}\end{displaymath}


where b_{2n} \, = \, 0 and

    \begin{displaymath}b_{2\, n \, + \, 1} \; = \; \frac{2}{\, 2 \, n \, + \, 1 \, }\end{displaymath}

which gives:

    \begin{displaymath}\mathbb{F}(x) \; = \; \frac{\pi}{2} \, + \, \sum_{n=1}^N \frac{\, sin(n \, x) \, }{n} \quad \text{for n odd}\end{displaymath}

Consider a pulse sequence of amplitude A and duty-cycle d (where d = k/T) centered about 0. By definition, this is an even function:

    \begin{displaymath}\[ x(t) = \left\{ \begin{array}{ll}A & \mbox{for $-k/2 \leq t \leq k/2$};\\0 & \mbox{elsewhere}.\end{array} \right. \]\end{displaymath}

 
The even-function coefficients are found from:

    \begin{displaymath}\begin{align}a_o \; &= \; A \, d \\\\a_n \; &= \; \frac{\, 2 \, A \, }{n \, \pi} \\\\b_n \; &= \; 0\end{align}\end{displaymath}

If A \, = \, 1 and d \, = \, 0.25, then the amplitudes for the first several terms are:

    \begin{displaymath}\begin{array}{rr}& \\0 & 0.25000\\1 & 0.45016\\2 & 0.31831\\3 & 0.15005\\4 & 0\\5 & -0.09003\\6 & -0.10610\\7 & -0.06431\\8 & 0\\9 & 0.05002\\10 & 0.06366\\11 & 0.04092\\12 & 0\end{array}\end{displaymath}

 Put into Mathematica code:

Gives this result:

The Gibbs Effect “ears” are prominent and indicate about 9% over and under shoot.

But the function is even – centered about 0; the full response appears as:

… sort of “sloppy” with only 13 terms (with DC).

If I calculate for 1200 terms, I get this:

The Gibbs “ears” remain at about \pm9%, but the duration decreases as N increases and the energy content tends to 0.

Time-shifting the function will alter the coefficients (Coefficients b_n are only zero if the function is centered about 0; i.e., an even function).

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top