現在この質問をフォロー中です
- フォローしているコンテンツ フィードに更新が表示されます。
- コミュニケーション基本設定に応じて電子メールを受け取ることができます。
BER OF M-ary PSK and M-ary QAM
7 ビュー (過去 30 日間)
古いコメントを表示
ABDUL
2020 年 10 月 1 日
Dear All....
I am trying to write a program for the implementation of MIMO-OFDMby using wavelets transfrom . when i plot the BER Curve i am getting a straight line i am not able to get as a standard curve . any help will be appreciated.
Regards
Abdul Azeez
11 件のコメント
ABDUL
2020 年 10 月 12 日
編集済み: ABDUL
2020 年 10 月 12 日
hi.... find attached below code which i am trying to implement for the ofdm by using the wavelet transforms to plot the BER V/s SNR graph and the Peak to Average Power Ratio (PAPR) for the same . i am trying to plot the BER V/s SNR graph for which i am getting a straight line
Regards
Abdul Azeez
clc
clear all;
close all;
M = 4; % QPSK signal constellatio
N = 64; % number of subcarriers
fft_size = N; % have 128 data poexitint
nbits = 100;
nDWTsym = ceil(nbits/N) ;% number of symbols for DWT system
nsym = nbits;
snr = 0:8;
% ------------------%
% TRANSMITTER
% ------------------%
data_source=randsrc(1, fft_size*(nsym-2), 0:M-1); %the data source
sp = reshape(data_source,fft_size,nsym-2).';% s/p
% sp = reshape(qpsk_mod , fft_size, nsym-2);% s/p
[rdwt,cdwt] = size (sp);
tx_dwt= [];
for i=2:nsym-1
for uu=1:cdwt
qpsk_mod=pskmod(sp,M);
DATADWT=qpsk_mod;
AC = DATADWT(1:rdwt/2,uu); % approximation coefficients
DC = DATADWT(rdwt/2+1:rdwt,uu); % detailed (wavelet) coefficients
IDWT=idwt(AC,DC,'haar'); % IDWT process
TXDWT(:,uu)= IDWT; % transmitted data for DWT
end
%%% parallel to serial =======> to the channel
ps1 = reshape( TXDWT,1,[]);
ofdm_signal_dwt=TXDWT;
pilot = zeros(size(TXDWT));
Signal_Power_dwt = abs(ofdm_signal_dwt.^2);
Peak_Power = max(Signal_Power_dwt,[],2);
Mean_Power = mean(Signal_Power_dwt,2);
PAPR_dwt = 10*log10(Peak_Power./Mean_Power);
tx_dwt = [tx_dwt ofdm_signal_dwt];
end
figure (1)
[cdf0,PAPR0] = ccdf(PAPR_dwt,0.1);
semilogy(PAPR0,cdf0,'-b')
legend('DWT based MIMO OFDM System')
xlabel('PAPR0 [dB]');
ylabel('CCDF (Pr[PAPR>PAPR0])');
tt_dwt=reshape(TXDWT,1,[]);
tt_dwt =[ pilot tx_dwt pilot];
x_abs_dwt=abs(tt_dwt);
papr_dwt=10*log(max(x_abs_dwt.^2)/mean(x_abs_dwt.^2));
% ------------
% CHANNEL
% ------------
% ---------------
% RECEIVER
% ------------
no_of_error_dwt=[];
ratio_dwt=[];
for ii=1:length(snr)
rx_dwt= [];
rx_signal_matrix_dwt = reshape(ps1,rdwt,cdwt).';%98x64, 64x98
[~, c] = size(rx_signal_matrix_dwt);
for j=1:cdwt
A1=[];
received_symbol=[];
received_symbol_1=[];
con_dwt=[];
received_symbol_1=[];
DWT=[];
cd=[];
RXDWT=[];
channel = 1/sqrt(2)*[randn(1,length(rx_signal_matrix_dwt))+sqrt(-1)*randn(1,length(rx_signal_matrix_dwt))];
%%% the transmitted signal is corrupted with addtive noise
A1=channel.*rx_signal_matrix_dwt(j,:);
received_symbol = awgn(A1, snr(ii));
% equalization:
received_symbol = conj(channel).* received_symbol;
% Convert Data back to "parallel" form to perform IDWT
con_dwt=reshape(received_symbol, 1,rdwt);
[DWT,cd]=dwt(con_dwt,'haar');%% DWT
RXDWT=[DWT cd];% recieved data for DWT
%%% parallel to serial
RXDWT1 = reshape(RXDWT.',1,[]);% at DWT
qpsk_demod=pskdemod(RXDWT,M);
rx_dwt =[rx_dwt qpsk_demod];
end
% counting the errors and ratio
[nDWT,rDWT]=biterr(data_source, rx_dwt);
simBerDWT(ii)=rDWT;%% DWT system
end
figure (2)
theory_Pb_BPSK = (1/2)*erfc(sqrt(10.^(snr/10)));
semilogy(snr,theory_Pb_BPSK,'bs-','LineWidth',2);
hold on
semilogy(snr,simBerDWT,'mx-','LineWidth',2);
axis([0 8 10^-6 1]); grid on
legend('theory', 'simulation for DWT(Haar)','simulation for FFT');
xlabel('SNR, dB') ; ylabel('Bit Error Rate')
title('BER for qpsk using DWT based ofdm ')
Walter Roberson
2020 年 10 月 12 日
qpsk_mod=pskmod(sp,M);
pskmod returns complex values.
DATADWT=qpsk_mod;
AC = DATADWT(1:rdwt/2,uu); % approximation coefficients
DC = DATADWT(rdwt/2+1:rdwt,uu); % detailed (wavelet) coefficients
So AC and DC are complex values
IDWT=idwt(AC,DC,'haar'); % IDWT process
idwt() is restricted to operating on real values.
Your code cannot generate any line; it crashes long before the plotting.
ABDUL
2020 年 10 月 12 日
編集済み: ABDUL
2020 年 10 月 12 日
is it possible to take ony real values for the qpsk modulated data and implement the wavelet transforms or by taking the absolute values of the psk mod values. is there any method by which i can implement the OFDM technique by using the wavelet transforms ?.
Walter Roberson
2020 年 10 月 13 日
Of course you can take real() or imag() or abs() of the qpsk modulated data, and do a wavelet transform on that.
The question would be whether you would get anything useful out of doing that.
qpsk uses constellations. With M = 16, you end up with 8 different real() values (4 unique values and their negatives), and cannot tell the difference between the two cases involving A +/- B*1i . And with a constellation, all of the values have the same absolute value: they all have the same magnitude, just with different vector rotations.
You would be safer taking real() and imag() and forming a vector twice as long. Possibly even doing dwt separately on the two parts.
... But I have no idea how this relates to OFDM.
ABDUL
2020 年 10 月 13 日
編集済み: ABDUL
2020 年 10 月 13 日
when i try to implement the complex data of size 1x64 , by separting the real and imag parts the and computing the idwt of the data i will be getting the data of twice the size i.e., 1x64 for the real values and 1 x 64 for the imag values when i concatenate it i will be getting the data of size 1x 128 after performing the idwt operation how do i change the data to original data of size 1x 64 ?
Walter Roberson
2020 年 10 月 13 日
編集済み: Walter Roberson
2020 年 10 月 13 日
ireal = idwt(real(AC), real(DC), 'haar');
icpx = idwt(imag(AC), imag(AC), 'haar');
IDWT = complex(ireal, icpx);
ABDUL
2020 年 10 月 13 日
how we go ahead with the implemenation of the dwt as we have 1x98 data samples which are complex ?
Walter Roberson
2020 年 10 月 13 日
I do not understand where you got the 98 data samples from? You have been talking about 1 x 64.
ABDUL
2020 年 11 月 5 日
hi...
if i change the wavelet to other wavelets like db2,db3, sym2, sym3 my data is getting reduced for eg if i have a data of 1x64 , Ac will have 1x32 and Dc will have 1x32 through haar wavelet i will be getting a size of 1x64 but when i use other wavelet like db2 i will be getting the size for 1x30 for Ac and for Dc i will be getting 1x30 the total size of the data will be 1x60 how to retain the same size as 1x64 only when i use the wavelet of db2 and other wavelets
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Signal Analysis についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!エラーが発生しました
ページに変更が加えられたため、アクションを完了できません。ページを再度読み込み、更新された状態を確認してください。
Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
- América Latina (Español)
- Canada (English)
- United States (English)
ヨーロッパ
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom(English)
アジア太平洋地域
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)