Wireless channel modeling: Error using plot Specify the coordinates as vectors or matrices of the same size, or as a vector and a matrix that share the same length in at least
betaTT=90; %
betaRR=90;
Ft_max=570;
Fr_max=570;
alphavT=0;
alphavR=0;
kappa=0;
Ut=45;
tau=0;
Freq_diff=0;
D=300;
Rt=40;
Fc=5.9*10^9;
C=3*10^8;
deltaT=2;
N=20;
% Conversion from degree to radian
betaT=(2*pi*betaTT)/360;
betaR=(2*pi*betaRR)/360;
alpha_0=(2*pi*Ut)/360;
lamda=0.15;
deltaR=linspace(0,2.5,200);
% CF_SB1=zeros(length(deltaT),length(deltaR));
% lambda=(Fc/C);
change_inT=40/300;
alphaT=linspace(-pi,pi,200);
% alphaT=zeros(1,length(alphaT));
for i=1:length(alphaT)
% if (alphaT(i)>-pi)&(alphaT(i)<=pi)
alphaR(i)=pi-(change_inT*sin(alphaT(i)));
end
for b=1:length(deltaR);
% for c=1:length(deltaT);
O=deltaT*cos(alphaT-betaT);
Q=deltaR(b).*cos(alphaR(i)-(betaR));
CF_SB1(b)=(1/(2*pi*besseli(0,kappa)))*trapz(alphaT,exp(sqrt(-1)*2*pi)*(Q+O));
end
figure(1)
plot(deltaR,real(CF_SB1),’–g’);
set(0,’DefaultAxesFontSize’,18);betaTT=90; %
betaRR=90;
Ft_max=570;
Fr_max=570;
alphavT=0;
alphavR=0;
kappa=0;
Ut=45;
tau=0;
Freq_diff=0;
D=300;
Rt=40;
Fc=5.9*10^9;
C=3*10^8;
deltaT=2;
N=20;
% Conversion from degree to radian
betaT=(2*pi*betaTT)/360;
betaR=(2*pi*betaRR)/360;
alpha_0=(2*pi*Ut)/360;
lamda=0.15;
deltaR=linspace(0,2.5,200);
% CF_SB1=zeros(length(deltaT),length(deltaR));
% lambda=(Fc/C);
change_inT=40/300;
alphaT=linspace(-pi,pi,200);
% alphaT=zeros(1,length(alphaT));
for i=1:length(alphaT)
% if (alphaT(i)>-pi)&(alphaT(i)<=pi)
alphaR(i)=pi-(change_inT*sin(alphaT(i)));
end
for b=1:length(deltaR);
% for c=1:length(deltaT);
O=deltaT*cos(alphaT-betaT);
Q=deltaR(b).*cos(alphaR(i)-(betaR));
CF_SB1(b)=(1/(2*pi*besseli(0,kappa)))*trapz(alphaT,exp(sqrt(-1)*2*pi)*(Q+O));
end
figure(1)
plot(deltaR,real(CF_SB1),’–g’);
set(0,’DefaultAxesFontSize’,18); betaTT=90; %
betaRR=90;
Ft_max=570;
Fr_max=570;
alphavT=0;
alphavR=0;
kappa=0;
Ut=45;
tau=0;
Freq_diff=0;
D=300;
Rt=40;
Fc=5.9*10^9;
C=3*10^8;
deltaT=2;
N=20;
% Conversion from degree to radian
betaT=(2*pi*betaTT)/360;
betaR=(2*pi*betaRR)/360;
alpha_0=(2*pi*Ut)/360;
lamda=0.15;
deltaR=linspace(0,2.5,200);
% CF_SB1=zeros(length(deltaT),length(deltaR));
% lambda=(Fc/C);
change_inT=40/300;
alphaT=linspace(-pi,pi,200);
% alphaT=zeros(1,length(alphaT));
for i=1:length(alphaT)
% if (alphaT(i)>-pi)&(alphaT(i)<=pi)
alphaR(i)=pi-(change_inT*sin(alphaT(i)));
end
for b=1:length(deltaR);
% for c=1:length(deltaT);
O=deltaT*cos(alphaT-betaT);
Q=deltaR(b).*cos(alphaR(i)-(betaR));
CF_SB1(b)=(1/(2*pi*besseli(0,kappa)))*trapz(alphaT,exp(sqrt(-1)*2*pi)*(Q+O));
end
figure(1)
plot(deltaR,real(CF_SB1),’–g’);
set(0,’DefaultAxesFontSize’,18); space-time-frequency correlation function MATLAB Answers — New Questions