图像匹配滤波器 matlab,[转载]匹配滤波器的仿真验证(MATLAB)

匹配滤波器的仿真验证

一. 实验目的:利用matlab验证匹配滤波器的特性

二. 实验要求:设二进制数字基带信号s(t)=∑an

g(t-nTs),加性高斯白噪声的功率谱密度为0。

其中an∈{+1,-1},g(t)= 1

0

0 其他

(1)若接收滤波器的冲激响应函数h(t)=g(t),画出经过滤波器后的输出波形图;

(2)若H(f)= 1

︱f︱<5/(2Ts)

0 其他

画出经过滤波器后的输出波形图.

三. 实验源码

clear all;

close all;

N=100;

N_sample=8;

Ts=1;

dt=Ts/N_sample;

t=0:dt:(N*N_sample-1)*dt;

gt=ones(1,N_sample);

d=sign(randn(1,N));

a=sigexpand(d,N_sample);

st=conv(a,gt);

ht1=gt;

rt1=conv(st,ht1);

ht2=5*sinc(5*(t-5)/Ts);

rt2=conv(st,ht2);

figure(1)

subplot(321)

plot(t,st(1:length(t)));

axis([0 20 -1.5 1.5]);ylabel('输入双极性NRZ数字基带波形

');

subplot(322)

stem(t,a);

axis([0 20 -1.5 1.5]);ylabel('输入数字序列');

subplot(323)

plot(t,[0 rt1(1:length(t)-1)]/8);

axis([0 20 -1.5 1.5]);ylabel('方波滤波后输出');

subplot(324)

dd=rt1(N_sample:N_sample:end);

ddd=sigexpand(dd,N_sample);

stem(t,ddd(1:length(t))/8);

axis([0 20 -1.5 1.5 ]);ylabel('方波滤波后抽样输出');

subplot(325)

plot(t-5,[0 rt2(1:length(t)-1)]/8);

axis([0 20 -1.5 1.5 ]);

xlabel('t/Ts');ylabel('理想低通滤波器输出');

subplot(326)

dd=rt2(N_sample-1:N_sample:end);

ddd=sigexpand(dd,N_sample);

stem(t-5,ddd(1:length(t))/8);

axis([0 20 -1.5 1.5 ]);

xlabel('t/Ts');ylabel('理想低通滤波器抽样输出 ');

function[out]=sigexpand(d,M);

N=length(d);

out=zeros(M,N);

out(1,:)=d;

out=reshape(out,1,M*N);

四. 实验结果及分析

第一问中的接收滤波器为匹配滤波器,第二问中的接收滤波器为非匹配滤波器,该实验的目的是比较两种滤波器的输出波形与发送波形的误码情况。

  • 0
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值