DELHI TECHNOLOGICAL UNIVERSITY
Department of Electronics & Communication Engineering
LABORATORY FILE
Communication Systems Laboratory
Course Code: EC206 | Semester: IV
Name of Student
Roll Number
Batch / Group
Session
Submitted To
MATLAB-Based Simulation Record of Analog Modulation & Demodulation Techniques
EC206 – Communication Systems Laboratory
TABLE OF CONTENTS
[Link]. Title of Experiment Page
Generation of Elementary
1 Continuous-Time & Discrete- 3
Time Signals
Standard Amplitude Modulation
2 (DSB-FC) – Generation & 5
Spectral Analysis
Double Sideband Suppressed
3 8
Carrier (DSB-SC) Modulation
Single Sideband Suppressed
4 10
Carrier (SSB-SC) Modulation
Envelope Detection of a
5 Standard AM Signal in the 12
Presence of AWGN
Frequency Modulation (FM) –
6 14
Generation & Spectral Analysis
Phase Modulation (PM) –
7 16
Generation & Spectral Analysis
Coherent (Synchronous)
8 Demodulation of a DSB-SC 18
Signal
Coherent (Synchronous)
9 20
Demodulation of an SSB Signal
Demodulation of FM and PM
10 22
Signals via Phase Extraction
2
EC206 – Communication Systems Laboratory
1. Generation of Elementary Continuous-Time & Discrete-Time
Signals
AIM
To generate the basic building-block signals of signal processing — the unit step, unit impulse, unit ramp,
sinusoid, exponential, triangular wave and square wave — in MATLAB, and to compare each signal's
continuous-time form with its uniformly sampled, discrete-time counterpart.
THEORY
Any quantity that evolves with an independent variable, most often time, and that carries information
about a physical process is called a signal. Signals are broadly split into two families: continuous-time
signals, which are defined for every real instant of time, and discrete-time signals, which exist only at
uniformly spaced sampling instants obtained by reading the continuous waveform at multiples of a
sampling interval. Nearly every communication and DSP system eventually works with a sampled version
of an originally continuous waveform, which is why comparing the two representations for a common set
of elementary signals is a useful starting exercise.
• Unit step u(t): zero for negative time and unity from t = 0 onward; used to model the sudden
switching-on of a source.
• Unit impulse δ(t): an idealised pulse of zero width and unit area located at the origin; formally the
time-derivative of the unit step.
• Unit ramp r(t): the running integral of the unit step, so it rises linearly with slope one for t ≥ 0.
• Sinusoid: A·cos(2πft+φ), the canonical test waveform for every modulation scheme studied later in
this course.
• Exponential: A·e^(at); models charge/discharge transients and growth or decay processes
depending on the sign of a.
• Triangular and square waves: periodic waveforms built from straight-line ramps or two-level
transitions respectively; both can be expressed as a Fourier series of harmonically related sinusoids
and are common test signals in switching and timing circuits.
In the discrete-time versions, the same mathematical definitions are simply evaluated on an integer index
n instead of a continuous variable t, which is exactly what happens when a real-world signal is captured
through an analog-to-digital converter.
MATLAB CODE
%% Elementary Signals - Continuous vs Discrete Time
clc; clear; close all;
tc = -5:0.005:5; % fine grid used for the "continuous" plots
nd = -5:5; % integer grid used for the discrete plots
figure('Units','normalized','Position',[0.05 0.05 0.9 0.9]);
% --- Unit step ---
subplot(4,2,1); plot(tc, double(tc>=0), 'LineWidth',1.4); grid on
title('Unit Step - Continuous'); xlabel('t'); ylabel('u(t)')
subplot(4,2,2); stem(nd, double(nd>=0), 'filled')
3
EC206 – Communication Systems Laboratory
title('Unit Step - Discrete'); xlabel('n'); ylabel('u[n]')
% --- Unit impulse ---
subplot(4,2,3); plot(tc, double(tc==0), 'LineWidth',1.4); grid on
title('Unit Impulse - Continuous'); xlabel('t'); ylabel('\delta(t)')
subplot(4,2,4); stem(nd, double(nd==0), 'filled')
title('Unit Impulse - Discrete'); xlabel('n'); ylabel('\delta[n]')
% --- Unit ramp ---
subplot(4,2,5); plot(tc, tc.*(tc>=0), 'LineWidth',1.4); grid on
title('Unit Ramp - Continuous'); xlabel('t'); ylabel('r(t)')
subplot(4,2,6); stem(nd, nd.*(nd>=0), 'filled')
title('Unit Ramp - Discrete'); xlabel('n'); ylabel('r[n]')
% --- Sinusoid ---
ts = 0:0.01:2; ns = 0:20;
subplot(4,2,7); plot(ts, sin(2*pi*ts), 'LineWidth',1.4); grid on
title('Sinusoid - Continuous'); xlabel('t'); ylabel('x(t)')
subplot(4,2,8); stem(ns, sin(0.3*pi*ns), 'filled')
title('Sinusoid - Discrete'); xlabel('n'); ylabel('x[n]')
figure('Units','normalized','Position',[0.05 0.05 0.9 0.9]);
te = 0:0.01:5; ne = 0:12;
subplot(3,2,1); plot(te, exp(-te), 'LineWidth',1.4); grid on
title('Exponential - Continuous'); xlabel('t')
subplot(3,2,2); stem(ne, exp(-0.4*ne), 'filled')
title('Exponential - Discrete'); xlabel('n')
tt = 0:0.01:4; nt = 0:20;
subplot(3,2,3); plot(tt, sawtooth(2*pi*1*tt,0.5), 'LineWidth',1.4); grid on
title('Triangular Wave - Continuous'); xlabel('t')
subplot(3,2,4); stem(nt, sawtooth(2*pi*0.1*nt,0.5), 'filled')
title('Triangular Wave - Discrete'); xlabel('n')
subplot(3,2,5); plot(tt, square(2*pi*1*tt), 'LineWidth',1.4); grid on
title('Square Wave - Continuous'); xlabel('t')
subplot(3,2,6); stem(nt, square(2*pi*0.1*nt), 'filled')
title('Square Wave - Discrete'); xlabel('n')
OUTPUT
[ Simulation screenshot for this experiment to be pasted here ]
CONCLUSION
All seven elementary signals were generated successfully in both continuous-time and sampled form. The
discrete-time plots were seen to be nothing but the continuous waveforms read out at integer instants,
confirming that sampling preserves the underlying shape of a signal provided the sampling grid is fine
enough to capture its variation.
4
EC206 – Communication Systems Laboratory
2. Standard Amplitude Modulation (DSB-FC) – Generation &
Spectral Analysis
AIM
To generate a standard AM (double sideband, full carrier) signal for a single-tone message in MATLAB, and
to examine its time-domain waveform together with the two-sided amplitude spectrum of the message,
the carrier and the modulated signal.
THEORY
Standard amplitude modulation, also referred to as DSB-FC, impresses the message onto the amplitude of
a carrier while its frequency and phase remain fixed, and it transmits the carrier itself along with both
sidebands. For a tone message m(t) = Am·cos(2πfmt) and carrier c(t) = Ac·cos(2πfct), the modulated signal
is s(t) = Ac[1 + μ·cos(2πfmt)]·cos(2πfct), where μ = kaAm is the modulation index.
Three regimes follow from the value of μ: under-modulation (μ < 1) leaves the envelope well-formed but
wastes transmitted power in an under-used carrier; 100% modulation (μ = 1) makes the most efficient use
of the envelope's swing; and over-modulation (μ > 1) folds the envelope onto itself, which corrupts the
simple envelope-detection process used at the receiver. In the frequency domain the spectrum of s(t) is a
line at the carrier frequency fc flanked by two sidebands at fc – fm and fc + fm, giving an overall
transmission bandwidth of 2fm.
MATLAB CODE
%% Standard AM (DSB-FC) - Generation & Spectrum
clc; clear; close all;
Fs = 8000; % sampling rate (Hz)
t = 0:1/Fs:0.1; % 100 ms observation window
N = length(t);
f = (-N/2:N/2-1)*(Fs/N); % two-sided frequency axis
Am = 1; fm = 50; % message amplitude & frequency (Hz)
Ac = 2; fc = 1000; % carrier amplitude & frequency (Hz)
mu = 0.8; % modulation index
m = Am*cos(2*pi*fm*t); % message signal
c = Ac*cos(2*pi*fc*t); % carrier signal
s = Ac*(1 + mu*(m/Am)).*cos(2*pi*fc*t); % standard AM / DSB-FC signal
Mf = abs(fftshift(fft(m)))/N;
Cf = abs(fftshift(fft(c)))/N;
Sf = abs(fftshift(fft(s)))/N;
figure;
subplot(3,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)');
ylabel('Amplitude')
subplot(3,2,2); plot(f,Mf); grid on; title('Message Spectrum'); xlabel('Frequency
(Hz)')
subplot(3,2,3); plot(t,c); grid on; title('Carrier Signal'); xlabel('Time (s)');
ylabel('Amplitude')
subplot(3,2,4); plot(f,Cf); grid on; title('Carrier Spectrum'); xlabel('Frequency
(Hz)')
subplot(3,2,5); plot(t,s); grid on; title('AM (DSB-FC) Signal'); xlabel('Time (s)');
ylabel('Amplitude')
subplot(3,2,6); plot(f,Sf); grid on; title('AM Spectrum'); xlabel('Frequency (Hz)')
5
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 2.1: Message, carrier and AM (DSB-FC) signals with their two-sided spectra (wide frequency span).
Fig. 2.2: Same AM (DSB-FC) signal viewed on a narrower frequency axis, with the carrier line and the two sidebands
clearly resolved.
6
EC206 – Communication Systems Laboratory
CONCLUSION
The standard AM signal was generated for a single-tone message, and its spectrum was verified to consist
of a strong line at the carrier frequency with two sidebands spaced fm on either side, matching the 2fm
transmission bandwidth predicted by theory.
7
EC206 – Communication Systems Laboratory
3. Double Sideband Suppressed Carrier (DSB-SC) Modulation
AIM
To generate a DSB-SC signal by directly multiplying a message signal with a carrier, and to confirm from its
spectrum that the discrete carrier component is absent.
THEORY
DSB-SC removes the carrier term that standard AM wastes power on, transmitting only the two sidebands
that already carry all of the message information. Mathematically it is simply the product of the message
and the carrier, s(t) = m(t)·c(t), realised in hardware with a balanced or product modulator (mixer).
Because no carrier is transmitted, DSB-SC is considerably more power-efficient than standard AM for the
same sideband power, but the saving comes at a cost: the receiver can no longer use a simple envelope
detector and must instead regenerate a carrier that is synchronised in both frequency and phase with the
one used at the transmitter before demodulation is possible.
MATLAB CODE
%% DSB-SC Generation
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
f = (-N/2:N/2-1)*(Fs/N);
fm = 50; fc = 1000;
m = cos(2*pi*fm*t); % message signal
c = cos(2*pi*fc*t); % carrier signal
s = m.*c; % DSB-SC modulated signal
M = abs(fftshift(fft(m)))/N;
C = abs(fftshift(fft(c)))/N;
S = abs(fftshift(fft(s)))/N;
figure;
subplot(3,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(3,2,2); plot(f,M); grid on; title('Message Spectrum'); xlabel('Frequency (Hz)')
subplot(3,2,3); plot(t,c); grid on; title('Carrier Signal'); xlabel('Time (s)')
subplot(3,2,4); plot(f,C); grid on; title('Carrier Spectrum'); xlabel('Frequency (Hz)')
subplot(3,2,5); plot(t,s); grid on; title('DSB-SC Modulated Signal'); xlabel('Time
(s)')
subplot(3,2,6); plot(f,S); grid on; title('DSB-SC Spectrum'); xlabel('Frequency (Hz)')
8
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 3.1: Message and carrier signals, the DSB-SC modulated signal and its spectrum, showing only the two sidebands with
no line at fc.
CONCLUSION
Multiplying the message directly with the carrier produced the expected DSB-SC waveform, and its
spectrum confirmed that all of the transmitted energy sits in the two sidebands at fc ± fm, with the carrier
line completely absent.
9
EC206 – Communication Systems Laboratory
4. Single Sideband Suppressed Carrier (SSB-SC) Modulation
AIM
To derive the upper-sideband and lower-sideband SSB signals from a common message using the Hilbert-
transform (phase-shift) method, and to verify that each occupies only half the bandwidth of the
corresponding DSB signal.
THEORY
SSB-SC carries the efficiency of DSB-SC a step further by transmitting only one of the two sidebands —
upper or lower — since both sidebands of a DSB signal contain identical message information and only one
is needed for recovery. This cuts the required channel bandwidth from 2fm down to fm.
One practical way of generating SSB is the phase-shift method: if m̂ (t) denotes the Hilbert transform of the
message m(t), the upper-sideband signal is formed as sUSB(t) = m(t)cos(2πfct) – m̂ (t)sin(2πfct), and the
lower-sideband signal as sLSB(t) = m(t)cos(2πfct) + m̂ (t)sin(2πfct). The bandwidth saving of SSB comes at
the cost of a more elaborate transmitter, since an accurate wideband 90° phase-shift network (or an
equally sharp sideband filter) is required to reject the unwanted sideband.
MATLAB CODE
%% SSB-SC Generation (Hilbert / Phase-Shift Method)
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
f = (-N/2:N/2-1)*(Fs/N);
fm = 50; fc = 1000;
m = cos(2*pi*fm*t);
mh = imag(hilbert(m)); % Hilbert transform of the message
usb = m.*cos(2*pi*fc*t) - mh.*sin(2*pi*fc*t); % upper sideband signal
lsb = m.*cos(2*pi*fc*t) + mh.*sin(2*pi*fc*t); % lower sideband signal
M = abs(fftshift(fft(m)))/N;
USBf = abs(fftshift(fft(usb)))/N;
LSBf = abs(fftshift(fft(lsb)))/N;
figure;
subplot(3,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(3,2,2); plot(f,M); grid on; title('Message Spectrum'); xlabel('Frequency (Hz)')
subplot(3,2,3); plot(t,usb); grid on; title('Upper Sideband Signal'); xlabel('Time
(s)')
subplot(3,2,4); plot(f,USBf); grid on; title('USB Spectrum'); xlabel('Frequency (Hz)')
subplot(3,2,5); plot(t,lsb); grid on; title('Lower Sideband Signal'); xlabel('Time
(s)')
subplot(3,2,6); plot(f,LSBf); grid on; title('LSB Spectrum'); xlabel('Frequency (Hz)')
10
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 4.1: Message signal with its spectrum, alongside the upper- and lower-sideband SSB signals and their respective
spectra.
CONCLUSION
The phase-shift method successfully produced separate upper- and lower-sideband signals from a
common message, and their spectra confirmed that each retained only the band on its own side of the
carrier, occupying half the bandwidth of the DSB case.
11
EC206 – Communication Systems Laboratory
5. Envelope Detection of a Standard AM Signal in the Presence of
AWGN
AIM
To recover the message from a standard AM signal using envelope detection, first in a noise-free channel
and then after Additive White Gaussian Noise has been added, and to compare the two recovered
waveforms.
THEORY
Because a standard AM signal already carries the carrier along with the sidebands, it can be demodulated
non-coherently: the magnitude of the analytic signal (equivalently, a rectifier followed by a low-pass filter)
tracks the message envelope directly, provided the modulation index does not exceed unity.
Real channels, however, add Additive White Gaussian Noise (AWGN) to the transmitted signal. This
experiment adds noise at a specified signal-to-noise ratio to the modulated signal before detection, so that
the graceful degradation of the recovered envelope — visible as ripple superimposed on the message —
can be observed and related to the operating SNR.
MATLAB CODE
%% Envelope Detection of AM in AWGN
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
f = (-N/2:N/2-1)*(Fs/N);
fm = 50; fc = 1000; mu = 0.8;
m = cos(2*pi*fm*t);
s = (1 + mu*m).*cos(2*pi*fc*t); % standard AM signal
r = awgn(s, 15, 'measured'); % add AWGN at 15 dB SNR
env_noisy = abs(hilbert(r)); % envelope via the analytic signal
dem = (env_noisy - mean(env_noisy))/mu;
Rf = abs(fftshift(fft(r)))/N;
Demf = abs(fftshift(fft(dem)))/N;
figure;
subplot(3,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(3,2,2); plot(t,s); grid on; title('AM Signal'); xlabel('Time (s)')
subplot(3,2,3); plot(t,r); grid on; title('AM Signal with AWGN'); xlabel('Time (s)')
subplot(3,2,4); plot(t,dem); grid on; title('Demodulated Signal'); xlabel('Time (s)')
subplot(3,2,5); plot(f,Rf); grid on; title('Spectrum of Received Signal');
xlabel('Frequency (Hz)')
subplot(3,2,6); plot(f,Demf); grid on; title('Spectrum of Demodulated Signal');
xlabel('Frequency (Hz)')
12
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 5.1: Message, clean AM, noisy AM, and demodulated signals, together with the spectra of the received and
demodulated waveforms.
CONCLUSION
Envelope detection recovered the message cleanly in the absence of noise; once AWGN was added at the
chosen SNR, the demodulated output retained the shape of the original message but with visible ripple,
showing that envelope detection degrades gracefully rather than failing outright under additive noise.
13
EC206 – Communication Systems Laboratory
6. Frequency Modulation (FM) – Generation & Spectral Analysis
AIM
To generate a single-tone FM signal in MATLAB and to compare the spectral spread of the modulated
signal with the bandwidth of the original message.
THEORY
Angle modulation keeps the carrier amplitude fixed and instead varies its phase or frequency with the
message, which gives it markedly better noise immunity than amplitude modulation at the cost of a wider
transmission bandwidth. Frequency Modulation (FM) varies the instantaneous frequency of the carrier
linearly with the message: s(t) = Ac·cos[2πfct + 2πkf∫m(τ)dτ], where kf is the frequency-deviation constant.
Unlike AM, the FM bandwidth is not simply twice the message bandwidth. Carson's rule approximates it as
BW ≈ 2(Δf + fm), where Δf = kfAm is the peak frequency deviation, which is why the spectrum of an FM
signal spreads well beyond the message bandwidth on either side of the carrier.
MATLAB CODE
%% FM Generation
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
f = (-N/2:N/2-1)*(Fs/N);
fm = 50; fc = 1000; kf = 200; % kf in Hz per unit message amplitude
m = cos(2*pi*fm*t);
int_m = cumsum(m)/Fs; % running integral of the message
s = cos(2*pi*fc*t + 2*pi*kf*int_m); % FM signal
M = abs(fftshift(fft(m)))/N;
S = abs(fftshift(fft(s)))/N;
figure;
subplot(2,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(2,2,2); plot(f,M); grid on; title('Message Spectrum'); xlabel('Frequency (Hz)')
subplot(2,2,3); plot(t,s); grid on; title('FM Modulated Signal'); xlabel('Time (s)')
subplot(2,2,4); plot(f,S); grid on; title('FM Spectrum'); xlabel('Frequency (Hz)')
14
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 6.1: Message signal and FM modulated signal with their respective spectra.
CONCLUSION
The generated FM signal showed the expected compression and stretching of instantaneous frequency in
step with the message, and its spectrum was noticeably broader than the message spectrum, consistent
with the spreading predicted by Carson's rule.
15
EC206 – Communication Systems Laboratory
7. Phase Modulation (PM) – Generation & Spectral Analysis
AIM
To generate a single-tone PM signal in MATLAB and to compare its spectral behaviour with that of the FM
signal produced in the previous experiment.
THEORY
Phase Modulation (PM) is the second common form of angle modulation. Here the instantaneous phase of
the carrier, rather than its frequency, is varied directly in proportion to the message: s(t) = Ac·cos[2πfct +
kp·m(t)], with kp the phase-deviation constant and the carrier amplitude again held constant.
FM and PM are two views of the same underlying idea: phase-modulating a carrier with the integral of a
message produces an FM signal, while frequency-modulating a carrier with the derivative of a message
produces a PM signal. Because phase tracks m(t) directly in PM, its spectral spread depends on the
instantaneous value of the message itself rather than on its accumulated integral, which is why PM and FM
spectra differ even for the same message and comparable deviation constants.
MATLAB CODE
%% PM Generation
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
f = (-N/2:N/2-1)*(Fs/N);
fm = 50; fc = 1000; kp = 3; % kp in radians per unit message amplitude
m = cos(2*pi*fm*t);
s = cos(2*pi*fc*t + kp*m); % PM signal
M = abs(fftshift(fft(m)))/N;
S = abs(fftshift(fft(s)))/N;
figure;
subplot(2,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(2,2,2); plot(f,M); grid on; title('Message Spectrum'); xlabel('Frequency (Hz)')
subplot(2,2,3); plot(t,s); grid on; title('PM Modulated Signal'); xlabel('Time (s)')
subplot(2,2,4); plot(f,S); grid on; title('PM Spectrum'); xlabel('Frequency (Hz)')
16
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 7.1: Message signal and PM modulated signal with their respective spectra.
CONCLUSION
The PM signal generated for the same tone message showed the constant-amplitude, phase-varying
character expected of angle modulation; as anticipated, its spectral spread tracked the instantaneous
message value directly rather than its integral, distinguishing it from the FM case.
17
EC206 – Communication Systems Laboratory
8. Coherent (Synchronous) Demodulation of a DSB-SC Signal
AIM
To recover the baseband message from a DSB-SC signal using a coherent product detector followed by low-
pass filtering.
THEORY
A DSB-SC waveform carries no discrete carrier component, so a simple envelope detector cannot be used
to recover the message; coherent (synchronous) detection is required instead. The received signal is
multiplied by a locally generated carrier that matches the transmitter's carrier in both frequency and
phase, which shifts one copy of the message spectrum back to baseband while creating a second,
unwanted copy centred at 2fc.
A low-pass filter placed after the multiplier removes the 2fc component, leaving a scaled replica of the
original message. Any residual frequency or phase error in the local oscillator degrades the recovered
signal, which is why practical coherent receivers rely on carrier-recovery circuits such as a Costas loop to
keep the local reference locked to the incoming carrier.
MATLAB CODE
%% Coherent Detection of DSB-SC
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
fm = 50; fc = 1000;
m = cos(2*pi*fm*t);
s = m.*cos(2*pi*fc*t); % DSB-SC signal
lo = cos(2*pi*fc*t); % locally generated, phase-locked carrier
mix = s.*lo; % coherent product-detector output
[b,a] = butter(6, 2*fm/(Fs/2)); % low-pass filter to remove the 2fc term
demod = filtfilt(b,a,mix);
figure;
subplot(4,1,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(4,1,2); plot(t,s); grid on; title('DSB-SC Modulated Signal'); xlabel('Time
(s)')
subplot(4,1,3); plot(t,mix); grid on; title('Coherently Demodulated Signal');
xlabel('Time (s)')
subplot(4,1,4); plot(t,2*demod); grid on; title('Recovered Message Signal');
xlabel('Time (s)')
18
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 8.1: Message signal, DSB-SC signal, the coherent detector's mixer output, and the low-pass filtered, recovered
message.
CONCLUSION
Multiplying the DSB-SC signal by a synchronised local carrier and low-pass filtering the result reproduced
the original message closely, confirming correct operation of the coherent detector and the necessity of
frequency/phase-locked local carrier generation.
19
EC206 – Communication Systems Laboratory
9. Coherent (Synchronous) Demodulation of an SSB Signal
AIM
To recover the message from an SSB signal using a coherent detector followed by low-pass filtering, in the
same manner as for DSB-SC.
THEORY
SSB, like DSB-SC, carries no discrete carrier line and must therefore be demodulated coherently.
Multiplying the received single-sideband signal by a synchronised local carrier shifts the retained sideband
back to baseband while producing an unwanted image near twice the carrier frequency, exactly as it does
for DSB-SC.
A low-pass filter following the multiplier removes this image and leaves the recovered message. Because
SSB occupies only half the bandwidth of DSB-SC, the passband edge of the recovery filter must be chosen a
little more carefully, but the underlying coherent-detection principle is identical.
MATLAB CODE
%% Coherent Detection of SSB
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
fm = 50; fc = 1000;
m = cos(2*pi*fm*t);
mh = imag(hilbert(m));
s = m.*cos(2*pi*fc*t) - mh.*sin(2*pi*fc*t); % upper-sideband SSB signal
lo = cos(2*pi*fc*t);
mix = s.*lo;
[b,a] = butter(6, 2*fm/(Fs/2));
demod = filtfilt(b,a,mix);
figure;
subplot(4,1,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(4,1,2); plot(t,s); grid on; title('SSB Signal'); xlabel('Time (s)')
subplot(4,1,3); plot(t,mix); grid on; title('Demodulated Signal'); xlabel('Time (s)')
subplot(4,1,4); plot(t,2*demod); grid on; title('Recovered Signal'); xlabel('Time (s)')
20
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 9.1: Message signal, SSB signal, the coherent detector output, and the low-pass filtered, recovered signal.
CONCLUSION
The coherent detector reproduced the original tone message from the single-sideband signal after low-
pass filtering, verifying that synchronous detection works equally well for SSB provided the recovery filter
bandwidth is matched to the (halved) message bandwidth.
21
EC206 – Communication Systems Laboratory
10. Demodulation of FM and PM Signals via Phase Extraction
AIM
To demodulate both an FM signal and a PM signal by extracting the instantaneous phase of each received
waveform through the Hilbert transform.
THEORY
Angle-modulated signals keep their amplitude fixed and carry the message in phase or frequency instead,
so envelope detection is of no use here. The analytic signal obtained via the Hilbert transform gives direct
access to the instantaneous phase of the received waveform; unwrapping this phase removes the artificial
2π discontinuities introduced by the arctangent computation.
For an FM signal the message is proportional to the derivative of the unwrapped phase, so the
demodulator differentiates the phase and scales it by 1/(2πkf). For a PM signal the message is proportional
to the phase itself, so the demodulator simply scales the unwrapped phase by 1/kp, with no differentiation
step required.
MATLAB CODE
%% FM and PM Demodulation via Phase Extraction
clc; clear; close all;
Fs = 8000; t = 0:1/Fs:0.1; N = length(t);
fm = 50; fc = 1000; kf = 200; kp = 3;
m = cos(2*pi*fm*t);
int_m = cumsum(m)/Fs;
fm_sig = cos(2*pi*fc*t + 2*pi*kf*int_m);
pm_sig = cos(2*pi*fc*t + kp*m);
phi_fm = unwrap(angle(hilbert(fm_sig)) - 2*pi*fc*t);
fm_dem = [0, diff(phi_fm)*Fs/(2*pi*kf)];
phi_pm = unwrap(angle(hilbert(pm_sig)) - 2*pi*fc*t);
pm_dem = phi_pm/kp;
figure;
subplot(3,2,1); plot(t,m); grid on; title('Message Signal'); xlabel('Time (s)')
subplot(3,2,2); plot(t,fm_sig); grid on; title('FM Signal'); xlabel('Time (s)')
subplot(3,2,3); plot(t,fm_dem); grid on; title('FM Demodulated Signal'); xlabel('Time
(s)')
subplot(3,2,4); plot(t,pm_sig); grid on; title('PM Signal'); xlabel('Time (s)')
subplot(3,2,5); plot(t,pm_dem); grid on; title('PM Demodulated Signal'); xlabel('Time
(s)')
22
EC206 – Communication Systems Laboratory
OUTPUT
Fig. 10.1: Message signal, FM signal and its phase-derived demodulated output, and the PM signal with its phase-scaled
demodulated output.
CONCLUSION
Extracting and unwrapping the instantaneous phase of each received signal successfully recovered the
original tone message in both the FM and PM cases, with the FM path additionally requiring differentiation
of the phase that the PM path did not need.
23