QAM Theoretical BER in AWGN

Quadrature Amplitude Modulation (QAM) is an important modulation scheme as it allows for higher data rates and spectral efficiencies. The bit error rate (BER) of QAM can be calculated through Monte Carlo simulations. However this becomes quite complex as the constellation size of the modulation schemes increases. Therefore a theoretical approach is sometimes preferred. The BER for Gray coded QAM, for even number of bits per symbol, is shown below.

BER of 4-QAM, 16-QAM, 64-QAM, 256-QAM in AWGN
BER of 4-QAM, 16-QAM, 64-QAM, 256-QAM in AWGN

Gray coding ensures that a symbol error results in a single bit error. The code for calculating the theoretical QAM BER for k even (even number of bits per symbol) is given below. The formula for calculating the BER for k odd is different, however, the formula given below can be used a first estimate.


1. Each additional bit/symbol requires about 2dB extra in SNR to achieve the same BER.
2. 4-QAM is essentially QPSK modulation.

0.00 avg. rating (0% score) - 0 votes

17 thoughts on “QAM Theoretical BER in AWGN

  1. How are you doing
    I am doing the performance analysis of quasi-orthogonal space-time codes under QAM debugging, using MATLAB simulation, but I do not know the error rate simulation formula How to say, is the same as you write the simulation formula? If not, do you know what it is? I have a piece of code but is under QPSK debugging, its simulation formula is PPQOSTBC (KK) = 0.5*ERFC (sqrt (0.5*SNRQOSTBC)). Can you tell me if you know?
    Thank you so much

  2. I simulate the BER performance of M-ary QAM .
    now I want to check that result with theoretical ber. So, please send to me theoretical BER equation of M-ary QAM
    thank U

  3. Hello, Can someone please help me with the following?
    The source generates equal probable symbols, P(si) = 0.125, i=0,…,7, and Gray mapping is used to map information bits to the PAM signals.
    (a) Create a Matlab program so it can simulate the symbol error performance and the
    bit error rate performance of the 8-PAM communication system for the transmission of packets of 10,000 symbols each.
    (b) Using your program to simulate the symbol error performance and the bit error
    performance of the system with
    Eb/N0 = 0, 2, 4, 6, 8, 10 dB.

    So far, I have the following code.
    N = 10^4; % number of symbols
    >> alpha8pam = [-7 -5 -3 -1 1 3 5 7]; % 8-PAM alphabets
    >> Es_N0_dB = [0:2:4:6:8:10]; % multiple Eb/N0 values
    >> ipHat = zeros(1,N);
    for ii = 1:length(Es_N0_dB)
    ip = randsrc(1,N,alpha8pam);
    s = (1/sqrt(5))*ip; % normalization of energy to 1
    n = 1/sqrt(2)*[randn(1,N) + j*randn(1,N)]; % white guassian noise, 0dB variance

    y = s + 10^(-Es_N0_dB(ii)/20)*n; % additive white gaussian noise

    % demodulation
    r = real(y); % taking only the real part
    ipHat(find(r= 2/sqrt(5))) = 3;
    ipHat(find(r>=-2/sqrt(5) & r=0 & r<2/sqrt(5))) = 1;

    I'm not sure how to write the rest of the 'iphat' values.

  4. My Octave version.

    I’m new to Octave and doing this sort of thing so please offer suggestions and corrections.

    function Y=Q(X)

    K=[2 4 6 8]
    title(“M-QAM BER v SNR”)
    grid on
    grid minor on
    ylim([1e-8 1e0])
    xlabel(“Eb/No (dB)”)
    print -dsvg q.svg

    1. This is the complete code. You should be able to reproduce the above Fig. If you are still unable to do so, please share your code here.


  5. I simulate the BER performance of M-ary QAM over Rayleigh fading channel in Matlab tool, now I want to check that result with theoretical ber. So, please send to me theoretical BER equation of M-ary QAM over Rayleigh fading channel.

    Thanking you.

  6. Hello, it seems that everyone is in need of those codes :). Could you send me the code for matlab also??

    I’ll appreciate it. Thank you!!

  7. Gordon: Frankly speaking I could not figure this out easily and had to do a simulation. It turns out that there is significant difference (2-3 dB) at low EbNo but at higher signal to noise ratios the difference is reduced to a fraction of a dB.

    The simulation considered 64-QAM modulation but similar results are expected for other modulation schemes.

  8. May I know the sensitivity difference between the cases with and without gray coding?



  9. Hello,
    I tried to do the graphic that you upload to the website in order to calculate the theorical BER of 4-QAM, 16-QAM and 64-QAM.
    I am not able to reproduce that graphic, could you send me the complete matlab code??

    Thank you very much

Leave a Reply

Your email address will not be published. Required fields are marked *