EE513 Audio Signals and Systems - University of...
Transcript of EE513 Audio Signals and Systems - University of...
EE513Audio Signals and Systems
NoiseKevin D. DonohueKevin D. Donohue
Electrical and Computer EngineeringUniversity of KentuckyUniversity of Kentucky
Quantization NoiseSignal amplitudes take on a continuum of values A discrete signal must be digitizedvalues. A discrete signal must be digitized (mapped to a finite set of values) to be stored and processed on a computer/DSPp p
Digital SignalDiscrete-time SignalAnalog Signal )(ˆ nxSignal
QuantizerAnalog Signal
Coder
11
)(nTxa )(ˆ nTx
)(nx
11 10 01 00
Quantization Error and Noise)(txa )(nTxa )(ˆ nTxAnalog Discrete Digital
11 10 01 00
Analog Discrete Digital
Quantization has the same effects as adding noise to the signal:
)(ˆ)()( nTxnTxnT aq )(ˆ)()( nTxnTnTx qa Intervals between quantization levels are proportional to the resulting quantization noise since they limit the maximum rounding orresulting quantization noise since they limit the maximum rounding or truncation error.
For uniform quantization, the interval between signal levels is the maximum signal amplitude value divided by the number of quantization intervals.
Quantization NoiseOriginal CD clip quantized at 16 bits (blue) Quantized at 6 bits (red)Quantized at 6 bits (red)Quantized at 3 bits (black)
PSD f Q ti d Si l S T ll M M
0
20PSDs of Quantized Signal; Song -Tell Me Ma
3 bit
-40
-20
dB 6 bit
80
-60
40
16 bit
101 102 103 104 105-80
Hertz
Quantization Noise AnalysisAssume is a uniformly distributed (amplitude), white stationary process that is uncorrelated with the
)(nqwhite, stationary process that is uncorrelated with the signal.
• Show that the signal to quantization noise ratio (SNRq) for a full-swing range (FSR) sinusoid, quantized with Bbit words is approximately:bit words is approximately:
dB 8.16SNR q B
Room NoiseNoise generated from a source inside a room will undergo frequency dependent propagation, absorption and refection before reaching the sink. Thus, the room effectively filters the sound.Sound impinging on surfaces in the room will be absorbed, reflected, or diffused.
Absorption Reflection DiffusionAbsorption Reflection Diffusion
HeatTransmission
DirectSound
DirectSoundSpecular
R fl t d
DirectSound
DiffuseScattered
SoundReflectedSound
Reflection Absorption EffectsReflected and reverberant sounds become particularly bad distractions because they are highly correlated with the original sound source. The use of absorbers and diffusers on reflective surfaces can cut down the reverberation effects in rooms.The model for a signal received at a point in space from many reflections is given as:
N
nnn dtstr
1 0
))(()()(
where n(t) denotes the attenuation of each reflected signal due to propagation through the air and absorption at each reflected i t f d i th ti d l i t d ith th t l th finterface and n is the time delay associated with the travel path from the source to the receiver. The signal in the frequency domain is given by:
N
n
nn fjffSfR1
)2exp()()()(
Reverberant Sound TravelEF1
RF1
LS
EF2
RF2D
EF3
EF4 RF3
The near or direct field (D)The near or direct field (D)The free or early field (EF1 and EF2)The reverberant or diffuse field (RF1 to RF3)
Decay of Reverberant Sound Field
Direct Sound
Leve
lSo
und
L
Reverberation60 dB
TimeInitial Time Delay Gap Reverberation Time
The time it takes for the reverberant sound field to decayby 60dB has become a standard way to characterizeby 60dB has become a standard way to characterize reverberation in room acoustics.
Room Reverberation TimeFor a space with many randomly distributed reflectors (typically large rooms) reverberation time (RT60 ) is defined as the amount of time for the sound pressure in a
t d b 60 dB f it i Th tiroom to decrease by 60 dB from its maximum. The time is statistically predicted from the room features with the Sabine equation:
VffS
VfRT N)(4)(
161.)(60
where V is the volume of the room in cubic meters
VfmfaSi
ii )(4)(1
V is the volume of the room in cubic meters Si is the surface area of the ith surface in room (in square meters) ai is the absorption coefficient of ith surface m is the absorption coefficient of air.
Discuss: The relationship between absorption, volume, and RT.
Room Response to White Noise Input
Data collected and spectrogram computed by H L FournierData collected and spectrogram computed by H.L. FournierNote frequency dependence on of decay time.
Examplei h i l d b i l h i d hGiven the simulated reverb signal compute the RT60. Find the
autocorrelation function and try to estimate the delays associated with the major scatterers.
% Create reverb signal
[y,fs] = wavread('clap.wav'); % Read in Clap sound
% Apply simulated reverb signal
yout1 = mrevera(y fs [30 44 121]*1e-3 [ 6 8 6]);
% Compute autocorrelation function of envelop and look for peaks % to indicate delay of major echoes
maxlag = fix(fs*.5);
[ac, lags] = xcorr(env-mean(env), maxlag);yout1 = mrevera(y,fs,[30 44 121] 1e-3,[.6 .8 .6]);
taxis = [0:length(yout1)-1]/fs;
% Compute envelope of signal
env = abs(hilbert(yout1));
figure(2)
plot(lags/fs,ac)
xlabel('seconds')
l b l('AC ffi i t')figure(1)
plot(taxis,20*log10(env+eps)) % Plot Power over time
hold on
% Create Line at 60 dB below max point and look for
ylabel('AC coefficient')
% Compute autocorrelation function of raw and look for peaks to
% indicate delay of major echoes
[ac, lags] = xcorr(yout1, maxlag);% C eate e at 60 d be ow a po t a d oo ointersection point
mp = max(20*log10(env+eps));
mp = mp(1);
dt = mp-60;
figure(3)
plot(lags/fs,ac)
xlabel('seconds')
ylabel('AC coefficient')dt mp 60;
plot(taxis,dt*ones(size(taxis)),'r'); hold off; xlabel('Seconds')
ylabel('dB'); title('Envelope of Room Impulse Response')
ylabel( AC coefficient )
Room ModesThe air in a (small) rectangular room has natural modes of vibration given by:
222
2
Hr
Wq
Lpcf
where c is the speed of sound in the room p, h, and r are
2 HWLf
p pintegers 0,1,2, …., and L, W, and H are the length, width, and height of the room.
Amplifiers and DistortionEfficiency – Output power over Input power (including that of the power supply). Distortion – Total harmonic distortion (THD). For a sinusoidal signal input, THD is the ratio of power at all harmonic frequencies Pi (excluding the fundamental P1) to the power at the fundamental ffrequency.
12
PPP
P
PTHD Ti
i
where PT is total signal power
l f f h i d b
11 PP
Fidelity – Flatness of frequency response characterized by frequency range and transfer function variation in that range.
Example Given the transfer characteristic for a class B amplifier below, compute the THD for a 3 volt input sinusoid.
Vout7v
Vin-0.6v
-3v in
0.6v3v
-7v
Amplifier ClassesClass A - Low distortion, bad efficiency. Output stage with single transistor requires DC biased output (10-20% efficiency)efficiency).
Class B - Crossover distortion, good efficiency. Output stage has 2 transistors so bias current is zero (~80%stage has 2 transistors so bias current is zero (~80% efficient).
Class AB Reduced crossover distortion goodClass AB – Reduced crossover distortion, good efficiency. Output stage has 2 transistors with biasing to push signal out of crossover distortion range.
Class D – Moderate distortion, high efficiency, operates in switch mode. Good for battery driven applications.
Center Clip Distortion3
1
2
3
tude
OriginalDistorted
-2
-1
0am
plit
0 0.005 0.01 0.015 0.02 0.025 0.03 0.035 0.04-3
seconds
Harmonic Peak Heights = [-8, -23, -29, -37, -47, -55, -47, -46, -49, -57];
-40
-20
0
OriginalDistorted
f 200
10/8
10/5710/3710/2910/23
1010101010
THD
-80
-60
dB fo = 200 HzTHD = 4.13%
0 500 1000 1500 2000 2500 3000 3500 4000-100
Hz
Example Given the transfer characteristic for a class AB amplifier below, compute the THD for a 3 volt input sinusoid.
Vout7v
V-3v
-1.75v Vin
3v1.75v
1.75v
-7v
Clip/Overload Distortion
1
2
3
ude
OriginalDistorted
-2
-1
0
ampl
itu
0 0.005 0.01 0.015 0.02 0.025 0.03 0.035 0.04-3
seconds
Harmonic Peak Heights = [-7, -21, -46, -37, -44, -49, -45, -72, -49, -55];
-40
-20
0 OriginalDistorted
f = 200 Hz
10/7
10/5510/3710/4610/21
1010101010
THD
-80
-60
dB
fo 200 HzTHD = 4.14%
0 500 1000 1500 2000 2500 3000 3500 4000-100
Hz