%Illustration of convergence of SINR by reducing the signal power by the
%factor Mof number of antennas in the basestation
SNRdB=10;
SINR=[];
for q=1:1:50000
ncol=0;
h1col=0;
s=0;
v=1/(10^(SNRdB/10));
h1=(randn(q,1)+j*randn(q,1));
h1norm=norm(h1);
noise=0;
I=0;
for i=1:1:50000
h2=(randn(q,1)+j*randn(q,1));
I=I+(abs((h1/h1norm)'*h2)^2);
n=sqrt(v/2)*(randn(q,1)+j*randn(q,1));
noise=noise+(abs((h1/h1norm)'*n))^2;
end
I=I/50000;
noise=noise/50000;
SINR=[SINR (((1/q)*h1norm^2)/((I/q)+noise))];
end

