Tcom 370: Principles of Data Communications University of Pennsylvania Handout 8 Spring Semester 2000 Midterm Examination Solutions In class, closed book, 80 minutes. All problems carry equal credit. Do any four of the five problems. Begin each problem on a separate page. 1. Consider a communication network for a city of one million inhabitants. a. Suppose that each inhabitant, during the busiest hour of the day, is involved in an average of 4 data transactions per hour that use this network. Each transaction, on average, causes 4 packets of 1000 bits each to be sent. Each packet travels over an average of 3 links. What is the aggregate average number of bits per second carried by this network? How many 64 kbit/sec voice telephone links are required to carry this tra c? b. Suppose that the inhabitants use their telephones an average of 10% of the time during the busy hour. How many voice telephone links are required for this? Assume that all calls are within the city and travel over an average of 3 links. Solution. a. Data are generated at an average rate of 106 × 4 transactions packets bits 1 hour ×4 × 1000 × hour transaction packet 3600 seconds ≈ 4.44 × 106 bits . second As each bit has to travel over three links, the tra c supported by the network on average is approximately 1.332 ×107 bits per second. The number of 64 kbps voice telephone links needed to carry this tra c is hence » 1.332 × 107 64 × 103 ¼ = 209. b. On average, at any given instant there are 106 ×0.1 = 105 individuals on the phones. This requires 105 /2 = 5 × 104 end-to-end voice links as all calls are between two people (assuming no conference calls). In circuit switching all voice links are dedicated for the duration of the call. As each such call requires three links, it follows that 1.5 × 105 voice links are needed. Compare with the answer for data transfer. 2. In the Fibre Distributed Data Interface (FDDI) every 4-bit block of data is encoded using a 5-bit code, sometimes called a 4B/5B code, which is constructed so that there is never more than one leading zero and no more than two trailing zeros in each 5-bit codeword. The resulting 5-bit codewords are then transmitted using NRZ-I encoding. 1 Tcom 370: Principles of Data Communications University of Pennsylvania Handout 8 Spring Semester 2000 The 4B/5B code table is shown below. 4-bit data 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111 5-bit codeword 11110 01001 10100 10101 01010 01011 01110 01111 10010 10011 10110 10111 11010 11011 11100 11101 a. The data bit sequence 0010011110000100 is to be transmitted over an FDDI network. Sketch the transmitted waveform. b. What are the advantages of the FDDI encoding technique? Comment on its bandwidth e ciency vis à vis Manchester encoding and on whether long strings of 0s in the data stream will cause synchronisation problems. What if there is a long string of 1s in the data stream? Solution. a. Breaking up the data sequence into four bit blocks, the corresponding coded sequence can be written down directly by inspection from the 4B/5B code table. Spaces have been introduced for reading clarity. Data sequence: 0010 0111 1000 0100 Coded sequence: 10100 01111 10010 01010 The corresponding NRZ-I waveform is shown below. b. The FDDI scheme almost doubles the bandwidth e ciency compared to Manchester encoding. (Recall that NRZ requires only one-half the bandwidth of Manchester.) The improvement in bandwith e ciency over Manchester encoding is not 2 Tcom 370: Principles of Data Communications University of Pennsylvania Handout 8 Spring Semester 2000 quite 100% because five bits are transmitted for every four data bits. Thus, the improvement in bandwidth e ciency over Manchester encoding is 80%. Long strings of 1s do not pose a synchronisation or DC problem in FDDI which inherits its immunity from the di erential encoding NRZ-I. In addition, unlike plain vanilla NRZ-I, FDDI also enjoys immunity from synchronisation or DC problems caused by long strings of 0s by virtue of the 4B/5B encoding—observe that the encoding guarantees that there will be no more than 3 contiguous 0s in the coded sequence. Thus, neither long strings of 1s nor long strings of 0s cause synchronisation or DC di culties in FDDI. This improvement over NRZ-I is at a cost of just 20% in bandwidth. 3. A linear, time-invariant channel has the following response to a pulse input. a. Sketch the output waveform y(t) of the channel when the input waveform x(t) is as shown below. Hint: What would be the output waveform if p(t − τ1 ) + p(t − τ2 ) is input for any fixed τ1 and τ2 ? b. Suppose NRZ-L signalling is used to encode 3-bit sequences of data using the pulse p(t). Are the resulting waveforms received distortion-free by the receiver? Can the receiver decode the original bit stream without errors? Assume the receiver has perfect synchronisation and that the channel is noise-free. Solution. a. The input waveform x(t) is just the superposition of shifted versions of the pulse p(t): x(t) = p(t) − p(t − T ) + p(t − 2T ). As the system is LTI, it follows that the output waveform is given by y(t) = q(t) − q(t − T ) + q(t − 2T ) and sketched below. 3 Tcom 370: Principles of Data Communications University of Pennsylvania Handout 8 Spring Semester 2000 b. In addition to a T -unit delay, the channel causes a spreading of each pulse waveform so that successive bits encoded via NRZ-L are subject to intersymbol interference. Thus, all output waveforms are distorted. Nonetheless, in the absence of noise and assuming perfect synchrony, the receiver can ambiguously decode the original bit stream without errors. To see this observe that each input bit string results in a unique output waveform so that the receiver could actually maintain a look-up table which maps each possible output waveform to the unique input bit string that causes it. Much less e ort is needed, however, and the receiver can actually decode the input bit string sequentially from the output waveform. How would he go about doing so? 4. Consider the periodic rectangular pulse train x(t) shown below. Suppose T = 1 ms. The pulse train x(t) is input to a linear, time-invariant transmission medium which introduces a delay of 1/6 ms. The medium has a flat passband between 2000 Hz and 4000 Hz and blocks all other frequencies. Determine the channel output signal y(t) and sketch it. Hint: Use Euler’s formulæ for the trigonometric functions to put the complex exponential Fourier series in a familiar trigonometric form first. Solution. As usual, set f0 = 1/T . The DC (or zero frequency) coe series is then given by a0 = 1 T while, for n 6= 0, the Fourier coe 1 an = T Z T/2 −T/2 x(t)e −j2πnf 0 t Z T/2 x(t) dt = −T/2 1 T Z T/2 0 dt = cient of the Fourier 1 , 2 cients are given by 1 dt = T Z T/2 e −j2πnf 0 t 0 = 4 ¯T/2 e−j2πnf 0 t ¯¯ dt = −j2πnf0 T ¯0 1 1 − cos(nπ) (1 − e−jπnf 0 T ) = . j2πnf0 T j2πn Tcom 370: Principles of Data Communications University of Pennsylvania Thus, when n 6= 0, an = ± Handout 8 Spring Semester 2000 1/jπn if n is odd, 0 if n is even. Thus, the pulse train has the Fourier series representation x(t) = ∞ ∞ X X 1 ej2πnf 0 t 1 2 + = + sin(2πnf0 t) 2 n =−∞ jπn 2 πn n =1 n odd n odd by combining the corresponding negative and positive terms in the complex exponential Fourier series and using Euler’s formula. This looks very familiar. And indeed it is. Look up the odd square wave we’d analysed in class. How is it related to the pulse train shown here? If we pass x(t) through an LTI system with transfer function H(f) we obtain the output waveform y(t) = ∞ X 1 H(nf0 )ej2πnf 0 t H(0) + . 2 jπn n =− ∞ n odd Write H(f) = A(f)e jθ (f) . We’re given A(f) = ± 1 if 2000 < |f| < 4000, 0 otherwise, and, as the medium introduces a constant delay τ = T/6 = 1/6 ms, θ(f) = −2πfτ. Observe, in particular, as f0 = 1/T = 1000 Hz, A(nf0 ) = ± 1 if n = −3 or n = 3, 0 otherwise. so that it follows that all harmonics nf0 for |n| 6= 3 are blocked and the only terms in the Fourier series that survive are the terms n = −3 and the term n = 3. Thus, y(t) = ¢ ¢ 1 ¡ 1 ¡ j6πf 0 t−j6πf 0 τ H(3f0 )ej6πf 0 t − H(−3f0 )e−j6πf 0 t = e − e−j6πf 0 t+j6πf 0 τ j3π j3π 2 2 = sin(6πf0 t − 6πf0 τ) = sin(6πf0 t − π) 3π 3π as f0 τ = 1/6. It follows that y(t) = − 2 sin(6πf0 t). 3π 5. A particular noisy communication link has a length of 10 km. In a digital signalling scheme, each d km length of the link may be modelled as a binary symmetric channel (n) with raw bit error probability p = p(d) for any 0 ≤ d ≤ 10. Let Pbit = Pbit denote the end-to-end bit error probability when n uniformly spaced repeaters are deployed in the link. For our purposes the receiver himself counts as a repeater. 5 Tcom 370: Principles of Data Communications University of Pennsylvania (1) (2) Handout 8 Spring Semester 2000 (3) a. Determine Pbit , Pbit , and Pbit when p(d) = d2 /1000 for 0 ≤ d ≤ 10. b. Repeat when p(d) = d/100 for 0 ≤ d ≤ 10. Comment on the two cases. Solution. For any n, the direct approach shows us that (n ) Pbit n µ ¶ X ¡ ¢ n k = p (1 − pn−k ) = 12 1 − (1 − 2p)n , k k=0 k odd where p = p(d) = p(D/n) where D = 10 km is the end-to-end distance along the link, and d = D/n is the link length between successive repeaters. a. When p(d) = d2 /1000, direct substitution shows that (1) ¡ ¢ 1 − (1 − 2 × 102 /1000)1 = 0.1, ¡ ¢ = 12 1 − (1 − 2 × 52 /1000)2 = 0.04875, ¡ ¢ = 12 1 − (1 − 2 × 102 /32 × 1000)3 = 0.0325981. Pbit = (2) Pbit (3) Pbit 1 2 b. When p(d) = d/100, direct substitution again yields (1) ¡ ¢ 1 − (1 − 2 × 10/100)1 = 0.1, ¡ ¢ = 12 1 − (1 − 2 × 5/100)2 = 0.095, ¡ ¢ = 12 1 − (1 − 2 × 10/3 × 100)3 = 0.0934815. Pbit = (2) Pbit (3) Pbit 1 2 It is clear that increasing the number of repeaters brings more benefit when the raw bit error probability increases faster than linearly with link length. 6