Fundamental operation for LTI systems and filtering. Definition Continuous-Time $$ y(t) = (x * h)(t) = \int_{-\infty}^{\infty} x(\tau) h(t - \tau) d\tau $$ Discrete-Time $$ y[n] = (x * h)[n] = \sum_{k=-\infty}^{\infty} x[k] h[n - k] $$ Physical Interpretation Convolution represents the output of an LTI system: $x[n]$: …
Read MoreMeasure similarity between signals for pattern matching and analysis. Cross-Correlation $$ (x \star y)[n] = \sum_{k=-\infty}^{\infty} x[k] y[n + k] $$ Auto-Correlation $$ R_{xx}[n] = (x \star x)[n] = \sum_{k=-\infty}^{\infty} x[k] x[n + k] $$ Implementation 1import numpy as np 2 3# Cross-correlation 4corr = …
Read MoreFilter Types Type Passband Stopband Transition Butterworth Flat Monotonic Moderate Chebyshev I Ripple Monotonic Sharp Chebyshev II Flat Ripple Sharp Elliptic Ripple Ripple Sharpest Design Workflow Specify requirements: Passband, stopband, ripple, attenuation Choose filter type: FIR vs IIR, Butterworth vs Chebyshev, …
Read MorePractical guides and mathematical principles behind digital filters, including Kalman, FIR, and IIR filters.
Read MoreFinite Impulse Response filters - always stable, linear phase possible. Definition $$ y[n] = \sum_{k=0}^{M-1} b_k x[n-k] $$ Design Methods Window Method 1from scipy import signal 2import numpy as np 3 4# Design lowpass FIR filter 5numtaps = 51 # Filter order + 1 6cutoff = 0.3 # Normalized frequency (0 to 1) 7 8# Using …
Read MoreTransform signals between time and frequency domains. Overview The Fourier Transform decomposes a signal into its constituent frequencies, revealing the frequency content of time-domain signals. Continuous Fourier Transform (CFT) Forward Transform $$ X(f) = \int_{-\infty}^{\infty} x(t) e^{-j2\pi ft} dt $$ Inverse …
Read MoreInfinite Impulse Response filters - efficient but can be unstable. Definition $$ y[n] = \sum_{k=0}^{M} b_k x[n-k] - \sum_{k=1}^{N} a_k y[n-k] $$ Design Methods Butterworth (Maximally Flat) 1from scipy import signal 2 3# Design 4th-order Butterworth lowpass 4order = 4 5cutoff = 0.3 # Normalized frequency 6b, a = …
Read MoreNon-linear filter excellent for removing salt-and-pepper noise while preserving edges. Definition Replace each sample with the median of its neighborhood: $$ y[n] = \text{median}{x[n-k], \ldots, x[n], \ldots, x[n+k]} $$ Implementation 1from scipy import signal, ndimage 2import numpy as np 3 4# 1D median filter …
Read MoreConvert between continuous and discrete-time signals. Nyquist-Shannon Sampling Theorem A bandlimited signal with maximum frequency $f_{max}$ can be perfectly reconstructed if: $$ f_s \geq 2f_{max} $$ Reconstruction Ideal (Sinc Interpolation) $$ x(t) = \sum_{n=-\infty}^{\infty} x[n] \cdot \text{sinc}\left(\frac{t - …
Read MoreFundamental concepts for understanding and processing signals. Signal Types Continuous-Time vs Discrete-Time Continuous-Time Signal: $x(t)$, defined for all $t \in \mathbb{R}$ Discrete-Time Signal: $x[n]$, defined only at integer values $n \in \mathbb{Z}$ Analog vs Digital Analog: Continuous in both time and amplitude …
Read MoreFundamental concepts and mathematical tools for signal processing, including Fourier analysis, convolutions, and correlations.
Read MoreReduce spectral leakage in FFT analysis. Common Windows Rectangular (No Window) $$w[n] = 1$$ Hanning $$w[n] = 0.5 \left(1 - \cos\left(\frac{2\pi n}{N-1}\right)\right)$$ Hamming $$w[n] = 0.54 - 0.46\cos\left(\frac{2\pi n}{N-1}\right)$$ Blackman $$w[n] = 0.42 - 0.5\cos\left(\frac{2\pi n}{N-1}\right) + …
Read More