Вы находитесь на странице: 1из 10

COMMUNICATION SYSTEM

EECB353
GROUP ASSIGNMENT:
Question 9
Member

KRISNA YAP ( EE089865)

Member

VINISH A/L GOVINDARAJOO (EE091198)

Member

PALANI VELOO A/L SUBRAMANIAM (EE091123)

Member

HARINDRAN A/L KRISHNAN (EE090699)

Section

01

Lecturer

DR. NOR AZIZAH BT MOHD ARIPIN

Part A
Question 1

Input signal

Amplifier

Output

Frequency
Voltage
Converter

Voltage to
frequency
converter

Transmitter

Voltage
summer and
Amplifier

Receiver

Question 2

Assume, Vpp = 10V


fm = 500hz
fs (sampling frequency) = 1000Hz

Calculation:
Qe

= 2% of Vpp
= (2/100) x 10
= 0.2V

Qe

=
V

V/2
= 2x Qe

= 2(0.2)
=0.4

= Vpp/ L

Vpp/

= 10/0.4
=25
2n

=L

2n

=25

=4.6439

Hence, n 5
Pcm codebook
Magnitude

Decimal Value

Quantization Range (V)

11111
11110
11101
11100
11011
11010
11001
11000
10111
10110
10101
10100
10011
10010
10001
10000
01111
01110
01101
01100
01011
01010
01001
01000
00111
00110

31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
15
14
13
12
11
10
9
8
7
6

+4.6875 to +5
+4.375 to +4.6875
+4.0625 to +4.375
+3.75 to +4.0625
+3.4375 to +3.75
+3.125 to +3.4375
+2.8125 to +3.125
+2.5 to +2.8125
+2.1875 to +2.5
+1.875 to +2.1875
+1.5625 to +1.875
+1.25 to +1.5625
+0.9375 to +1.25
+0.625 to +0.9375
+0.3125 to +0.625
0 to +0.3125
0 to-0.3125
-0.3125 to -0.625
-0.625 to -0.9375
-0.9375 to -1.25
-1.25 to -1.5625
-1.5625 to -1.875
-1.875 to -2.1875
-2.1875 to -2.5
-2.5 to -2.8125
-2.8125 to -3.125

00101
00100
00011
00010
00001
00000

5
4
3
2
1
0

-3.125 to -3.4375
-3.4375 to-3.75
-3.75 to -4.0625
-4.0625 to -4.375
-4.375 to -4.6875
-4.6875 to -5

Question 3
n=input('Enter n value for n-bit PCM system : ');
n1=input('Enter number of samples in a period : ');
L=2^n;
% % Signal Generation
% x=0:1/100:4*pi;
% y=4*sin(x);
% subplot(2,2,1);
% plot(x,y);grid on;
% Sampling Operation
x=0:2*pi/n1:4*pi;
s=4*sin(x);
subplot(3,1,1);
plot(s);
title('analog Signal');
ylabel('Amplitude--->');
xlabel('Time--->');
subplot(3,1,2);
stem(s);grid on; title('Sampled Sinal'); ylabel('Amplitude--->'); xlabel('Time--->');
QUANTIZATION PROCESS
vmax=4;
vmin=-vmax;
del=(vmax-vmin)/L;
part=vmin:del:vmax;
code=vmin-(del/2):del:vmax+(del/2);
[ind,q]=quantiz(s,part,code);
l1=length(ind);
l2=length(q);
for i=1:l1
if(ind(i)~=0)
end
i=i+1;
end
for i=1:l2
if(q(i)==vmin-(del/2))
end
end

ind(i)=ind(i)-1;

q(i)=vmin+(del/2);

subplot(3,1,3);
stem(q);grid on;
title('Quantized Signal');
ylabel('Amplitude--->');
xlabel('Time--->');
ENCODING
figure
code=de2bi(ind,'left-msb');
k=1;
for i=1:l1
for j=1:n
coded(k)=code(i,j);
j=j+1;
k=k+1;
end
i=i+1;
end
subplot(2,1,1); grid on;
stairs(coded);
axis([0 100 -2 3]); title('Encoded Signal');
ylabel('Amplitude--->');
xlabel('Time--->');
DECODING
qunt=reshape(coded,n,length(coded)/n);
index=bi2de(qunt','left-msb');
q=del*index+vmin+(del/2);
subplot(2,1,2); grid on;
plot(q);
ylabel('Amplitude--->');
xlabel('Time--->');

Question 4

title('Decoding Signal');

Figure 1

Figure 2

Figure 3

As we can see from figure 1 and 3, the analog signals amplitude


and frequency is the same as decoded signals amplitude and
frequency.

Question 5

Figure 4

Figure 3 shows the result for one sample of encoded signal at the
transmitter.

Part B
Question 1

Proposed modification
-For each patient the Fm is 500Hz
Fs=1000Hz

Fm=500
Fm=500
Fm=500
Fm=500

5000 Hz

S/H
S/H
S/H
S/H

5000 Hz
5000 Hz
5000 Hz

R = n x Fs
= 5 x 1000Hz
=5000Hz

Question 2
clear all;
close all;
n=input('Enter the number the signal you multiplexed : ');
r=input('Enter the number of bits in each signal : ');

20000

%signaling
for i=1:n
a=input('enter data bits : ');
for j=1:r
a1(i,j)=a(1,j);
j=j+1;
end
disp('Enter next signal data bits : ');
i=i+1;
end
%displaying the signal
figure
for i=1:n
for j=1:r
a2(1,j)=a1(i,j)
j=j+1;
end
subplot(n,1,i);
plot(a2);title('Input Signal');
i=i+1;
end
%multiplexed signal
figure
k=1;
for i=1:n
for j=1:r
m(1,k)=a1(i,j);
j=j+1;
k=k+1;
end
i=i+1;
end
plot(m);title('Multiplexed Signal');
%demultiplexed signal
figure
k=1;
for i=1:n
for j=1:r
t(1,j)=m(1,k)
d(i,j)=t(1,j);
j=j+1;
k=k+1;
end
subplot(n,1,i);
plot(t);title('Received Signal');
end

Question 3

Figure 5: 4 input signal of the patients

Figure 6: multiplexed signal

Figure 7: received signal

Вам также может понравиться