-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathExample5_07.m
More file actions
65 lines (50 loc) · 1009 Bytes
/
Example5_07.m
File metadata and controls
65 lines (50 loc) · 1009 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
% File: Example5_07.m for Example 5-7
clear
clf
fc = 5;
Beta = 0.8;
fm = 1;
Tm = 1/fm;
dt = 2*Tm/200;
wc = 2*pi*fc;
wm = 2*pi*fm;
t = 0:dt:Tm;
m = sin(wm*t);
m = m(:);
theta = Beta*m;
j = sqrt(-1);
g = exp(j*theta);
g = g(:);
carrier = exp(j*wc*t);
carrier = carrier(:);
v = real(g.*carrier);
s = cos(wc*t) - theta'.*sin(wc*t);;
s = s(:);
subplot(411)
plot(t,m);
xlabel('t in sec -->');
ylabel('m(t)');
axis([0 1 -1.2 1.2])
title(['Modulating Signal, fm = ', num2str(fm), ' Hz'])
subplot(412);
plot(t,real(carrier));
xlabel('t in sec -->');
ylabel('v(t)');
axis([0 1 -1.2 1.2])
title(['Carrier Signal, fc = ', num2str(fc), ' Hz'])
grid
subplot(413);
plot(t,v);
xlabel('t in sec -->');
ylabel('v(t)');
axis([0 1 -1.2 1.2])
title(['Exact PM Signal, Beta = ',num2str(Beta), ', fc = ',num2str(fc)]);
grid
subplot(414);
plot(t,s);
xlabel('t in sec -->');
ylabel('s(t)');
axis([0 1 -1.2 1.2])
title(['Narrowband Approximation of PM Signal, Beta = ',num2str(Beta), ', fc = ',num2str(fc)]);
grid