使用遗传算法通过FIR滤波器最小化MSE

时间:2015-11-02 02:06:15

标签: matlab signal-processing genetic-algorithm genetic-programming geneticsharp

此代码用于生成训练序列,我该如何使用此序列 用最佳参数训练FIR和GA?

% Simulate some (useful) signal to be transmitted
a= (randn(500,1)>0) *2-1; % Random bipolar (-1,1) sequence;

% CHANNEL MODEL
W=3.5; %corresponds to high channel distortion
h= [ 0, 0.5 * (1+cos(2*pi/W*(-1:1))) ]; % create a 5 tap channel impulse response.

ah=conv(h,a);

v= sqrt(0.001)*randn(500,1); % Gaussian noise with variance 0.001;
u=ah(1:500)+v;

subplot(221) , stem(impz(h,1,10)), title('Channel input response h(n)')
subplot(222) , stem(ah(1:59)), title('Convolved (distorted) signal h*a')
subplot(223) , stem(a(1:59)), title('Original signal to be transmitted')
subplot(224) , stem(u(1:59)), title('Received signal (noise + distortion)')

0 个答案:

没有答案