How to do Amplitude Shift Keying (ASK) using MATLAB

1.Introduction:-
Amplitude Shift Keying(ask) is the simplest method of modulation. the amplitude of carrier wave varies with respect to the amplitude of square pulse. The of achieving of ASK is to switching OFF the carrier when the pulse amplitude is '0' and switching ON when carrier when the pulse amplitude is '1'.this method is called as ON-OFF keying.



2.Problem Statement:-
To generate the ASK wave using MATLAB and plot the carrier ,square pulse and ASK signal on figure window.


3.Program:-
clc;
clear all;
close all;
f1=input('Enter the frequency of carrier=');
f2=input('Enter the frequency of pulse=');
a=3;
t=0:0.001:1;
x=a*sin(2*pi*f1*t);
u=a/2*square(2*pi*f2*t)+a/2;
v=x.*u;
subplot(3,1,1);
plot(t,x);
xlabel('time');
ylabel('amplitude');
title('carrier');
grid on;
subplot(3,1,2);
plot(t,u);
xlabel('time');
ylabel('amplitude');
title('square pulse');
grid on;
subplot(3,1,3);
plot(t,v);
xlabel('time');
ylabel('amplitude');
title('ask modulated signal');
grid on;


4.How to use this code:-
Here you have to only copy the code to MATLAB and just run it and after this you have to give the value of frequency of carries wave and square pulses.

5.Output :-
 Figure Window  
                                 



Command Window

                                                     



6.Conclusion -
Here we have successfully plot the ASK using the MATLAB.



For any question contact me on: akshayadivarekar777@gmail.com

Comments

Popular post

How to add ,read,insert IMAGE in MATLAB

How to plot different discrete signal using MATLAB

How to do Frequency Shift Keying (FSK) using MATLAB