| ²é¿´: 178 | »Ø¸´: 1 | |||
| µ±Ç°Ö÷ÌâÒѾ´æµµ¡£ | |||
aaaa4564ľ³æ (ÕýʽдÊÖ)
|
[½»Á÷]
¡¾ÇóÖú¡¿VBLASTϵͳµÄIPICËã·¨µÄÁ÷³Ì
|
||
|
Çë½Ì¸ßÊÖ°ïæÓÃmaltab±à³Ì£¬ÒÔϸø³öÁËËã·¨µÄÁ÷³Ì£¡Ð¡µÜ¼±ÐèÓ㡸÷λÐÐÐк㬰ï°ï棡СµÜÏÈÔÚ´Ëл¹ýÁË£¡ Ö»Òª´ó¼Ò¶ÔvblastϵͳµÄzf,mmseËã·¨Á˽âµÄ£¬»ù±¾ÉϱäÁ¿ÊÇÒ»Öµģ¬Ö»ÊÇ´¦Àí¸ÉÈŵĹý³Ì²»Í¬¡£ ¸÷¸ö±äÁ¿»ù±¾ÊÇÒ»Öµģ¡ ÒÔÏÂÊÇzf_osucºÍmmse_osucËã·¨µÄ³ÌÐò£¬Çë¸÷λ²Î¿¼ÒÔÏ£¡ ÎÒÖ»Ðè×ö2·¢2ÊÕµÄIPICËã·¨µÄÐźżì²â£¡ function [BER]=vblast(Num,alg,modulation,corr,alpha) %************************************************************************** % This program implements vblast using perfect channel estimation for a 2x2 % system. % z=vblast(Num,alg,modulation,corr,alpha) where % Num-> number of runs % alg -> algorithm.Choose from 'ZF' (for zero-forcing),'MM'(MMSE % estimation),'ML'(maximum-likelihood decoding) % modulation -> 'BPSK,'QPSK','16QAM','64QAM' (Note: for 'ML' algorithm only % BPSK and QPSK exist and that too only for 2x2 configuration, as otherwise % run time is too high. % corr -> 1 for correlation at the receiver, 0 for no correlation % alpha -> correlation coefficient value from 0 -> 1 and 0 in case corr =0; % EXAMPLE: vblast(1000,'ZF','QPSK',1,0.5)plots ZF curve for QPSK with 0.5 % correlation coefficient at the receiver using 1000 Monte Carlo runs %************************************************************************** clc; close all; % identify bits for each type of modulation switch modulation case 'BPSK' BITS=1; case 'QPSK' BITS=2; case '16QAM' BITS=4; case '64QAM' BITS=6; end % define SNR range EbNo=[0:1:10]; %define plotting axis SNR_axis=[]; BER_axis=[]; %set initial count idx=1; %define numbers of antennas M=2;%rx antennas N=1;%tx antennas %parameters for wait bar h = waitbar(0,'Please wait...'); wb=6.25; %clear BER register BER=[]; %commence SNR loop for SNR=EbNo errors=0; %define standard deviation, sigma, for noise sigma=0.5/(sqrt(N)*10^(SNR/10)); for iter=1:Num %commence iteration loop %define a random Rayleigh channel H=(randn(M,N)+j*randn(M,N))/sqrt(2); %exercise correlation option, if any if corr R=chol([1 alpha;alpha 1]);%cholesky factor of correlation matrix, i.e. 'R' square root of correlation matrix H=R*H; % R^0.5 *H -> correlation at receiver end H_save=H;%assign H to unalterable value % modulated input data tx_bits=randn(N,BITS)>0; temp1=[]; for i=1:N d1=tx_modulate(tx_bits(i, ,modulation);temp1=[temp1; d1]; end d=temp1; %AWGN noise AWGN_noise = sqrt(sigma)*(randn(M, N)+j*randn(M, N)); %receiver signal vector added to AWGN noise r = (H_save*d)/sqrt(N) + sqrt(sigma)*(randn(M, 1)+j*randn(M, 1)); %Zero-forcing algorithm if alg=='ZF' %initialization G=pinv(H); [gk k0]=min(sum(abs(G).^2,2)); for m=1:N % This FOR loop determines the ordering sequence k1 and determines the 'a' matrix. %This is just one run,i.e. one for each H matrix. %The 'a' matrix is automatically sorted as [a1 a2...aM] k1(m)=k0; w(m, =G(k1(m), ;y=w(m, *r;a(k1(m),1)=Q(y,modulation); r = r - a(k1(m)) * H_save(:, k1(m)); H(:,k0)=zeros(M,1); G=pinv(H); for t=1:m G(k1( t), =inf;endm [gk k0]=min(sum(abs(G).^2,2)); end %MMSE algorithm elseif alg=='MM' %initialisation G=inv(H'*H+N/(10^(0.1*SNR))*eye(N))*H'; [gk k0]=min(sum(abs(G).^2,2)); for m=1:N % This FOR loop determines the ordering sequence k1 and determines the 'a' matrix. % This is just one run,i.e.one for each H matrix.The 'a' matrix is automatically sorted % as [a1 a2...aM] k1(m)=k0; w(m, =G(k1(m), ;y=w(m, *r;a(k1(m),1)=Q(y,modulation); r = r - a(k1(m)) * H_save(:, k1(m)); H(:,k0)=zeros(M,1); G=inv(H'*H+N/(10^(0.1*SNR))*eye(N))*H'; for t=1:m G(k1(t), =inf;end [gk k0]=min(sum(abs(G).^2,2)); end %count errors if BITS==1 %for BPSK modulation errors(iter) = sum((sign(real(a))~=sign(real(d)))); else %for QPSK,16QAM and 64QAM modulations errors(iter) = sum((sign(real(a))~=sign(real(d))) | sign(imag(a))~=sign(imag(d))); end end %end of iteration loop Loop BER(idx)=sum(errors)/(Num) ; % Calculate BER after completion of 'Num' runs SER(idx)=BER(idx)*BITS; %calculate symbol error rate idx=idx + 1; %increment count waitbar(wb/100); wb=wb+6.25;%increment wait bar end %end of SNR loop close(h);%terminate wait bar SNR_axis=EbNo; BER_axis=[BER_axis BER]; SER_axis=SER; %plot BER semilogy(SNR_axis,BER_axis,'b-'); xlabel('SNR [dB]'); ylabel('BER'); legend('') %title('BER Plots'); %hold; %plot SER semilogy(SNR_axis,SER_axis,'b-o'); axis([0 10 1e-4 1]); grid on; legend('BER','SER'); hold off; if alg=='MM' alg='MMSE' end str=['VBLAST System-' '2x 2 ' alg ' Algorithm with ' modulation ' Modulation']; set(gcf,'NumberTitle','off'); set(gcf,'Name',str); grid on [ Last edited by aaaa4564 on 2009-6-28 at 21:18 ] |
» ²ÂÄãϲ»¶
±¾¿Æ211£¬293·ÖÇëÇóµ÷¼Á
ÒѾÓÐ4È˻ظ´
Çóµ÷¼Á
ÒѾÓÐ3È˻ظ´
085400µç×ÓÐÅÏ¢319Çóµ÷¼Á£¨½ÓÊÜ¿çרҵµ÷¼Á£©
ÒѾÓÐ5È˻ظ´
268Çóµ÷¼Á
ÒѾÓÐ9È˻ظ´
һ־Ը˫·Ç085502£¬267·Ö£¬¹ýËļ¶Çóµ÷¼Á
ÒѾÓÐ3È˻ظ´
Ò»Ö¾Ô¸085404£¬×Ü·Ö291£¬Ëļ¶Òѹý£¬Çóµ÷¼Á
ÒѾÓÐ4È˻ظ´
297Çóµ÷¼Á
ÒѾÓÐ12È˻ظ´
26µ÷¼Á 086003
ÒѾÓÐ3È˻ظ´
265Çóµ÷¼Á
ÒѾÓÐ20È˻ظ´
271·ÖÇóµ÷¼ÁѧУ
ÒѾÓÐ11È˻ظ´
mininurse
½ð³æ (ÕýʽдÊÖ)
- Ó¦Öú: 44 (СѧÉú)
- ½ð±Ò: 1020
- É¢½ð: 686
- ºì»¨: 2
- Ìû×Ó: 384
- ÔÚÏß: 165.4Сʱ
- ³æºÅ: 455795
- ×¢²á: 2007-11-10
- רҵ: ϵͳÉúÎïѧ
- ¹ÜϽ: ǩָ֤ÄÏ
¡ï ¡ï ¡ï ¡ï
kuhailangyu(½ð±Ò+2,VIP+0):»¶Ó¹âÁÙ£¬¶à¶à²ÎÓë 6-29 09:50
aaaa4564(½ð±Ò+1,VIP+0):xiexie 8-12 07:04
wuguocheng(½ð±Ò+1,VIP+0):¶à¹ÄÀø£¬¶à²ÎÓë 8-12 10:11
kuhailangyu(½ð±Ò+2,VIP+0):»¶Ó¹âÁÙ£¬¶à¶à²ÎÓë 6-29 09:50
aaaa4564(½ð±Ò+1,VIP+0):xiexie 8-12 07:04
wuguocheng(½ð±Ò+1,VIP+0):¶à¹ÄÀø£¬¶à²ÎÓë 8-12 10:11
|
ÖмäȱʧµÄ¶«Î÷»¹ÊǺܶàµÄ£¬ÓÐһЩ±äÁ¿¸ù±¾²»Çå³þµ½µ×ÖµÓ¦¸Ã´ÓÄÄÀïÀ´¡£½¨Ò黹ÊÇ×Ô¼º¿´Ò»ÏÂMatlab£¬Èç¹ûÓÐPERL»òÕßCµÄ»ù´¡£¬±àMatlab³ÌÐòÄѶȲ»´ó¡£ |
2Â¥2009-06-28 21:08:59














,modulation);
»Ø¸´´ËÂ¥