资源简介
里面有cm_bpske.m gngauss.m trng_guass.m三个文件
代码片段和文件信息
function[p]=cm_bpske(snr_in_db)
% [p]=cm_bpske(snr_in_db)
% cm_bpske finds the probability of error for the given value of snr_in_db
N=5000;
E=1; %energy per symbol
snr=10^(snr_in_db/10); %signal to noise ratio
sgma=E/sqrt(snr*2); %noise variance
%generation of data source
for i=1:N
temp=rand;
if(temp<0.5)
dsource(i)=0;
else
dsource(i)=1;
end
end
%detection and the probability of errror calculation
numofbiterror=0;
for i=1:N
%received signal at the detector for the ith symbol is:
if (dsource(i)==0)
r0=E+gngauss(sgma);
r1=gngauss(sgma);
else
r1=E+gngauss(sgma);
r0=gngauss(sgma);
end
% the detector is:
if(r0>r1)
decis=0;
else
decis=1;
end
%increment the error counterif the decision is not correct
if (decis~=dsource(i))
numofbiterror=numofbiterror+1;
end
end
p=numofbiterror/N;
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 1048 2003-08-10 12:05 AWGN\cm_bpske.m
文件 711 2003-08-10 14:12 AWGN\gngauss.m
文件 735 2003-08-10 12:02 AWGN\trng_guass.m
..AD... 0 2003-08-11 12:19 AWGN
----------- --------- ---------- ----- ----
2494 4
- 上一篇:matlab控制摄像头拍照的程序
- 下一篇:pca-Matlab250774
相关资源
- matlab_OFDM调制解调(来自剑桥大学)
- Matlab路面裂缝识别69319
- 高灵敏度GPS接收机MATLAB仿真,附捕获
- 基于MATLAB的质点弹道计算与外弹道优
- 阵列天线的matlab仿真
- MATLAB 经典程序源代码大全
- MATLAB小波软阈值去噪代码33473
- 天线阵的波束形成在MATLAB仿真程序及
- 非线性SVM算法-matlab实现
- 《MATLAB 智能算法超级学习手册》-程序
- 组合导航matlab程序
- 读取txt文件内容matlab代码实现
- Matlab实现基于相关的模板匹配程序
- matlab优化工具箱讲解
- 基于MATLAB的快速傅里叶变换
- 光纤传输中的分布傅立叶算法matlab实
- 基于matlab的图像处理源程序
- matlab 椭圆拟合程序
- 算术编码解码matlab源代码
- optical_flow 光流法 matlab 实现程序
- 引导图像滤波器 Matlab实现
- 分形几何中一些经典图形的Matlab画法
- OFDM系统MATLAB仿真代码
- SVM工具箱(matlab中运行)
- 图像小波变换MatLab源代码
- LU分解的MATLAB实现
- 冈萨雷斯数字图像处理matlab版(第三
- 替代数据法的matlab程序
- 用matlab实现的多站定位系统性能仿真
- 通过不同方法进行粗糙集属性约简m
评论
共有 条评论