필터 지우기
필터 지우기

i am referring to a book titled " MIMO - OFDM wireless comm with matlab". In this i understood the mathematics but unable to understand the code for rayleigh and rician fading channels. Pls if some one can share his views on this will be very helpful

조회 수: 1 (최근 30일)
% plot_Ray_Ric_channel.m
clear, clf
N=200000; level=30; K_dB=[-40 15];
gss=[k-s; b-o; r-^];
% Rayleigh model
Rayleigh_ch=Ray_model(N);
[temp,x]=hist(abs(Rayleigh_ch(1,:)),level);
plot(x,temp,gss(1,:)), hold on
% Rician model
for i=1:length(K_dB);
Rician_ch(i,:) = Ric_model(K_dB(i),N);
[temp x] = hist(abs(Rician_ch(i,:)),level);
plot(x,temp,gss(i+1,:))
end
xlabel(x), ylabel(Occurrence)
legend(Rayleigh,Rician, K=-40dB,Rician, K=15dB)
%%%% functions 1
function H=Ray_model(L)
% Rayleigh channel model
% Input : L = Number of channel realizations
% Output: H = Channel vector
H = (randn(1,L)+j*randn(1,L))/sqrt(2);
%%%% functions 2
function H=Ric_model(K_dB,L)
% Rician channel model
% Input : K_dB = K factor[dB]
% Output: H = Channel vector
K = 10^(K_dB/10);
H = sqrt(K/(K+1)) + sqrt(1/(K+1))*Ray_model(L); %%%%% didnt understand this line.
  댓글 수: 2
dpb
dpb 2019년 6월 22일
What specifically didn't you understand?
The second model is just a constant plus a scaled magnitude of the first. This should be related to the mathematics in the reference, but I haven't tried to find it..

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 WLAN Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by