www.pudn.com > mimoprecoding.rar > tx_diversity.m, change:2006-06-09,size:1475b


function div_ofdm_syms = tx_diversity(ofdm_symbols, sim_options) 
global sim_consts; 
if sim_options.UseTxDiv == 2 
  %采用4根发射天线分集,不使用空时码 
  div_ofdm_syms = tx_fourTotwo(ofdm_symbols); 
elseif sim_options.UseTxDiv 
  % Radon-Hurwitz or Alamouti tx diversity 
  div_ofdm_syms = tx_radon_hurwitz(ofdm_symbols); 
else 
  % No diversity 
  div_ofdm_syms = ofdm_symbols; 
end 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 
% %STBC  Alamouti 
% if sim_options.UseTxDiv 
%    %tmp = size(ofdm_symbols); 
%    %if mod(tmp(2),2) ~=0 %保证列数是偶数 
%    %    P_dSource = [P_dSource,ones(tmp(1),1)]; 
%    %end 
%    temp = size(ofdm_symbols); 
%    ofdm_symbols = reshape(ofdm_symbols,sim_consts.NumDataSubc,temp(2)/sim_consts.NumDataSubc); 
%    tmp = size(ofdm_symbols); 
%    P_dSource1 = reshape(ofdm_symbols,tmp(1)*2,tmp(2)/2); 
%    P_dSource2 = -conj(P_dSource1((tmp(1)+1):2*tmp(1),:)); 
%    P_dSource3 = conj(P_dSource1(1:tmp(1),:)); 
%    P_dSource4 = [P_dSource1;P_dSource2;P_dSource3]; 
%    P_dSource5 = reshape(P_dSource4,2*tmp(1),tmp(2)); 
%    P_dSource_tr1 = P_dSource5(1:tmp(1),:); 
%    P_dSource_tr2 = P_dSource5((tmp(1)+1):tmp(1)*2,:); 
%     
%    div_ofdm_syms = zeros(2, temp(2)); 
%    div_ofdm_syms(1,:) = P_dSource_tr1(:).'; 
%    div_ofdm_syms(2,:) = P_dSource_tr2(:).'; 
% else 
%    % No diversity 
%    div_ofdm_syms = ofdm_symbols; 
%  
% end 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 

2018无需申请注册送58体验金