⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mn_4.m

📁 the matlab code is the MN=4 MIMO capacity
💻 M
字号:
clear all; close all;
M=[1 2 1 2 4 1];
N=[1 1 2 2 1 4];
SNR_1=linspace(0,30,31);
SNR = 10.^(SNR_1/10);
C= zeros(6,31);
for i=1:6
    if N(i)>M(i)
        C(i,:) = M(i)*log2(1+(N(i)*SNR)/M(i));
    elseif M(i)>=N(i)
        C(i,:) = N(i)*log2(1+SNR);
    end
end
figure (1);
plot(SNR_1,C(1,:),'ko-');
hold on;
plot(SNR_1,C(2,:),'rs-');
hold on;
plot(SNR_1,C(3,:),'gd-');
hold on;
plot(SNR_1,C(4,:),'bh-');
hold on;
plot(SNR_1,C(5,:),'c*-');
hold on;
plot(SNR_1,C(6,:),'mx-');
hold on;
grid on
title('Independent Rayleigh fading channel, CDI/CSI mode')
xlabel('SNR in dB')
ylabel('MIMO capacity (bits/transmission)')
axis([0 30 0 20]);
legend('(M=1, N=1)','(M=2, N=1)','(M=1, N=2)','(M=2, N=2)','(M=4, N=1)','(M=1, N=4)');

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -