Nothing Special   »   [go: up one dir, main page]

Lab Ber

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

Bit-Error-Rate (BER)

INTRODUCTION

A bit error rate (BER) is defined as the rate at which errors occur in a transmission system. This can
be directly translated into the number of errors that occur in a string of a stated number of bits:

BER = number of errors / total number of bits sent

If the medium between the transmitter and receiver is good and the signal to noise ratio is high, then the bit
error rate will be very small possibly insignificant and having no noticeable effect on the overall system
However if noise can be detected, then there is chance that the bit error rate will need to be
considered. Although there are some differences in the way these systems work and the way in which
bit error rate is affected, the basics of bit error rate itself are still the same. When data is transmitted over a
data link, there is a possibility of errors being introduced into the system. If errors are introduced into the
data, then the integrity of the system may be compromised.

The main reasons for the degradation of a data channel and the corresponding bit error rate, BER is
noise and changes to the propagation path (where radio signal paths are used). Both effects have a
random element to them, the noise following a Gaussian probability function while the propagation
model follows a Rayleigh model. This means that analysis of the channel characteristics are normally
undertaken using statistical analysis techniques. For fiber optic systems, bit errors mainly result from
imperfections in the components used to make the link. These include the optical driver, receiver,
connectors and the fiber itself. Bit errors may also be introduced as a result of optical dispersion and
attenuation that may be present. Also noise may be introduced in the optical receiver itself. Typically
these may be photodiodes and amplifiers which need to respond to very small changes and as a result
there may be high noise levels present.

Another contributory factor for bit errors is any phase jitter that may be present in the system as this can
alter the sampling of the data. Signal to noise ratios and Eb/No figures are parameters that are more
associated with radio links and radio communications systems. In terms of this, the bit error rate, BER, can
also be defined in terms of the probability of error or POE. The determine this, three other variables
are used. They are the error function, erf, the energy in one bit, Eb, and the noise power spectral density
(which is the noise power in a 1 Hz bandwidth), No. It should be noted that each different type of
modulation has its own value for the error function. This is because each type of modulation performs
differently in the presence of noise. In particular, higher order modulation schemes (e.g. 64QAM, etc) that
are able to carry higher data rates are not as robust in the presence of noise. Lower order modulation
formats (e.g. BPSK, QPSK, etc.) offer lower data rates but are more robust. The energy per bit, Eb,
can be determined by dividing the carrier power by the bit rate and is a measure of energy with the
dimensions of Joules. No is a power per Hertz and therefore this has the dimensions of power (joules per
second) divided by seconds). Looking at the dimensions of the ratio Eb/No all the dimensions cancel out
to give a dimensionless ratio. It is important to note that POE is proportional to Eb/No and is a form of
signal to noise ratio.

FACTORS AFFECTING BIT ERROR RATE

It can be seen from using Eb/No, that the bit error rate, BER can be affected by a number of factors. By manipulating
the variables that can be controlled it is possible to optimize a system to provide the performance levels that are
required. This is normally undertaken in the design stages of a data transmission system so that the performance
parameters can be adjusted at the initial design concept stages.

The interference levels present in a system are generally set by external factors and cannot be changed by the
system design. However it is possible to set the bandwidth of the system. By reducing the bandwidth the level of
interference can be reduced. However reducing the bandwidth limits the data throughput that can be achieved. It is also
possible to increase the power level of the system so that the power per bit is increased. This has to be balanced against
factors including the interference levels to other users and the impact of increasing the power output on the size of the
power amplifier and overall power consumption and battery life, etc. Lower order modulation schemes can be used,
but this is at the expense of data throughput. It is necessary to balance all the available factors to achieve a satisfactory
bit error rate. Normally it is not possible to achieve all the requirements and some trade-offs are required.
However, even with a bit error rate below what is ideally required, further trade-offs can be made in terms of the levels
of error correction that are introduced into the data being transmitted. Although more redundant data has to be sent
with higher levels of error correction, this can help mask the effects of any bit errors that occur, thereby improving the
overall bit error rate.

BER SIMULATION

Here is the Matlab Code For BER Simulation:

N = 10^6 % number of bits or symbols


rand('state',100); % initializing the rand() function
randn('state',200); % initializing the randn() function
% Transmitter
ip = rand(1,N)>0.5; % generating 0,1 with equal probability
s = 2*ip-1; % BPSK modulation 0 -> -1; 1 -> 1
n = 1/sqrt(2)*[randn(1,N) + j*randn(1,N)]; % white gaussian noise, 0dB
variance
Eb_N0_dB = [-3:10]; % multiple Eb/N0 values
for ii = 1:length(Eb_N0_dB)
% Noise addition
y = s + 10^(-Eb_N0_dB(ii)/20)*n; % additive white gaussian noise
% receiver - hard decision decoding
ipHat = real(y)>0;
% counting the errors
nErr(ii) = size(find([ip- ipHat]),2);
end
simBer = nErr/N; % simulated ber
theoryBer = 0.5*erfc(sqrt(10.^(Eb_N0_dB/10))); % theoretical ber
% plot
close all
figure
semilogy(Eb_N0_dB,theoryBer,'b.-');
hold on
semilogy(Eb_N0_dB,simBer,'mx-');
axis([-3 10 10^-5 0.5])
grid on
legend('theory', 'simulation');
xlabel('Eb/No, dB');
ylabel('Bit Error Rate');
title('Bit error probability curve for BPSK modulation');
QUESTIONS
a. run the code shown
b. Indicate on the lines of code of the simulation process
c. Add the lines corresponding to two modulations for WLAN, other than BPSK modulation
and show the comparatively
d. Comment that has that parameter value and in what situations would have practical
application