Ee132b Hw3 Sol
Ee132b Hw3 Sol
Ee132b Hw3 Sol
Problem 1
Consider a broadcasting bus system as shown in Figure 1. Attaching to the bus
are N stations, and they share the channel under pure ALOHA scheme. Suppose
that the transmission rate is R (bits/sec), and the message size is M bits. Neglect
the effect of propagation delay.
Statin i
1
i+1
Broadcasting Bus
M
R
(b)
The distribution for the idle time of the broadcast channel is given by
P (T > t) = P (min{Ti | i = 1, 2, . . . , N } > t)
= P (T1 > t, T2 > t, . . . , TN > t)
= P (T1 > t)P (T2 > t) . . . P (TN > t)
= e1 t e2 t . . . eN t
= e(1 +2 ++N )t .
Therefore, P (T t) = 1 e(1 +2 ++N )t , which is an exponential distribution with
parameter 1 + 2 + + N .
1
EE132B-HW Set #3
(c)
The probability that this message transmission will not be unsuccessful.
P (no collision) = P (T1 >
=e
M
M
M
M
, . . . , Ti1 >
, Ti+1 >
, . . . , TN >
)
R
R
R
R
PN
=e
k=1,k6=i
P
N
k=1,k6=i
k M
R
k M
R
Problem 2
Consider a slotted token ring system with N stations. The token travels in the
counter clockwise direction as shown in Figure 2. In this polling system, a busy
station will capture the token and hold it for the duration of its frame transmission.
It then releases the token and makes it available for capture by the neighboring
station along the ring network. Assume for our analysis that each station holds
the token for a random period of time. Let Hi denote the token holding time of
station i (measured in units of slots). Assume that {Hi | i = 1, 2, . . . , N } is a set
of independent and identically distributed (i.i.d.) random variables. We also assume
that Hi is governed by a geometric distribution with parameter 1 p such that
P (Hi = n) = p(1 p)n , n = 0, 1, . . . . Note that p represents the probability that
station i releases the token at the end of a time slot.
Station 1
Station
1
2
3
Token ring
direction
H1
H2
H3
Station N
Station 2
Station j
Station 3
HN
EE132B-HW Set #3
(c) Suppose that the propagation delay from any station to its adjacent station is
slots. What is the throughput rate of this system? (HINT: Consider a cycle
period (occurring between successive visits of the token to the same station).
Calculate the throughput rate as the ratio between the average amount of "work"
performed by stations during a cycle to the average duration of the cycle. A
station is said to perform "work" when it holds the token; its amount of "work"
is set equal to the time that it holds the token.)
Ans:
(a)
The probability that station 3 receives the token at the start of slot k is given by
P (H1 + H2 = k) = fH1 fH2 (k)
=
=
=
=
k
X
n=0
k
X
n=0
k
X
n=0
k
X
n=0
(b)
Based on the hint, the probability that station 1 receives the token ring again at
the start of slot k is given by
P (H1 + H2 + + HN = k) = fH1 fH2 fHN (k)
!
k+N 1
=
(1 p)N pk .
k
(c)
The throughput rate measures the average amount of work per unit time. The
amount of performed work is measured as the total time spent by stations in holding
the token. Define a cycle to be the time elapsed from the instant the token is received
by any station to the earliest instant it is received by the same station. Consider the
amount of work during a cycle denoted by W . Then, the average amount of work
during a cycle is given by
E[W ] = E
"N
X
i=1
Hi =
N
X
i=1
E [Hi ] =
N (1 p)
,
p
EE132B-HW Set #3
and the average length of a cycle is E[W ] + N . Thus, we have the throughput rate
(denoted as ), which is given by
E[W ]
=
=
E[W ] + N
N (1p)
p
N (1p)
+ N
p
1p
p
(1p)
+
p
1p
.
1 p + p
(1)
Problem 3
(a) In a few words, describe the most significant difference between circuit-switching
and packet-switching systems. Is email system a circuit-switching or a packetswitching system?
(b) Outline the key differences between datagram and virtual-circuit switching systems.
(c) Consider the following situations in conjunction with multiple access schemes.
Which multiple access scheme is typically employed in each situation?
(i) You are waiting at an intersection with 4-way stop sign.
(ii) You present your research work at a small conference where you raise your
hand before you speak.
(iii) You let your child use your car every Saturday night.
(iv) You are trying to take the elevator in ENGINEERING IV Bldg.
Ans:
(a)
The most critical difference between circuit switching and packet switching systems is that the circuit switching system provides dedicated space, time, and/or
frequency resource to a user, regardless of the frequency and the efficiency of the
resource utilization by the user. The packet switching network system does not dedicate link capacity resources to a user flow. It allocates resources to a user when the
user needs such a resource. Email applications are typically carried over a packet
switching network system.
(b)
In the virtual circuit approach to packet switching, the relationship between all
packets belonging to the message or a session is preserved. A single route is chosen
between the sender and the receiver at beginning of the session. When the data are
sent, all packets of transmission travel one after another along that route. In the
other approach of packet switching that is the datagram approach, each packet is
treated independently of all others. Even if one packet is just a piece of a muti-packet
transmission, the network treats it as though it is existed alone.
4
EE132B-HW Set #3
(c)
There is no absolutely correct answer. Possible answers are:
(i) Statistical multiplexing: ATDM
(ii) Reservation (demand assigned TDMA)
(iii) TDMA
(iv) Reservation (demand assigned TDMA)
Problem 4
A
C
D
E
1
2
3
4
4 by 4
switch
1
2
3
4
K
L
M
Time-division multiplexer
EE132B-HW Set #3
Input Port
Line NO.
1
3
4
3
2
4
1
2
Slot NO.
1
1
1
2
2
2
2
1
Output Port
Line NO.
3
2
3
4
4
2
1
1
Slot NO.
1
1
2
1
2
2
1
2
Slot NO.
1
2
1
2
1
Output Port
Line NO.
4
4
3
1
3
Slot NO.
1
2
2
1
1
(d)
The frame duration time must be equal to the length of sampling interval. Thus,
1
kHz = 44.64 sec. Since each frame has two slots,
the frame duration time is 22.4
the slot duration time is 22.32 sec. The number of quantization levels is 256 so that
6
EE132B-HW Set #3
each sample is represented as a binary code of 8 bits. Note that a slot per frame is
assigned for a station. Therefore, a station must transmit at least 8 bits during a slot
8 bits
) = 358 kbps.
and the minimum transmission rate is therefore equal to ( 22.32
sec