





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!






To write a code in MATLAB for amplitude modulation of a signal and understanding the different cases of modulation in context of modulation index.
Generate a message signal of frequency 1Hz with m(t) = A + A (^) mcos(2ฯfmt), and |m(t)|> Generate a carrier signal of frequency 20Hz Plotting both the signals and their spectrum. Plotting the modulated signal and itโs spectrum Amplitude modulation of the message signal with ฮผ = 0.5, ฮผ = 1, ฮผ = 1. Mention the case of over modulation.
Message Signal: To generate the message signal, the values of amplitude A (^) m, frequency f (^) m, offset value A and time axis have been defined. The value of f (^) m is chosen as specified and values of A (^) m and t are taken arbitrarily. A>A (^) m to satisfy the condition |m(t)|>0. t is chosen such that sampling frequency is 500 samples/sec
m(t) = A + A (^) m cos(2ฯfm t)
Carrier Signal: For generation of carrier signal f (^) c is taken as specified. The Amplitude Ac is taken arbitrarily.
c(t) = A (^) c cos(2ฯfc t)
Spectrum Plot: Since the spectrum plot is generated to find the frequency components of a signal, therefore, to plot the spectrum of message and carrier signal, their zero shifted Fourier transforms have been taken. Only their positive side has been taken and plotted against linear frequency.
Amplitude Modulation: As in case of Amplitude Modulation, the message signal is simply multiplied by the carrier signal, therefore here the amplitude modulated signal has been generated by using the dot multiplication operator (.*) in MATLAB.
s(t) = m(t) x c(t)
figure, plot(t,c), title('Carrier Signal'),xlabel('time'),ylabel('Amplitude'),grid on,hold on
figure, stem(w(501:1001),C(501:1001)), title('Spectrum of Carrier Signal'),xlabel('frequency (Hz)'),ylabel('Amplitude'),grid on,hold on
% Step 4:
s=(m.*c);
S=fftshift(real(fft(s)));
figure, plot(t,s), title('Modulated Signal'),xlabel('time'),ylabel('Amplitude'),grid on,hold on
figure, stem(w(501:1001),S(501:1001)), title('Spectrum of Modulated Signal'),xlabel('frequency (Hz)'),ylabel('Amplitude'),grid on,hold on
% Step 5:
% (i) u = 0.
A=20; % using u = Am/A
m=A+Amcos(2pifmt);
s=(m.*c);
figure, plot(t,s), title('Modulated Signal for u = 0.5'),xlabel('time'),ylabel('Amplitude'),grid on,hold on
% (ii) u = 1
A=10;
m=A+Amcos(2pifmt);
s=(m.*c);
figure, plot(t,s), title('Modulated Signal for u = 1'),xlabel('time'),ylabel('Amplitude'),grid on,hold on
% Step 6
% for u =
% (iii) u = 1
A=6.
m=A+
s=(m.
figure 1.5'),x
= 1.5, over
+Amcos(2p
*c);
e, plot(t,s), ti xlabel('time'
r modulatio
pifmt);
tle('Modulat ),ylabel('Am
on occurs.
ted Signal fo plitude'),gri
or u = d on,hold onn