Intuitive Guide to Fourier Analysis Charan Langton Victor Levin Much of this book relies on math developed by important persons in the field over the last 200 years. When known or possible, the authors have given the credit due. We relied on many books and articles and consulted many articles on the internet and often many of these provided no name for credits. In this case, we are grateful to all who make the knowledge available free for all on the internet. The publisher offers discounts on this book when ordered in quantity for bulk purchase or special sales. We can also make available on special or electronic version applicable to your business goals, such as training, marketing and branding issues. For more information, please contact us. [email protected] Website for this book: complextoreal.com/fftbook Copyright 2016 Charan Langton and Victor Levin ISBN- 13: 978-0-913063-26-2 All Rights reserved Printed in the United States of America. This publication is protected by copyright and permission must be obtained from the Publisher prior to prohibited reproduction, storate in a retrieval system, recording. For information regarding permissions, please contact the publisher. Contents Preface ix 1 Trigonometric Representation What is Fourier analysis . . . . . . . . . . . . . . . . . . . . Frequency and time domain views of a signal . . . . . . . Spectrum of a signal . . . . . . . . . . . . . . . . . . . Fundamental waves and their harmonics . . . . . . . Harmonics as basis functions . . . . . . . . . . . . . . . . . Even and oddness of sinusoids . . . . . . . . . . . . . Making waves . . . . . . . . . . . . . . . . . . . . . . . Square waves . . . . . . . . . . . . . . . . . . . . . . . Gibbs phenomenon . . . . . . . . . . . . . . . . . . . . Creating a sawtooth wave . . . . . . . . . . . . . . . . Generalizing the Fourier series equation . . . . . . . . . . Multiple ways of writing the Fourier series equation Fourier series in the complex form . . . . . . . . . . . The Fourier Analysis . . . . . . . . . . . . . . . . . . . . . . . Computing a0 , the DC coefficient . . . . . . . . . . . Computing bk , the coefficients of sine waves . . . . Computing coefficient of cosine, ak . . . . . . . . . . Coefficients are the spectrum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1 3 4 5 8 10 11 11 13 13 14 15 16 16 17 19 22 25 2 Complex Representation Euler’s equation . . . . . . . . . . . . . . . . . . The complex exponential . . . . . . . . . Projections of the complex exponenetial The sinusoids . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 34 34 35 37 iii . . . . . . . . . . . . . . . . . . . . . . . . . . . . CONTENTS Fourier series representation using complex exponentials . . . . . . . . . . . . . . . . . 40 Power spectrum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51 Appendix: A little bit about complex numbers . . . . . . . . . . . . . . . . . . . . . . . . 58 3 Discrete-time Signals Discrete signals are different from analog signals . . . . . . . . . Discrete vs. digital . . . . . . . . . . . . . . . . . . . . . . . . Generating discrete signals . . . . . . . . . . . . . . . . . . . Sampling and interpolation . . . . . . . . . . . . . . . . . . . . . . Ideal sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . Reconstruction of the analog signal from discrete samples Method 1: Zero-order hold . . . . . . . . . . . . . . . . . . . Method 2: First order hold (linear interpolation) . . . . . . Method 3: Sinc interpolation . . . . . . . . . . . . . . . . . . Sinc function detour . . . . . . . . . . . . . . . . . . . . . . . Sampling rate . . . . . . . . . . . . . . . . . . . . . . . . . . . Shannon’s Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . Aliasing of discrete signals . . . . . . . . . . . . . . . . . . . Bad sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . Good sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . Discrete signal parameters . . . . . . . . . . . . . . . . . . . . . . . Digital frequency, only for discrete signals . . . . . . . . . . Are discrete signals periodic? . . . . . . . . . . . . . . . . . . Discrete complex exponentials as basis of DT Fourier series . . . Harmonics of a discrete fundamental CE . . . . . . . . . . . Repeating Harmonics of a discrete signal . . . . . . . . . . . Discrete-time Fourier Series (DTFS) representation . . . . . . . . DTFS Examples . . . . . . . . . . . . . . . . . . . . . . . . . . DTFSC of a repeating square pulse signal . . . . . . . . . . Power spectrum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Matrix method for computing Fourier series coefficients . . . . . 4 Continuous-time Fourier Transform Applying Fourier series to aperiodic signals . . . . . . . . . . . . Extending the period to infinity . . . . . . . . . . . . . . . . Continuous-Time Fourier Transform (CTFT) . . . . . . . . . Comparing Fourier series coefficients and the Fourier transform iv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 . 64 . 64 . 64 . 66 . 66 . 67 . 68 . 69 . 71 . 71 . 74 . 75 . 76 . 77 . 78 . 81 . 81 . 83 . 86 . 86 . 87 . 91 . 92 . 98 . 101 . 102 . . . . 107 . 108 . 108 . 110 . 113 CONTENTS CTFT of important aperiodic functions . . CTFT of an impulse function . . . . . CTFT of a constant . . . . . . . . . . . CTFT of a sinusoid . . . . . . . . . . . CTFT of a complex exponential . . . Time-shifting a function . . . . . . . . Duality with frequency shift . . . . . . Convolution property . . . . . . . . . . CTFT of a Gaussian function . . . . . CTFT of a square pulse . . . . . . . . . Fourier transform of periodic signals . . . . CTFT of a periodic square pulse train . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Discrete-time Fourier Transform Discrete-time Fourier Transform (DTFT) . . . . . . . . . . . DTFT is continuous and periodic with period of 2π . . . . Comparing DTFT with CTFT . . . . . . . . . . . . . . . Obtaining a DTFT from CTFT . . . . . . . . . . . . . . . DTFT of a delayed impulse . . . . . . . . . . . . . . . . DTFT of superposition of impulses . . . . . . . . . . . . . . . DTFT of a square pulse . . . . . . . . . . . . . . . . . . . . . . Dirichlet detour . . . . . . . . . . . . . . . . . . . . . . . Applying time-shift property to the DTFT of a square pulse Time expansion property . . . . . . . . . . . . . . . . . . . . . DTFT of a triangular pulse . . . . . . . . . . . . . . . . . . . . Computing the DTFT of a Raised-cosine pulse . . . . . . . . DTFT of a Gaussian pulse . . . . . . . . . . . . . . . . . . . . Now the DTFT of periodic signals . . . . . . . . . . . . . . . DTFT of periodic signals . . . . . . . . . . . . . . . . . . . . . 6 Discrete Fourier Transform (DFT) The four cases of Fourier transform . . . The Discrete Fourier transform (DFT) . . DFT from DTFT . . . . . . . . . . . . DFT frequency resolution . . . . . . Understanding the x-axis of a DFT . Periodic signal assumption . . . . . . . . . . . v . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114 . 115 . 117 . 118 . 119 . 122 . 125 . 126 . 127 . 128 . 131 . 133 . . . . . . . . . . . . . . . 139 . 141 . 142 . 143 . 144 . 145 . 146 . 149 . 150 . 151 . 153 . 153 . 154 . 156 . 157 . 160 . . . . . . 167 . 168 . 170 . 170 . 171 . 173 . 174 CONTENTS Computing DFT . . . . . . . . . . . . . . . . . . . . . . . . Computing DFT, the hard way with integration . . Computing DFT the easier way with matrix math Computing DFT the easy way with Matlab . . . . . . . . Zero-padding . . . . . . . . . . . . . . . . . . . . . . . . . . Better interpolation density vs. better resolution . Fundamental functions and their DFT . . . . . . . . . . . DFT of an impulse function . . . . . . . . . . . . . . DFT of a delayed impulse . . . . . . . . . . . . . . . DFT of a sinusoid . . . . . . . . . . . . . . . . . . . . DFT of a complex exponential . . . . . . . . . . . . DFT of a square pulse . . . . . . . . . . . . . . . . . DFT of a finite sinc function . . . . . . . . . . . . . . DFT repeats with sampling frequency . . . . . . . . DFT Periodicity and Leakage . . . . . . . . . . . . . . . . Truncation effect . . . . . . . . . . . . . . . . . . . . Truncation causes leakage . . . . . . . . . . . . . . . Reducing leakage by doing a longer DFT . . . . . . Reducing leakage by windowing . . . . . . . . . . . DFT and Multi-rate processing . . . . . . . . . . . . . . . Up-sampling and seeing images . . . . . . . . . . . Down-sampling . . . . . . . . . . . . . . . . . . . . . Interpolation . . . . . . . . . . . . . . . . . . . . . . . Convolution by DFT . . . . . . . . . . . . . . . . . . . . . . Short-Time Fourier transform . . . . . . . . . . . . . . . . DFT in real-life . . . . . . . . . . . . . . . . . . . . . . . . . Fast Fourier Transform (FFT) . . . . . . . . . . . . . . . . 7 Signal Windowing Smearing and leakage due to truncation . The rectangular window is always present Window Quality metrics . . . . . . . . . . . Filtering with Windows . . . . . . . . . . . . Spectral estimation . . . . . . . . . . . . . . Comparing windows . . . . . . . . . . . . . The flexible Kaiser window . . . . . . . . . vi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175 . 175 . 177 . 183 . 184 . 187 . 188 . 188 . 189 . 189 . 189 . 192 . 192 . 193 . 194 . 195 . 197 . 198 . 199 . 200 . 200 . 203 . 204 . 205 . 207 . 208 . 210 . . . . . . . 217 . 218 . 221 . 225 . 226 . 227 . 228 . 230 CONTENTS 8 Fourier Analysis of Random Signals Fourier analysis of deterministic vs. random signals Conditions when Fourier analysis is valid . . . Energy and Power signals . . . . . . . . . . . . . Energy Spectral Density . . . . . . . . . . . . . . Power Spectral Density (PSD) . . . . . . . . . . Characteristics of Random Signals . . . . . . . . . . . An ensemble and a realization . . . . . . . . . . Measure of Randomness . . . . . . . . . . . . . . Stationarity . . . . . . . . . . . . . . . . . . . . . . Strict and not so strict stationarity . . . . . . . . Ergodicity . . . . . . . . . . . . . . . . . . . . . . . Understanding properties of random signals . . . . . Time average vs. Ensemble average . . . . . . . Probability distribution . . . . . . . . . . . . . . . Moments . . . . . . . . . . . . . . . . . . . . . . . The Autocorrelation function . . . . . . . . . . . . . . Ways of looking at ACF . . . . . . . . . . . . . . Varieties of Autocorrelation Function . . . . . . Properties of the ACF . . . . . . . . . . . . . . . . Comparing Auto-correlation with Convolution Some interesting signals and their ACF . . . . . . . . Barker Codes . . . . . . . . . . . . . . . . . . . . . Chirp signal . . . . . . . . . . . . . . . . . . . . . . Fourier transform of the ACF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 Power Spectrum of random signals Power Spectrum of a deterministic signal . . . . . . . . . . . Spectrum of a random signal . . . . . . . . . . . . . . . . . . Non-parametric spectral estimation via Autopower . . . . . Auto-correlation function bias caused by finite length The measure of an estimate, MSE, bias and variance . . . . The Autopower Method and its parameters . . . . . . . . . What is a reasonable length for the signal? . . . . . . Biased vs. unbiased ACF . . . . . . . . . . . . . . . . . . Windowing the ACF . . . . . . . . . . . . . . . . . . . . How to choose a window . . . . . . . . . . . . . . . . . vii . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 237 . 238 . 239 . 242 . 243 . 245 . 247 . 249 . 249 . 251 . 251 . 252 . 253 . 254 . 255 . 256 . 258 . 259 . 261 . 267 . 269 . 270 . 270 . 271 . 273 . . . . . . . . . . 279 . 280 . 280 . 281 . 283 . 284 . 286 . 286 . 287 . 288 . 290 CONTENTS Shortening the ACF . . . . . . . . . . . . . . . . . . . . . . . . Blackman-Tukey Algorithm to improve the Autopower . . The second non-parametric method, the Periodogram . . . . . . Periodogram vs. length of signal . . . . . . . . . . . . . . . . Improving the Periodogram . . . . . . . . . . . . . . . . . . . Reducing Periodogram variance using the Bartlett Method Reducing Periodogram variance with Welch Method . . . . Bartlett method . . . . . . . . . . . . . . . . . . . . . . . . . . Welch Method . . . . . . . . . . . . . . . . . . . . . . . . . . . Comparing Autopower and Periodogram . . . . . . . . . . . . . . Figure of Merit of a spectrum . . . . . . . . . . . . . . . . . . . . . viii . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291 . 292 . 293 . 295 . 299 . 300 . 301 . 302 . 302 . 303 . 304
© Copyright 2025 Paperzz