simulator.m

来自「线形内插在MIMO OFDM上的实现,包括格拉斯曼域的仿真」· M 代码 · 共 62 行

M
62
字号
clear all;clc;% =========================================================================SNR_vector = [0 3 6 9 12];pro_time_vector = [0.05 0.1 0.2 0.3 0.4];% Main Programme for simulation%Error_Vector_A = zeros(1,length(SNR_vector));%disp('*************Start Simulation*************');%disp('******************A***********************');%for k = 1:length(SNR_vector)%    SNR = SNR_vector(k);%    pro_time = pro_time_vector(k);%    disp('SNR is:');%    disp(SNR_vector(k));%    sim('STBC_OFDM_Tx2_Rx1_COST_207_blockfading_grassman_A');      %    Error_Vector_A(k) = ErrorVec_A(length(ErrorVec_A));%    save Error_Vector_A;%    disp('BER is:');%    disp(Error_Vector_A(k));%    disp('***********************');  %end%semilogy(SNR_vector ,Error_Vector_A,'r');%hold on;% =========================================================================% Main Programme for simulation%Error_Vector_B = zeros(1,length(SNR_vector));%disp('*************Start Simulation*************');%disp('******************B***********************');%for k = 1:length(SNR_vector)%    SNR = SNR_vector(k);%    pro_time = pro_time_vector(k);%    disp('SNR is:');%    disp(SNR_vector(k));%    sim('STBC_OFDM_Tx2_Rx1_COST_207_blockfading_grassman_B');      %    Error_Vector_B(k) = ErrorVec_B(length(ErrorVec_B));%    save Error_Vector_B;%    disp('BER is:');%    disp(Error_Vector_B(k));%    disp('***********************');  %end%semilogy(SNR_vector ,Error_Vector_B,'b');%hold on;% =========================================================================% Main Programme for simulationError_Vector_C = zeros(1,length(SNR_vector));disp('*************Start Simulation*************');disp('******************C***********************');for k = 1:length(SNR_vector)    SNR = SNR_vector(k);    pro_time = pro_time_vector(k);    disp('SNR is:');    disp(SNR_vector(k));    sim('STBC_OFDM_Tx2_Rx1_COST_207_blockfading_grassman_C');          Error_Vector_C(k) = ErrorVec_C(length(ErrorVec_C));    save Error_Vector_C;    disp('BER is:');    disp(Error_Vector_C(k));    disp('***********************');  endsemilogy(SNR_vector ,Error_Vector_C,'g');grid on;disp('*************End Simulation*************');

⌨️ 快捷键说明

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