Professional Documents
Culture Documents
'Array' 'Subarrayselection' 'Subarraysteering' 'Custom' 'Array' 'Subarrayselection' 'Subarraysteering' 'Custom'
'Array' 'Subarrayselection' 'Subarraysteering' 'Custom' 'Array' 'Subarrayselection' 'Subarraysteering' 'Custom'
'Array' 'Subarrayselection' 'Subarraysteering' 'Custom' 'Array' 'Subarrayselection' 'Subarraysteering' 'Custom'
rng(4096);
>>The rng command controls the seed, or starting point, for this value
>>> A random seed is a starting point in generating random numbers
txarray = phased.PartitionedArray(...
'Array',phased.URA([sqrt(Nt) sqrt(Nt)],lambda/2),...
'SubarraySelection',ones(NtRF,Nt),'SubarraySteering','Custom');
rxarray = phased.PartitionedArray(...
'Array',phased.URA([sqrt(Nr) sqrt(Nr)],lambda/2),...
'SubarraySelection',ones(NrRF,Nr),'SubarraySteering','Custom');
>>The above array can be modeled by partitioning the array aperture into 4 completely connected
subarrays.
Nscatter = Nray*Ncl;
txclang = [rand(1,Ncl)*120-60;rand(1,Ncl)*60-30];
rxclang = [rand(1,Ncl)*120-60;rand(1,Ncl)*60-30];
txang = zeros(2,Nscatter);
rxang = zeros(2,Nscatter);
>>>compute the rays within each cluster
for m = 1:Ncl
txang(:,(m-1)*Nray+(1:Nray)) =
randn(2,Nray)*sqrt(angspread)+txclang(:,m);
rxang(:,(m-1)*Nray+(1:Nray)) =
randn(2,Nray)*sqrt(angspread)+rxclang(:,m);
pattern(txarray,fc,-90:90,-90:90,'Type','efield',...
'ElementWeights',F','PropagationSpeed',c);
Ns_param = [1 2]; >> nS_param should have the same number of rows as the number of
Zero element with coefficient
Ropt = zeros(Nsnr,NNs);
for m = 1:Nsnr
snr = db2pow(snr_param(m));
for n = 1:Niter
>> Channel realization
txang = [rand(1,Nscatter)*60-30;rand(1,Nscatter)*20-10];
rxang = [rand(1,Nscatter)*180-90;rand(1,Nscatter)*90-45];
At = steervec(txpos,txang);
Ar = steervec(rxpos,rxang);
g = (randn(1,Nscatter)+1i*randn(1,Nscatter))/sqrt(Nscatter);
H = scatteringchanmtx(txpos,rxpos,txang,rxang,g);
for k = 1:NNs
Ns = Ns_param(k);
>> Compute optimal weights and its spectral
efficiency
[Fopt,Wopt] = helperOptimalHybridWeights(H,Ns,1/snr);
Ropt(m,k) = Ropt(m,k)
+helperComputeSpectralEfficiency(H,Fopt,Wopt,Ns,snr);
plot(snr_param,Ropt(:,1),'--sr',...
snr_param,Ropt(:,2),'--b',...
xlabel('SNR (dB)');