-
大小: 164KB文件类型: .rar金币: 2下载: 0 次发布日期: 2024-02-01
- 语言: Matlab
- 标签: Resource Allocation; OFDMA
资源简介
OFDMA功率分配经典文献 "A Low Complexity Algorithm for Proportional Resource Allocation in OFDMA Systems"的相应MATLAB代码
代码片段和文件信息
function [envIQ]= chtry(userNumsampleNumfm)
%WLAN channel modeling
%Zukang Shen
%04/15/02
%Ts=50e-9*10000*2/20; %time sample interval
Ts=1e-3;
N=200; %number of input waves
n=[0:N-1];
cita=2*pi*n/N; %input angles
for user=1:userNum
alfa1=randn(1N); %magnitudes of input waves tap 1
alfanormed(1:)=alfa1/sqrt(sum(alfa1.^2)); %normalized magnitude tap 1
alfa2=randn(1N); %magnitudes of input waves tap 2
alfanormed(2:)=alfa2/sqrt(sum(alfa2.^2)); %normalized magnitude tap 2
alfa3=randn(1N); %magnitudes of input waves tap 3
alfanormed(3:)=alfa3/sqrt(sum(alfa3.^2)); %normalized magnitude tap 3
alfa4=randn(1N); %magnitudes of input waves tap 4
alfanormed(4:)=alfa4/sqrt(sum(alfa4.^2)); %normalized magnitude tap 4
alfa5=randn(1N); %magnitudes of input waves tap 5
alfanormed(5:)=alfa5/sqrt(sum(alfa5.^2)); %normalized magnitude tap 5
alfa6=randn(1N); %magnitudes of input waves tap 6
alfanormed(6:)=alfa6/sqrt(sum(alfa6.^2)); %normalized magnitude tap 6
phaseinit1=randn(1N);
phaseinit(1:)=phaseinit1*2*pi/max(phaseinit1); %initial phases tap 1
phaseinit2=randn(1N);
phaseinit(2:)=phaseinit2*2*pi/max(phaseinit2); %initial phases tap 2
phaseinit3=randn(1N);
phaseinit(3:)=phaseinit3*2*pi/max(phaseinit3); %initial phases tap 3
phaseinit4=randn(1N);
phaseinit(4:)=phaseinit4*2*pi/max(phaseinit4); %initial phases tap 4
phaseinit5=randn(1N);
phaseinit(5:)=phaseinit5*2*pi/max(phaseinit5); %initial phases tap 5
phaseinit6=randn(1N);
phaseinit(6:)=phaseinit6*2*pi/max(phaseinit6); %initial phases tap 6
%using one-sided exponential profile
to=1*Ts;
tt=[0:5]*Ts;
g=exp(-tt/to);%relative engery for the 6 taps
for j=1:6%%multi-path
for i=0:sampleNum-1%time-variety
t=i*Ts;
is=g(j)*sum(alfanormed(j:).*cos(2*pi*fm*t*cos(cita)+phaseinit(j:)));
qs=g(j)*sum(alfanormed(j:).*sin(2*pi*fm*t*cos(cita)+phaseinit(j:)));
I(userji+1)=is;
Q(userji+1)=qs;
envs=sqrt(qs^2+is^2);
env(userji+1)=envs;
end
end
end
for i=1:sampleNum
envtmp(i)=env(11i);
end
% figure
% stem([0:sampleNum-1]*Ts 20*log10(envtmp))
% title(‘Rayleigh Fading‘)
% xlabel(‘t‘)
% ylabel(‘r(t)‘)
%
% figure
% stem([0:sampleNum-1]*Ts envtmp)
% title(‘Rayleigh Fading‘)
% xlabel(‘t‘)
% ylabel(‘r(t)‘)
clear alfa1 alfa2 alfa3 alfa4 alfa5 alfa6 alfanormed phaseinit1 phaseinit2 phaseinit3 phaseinit4 phaseinit5 phaseinit6
clear phaseinit is qs envs
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
I.A.... 188456 2015-07-04 18:05 MATLAB-code-of-OFDMA-power-allocation\A_Low_Complexity_Algorithm_for_Proportional_Resource_Allocation_in_OFDMA_Systems.pdf
文件 2548 2010-04-12 16:19 MATLAB-code-of-OFDMA-power-allocation\chtry.m
文件 2089 2009-07-28 09:43 MATLAB-code-of-OFDMA-power-allocation\rheesub.m
文件 953 2009-07-27 17:49 MATLAB-code-of-OFDMA-power-allocation\rootfinding.m
文件 2594 2010-04-16 16:03 MATLAB-code-of-OFDMA-power-allocation\shenpowerallo.asv
文件 2711 2010-04-16 16:38 MATLAB-code-of-OFDMA-power-allocation\shenpowerallo.m
文件 5363 2010-04-13 20:43 MATLAB-code-of-OFDMA-power-allocation\SIPS04main.asv
文件 5394 2010-04-16 17:17 MATLAB-code-of-OFDMA-power-allocation\SIPS04main.m
文件 2218 2009-07-29 15:32 MATLAB-code-of-OFDMA-power-allocation\Unti
文件 1585 2010-04-13 20:09 MATLAB-code-of-OFDMA-power-allocation\waterfilling.m
文件 3283 2009-07-31 17:20 MATLAB-code-of-OFDMA-power-allocation\wongpowerallo.m
文件 2823 2009-07-28 09:43 MATLAB-code-of-OFDMA-power-allocation\wongsuballo.m
目录 0 2015-07-04 18:05 MATLAB-code-of-OFDMA-power-allocation
----------- --------- ---------- ----- ----
220017 13
评论
共有 条评论