Please post any discussion relating to the project here

Comments about the whitening filter.

Folks, the whitening filter turns out to be an IIR filter which is anticausal. This cannot be implemented with a finite delay. However, this can be implemented by filtering the sequence backwards in time. Here is a small MATLAB code that i wrote to show you how to do this.

% This is a program to see how to implement a whitening filter that is

% anticausal and stable

% define h and compute x

h = [1 0.9 0.8];

L = length(h)-1;

x = xcorr(h);

f = h; % This should be the equivalent channel including the whitening filter

% generate data

N = 1000;

I = [sign(rand(1,N)-0.5)]; % this is a random data sequence

% This is the filtering with x

y = conv(x,I);

% filter with the whitening filter

% Notice that the filter coefficient is f since implementing the filter

% with reverse time makes the equivalent filter like this. Think about this

% it is good to actually write this out on a piece of paper and see the equations

% in the time domain. Then try to compute v[n] from v[n+1], v[n+2] and y[n]

% Then you will see what is going on. dont try to compute v[n+2] from v[n+1], v[n]

% and y[n]. This is an unstable operation.

yflip = fliplr(y);

vflip = filter([1],f,yflip);

vtemp = fliplr(vflip);

v = vtemp(L+1:length(vtemp));

%-—Now we check to see if v is the same as filtering I with f

% The difference between u and v should be very small (ideally they

should be the same).

u = conv(f,I);

error = (u-v)*(u-v)'

[Comment:] It looks like this does not work when h is complex. Trying the channel coefficient we use in this project.

[Comment] Yes ,I also checked it,it is not working!

[Comment:] I believe that the whitening filter coefficients should be conj(f) rather than f.

_Question_ Could you please specify what the variable names would be in the audio_sample.dat and noisevariance.dat files, meaning how to use it in our program, can I just say load noisevariance.dat, variable_name = noise_variance?

[Comment, grader] Removed. Please follow the updated instructions at http://ecen661tamu.wikidot.com/midterm2.