FIRFilterOrder - % Finding FIR Filter Order clear all %...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
%% Finding FIR Filter Order clear all % STEP 1 : inputs and outputs. Nt = 400; cclass = 0; for epoch = 1:30 u=normrnd(0,2,1,Nt); % A white gaussian input sequence u with length %Nt 0 mean and standard deviation 2 ut=normrnd(0,2,1,200); %input for testing. e=normrnd(0,.2,1,Nt); % A white gaussian with zero mean and standart de %viation .2 with length Nt. it is error term b = [1 .8 .3 .4 .3 .5 -.35 .2] ; N=200; r=14; %STEP 1 : Obtain inputs and Outputs. [h,tt] = impz(b,[1]); %filter impulse response %v = sinc(u).*u.^2; % not needed now. may be needed later for hammerstein. y = conv(h,u); % the output is obtained % figure(2) ; plot(y(1:Nt)); title('y for little code') % it is fine here for m = 0:7 N = 200; sg = 1; % N: # of training data K = zeros(N-r+1,N-r+1);Ker = zeros(N-r+1,200); x = zeros(m+1,Nt); xr = zeros(m+1,Nt); %regression vectors. %STEP 2 : regression vectors for t = 1:Nt if (t>=r) % BE CAREFUL ABOUT THIS "r" VALUE. it is may be the source of all results. x(:,t) = [(u(t:-1:t-m)) ]'; %
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 07/04/2011 for the course ECE 501 taught by Professor Deniz during the Spring '11 term at Istanbul Universitesi.

Page1 / 2

FIRFilterOrder - % Finding FIR Filter Order clear all %...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online