官方淘宝店 易迪拓培训 旧站入口
首页 > 无线通信 > 通信技术学习讨论 > 超宽带无线电模型设计

超宽带无线电模型设计

01-04
%
% FUNCTION 8.8 : "cp0802_IEEEuwb"
%
% Generates the channel impulse response for a multipath
% channel according to the statistical model proposed by
% the IEEE 802.15.SG3a.
%
% 'fc' is the sampling frequency
% 'TMG' is the total multipath gain
%
% The function returns:
% 1) the channel impulse response 'h0'
% 2) the equivalent discrete-time impulse response 'hf'
% 3) the value of the Observation Time 'OT'
% 4) the value of the resolution time 'ts'
% 5) the value of the total multipath gain 'X'
%
% Programmed by Guerino Giancola
%
function [h0,hf,OT,ts,X] = cp0802_IEEEuwb(fc,TMG);
% ----------------------------
% Step Zero - Input parameters
% ----------------------------
OT = 300e-9;              % Observation Time [s]
ts = 2e-9;                % time resolution [s]
                          % i.e. the 'bin' duration  
LAMBDA = 0.0667*1e9;      % Cluster Arrival Rate (1/s)
lambda = 2.1e9;           % Ray Arrival Rate (1/s)
GAMMA = 24e-9;            % Cluster decay factor  
gamma = 12e-9;            % Ray decay factor  
sigma1 = 10^(3.3941/10);  % Stdev of the cluster fading
sigma2 = 10^(3.3941/10);  % Stdev of the ray fading
sigmax = 10^(3/10);       % Stdev of lognormal shadowing
% ray decay threshold
rdt = 0.001;
% rays are neglected when exp(-t/gamma)<rdt
% peak treshold [dB]
PT = 50;
% rays are considered if their amplitude is
% whithin the -PT range with respect to the peak
G = 1;
% G = 1 graphical output
% G = 0 no graphical output
% -----------------------------------
% Step One - Cluster characterization
% -----------------------------------
dt = 1 / fc;        % sampling time
T = 1 / LAMBDA;     % Average cluster inter-arrival time
                    % [s]
t = 1 / lambda;     % Average ray inter-arrival time [s]
i = 1;
CAT(i)=0;           % First Cluster Arrival Time
next = 0;    
while next < OT
    i = i + 1;
    next = next + expinv(rand,T);
    if next < OT
        CAT(i)= next;
    end
end % while remaining > 0
Error in ==> cp0802_IEEEuwb at 57
d t = 1 / fc;        % sampling time
这个错误是?

你应该从外部调用它而不是直接run,
try this :
cp0802_IEEEuwb(1000000,TMG)

楼主从哪搜来的代码啊,支离破碎的,东西都不全

Top