200 likes | 436 Views
ELEN E4810: Digital Signal Processing Topic 11: Continuous Signals. Sampling and Reconstruction Quantization. WORLD. 1. Sampling & Reconstruction. DSP must interact with an analog world:. A to D. D to A. x ( t ). x [ n ]. y [ n ]. y ( t ). DSP. ADC. DAC. Anti- alias filter.
E N D
ELEN E4810: Digital Signal ProcessingTopic 11: Continuous Signals • Sampling and Reconstruction • Quantization Dan Ellis
WORLD 1. Sampling & Reconstruction • DSP must interact with an analog world: A to D D to A x(t) x[n] y[n] y(t) DSP ADC DAC Anti- alias filter Sample and hold Reconstruction filter Sensor Actuator Dan Ellis
Sampling: Frequency Domain • Sampling: CT signalDT signal by recording values at ‘sampling instants’: • What is the relationship of the spectra? • i.e. relateand Discrete Continuous Sampling period T samp.freq. WT = 2p/T rad/sec W in rad/second CTFT DTFT w in rad/sample Dan Ellis
t Sampling • DT signals have same ‘content’ as CT signals gated by an impulse train: • gp(t) = ga(t)·p(t) is a CT signal with the same information as DT sequence g[n] gp(t) ga(t) t t ‘sampled’ signal:still continuous - but discrete values CT delta fn p(t) T 3T Dan Ellis
Spectra of sampled signals • Given CT • Spectrum • Compare to DTFT • i.e. by linearity W p/T= WT/2 w p Dan Ellis
Spectra of sampled signals • Also, note thatis periodic, thus has Fourier Series: • But so shift in frequency - scaled sum of shifted replicas of Ga(jW)by multiples of sampling frequency WT Dan Ellis
CT and DT Spectra So: or DTFT CTFT ga(t) is bandlimited @ WM M W -WM WM W -2WT -WT WT 2WT = shifted/scaled copies M/T W w -4p -2p 2p 4p Dan Ellis
Aliasing • Sampled analog signal has spectrum: • ga(t) is bandlimited to ± WM rad/sec • When sampling frequency WT is large... no overlap between aliases can recover ga(t) from gp(t) by low-pass filtering Ga(jW) “alias” of “baseband” signal Gp(jW) W -WM WT -WT WM WT -WM -WT +WM Dan Ellis
The Nyquist Limit • If bandlimit WM is too large, or sampling rate WT is too small, aliases will overlap: • Spectral effect cannot be filtered outcannot recoverga(t) • Avoid by: • i.e. bandlimit ga(t) at ≤ Gp(jW) W WM WT -WT -WM WT -WM Sampling theorum Nyquistfrequency Dan Ellis
Anti-Alias Filter • To understand speech, need ~ 3.4 kHz 8 kHz sampling rate (i.e. up to 4 kHz) • Limit of hearing ~20 kHz 44.1 kHz sampling rate for CDs • Must remove energy above Nyquist with LPF before sampling: “Anti-alias” filter ‘space’ forfilter rolloff A to D ADC Anti-alias filter Sample & hold M Dan Ellis
Sampling Bandpass Signals • Signal is not always in ‘baseband’ around W = 0 ... may be some higher W: • If aliases from sampling don’t overlap, no aliasing distortion, can still recover • Basic limit: WT/2 ≥bandwidth DW M W WL WH -WH -WL Bandwidth DW = WH - WL M/T W 2WT -WT WT/2 WT Dan Ellis
Reconstruction • make a continuous impulse train gp(t) • lowpass filter to extract basebandga(t) Ga(ejw) • To turn g[n]back to ga(t): • Ideal reconstruction filter is brickwall • i.e. sinc - not realizable (especially analog!) • use something with finite transition band... g[n] n ^ w p ^ Gp(jW) ^ gp(t) ^ t W WT/2 ^ Ga(jW) ^ ga(t) ^ t W Dan Ellis
2. Quantization • Course so far has been about discrete-time i.e. quantization of time • Computer representation of signals also quantizes level (e.g. 16 bit integer word) • Level quantization introduces an error between ideal & actual signal noise • Resolution (# bits) affects data size quantization critical for compression • smallest data coarsest quantization Dan Ellis
Quantization • Quantization is performed in A-to-D: • Quantization has simple transfer curve: Quantized signal Quantization error Dan Ellis
+ Quantization noise • Can usually model quantization as additive white noise: i.e. uncorrelated with self or signal x ^ x[n] x[n] - e[n] bits ‘cut off’ by quantization; hard amplitude limit Dan Ellis
Quantization SNR • Common measure of noise is Signal-to-Noise ratio (SNR) in dB: • When |x| >> 1 LSB, quantization noise has ~ uniform distribution: signal power noise power (quantizer step = e) Dan Ellis
Quantization SNR • Now, sx2 is limited by dynamic range of converter (to avoid clipping) • e.g. b+1 bit resolution (including sign)output levels vary -2b·e .. (2b-1)e where full-scale range depends on signal i.e. ~ 6 dB SNR per bit Dan Ellis
Coefficient Quantization • Quantization affects not just signalbut filter constants too • .. depending on implementation • .. may have different resolution • Some coefficients are very sensitive to small changes • e.g. poles near unit circle high-Q pole becomes unstable Dan Ellis