1 Star2 Stars3 Stars4 Stars5 Stars (4 votes, average: 4.75 out of 5)
Loading ... Loading ...
Print Print

16QAM Bit Error Rate (BER) with Gray mapping

by Krishna Sankar on June 5, 2008

Let us derive the theoretical 16QAM bit error rate (BER) with Gray coded constellation mapping in additive white Gaussian noise conditions. Further, the Matlab/Octave simulation script can be used to confirm that the simulation is in good agreement with theory.

Gray coded bit mapping in 16-QAM modulation

As we discussed in the previous post on Binary to Gray code for 16QAM, the 4 bits in each constellation point can be considered as two bits each on independent 4-PAM modulation on I-axis and Q-axis respectively.

b0b1 I b2b3 Q
00 -3 00 -3
01 -1 01 -1
11 +1 11 +1
10 +3 10 +3

Table: Gray coded constellation mapping for 16-QAM

16QAM modulation with Gray coded mapping

Figure: 16QAM constellation plot with Gray coded mapping

Symbol Error and Bit Error probability

As can be seen from the above constellation diagram, with Gray coded bit mapping, adjacent constellation symbols differ by only one bit. So, if the noise causes the constellation to cross the decision threshold, only 1 out of bits will be in error. So the relation between bit error and symbol error is,

.

Note:

For very low value of , it may so happen that the noise causes the constellation to fall near a diagonally located constellation point. In that case, the each symbol error will cause two bit errors. Hence the need for approximate operator in the above equation. However, for reasonably high value of , the chances of such events are negligible.

Bit energy and symbol energy

As we learned from the post discussing Bit error rate for 16PSK, since each symbol consists of bits, the symbol to noise ratio k times the bit to noise ratio i.e,

where,

.

16QAM BER

From the post detaling the derivation of 16QAM Symbol error rate, we know that the symbol error is,

.

Combining the above two equations, the bit error rate for Gray coded 16QAM in Additive White Gaussian Noise is

.

Simulation model

The Matlab/Octave script performs the following:

(a) Generation of random binary sequence

(b) Assigning group of 4 bits to each 16-QAM constellation symbol per the Gray mapping

(c) Addition of white Gaussian Noise

(d) Demodulation of 16-QAM symbols and

(e) De-mapping per decimal to Gray conversion

(f) Counting the number of bit errors

(g) Running this for each value of Eb/No in steps of 1dB.

Click here to download : Script for computing 16QAM BER with Gray mapping

Figure: Bit Error Rate plot for 16QAM modulation with Gray mapping

I think we have analyzed the bit error and symbol error probabilites for most of the PSK and QAM modulation schemes in Additive White Gaussian Noise. Time to move on to error rate in multipath channel. receiver diversity. MIMO channel, modulation with memory etc etc :)

Hope this helps,
Krishna

Related posts

  1. Bit error rate for 16PSK modulation using Gray mapping
  2. Binary to Gray code for 16QAM
  3. Comparing 16PSK vs 16QAM for symbol error rate
  4. Softbit for 16QAM
  5. Comparing BPSK, QPSK, 4PAM, 16QAM, 16PSK, 64QAM and 32PSK

D id you like this article? Make sure that you do not miss a new article by subscribing to RSS feed OR subscribing to e-mail newsletter. Note: Subscribing via e-mail entitles you to download the free e-Book on BER of BPSK/QPSK/16QAM/16PSK in AWGN.

{ 2 trackbacks }

» 16QAM Bit Error rate with Gray mapping 3 EB: What The World Is Saying About 3 EB
June 6, 2008 at 4:54 am
Download free e-book on error probability in AWGN
October 1, 2008 at 9:42 pm

{ 29 comments… read them below or add one }

1 hamid kazemi August 23, 2008 at 8:37 pm

hi
I need article about walsh modulator
plz help me
bye

Reply

2 yvon June 5, 2009 at 3:26 pm

Hi, I have found your matlab code on the 16qam ber with gray code on the site http://www.dsplog.com and I have two question to ask you please.

1) What is the difference between “16qam ber with gray code” and “16qam ber without gray code”?
2) How do you get the theoretical expression of any M-aire qam ber.?
can you give me the corresponding expression of the 64-qam.?

Thanks for your help.

Reply

3 Krishna Pillai June 7, 2009 at 2:28 pm

@yvon: My replies:
1/ With Gray coded mapping, the bit loading into adjacent constellation symbols differ by only one bit. So, each error in constellation symbol typically results in one bit being in error. Without Gray coded bit mapping, this assumption is no longer true.

2/ I have posted about theoretical derivation of M-QAM symbol error rate @
http://www.dsplog.com/2008/05/24/article-in-dspdesignlinecom-m-qam-symbol-error/

Hope this helps.

Reply

4 K.T.Liao September 4, 2009 at 6:38 am

Hello Krishna Pillai
Your blog helps me a lot!
I still have some question about the BER and SER on 16QAM
In code for caculating SER
n = 1/sqrt(2)*[randn(1,N) + j*randn(1,N)];
y = s + 10^(-Es_N0_dB(ii)/20)*n; % additive white gaussian noise

In code for caculating BER
n = 1/sqrt(2)*[randn(1,N) + j*randn(1,N)];
y = s + 10^(-Es_N0_dB(ii)/20)*n; % additive white gaussian noise

1)what’s the difference using Es/N0 or Eb/N0?
2)if I want to draw the curve of SER and using Eb/N0 as the x-axis
is that wrong??
Thanks~

Reply

5 Krishna Sankar September 9, 2009 at 5:35 am

