A9 Exp 6

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

Experiment - 6

Group: A9 28-10-2022

Group Members Roll No. Email ID

Chanda Vamshi B191231EC chandavamshi_b191231ec@nitc.ac.in


Vardhan

Chandra Sekhar Kanuru B190470EC chandrasekhar_b190470ec@nitc.ac.in

Claret Thanikkal B191031EC claret_b191031ec@nitc.ac.in

Dadireddy Jahnavi B190181EC jahnavi_b190181ec@nitc.ac.in

David Joy B190825EC david_b190825ec@nitc.ac.in

a) Objective:
1. Design a sinc pulse (according to Nyquist’s first criterion for zero-ISI).
2. Design a duobinary pulse and modified duobinary pulse.
3. Find the spectrum of sinc pulse and duobinary pulse.
4. Transmit these sinc and duobinary pulses through a channel/filter designed in exp-5, and
observe the corresponding output.

b) Theoretical Background:

Bandwidth Limited Channel


The transmission channel is restricted to a finite bandwidth. All practical channels are
band-limited. Engineers limit the bandwidth of signals to enable multiple signals to share the
same channel with minimal interference.

Pulse Amplitude Modulation (PAM)

The transmission of data by altering the amplitudes (voltage or power levels) of individual pulses
in a regularly timed series of electrical or electromagnetic pulses is known as pulse amplitude
modulation (PAM).

Inter-Symbol Interference (ISI)


Bandwidth-limited channels suppress higher-frequency components of a signal, increasing
waveform rise and fall periods and extending the duration of each symbol. Each signal lasts for
the duration of the symbols that follow it. This means that each symbol has a chance of
interfering with later-transmitted symbols. This type of interference is known as inter-symbol
interference (ISI). ISI is often generated by multipath propagation or a communication channel's
inherent linear or nonlinear frequency response, which causes subsequent signals to merge
together.

Ways to avoid ISI


Some ways Inter-Symbol Interference can be avoided are:
1. Symbols should be separated in time by guard intervals.
2. By applying an equalisation at the receiver, which, in general, seeks to reverse the
impact of the channel by using an inverse filter.
3. At the receiver, use a sequence detector to estimate the sequence of transmitted
symbols using the Viterbi algorithm.
4. Create systems with impulse responses that are brief enough that relatively little energy
from one symbol spreads onto the next.

Nyquist Rule to avoid ISI


Consider a system that transmits symbols in the form of (infinitely-)short pulses ("impulses"). A
low-pass channel will restrict the pulses' rising time, causing the impulses to be spread out in
time. The impulses will not interfere with each other if the channel's reaction to these impulses
crosses zero at multiples of the symbol period. This is known as the Nyquist no-ISI criteria. So,
the response h[n] should satisfy the following condition in the time domain:

The above condition is represented in the continuous domain as follows:


An example of an impulse response that meets this criterion is the sinc() function:

which has a value of 1 at t = and 0 at multiples of T.


It is feasible to calculate the channel's frequency-domain transfer function characteristics that
result in no ISI. This condition is that the channel frequency response has odd symmetry around
half of the symbol frequency:

Both the real and imaginary parts of H(f) need to have this symmetry. We often have limited
control over the impulse response or transfer function of the channel and must apply filtering at
the transmit or receive sides of the channel to fulfil the Nyquist criterion.

Pulse-Shaping Filter

It should be noted that the Nyquist no-ISI criterion applies to a channel that produces no ISI for
impulses rather than the square pulses that are typically used. Because actual systems do not
transmit impulses, the Nyquist criteria cannot be directly applied to the physical channel.
Instead, suppose the transmitter has a hypothetical filter that transforms impulses into pulses
before sending them across the channel. When calculating the channel ISI, the response of this
(im)pulse-shaping filter must be considered. The Nyquist criterion must be met by the
combination of this impulse-shaping filter and the channel.

Duo-binary Signalling
Duo-binary data encoding is a form of correlative coding in partial response signalling. The
modulator drive signal can be produced by adding one-bit-delayed data to the present data bit
to give levels 0, 1, and 2. An identical effect can be achieved by applying a low-pass filter to the
ideal binary data signal.

Modified Duo-binary Signalling


Modified Duo-binary Signalling is an extension of duo-binary signalling. It has the advantage of
zero PSD at low frequencies (especially at DC) that is suitable for channels with poor DC
response. It correlates two symbols that are 2T time instants apart, whereas in duobinary
signalling, symbols that are 1T apart are correlated.
Eye Diagram

Fig. 3: Structure of an Eye Diagram

c) Pseudocode:
clear cache
clear screen
generate sinc pulse using required parameters
compute fft of sinc pulse
plot sinc pulse with respect to time
plot absolute value of fft of sinc pulse

define duobinary = sinc_pulse_1 +sinc_pulse_2


compute fft of duobinary signal
plot duobinary signal with respect to time
plot absolute value of fft of duobinary signal
generate modified duobinary signal =shifted_sinc_pulse_1 +shifted_sinc_pulse_2
compute fft of duobinary signal
plot modified duobinary signal with respect to time
plot modified absolute value of fft of duobinary signal

define channel as FIR low pass filter with parameters


define filter length and cut-off
generate the window function(blackmann)
generate sinc_filter as channel
multiply the sinc_filter and window function for FIR filter
compute fft of the FIR filter base channel
plot impulse response of channel filter
plot fft of channel filter

compute convolution of channel with impulse response of sinc pulse for output
normalise the output
compute the fft of output
normalise the fft of the output
plot the output in time domain
plot the fft of the output
compare the plot of input and output signals

convolute the channel filter with duobinary signal impulse response


normalise the output
compute the fft of output
normalise the fft of the output
plot the output in time domain

plot the fft of the output


compare the plot of input and output signals
convolute the channel filter with impulse response of modified duobinary signal
normalise the output
compute the fft of output
normalise the fft of the output
plot the output in time domain
plot the fft of the output
compare the plot of input and output signals
d) Results with explanation:

Plot of the input sinc pulse in time domain

Above plot shows the time domain representation of the sinc pulse according to Nyquist’s first
criterion for zero-ISI
FFT plot of the input sinc pulse
Above plot shows the frequency domain representation of the sinc pulse which is a rectangular
pulse.
Plot of the duobinary signal input

Above plot shows the time domain representation of the duobinary signal designed to obtain
the controlled ISI.
FFT plot of the duobinary signal input

Above plot shows the frequency domain representation of the duobinary signal which has a
smooth transition from high gain to low gain.
Time domain plot of modified duobinary pulse

Above plot shows the time domain representation of the modified duobinary signal designed to
obtain the controlled ISI.
FFT plot of the modified duobinary signal input

Above plot shows the frequency domain representation of the duobinary signal which has a
smooth transition from high gain to low gain.
Frequency response and impulse response of the channel:

Above plots show the time and frequency domain representation of the channel.
Comparison of channel input and channel output for sinc pulse input
Above plot shows the comparison of the input and output for the case of sinc pulse passed
through a channel. We can observe that the overlap is exact because of no spread in the signal.
FFT of channel output for sinc signal input

Comparison of channel input and channel output for duobinary pulse input

Above plot shows the comparison of the input and output for the case of duobinary signal
passed through a channel. We can observe that the overlap is exact because of no spread in the
signal.
FFT of channel output for duobinary signal input

Comparison of channel input and channel output for modified duobinary signal input

Above plot shows the comparison of the input and output for the case of modified duobinary
signal passed through a channel. We can observe that the overlap is exact because of no spread
in the signal.
FFT of channel output for modified duobinary signal input

e) Conclusion:
● A sinc pulse, a duobinary pulse and a modified duobinary pulse(both generated from
sinc pulse) were generated and passed through a channel constructed using FIR filter,
and outputs were analyzed.
● In the time domain plot of the sinc pulse we can observe that the plot is symmetric
about the Y-axis, zero crossings can be seen at the multiples of Tb, Tb=1.
● In the frequency domain plot of sinc pulse we can observe figure is symmetric about
Y-axis and zero crossing can be seen at 1/2Tb,i.e 0.5s
● In the time domain plot of the duobinary signal , we can observe that the plot is not
symmetric about the Y-axis which is theoretically expected.
● In the time domain plot of the modified duo binary signal it can be observed that it is
symmetrical about the y-axis which follows the theoretical result.
● We can observe that the comparison plots overlap in each case due to there being no
spread when passed through the channel which will reduce the ISI.

f) Appendix:
Code:

clc;
close all;

%defining the sinc pulse


Tb = 1;
fs = 1000;
t = -10*Tb:1/fs:10*Tb-(1/fs);
L = length(t);
f = -fs/2:fs/L:fs/2-1/L;
x = sinc(t/Tb);
Xf = fft(x);
figure(1);
subplot(2,1,1);
plot(t,x);
subplot(2,1,2);
plot(f,fftshift(abs(Xf)));
xlim([-5,5]);
%defining the duobinary signal:
x2 = sinc(t/Tb)+sinc(t/Tb-1);
X2f = fft(x2);
figure(2);
subplot(2,1,1);
plot(t,x2);
subplot(2,1,2);
plot(f,fftshift(abs(X2f)));
xlim([-5,5]);
%defining the Modified duobinary signal:
x3 = sinc(t+Tb)/Tb-sinc(t-Tb)/Tb;
X3f = fft(x3);
figure(3);
subplot(2,1,1);
plot(t,x3);
subplot(2,1,2);
plot(f,fftshift(abs(X3f)));
xlim([-5,5]);

%Defining the channel


fc = 1/Tb;
wc = 2*pi*(fc/fs);
N = 301;
M = N-1;
t1 = M/2;
n = 0:M;
%Blackman window function
W = 0.42 -0.5*(cos((2*pi*n)./M))+0.08*(cos((4*pi*n)./M));
h = sin(wc*(n-t1))./(pi*(n-t1));
h(t1+1) = wc/pi;
hd = h.*W;
h_f = fft(hd);
d = -1:2/length(h_f):(1-2/length(h_f));
figure(4);
subplot(2,1,1);
plot(d,fftshift(abs(h_f)));
title('Frequency response of Channel');
xlabel('Normalized(*pi)--->');
subplot(2,1,2);
plot(hd);
title('Impulse response of the channel');

%Channel output for sinc pulse


% f1 = -fs/2+(150*fs/L):fs/L:fs/2-1/L+(150*fs/L);
y1 = conv(hd,x);
y1 = y1/max(y1);
Y1f = fft(y1);
p1 =fftshift(abs(Y1f(151:end-150)));
p1 = p1/max(p1);
figure(5);
subplot(2,1,1);
plot(t,x);
hold on
plot(t,y1(151:end-150));
hold off
legend('channel output','input');
subplot(2,1,2);
% plot(p1);
% hold on
plot(fftshift(abs(Xf))/max(fftshift(abs(Xf))));
% hold off
% legend('channel output','input');
xlim([9600,10400]);

%Channel output for duobinary pulse


y2 = conv(hd,x2);
y2 = y2/max(y2);
Y2f = fft(y2);

p2 =fftshift(abs(Y2f(151:end-150)));
p2 = p2/max(p2);
figure(6);
subplot(2,1,1);
plot(t,x2);
hold on
plot(t,y2(151:end-150));
hold off
legend('channel output','input');
subplot(2,1,2);
% plot(p2);
% hold on
plot(fftshift(abs(X2f))/max(fftshift(abs(X2f))));
% hold off
% legend('channel output','input');
xlim([9600,10400]);

%Channel output for Modified duobinary pulse


y3 = conv(hd,x3);
y3 = y3/max(y3);
Y3f = fft(y3);
p3 =fftshift(abs(Y3f(151:end-150)));
p3 = p3/max(p3);
figure(7);
subplot(2,1,1);
plot(t,x3);
hold on
plot(t,y3(151:end-150));
hold off
legend('channel output','input');
subplot(2,1,2);
% plot(p3);
% hold on
plot(fftshift(abs(X3f))/max(fftshift(abs(X3f))));
% hold off
% legend('channel output','input');
xlim([9600,10400]);

**********************************************

You might also like