Effacer les filtres
Effacer les filtres

Info

Cette question est clôturée. Rouvrir pour modifier ou répondre.

Unable to perform assignment because the size of the left side is 5000-by-51 and the size of the right side is 5000-by-50.

1 vue (au cours des 30 derniers jours)
clear
P_per_cell = 20; %in watts
PRB = 50;
P_per_PRB =10*log10(P_per_cell/PRB); %in dB
ISD = 1; %km
No_of_users = 10;
Cell_radius = 1/sqrt(3);
d0 = Cell_radius/No_of_users; % distance of user 0 from cell center
%d = zeros(1, 10);
d = [d0 0 0 0 0 0 0 0 0 0];
for x = 1:9
d(x+1) = d(x)+d0;
end
T = 290;
k = physconst('Boltzmann');
B = 180*10^3;
N = k*T*B; % Noise %%%%%%%%%%%% confirm value of B
Path_gain = -115+35*log10(d(1)); % in dB
%Fading_traces = xlsread('Multipath fading traces.xlsx',2); % for user 0
for i=1:10
sheet = strcat('User-' , num2str(i-1));
Fading_traces(:,:,i) = xlsread('Multipath fading traces.xlsx', sheet);
end
cell_cnt=1;
for i=1:3
for j= 1:(i*6)
path_loss_cell_wise(1,cell_cnt) = (-(115 + 35*(log10(i)))); %Path loss for 36 remaining cells in a row vector
cell_cnt=cell_cnt+1;
end
end
for k=1:10 % for 10 users
% Interference Calculation
user = Fading_traces(:,:,k); % k replaced by 1 for user0 ie the first user
for cell_i=1:36
cnt=1;
for j=(135*cell_i)+1:size(user,1)
intf(cnt,:,cell_i) = P_per_PRB+path_loss_cell_wise(1,cell_i)+user(j,:); % interference 3d matrix acc to formula
cnt=cnt+1; % based on ith cell and user.
end
for j=1:135*cell_i
intf(cnt,:,cell_i) = P_per_PRB+path_loss_cell_wise(1,cell_i)+user(j,:); % interference 3d matrix acc to formula
cnt=cnt+1; % based on ith cell and user.
end
end
path_loss_user_wise = (-(115 + 35*(log10(0.05774*k)))); % replaced k by 1 for user0
for i=1:size(user,1) %5000
for j=1:size(user,2) %50
rxed_pow(i,j) = P_per_PRB + path_loss_user_wise+user(i,j); % tx power+pathloss user wise + multipath
sinr(i,j) = (10^(rxed_pow(i,j)/10))/(10^((sum(intf(i,j,:))/10))+N);
BitRate(i,j) = B*log2(1+sinr(i,j));
end
end
%Average bit rate per TTI
for i=1:size(BitRate,1)
BitRateperTTI(i,1) = sum(BitRate(i,:));
end
%Average bit rate over 5000 TTI
AggregateBitRate(k,1) = (sum(BitRateperTTI)/5000)/10e5;
end

Réponses (0)

Cette question est clôturée.

Produits


Version

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by