@K.T.Liao: My replies:
1) Es/N0 refers to symbol to noise ratio and Eb/N0 refers to bit to noise ratio. For eg, in 16QAM, each constellation symbol carries 4 bits, so Es/N0 = 4Eb/N0.
2) Nothing wrong in plotting SER vs Eb/N0. I have written a post on it @
http://www.dspdesignline.com/howto/208801783;jsessionid=QJJFYXQLQJMO1QE1GHRSKHWATMY32JVN?pgno=2

Reply

6 venkat September 8, 2009 at 7:08 am

hi i need the matlab code for
” channel estimation and predicition for adaptive OFDM links”.
plz help me….

Reply

7 Krishna Sankar September 9, 2009 at 5:51 am

@venkat: Sorry, I do not have the Matlab code.

Reply

8 ipraz2 September 28, 2009 at 1:15 pm

sir, i am new here. How i can add convolution encoding & viterbi decoding within the code. Are the code same for 16psk & 16qam???if u have code pls write.

Reply

9 Krishna Sankar October 1, 2009 at 5:25 am
10 izzat October 13, 2009 at 10:05 am

hi sir.
i’m new to matlab and have problem to modulate the 64QAM bit error rate.
how do i change the code u wrote in 16QAM to 64QAM or 256QAM?
every help is much appreciated.

Reply

11 Krishna Sankar October 15, 2009 at 5:20 am
12 Fritzou October 31, 2009 at 10:29 pm

Hello ! Thank you so much for this great work ^_^
I have a question about the n noise :
n = 1/sqrt(2)*[randn(1,N) + j*randn(1,N)]; 0 dB variance
if I didn’t use a complex noise, wh

Reply

13 Fritzou November 3, 2009 at 10:34 pm

Hello ! Thank you so much for this great work ^_^
I have a question about the n noise :
n = 1/sqrt(2)*[randn(1,N) + j*randn(1,N)]; 0 dB variance
if I use a real noise, what is the value of the variance ?

Reply

14 Krishna Sankar November 8, 2009 at 8:48 am

@Fritzou: 3dB less.

Reply

15 Krishna Sankar November 8, 2009 at 8:28 am

@Fritzou: If you dont use complex, then the variance will be down by 3dB.

Reply

16 minh November 12, 2009 at 9:29 am

I dont understand why while normalizing the transmit power to 1, you use the factor 1/sqrt(10). Would you explain it more? How about this factor in 32QAM and 64QAM? Thank you

Reply

17 Krishna Sankar November 13, 2009 at 5:38 am
18 Preston November 14, 2009 at 8:32 am

Thanks for the great info on here, it’s helping alot…

I am having a problem seeing how I would factor in the number of users, and the processing gain, of a CDMA system for the Probability of Bit error….

I am assuming that the Gp and the number of users, would be factored into the value for Eb but I’m not sure. Can you give me some direction on this?

Thanks

Reply

19 Krishna Sankar December 3, 2009 at 5:34 am

@Preston: Well, I did not quite understand how you are using 16QAM Gray mapping to the CDMA case? In the CDMA case, I would expect you to have a code for each user.

Reply

20 Fritzou November 17, 2009 at 10:40 pm

Hello Mr Krishna Sankar
Great work
why you didn’t use an filter in the transmission and in the reception?(raised cosine)
what would I do if I had this case ?
Thanks .

Reply

21 Krishna Sankar December 6, 2009 at 3:42 pm

@Fritzou: The transmit and receive filters will cause additional notational complexity, which I wished to avoid in this post. I have some posts on simulations with transmit and receive filters
a) http://www.dsplog.com/2008/05/01/eye-diagram-plot-matlab-raised-cosine-filter/
b) http://www.dsplog.com/2008/04/22/raised-cosine-filter-for-transmit-pulse-shaping/
c) http://www.dsplog.com/2009/05/08/ber-with-matched-filtering/

Reply

22 shadat December 6, 2009 at 2:31 pm

please send me simulation for 16QAM and 64 QAM modulation and demodulation for convolutionaly encoding and viterbi decoding and theoritical BER for convolutionaly BPSK,QPSK,16QAM,64QAM

Reply

23 Krishna Sankar December 7, 2009 at 5:28 am
24 waleed salos December 7, 2009 at 4:41 pm

I am waleed from palestinian
I was in need the performnce of bit error rate in pre-ffT and postfft at frequency selective fading .
plesae help me
thank for all

Reply

25 Krishna Sankar December 8, 2009 at 5:28 am

@waleed salos: Hopefully the post on BER for BPSK with OFDM in multipath channel might be of help
http://www.dsplog.com/2008/08/26/ofdm-rayleigh-channel-ber-bpsk/

Reply

26 waleed salos December 9, 2009 at 12:43 am

Dear Krishna sankar
I waleed salos Thank alot for Reply but I need Matlab codes for Post and pre-FFT Beamforming in an OFDM system
or
LMS Beamforming for Pre and Post-FFT processing in OFDM communication systems
Thank for all

Reply

27 Krishna Sankar December 10, 2009 at 6:03 am

@waleed: Sorry, I am not familiar with the topic which you are referring to.

Reply

28 anna February 20, 2010 at 10:18 pm

hye sir…. do you have any tutorial on how to structure the constellation because the symbols is randomly being plot in the graph… i want to start with {0000} first and lastly to {1111)..- from left top corner of the constellation then move to the right and down…

Reply

29 atif February 28, 2010 at 5:40 pm

please help me in 16 qam modulation.any one send me the matlab code of 16 qam modulation.

Reply

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Previous post: Binary to Gray code for 16QAM

Next post: BPSK BER with OFDM modulation