function ray_chann=rayleighnew(nsamp,tstp,fd,counter)
%****************** variables *************************
% idata : input Ich data
% qdata : input Qch data
% iout : output Ich data
% qout : output Qch data
% ramp : Amplitude contaminated by fading
% rcos : Cosine value contaminated by fading
% rsin : Cosine value contaminated by fading
% nsamp : Number of samples to be simulated
% tstp : Minimum time resolution
% fd : maximum doppler frequency
% no : number of waves in order to generate fading
% counter : fading counter
% flat : flat fading or not
% (1->flat (only amplitude is fluctuated),0->nomal(phase and amplitude are fluctutated)
%******************************************************
no=25;
if fd ~= 0.0
ac0 = sqrt(1.0 ./ (2.0.*(no + 1))); % power normalized constant(ich)
as0 = sqrt(1.0 ./ (2.0.*no)); % power normalized constant(qch)
%ic0 = counter; % fading counter
pai = 3.14159265;
wm = 2.0.*pai.*fd;
n = 4.*no + 2;
ts = tstp;
wmts = wm.*ts;
paino = pai./no;
xc=zeros(1,nsamp);
xs=zeros(1,nsamp);
ic=[1:nsamp]+counter;
for nn = 1: no
cwn = cos( cos(2.0.*pai.*nn./n).*ic.*wmts );
xc = xc + cos(paino.*nn).*cwn;
xs = xs + sin(paino.*nn).*cwn;
end
cwmt = sqrt(2.0).*cos(ic.*wmts);
xc = (2.0.*xc + cwmt).*ac0;
xs = 2.0.*xs.*as0;
%ramp=sqrt(xc.^2+xs.^2);
%rcos=xc./ramp;
%rsin=xs./ramp;
ray_chann=xc+j*xs;
else
ray_chann=ones(1,nsamp);
end
% ************************end of file***********************************
有谁看到过这个程序呢
我知道是用Jakes模型写的
但是好象与公式原理不太一样
如 cwn = cos( cos(2.0.*pai.*nn./n).*ic.*wmts );
这个ic指什么
有谁能说下吗?
我要赚赏金打赏帖 |
|
|---|---|
| OK1126B-S开发板下以导航按键控制云台/机械臂姿态调整被打赏¥29元 | |
| 【树莓派5】便携热成像仪被打赏¥36元 | |
| 【树莓派5】环境监测仪被打赏¥35元 | |
| OK1126B-S开发板下多时段语音提示型电子时钟被打赏¥27元 | |
| OK1126B-S开发板下函数构建及步进电机驱动控制被打赏¥25元 | |
| 【S32K3XX】LPI2C 参数配置说明被打赏¥20元 | |
| OK1126B-S开发板的脚本编程及应用设计被打赏¥27元 | |
| 5v升压8.4v两节锂电池充电芯片,针对同步和异步的IC测试被打赏¥35元 | |
| 【S32K3XX】S32DS LPI2C 配置失败问题解决被打赏¥22元 | |
| 【S32K3XX】FLASH 的 DID 保护机制被打赏¥19元 | |
我要赚赏金
