?? runpaproversampling.m
字號:
%This programming is for PAPR of OFDM.
clear;clc;
%% Parameters for simulink model PAPR_OFDM.
N=1024;%There are N symbols in each frame.
SampTime=1;%The sample time.
OutNum=1e3;%The model has OutNum numbers as output.
StopTime=N*4*SampTime*OutNum;
%% Simulate
J=4;%Oversampling factor.
sim('PAPR_oversampling.mdl');
%Calculation
PAPRInX=4:0.1:13;NumGtPAPR=zeros(1,length(PAPRInX));
for tmp1=4:0.1:13;
tmp3=round(10*(tmp1-4)+1);
for tmp2=1:length(PAPR);
if PAPR(tmp2)>tmp1;
NumGtPAPR(tmp3)=NumGtPAPR(tmp3)+1;
end;
end;
end;
CCDF=NumGtPAPR./length(PAPR);
%% Give a figure of the results.
figure(1);hold on;grid on;
semilogy(PAPRInX,CCDF,'r');
%Programming end.
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -