Blog
CCN BSSE 4th Mid Past Paper – UOS Main Campus
University of Sargodha main campus CCN (Computer Communication and Networks) mid-term paper for BSSE 4th (Self + Reg), 30 marks, 1.5 hours. Retyped from the original paper, with solved answers below.
Solved answers
Q1 – Line encoding of 010010101010111 (10)
Conventions used (Forouzan): NRZ-L 0 = +V, 1 = −V; NRZI inverts the level at every 1 (starting level +); AMI sends 0 V for 0 and alternates +/− for each 1; pseudo-ternary is the opposite (0 alternates, 1 = 0 V); Manchester 0 = high→low and 1 = low→high in the middle of the bit; Differential Manchester always has a mid-bit transition, plus an extra transition at the start of a bit for 0 and none for 1 (starting level +). State your convention in the exam, because books differ.
| Bit | 0 | 1 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1 | 1 | 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| NRZ-L | + | − | + | + | − | + | − | + | − | + | − | + | − | − | − |
| NRZI | + | − | − | − | + | + | − | − | + | + | − | − | + | − | + |
| AMI | 0 | + | 0 | 0 | − | 0 | + | 0 | − | 0 | + | 0 | − | + | − |
| Pseudo-ternary | + | 0 | − | + | 0 | − | 0 | + | 0 | − | 0 | + | 0 | 0 | 0 |
| Bit | 0 | 1 | 0 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1 | 0 | 1 | 1 | 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Manchester | +→− | −→+ | +→− | +→− | −→+ | +→− | −→+ | +→− | −→+ | +→− | −→+ | +→− | −→+ | −→+ | −→+ |
| Diff. Manchester | −→+ | +→− | +→− | +→− | −→+ | −→+ | +→− | +→− | −→+ | −→+ | +→− | +→− | −→+ | +→− | −→+ |
Draw each row as a waveform: one bit period per column, + = high level, − = low level, 0 = zero line, “→” = transition in the middle of the bit.
Baseline wandering: it happens when there is a long run of the same level (DC component). Manchester and Differential Manchester are best for avoiding baseline wandering, because every bit has a transition in the middle, so the average level is always zero (they also give self-synchronization). AMI and pseudo-ternary also have no DC component, but long runs of 0s (AMI) or 1s (pseudo-ternary) lose synchronization. NRZ-L and NRZI suffer most from baseline wandering.
More resources: Manchester and Differential Manchester need twice the bandwidth (signal rate is double the data rate, two signal changes per bit), so they are the most expensive. AMI and pseudo-ternary need three voltage levels, so the hardware is more complex than two-level NRZ.
Q2 – Network design for organization “X” (20)
Assumptions: one router and core switch per office; Lahore offices are in the same city; ISP leased lines are available between cities.
- Inside each office (LAN): star topology. Each customer care center (Karachi, Lahore1, Lahore2, Sargodha) has one 24-port Gigabit switch connecting its 10 computers with Cat-6 UTP cable, and one router for the WAN link.
- Lahore3: extended star / hierarchical design. A core (Layer-3) switch connects five department switches (Sales, HR, Operations, Audit, Security), one per department, each with 10 PCs on Cat-6. Each department is its own VLAN; the Main Computer of each department is reachable by the country head and the NY head office for video conferencing. Department switches connect to the core switch through fiber uplinks.
- Security department: connectivity cannot be lost, so use redundancy: two uplinks to two core switches (or a mesh between the security switch and core), dual routers with two different ISPs, and a UPS. This gives a backup path if one link fails.
- Between offices (WAN): hub-and-spoke topology. Karachi, Lahore1 and Sargodha connect to Lahore2 (customer care head office), and Lahore2 connects to Lahore3, as required. Lahore3 connects directly to the head office in New York through an international leased line / MPLS or VPN over the internet. Regional heads and the country head are interconnected through VPN tunnels for video calls.
- Transmission media: Lahore1 suffers from noise, so use optical fiber (immune to electromagnetic noise). Sargodha has distortion, so use fiber or a digital leased line with repeaters/equalizers. The Lahore2–Lahore3 link (same city) uses fiber. Karachi–Lahore2 uses a fiber leased line / MPLS. Lahore3–New York uses an international fiber (submarine) link from the ISP, with satellite as a backup.
Minimum bandwidth (assume 64 kbps per voice channel, PCM, and 384 kbps per video channel for compressed video conferencing):
- Each customer care center: 10 × 64 kbps + 2 × 384 kbps = 640 + 768 = 1,408 kbps ≈ 1.41 Mbps.
- Four customer care centers: 4 × 1.408 = 5.632 Mbps (this is what Lahore2 must carry to Lahore3).
- Lahore3: 50 × 64 kbps + 20 × 384 kbps = 3,200 + 7,680 = 10,880 kbps ≈ 10.9 Mbps.
- Total voice/video for the organization ≈ 5.63 + 10.88 = 16.5 Mbps; so the Lahore3 ↔ New York link should be at least about 20 Mbps to leave room for data traffic.
