Synopsis: Cyclic prefix in OFDM, tricks a natural channel to perform circular convolution. This simplifies equalizer design at the receiver. Hands-on demo in Matlab.
Cyclic Prefix-ed OFDM
A cyclic-prefixed OFDM (CP-OFDM) transceiver architecture is typically implemented using inverse discrete Fourier transform (IDFT) and discrete Fourier transform (DFT) blocks (refer Figure 13.3). In an OFDM transmitter, the modulated symbols are assigned to individual subcarriers and sent to an IDFT block. The output of the IDFT block, generally viewed as time domain samples, results in an OFDM symbol. Such OFDM symbols are then transmitted across a channel with certain channel impulse response (CIR). On the other hand, the receiver applies DFT over the received OFDM symbols for further demodulation of the information in the individual subcarriers.
This article is part of the book |
In reality, a multipath channel or any channel in nature acts as a linear filter on the transmitted OFDM symbols. Mathematically, the transmitted OFDM symbol (denoted as
The idea behind using OFDM is to combat frequency selective fading, where different frequency components of a transmitted signal can undergo different levels of fading. The OFDM divides the available spectrum in to small chunks called sub-channels. Within the subchannels, the fading experienced by the individual modulated symbol can be considered flat. This opens-up the possibility of using a simple frequency domain equalizer to neutralize the channel effects in the individual subchannels.
Circular convolution and designing a simple frequency domain equalizer
From one of the DFT properties, we know that the circular convolution of two sequences in time domain is equivalent to the multiplication of their individual responses in frequency domain.
Let
If we ignore channel noise in the OFDM transmission, the received signal is written as
We can note that the channel performs a linear convolution operation on the transmitted signal. Instead, if the channel performs circular convolution (which is not the case in nature) then the equation would have been
By applying the DFT property given in equation 2,
As a consequence, the channel effects can be neutralized at the receiver using a simple frequency domain equalizer (actually this is a zero-forcing equalizer when viewed in time domain) that just inverts the estimated channel response and multiplies it with the frequency response of the received signal to obtain the estimates of the OFDM symbols in the subcarriers as
Demonstrating the role of Cyclic Prefix
The simple frequency domain equalizer shown in equation 6 is possible only if the channel performs circular convolution. But in nature, all channels perform linear convolution. The linear convolution can be converted into circular convolution by adding Cyclic Prefix (CP) in the OFDM architecture. The addition of CP makes the linear convolution imparted by the channel appear as circular convolution to the DFT process at the receiver (Reference [1]).
Let’s understand this by demonstration.
To simply stuffs, we will create two randomized vectors for
N=8; %period of DFT s = randn(1,8); h = randn(1,3);
>> s = -0.0155 2.5770 1.9238 -0.0629 -0.8105 0.6727 -1.5924 -0.8007 >> h = -0.4878 -1.5351 0.2355
Now, convolve the vectors
lin_s_h = conv(h,s) %linear convolution of h and s cir_s_h = cconv(h,s,N) % circular convolution of h and s with period N
lin_s_h = 0.0076 -1.2332 -4.8981 -2.3158 0.9449 0.9013 -0.4468 2.9934 0.8542 -0.1885 cir_s_h = 0.8618 -1.4217 -4.8981 -2.3158 0.9449 0.9013 -0.4468 2.9934
Let’s append a cyclic prefix to the signal
Ncp = 2; %number of symbols to copy and paste for CP s_cp = [s(end-Ncp+1:end) s]; %copy last Ncp symbols from s and prefix it.
s_cp = -1.5924 -0.8007 -0.0155 2.5770 1.9238 -0.0629 -0.8105 0.6727 -1.5924 -0.8007
Lets assume that we send the cyclic-prefixed OFDM symbol
lin_scp_h = conv(h,s_cp) %linear convolution of CP-OFDM symbol s_cp and the CIR h
lin_scp_h = 0.7767 2.8350 0.8618 -1.4217 -4.8981 -2.3158 0.9449 0.9013 -0.4468 2.9934 0.8542 -0.1885
Compare the outputs due to cir_s_h
cir_s_h = 0.8618 -1.4217 -4.8981 -2.3158 0.9449 0.9013 -0.4468 2.9934 lin_scp_h = 0.7767 2.8350 0.8618 -1.4217 -4.8981 -2.3158 0.9449 0.9013 -0.4468 2.9934 0.8542 -0.1885
We have just tricked the channel to perform circular convolution by adding a cyclic extension to the OFDM symbol. At the receiver, we are only interested in the middle section of the lin_scp_h which is the channel output. The first block in the OFDM receiver removes the additional symbols from the front and back of the channel output. The resultant vector is the received symbol r after the removal of cyclic prefix in the receiver.
r = lin_scp_h(Ncp+1:N+Ncp)%cut from index Ncp+1 to N+Ncp
Verifying DFT property
The DFT property given in equation 5 can be re-written as
To verify this in Matlab, take N-point DFTs of the received signal and CIR. Then, we can see that the IDFT of product of DFTs of
R = fft(r,N); %frequency response of received signal H = fft(h,N); %frequency response of CIR S = fft(s,N); %frequency response of OFDM signal (non CP) r1 = ifft(S.*H); %IFFT of product of individual DFTs display(['IFFT(DFT(H)*DFT(S)) : ',num2str(r1)]) display([cconv(s,h): ', numstr(r)])
IFFT(DFT(H)*DFT(S)) : 0.86175 -1.4217 -4.8981 -2.3158 0.94491 0.90128 -0.44682 2.9934 cconv(s,h): 0.86175 -1.4217 -4.8981 -2.3158 0.94491 0.90128 -0.44682 2.9934
Rate this article: Note: There is a rating embedded within this post, please visit this post to rate it.
Reference:
Topics in this chapter
Orthogonal Frequency Division Multiplexing (OFDM) ● Introduction ● Understanding the role of cyclic prefix in a CP-OFDM system □ Circular convolution and designing a simple frequency domain equalizer □ Demonstrating the role of cyclic prefix □ Verifying DFT property ● Discrete-time implementation of baseband CP-OFDM ● Performance of MPSK-CP-OFDM and MQAM-CP-OFDM on AWGN channel ● Performance of MPSK-CP-OFDM and MQAM-CP-OFDM on frequency selective Rayleigh channel |
---|
Books by the author
Hi sir, Thank you very much for providing information on MATLAB coding for wireless communication techniques. Will you please help how to do MATLAB coding for OFDM modulation in underwater acoustic communication
Hello Mathuranathan. Nice article. You mentioned ‘estimated channel response’. I assume that means estimated discrete time domain channel impulse response. Have you got an article that shows some basics on obtaining estimates of the channel impulse response for OFDM communications? I see some papers online from authors with topics of channel estimation, but a lot of cryptic math is involved. If there is an entry-level demonstration that can be relatively easy to test or applied in practice, then that would give the newcomers a really nice boost in understanding the OFDM communications method. Thanks Mathuranathan.
Hello Kenny,
I have written some 25+ articles on estimation theory. Those can be accessed from this URL
https://www.gaussianwaves.com/category/estimation-theory/
Thanks for the excellent suggestion, I will definitely write more on the entry-level demos for beginners.
Hello Mathuranathan. Nice article. You mentioned ‘estimated channel response’. I assume that means estimated discrete time domain channel impulse response. Have you got an article that shows some basics on obtaining estimates of the channel impulse response for OFDM communications? I see some papers online from authors with topics of channel estimation, but a lot of cryptic math is involved. If there is an entry-level demonstration that can actually be easily tested or applied in practice, then that would give the newcomers a really nice boost in understanding the OFDM communications method. Thanks Mathuranathan.
if we want to implement 802.16e system in MATLAB using OFDM, how to know about detailing of structure ??
Please refer chapter 6.3.2 in the 802.16e specification (IEEE Standard for WirelessMAN-Advanced Air Interface for
Broadband Wireless Access Systems )
http://standards.ieee.org/getieee802/download/802.16.1-2012.pdf
The section contains tables that illustrates how OFDM subcarriers are arranged for various scenarios.
Thank you so much !! I will go through that
This section contains so many tables? how to go ahead ? and every table is not mentioning all the details of OFDMA for one scenario ? Pl. help
Tables are linked. You need to read the text above to understand the scenarios the tables can be applied.
Start by modelling the simplest possible config and you can build on to that. For example:
To begin with just choose a column in Table 6-146 that dictates the parameters for a given nominal channel BW.
Choose one CP ratio. Choose the same column in Table 6-147 that corresponds to nominal channel BW chosen for Table 6.146.
o. k. Thank you so much !!
Can I mail you the pdf which I am referring just to check whether I am studying correct one or not ?? It is not getting attached here.
Hi Sir,
I am Abid, in real world noise is not always gaussian. It has non gaussian component as well. However, all your codes and discussion about gaussian. Can u please guide me about non gaussian noise generation through MATLAB M file.
Thanks
Best Regards
Dr. ABID MUHAMMAD KHAN
hello sir
I want your help. i want matlab code of ber vs snr plot with bpsk,qpsk and 16qam modulation with mrc, egc and sc in mmse sic receiver
I don’t have the code for this specific scenario. May be I will reserve it for the future.
Sir i have code of sic receiver but i dont know how to add mrc,sc,egc and 16qam,gmsk,qpsk
i have the code but i dont know how to add gmsk,qpsk, 16 qam and selection combing, equal gain combining
It is great article. Thank you very much.
Thanks
Sir, actually I have a query. In your matlab book, the Rayleigh channel generation has been done taking the Jakes’s model into consideration. But the Rician channel generation has been done in a static scenario, unlike the Rayleigh case. It would have been really helpful for me if you could do the same (i.e., scenarios where Rician channel is generated taking into account the doppler effect and the inter-sampling duration) and upload a post regarding the same or share the Matlab code.