4.2 Data Sampling, Accuracy/Precision, and A/D Conversion
Key Takeaways
- The Nyquist-Shannon sampling theorem mandates that the sampling frequency f_s must be at least twice the highest frequency component of the analog signal (f_s >= 2 f_max) to prevent aliasing.
- Signal components above the Nyquist frequency (f_s / 2) fold back into the baseband spectrum as false low-frequency aliases given by f_alias = |f_in - k f_s|, requiring analog anti-aliasing low-pass filters prior to digitization.
- An n-bit Analog-to-Digital Converter (ADC) divides the full-scale voltage range (V_FSR) into 2^n quantization levels, yielding a minimum resolution step size of LSB = V_FSR / 2^n and a maximum ideal quantization error of ± LSB / 2.
- Theoretical Signal-to-Quantization-Noise Ratio (SQNR) increases by approximately 6.02 dB per bit of ADC resolution (SQNR = 6.02 n + 1.76 dB).
- Experimental measurement uncertainty combines systematic bias (reproducible calibration offsets) and random noise (statistical standard deviation of the mean) using Root-Sum-Square (RSS) error propagation.
4.2 Data Sampling, Accuracy/Precision, and A/D Conversion
Core Concept: Data acquisition (DAQ) bridges the physical analog domain and the digital processing domain. To capture dynamic physical signals without distortion, engineers must master the Nyquist-Shannon sampling theorem, anti-aliasing filtering, analog-to-digital converter (ADC) quantization limits, and statistical uncertainty analysis.
Nyquist-Shannon Sampling Theorem & Aliasing
When a continuous analog signal $x(t)$ is sampled at discrete time intervals $T_s = 1/f_s$, the continuous frequency spectrum is periodicized at intervals of $f_s$.
The Nyquist Criterion
To ensure complete, unambiguous reconstruction of a continuous signal from its discrete samples, the sampling frequency $f_s$ must be at least twice the maximum frequency component ($f_{max}$) present in the signal:
- Nyquist Frequency ($f_N$): The upper frequency boundary of the un-aliased baseband, defined as half the sampling rate:
Continuous Analog Spectrum Sampled Spectrum at f_s
| | | |
---|----------------------|--- ---|-------------------|---
-f_max +f_max -f_s/2 0 +f_s/2 (Nyquist limit)
Aliasing Mathematics
If the analog signal contains high-frequency components exceeding the Nyquist limit ($f_{in} > f_s / 2$), those components fold back into the baseband spectrum $[0, f_s/2]$ and appear artificially as low-frequency signals known as aliases.
The apparent frequency ($f_{alias}$) of an aliased component is calculated by:
where $k$ is an integer chosen such that $0 \le f_{alias} \le \frac{f_s}{2}$.
Anti-Aliasing Low-Pass Filters
Because real-world sensor signals contain high-frequency noise and harmonics, an analog anti-aliasing low-pass filter must be placed before the sample-and-hold circuit and ADC. The filter corner frequency $f_c$ is selected near $f_{max}$, sharply attenuating all spectral components above $f_s/2$.
Analog-to-Digital Converter (ADC) Performance Metrics
An Analog-to-Digital Converter (ADC) converts a continuous voltage $V_{in}$ within a Full-Scale Voltage Range ($V_{FSR} = V_{max} - V_{min}$) into an $n$-bit digital code.
Key Quantization Equations
-
Number of Discrete Levels ($N$):
-
Quantization Step Size / Least Significant Bit (LSB / $\Delta V$):
-
Maximum Ideal Quantization Error ($e_q$):
-
Signal-to-Quantization-Noise Ratio (SQNR): Assuming a full-scale sinusoidal input, theoretical SQNR in decibels is: Key Takeaway: Each additional bit of ADC resolution improves the signal-to-noise ratio by approximately $6.02\,\text{dB}$ (a factor of $2$ in voltage resolution).
-
Digital Output Code Computation ($D$): For a unipolar ADC ($0$ to $V_{FSR}$):
Common ADC Architecture Types
| ADC Type | Conversion Speed | Resolution ($n$) | Dominant Characteristics & Use Case |
|---|---|---|---|
| Flash (Parallel) | Ultra-Fast ($> 1\,\text{GSPS}$) | Low ($6\text{--}8$ bits) | Uses $2^n - 1$ parallel comparators. High power and cost. Oscilloscopes, radar. |
| Successive Approximation (SAR) | Fast ($100\,\text{kSPS} \text{ to } 10\,\text{MSPS}$) | Medium ($10\text{--}18$ bits) | Binary search algorithm using DAC and comparator. Standard choice for microcontroller DAQ systems. |
| Sigma-Delta ($\Sigma\Delta$) | Slow to Moderate ($< 1\,\text{MSPS}$) | High ($16\text{--}24+$ bits) | Over-sampling, noise shaping, digital filtering. Precision weigh scales, audio, RTD instrumentation. |
| Dual-Slope (Integrating) | Slow ($10\text{--}100\,\text{Hz}$) | Very High ($16\text{--}20$ bits) | Integrates input voltage against reference. High noise rejection (50/60 Hz line rejection). Digital multimeters. |
Accuracy, Precision, and Statistical Error Propagation
Accuracy vs. Precision
- Accuracy: The degree of closeness between a measured value and the true, accepted reference value. Inaccuracy is caused by systematic errors (bias) such as calibration shifts, zero offsets, or uncompensated thermal drift.
- Precision: The repeatability or mutual agreement among independent measurements taken under identical conditions. Imprecision is driven by random errors (noise) such as thermal Johnson noise or electromagnetic interference.
High Accuracy, High Precision Low Accuracy, High Precision (Bias)
+-----------+ +-----------+
| ( (O) ) | | (O) |
| (OO) | | (OO) |
+-----------+ +-----------+
Statistical Measures of Random Errors
For $N$ repeated measurements of a variable $x$:
-
Sample Mean ($\bar{x}$):
-
Sample Standard Deviation ($s$):
-
Standard Uncertainty of the Mean ($u_{\bar{x}}$):
Error Propagation (Root-Sum-Square Law)
When a derived engineering parameter $R$ is calculated from independent measured variables $x_1, x_2, \dots, x_k$ according to a functional relationship $R = f(x_1, x_2, \dots, x_k)$, the combined standard uncertainty $u_R$ is evaluated using partial derivative sensitivity coefficients:
Digital-to-Analog Converters (DAC) & Signal Reconstruction
DAC Functionality & Architectures
A Digital-to-Analog Converter (DAC) performs the inverse operation of an ADC, mapping an $n$-bit digital binary word into a proportional continuous analog output voltage:
- Binary Weighted Resistor DAC: Uses parallel resistors scaled as $R, 2R, 4R, 8R, \dots, 2^{n-1}R$ connected to an inverting summing amplifier. Simple concept, but requires impractically wide resistor precision ratios for high resolution.
- R-2R Ladder Network DAC: Uses only two resistor values ($R$ and $2R$) arranged in a repeating ladder topology. Easily fabricated in integrated circuits and widely used in precision motion control and audio playback.
Signal Reconstruction & Zero-Order Hold (ZOH)
The raw output of a DAC forms a discrete staircase waveform (Zero-Order Hold). An analog smoothing low-pass reconstruction filter is applied at the DAC output to eliminate high-frequency staircase steps and restore a smooth continuous waveform.
Worked Engineering Examples: Sampling & ADC Analysis
Problem 1: ADC Resolution, Quantization Error, and Code Calculation
Scenario: A 12-bit data acquisition system operates over a full-scale voltage range of $0.00\,\text{V}$ to $10.00\,\text{V}$ ($V_{FSR} = 10.00\,\text{V}$).
- Calculate the LSB voltage step size ($\Delta V$) and the maximum ideal quantization error $e_q$.
- Calculate the theoretical Signal-to-Quantization-Noise Ratio (SQNR) in decibels.
- Determine the output digital decimal code $D$ and quantized voltage for an analog input of $V_{in} = 6.345\,\text{V}$.
Solution:
-
Calculate LSB Step Size and Quantization Error:
-
Calculate SQNR:
-
Determine Digital Code and Quantized Voltage:
Problem 2: Nyquist Frequency and Aliasing Calculation
Scenario: An industrial machine vibration sensor produces a complex signal with frequency components at $f_1 = 80\,\text{Hz}$, $f_2 = 180\,\text{Hz}$, and $f_3 = 380\,\text{Hz}$. The signal is sampled at $f_s = 500\,\text{Hz}$ without an anti-aliasing filter.
- Calculate the Nyquist frequency $f_N$.
- Identify which frequency components alias.
- Determine the apparent alias frequency recorded in the digital dataset for any aliased component.
Solution:
-
Calculate Nyquist Limit:
-
Evaluate Components for Aliasing:
- $f_1 = 80\,\text{Hz} \le 250\,\text{Hz} \implies \text{Sampled accurately without aliasing.}$
- $f_2 = 180\,\text{Hz} \le 250\,\text{Hz} \implies \text{Sampled accurately without aliasing.}$
- $f_3 = 380\,\text{Hz} > 250\,\text{Hz} \implies \mathbf{Will\ alias!}$
- Calculate Apparent Alias Frequency:
Engineering Insight: The $380\,\text{Hz}$ vibration harmonic folds back into the spectrum and appears erroneously as a $120\,\text{Hz}$ signal, potentially leading to false diagnostic conclusions unless an anti-aliasing filter cutting off near $200\text{--}250\,\text{Hz}$ is installed.
A 10-bit Analog-to-Digital Converter (ADC) operates over a full-scale input range of 0.0 V to 5.0 V. What is the voltage step size (Least Significant Bit resolution) of this converter?
An acoustic transducer records sound wave frequencies up to a maximum component of 18.5 kHz. According to the Nyquist-Shannon sampling theorem, what is the absolute minimum sampling frequency required to sample the signal without aliasing?
A sinusoidal pressure signal at a frequency of 750 Hz is sampled by a data acquisition board at a sampling rate of 1000 Hz without an anti-aliasing filter. What is the apparent frequency of the aliased signal recorded in the data file?
What is the theoretical Signal-to-Quantization-Noise Ratio (SQNR) of an ideal 14-bit Analog-to-Digital Converter?