I created a MATLAB script which runs through 10000 tests. In each test a random signal is created and IIR filtered. The IIR numerator is 1 and the IIR denominator is: 1 -1.99240148160141 3.01948286335539 -2.81852242649452 2.03872063706253 -1.05454462109568 0.414446268750399 -0.115718625236828 0.0224985092722183 -0.0026689123535761 0.000148764452177762 I analyze the output of the IIR filter using LPC analysis of some order P which for each 10000 tests increments by 1 (from 1 to 30). For each test I sum the variance of the error signal and once the 10000 tests have completed I calculate the mean error. I had expected to see the mean error be at its minimum when the estimated model order matched the true model order, but for some reason it bottoms at model order = 7. How come? Here is the full matlab script: clc close all clear all % Unknown Linear Transfer Function [b,a] = butter(10,0.4); b = 1; eVec = []; for modelOrder = 1:30 sumVarE = 0; for n = 1:10000 filterInput = -0.05 + (0.05-(-0.05)).*rand(1,1000); filterOutput = filter(1,a,filterInput); % Estimate filter coefficients [est_a,est_e] = lpc(filterOutput,modelOrder); est_filterOutput = filter(1,est_a,filterInput); e = est_filterOutput - filterOutput; sumVarE = sumVarE + var(e); end sumVarE = sumVarE / 10000; eVec = [eVec sumVarE]; end plot(1:30,eVec,'kx--') drawnow
LPC experiment
Started by ●February 6, 2012