# FPGA代做|基于QPSK调制解调的误码率分析

### 时间：2017-4-27 2:43:23 点击：

核心提示：FPGA代做|基于QPSK调制解调的误码率分析...

FPGA代做|基于QPSK调制解调的误码率分析

%% QPSK simulation over Rayleigh Fading wireless channel
%% and its comparison with QPSK transmission over Wireline channel
close all;clear all;clc;
SNRdB=1:1:12;               %SNR in dB
SNR=10.^(SNRdB/10);         %SNR in linear Scale
bl=10^6;                    %No. of bits transmitted
ber=zeros(1,length(SNRdB)); %Simulated BER
x1=(2*floor(2*rand(1,bl)))-1;
x2=(2*floor(2*rand(1,bl)))-1;
x=x1+1i*x2;                 %Transmitted Symbols
%% QPSK Transmission over AWGN Wireline channel
parfor k=1:length(SNR);
y=(sqrt(SNR(k))*x1)+randn(1,bl)+1i*((sqrt(SNR(k))*x2)+randn(1,bl));
ber(k)=length(find((real(y).*x1)<0))+length(find((imag(y).*x2)<0));
end
ber=ber/bl;
semilogy(SNRdB,ber,'k-<', 'linewidth' ,2.0);        %Simulated BER
hold on
p=qfunc(sqrt(SNR));
semilogy(SNRdB,2*p-p.^2,'m-','linewidth',2.0);      %Theoritical BER

%% QPSK over Rayleigh Fading Wireless Channel
parfor k=1:length(SNR)
y=raylrnd(1/sqrt(2),1,bl).*(sqrt(SNR(k))*x1)+randn(1,bl)+1i*(raylrnd(1/sqrt(2),1,bl).*(sqrt(SNR(k))*x2)+randn(1,bl));
ber(k)=length(find((real(y).*x1)<0))+length(find((imag(y).*x2)<0));
end
ber=ber/bl;
semilogy(SNRdB,ber,'k-<', 'linewidth' ,2.0);       %Simulated BER
hold on
p=0.5*(1-(sqrt(SNR./(2+SNR))));
semilogy(SNRdB,2*p-p.^2,'r-','linewidth',2.0);     %Theoritical BER
title('QPSK over Wireline & Rayleigh Fading Wireless channel');xlabel('SNR(dB)');ylabel('BER');
axis tight
grid

• 百度搜索
• 查阅资料过程中
• 论坛发现
• 百度贴吧发现
• 朋友介绍
• 大名：
• 内容：