I use this code for Rayleigh fading channel . What is the corresponding code for Rician and Nakagmi fading Channel .
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
%----------------------Creating Rayleigh Channel--------------------------- Taps=4; % Number of Taps p1=0.5/2.3; % Power of Tap1 p2=0.9/2.3; % Power of Tap2 p3=0.7/2.3; % Power of Tap3 p4=0.2/2.3; gain1=sqrt(p1/2)*[randn(1,N) + j*randn(1,N)]; % Gain for Tap1 gain2=sqrt(p2/2)*[randn(1,N) + j*randn(1,N)]; % Gain for Tap2 gain3=sqrt(p3/2)*[randn(1,N) + j*randn(1,N)]; % Gain for Tap3 gain4=sqrt(p4/2)*[randn(1,N) + j*randn(1,N)]; % Gain for Tap4 x11=x(:); x12=reshape(x11,1,length(x11)) i=1:length(x12); delay1=1; for i=delay1+1:length(x12) % Producing one sample delay in Tap2 w.r.t. Tap1 x13(i)=x(i-delay1); end delay2=2; for i=delay2+1:length(x12) % Producing two sample delay in Tap2 w.r.t. Tap1 x14(i)=x(i-delay2); end delay3=3; for i=delay3+1:length(x12) % Producing three sample delay in Tap2 w.r.t. Tap1 x15(i)=x(i-delay3); end x1=reshape(x13,(n+3),length(x13)/(n+3)); x2=reshape(x14,(n+3),length(x14)/(n+3)); x3=reshape(x15,(n+3),length(x15)/(n+3)); ch1=repmat(gain1,(n+3),1); ch2=repmat(gain2,(n+3),1); ch3=repmat(gain3,(n+3),1); ch4=repmat(gain4,(n+3),1); data_channel=x.*ch1+x1.*ch2+x2.*ch3+x3.*ch4; % Passing data through channel
1 commentaire
Réponses (1)
DONY DARMAWAN PUTRA
le 3 Juil 2021
Nakagami
hBS = sqrt(ell_BS) .* random(makedist('Nakagami', 'mu', m_BS , 'omega', 1), N, simReps) .* exp(1i*(-pi + (pi+pi)*rand(N, simReps)));
for detail you can see https://ieeexplore.ieee.org/document/9290053/algorithms?tabFilter=code#algorithms
Rician
h=sqrt(K_AI/((1+K_AI))).*(randn(1,1)+j*randn(1,1));
g=sqrt(K_IU/((1+K_IU))).*(randn(1,1)+j*randn(1,1));
eta=h.*g;
for detail you can read https://ieeexplore.ieee.org/document/9129778
0 commentaires
Voir également
Catégories
En savoir plus sur Propagation and Channel Models dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!