BIT254 Network and Data Communications

Network and Data CommunicationsUnit 916 min read

Multiplexing, Switching, QoS: Techniques, Trade-offs, and Real-world QoS

Unit 9 of Network and Data Communications explores how networks efficiently share resources via multiplexing (FDM, TDM, WDM), compare circuit vs. packet switching, and ensure quality of service (QoS) through prioritization, buffering, and traffic shaping—with real-world examples from eSewa, Ncell, and YouTube.

TAKEAWAYS:

  • Multiplexing combines multiple signals over a single channel using frequency (FDM), time (TDM), or wavelength (WDM), each with distinct trade-offs in cost and efficiency.
  • Circuit switching guarantees dedicated paths (e.g., traditional phone calls) but wastes bandwidth; packet switching shares resources dynamically (e.g., internet) but risks delays and loss.
  • QoS mechanisms (prioritization, buffering, traffic shaping) ensure critical traffic (e.g., video calls on Pathao) gets precedence over less urgent data (e.g., file downloads).
  • Switching techniques (circuit, message, packet) differ in latency, overhead, and flexibility—packet switching dominates modern networks due to its scalability.
  • Real-world applications: FDM in cable TV, TDM in mobile networks (Ncell), and QoS in eSewa’s transaction prioritization during peak hours.
  • Exam focus: Differentiate multiplexing types, explain packet-switching phases, and compare QoS techniques with concrete examples (e.g., Daraz’s order queue vs. NTC’s bandwidth allocation).

1. Multiplexing: Combining Signals for Efficiency

Multiplexing allows multiple signals to share a single communication channel, increasing bandwidth utilization. The three primary techniques are Frequency Division Multiplexing (FDM), Time Division Multiplexing (TDM), and Wavelength Division Multiplexing (WDM). Each is suited to different scenarios, from analog radio to modern fiber-optic networks.

1.1 Frequency Division Multiplexing (FDM)

How it works: FDM divides the available bandwidth into non-overlapping frequency bands, assigning each signal a unique band. Signals are transmitted simultaneously without interference.

Band 1: Signal A (Voice)
Band 2: Signal B (Data)
Band 3: Signal C (Video)
...

Visual:


Real-world example:

  • Cable TV (e.g., NTC’s cable services): Each TV channel occupies a distinct frequency band (e.g., 50–56 MHz for Channel 2, 56–62 MHz for Channel 3). A single coaxial cable carries hundreds of channels simultaneously.
  • Mobile networks (e.g., Ncell): FDM separates voice and data signals in 4G/LTE bands (e.g., 1800 MHz for voice, 2100 MHz for data).

Worked example: A cable provider allocates 6 MHz per channel. If a user requests channels 10 (54–60 MHz), 20 (94–100 MHz), and 30 (138–144 MHz), their receiver tunes to these bands simultaneously. Total bandwidth used: 18 MHz (3 channels × 6 MHz).


1.2 Time Division Multiplexing (TDM)

How it works: TDM divides the channel into time slots, allocating each signal a fixed slot in a repeating cycle. Signals take turns transmitting in rapid succession, creating the illusion of simultaneous communication.

Slot 1Signal ASlot 2Signal BSlot 3Signal CSlot 4Signal DSlot 5Repeat cycle
TDM time slots for 4 signals (repeating cycle)
Time Slot 1: Signal A (User 1)
Time Slot 2: Signal B (User 2)
Time Slot 3: Signal C (User 3)
...

Visual:


Real-world example:

  • Mobile networks (e.g., Ncell’s 2G/3G): TDM assigns time slots to multiple users on the same frequency. For example, in GSM, 8 time slots per frame allow 8 users to share a single frequency band.
  • Digital telephony (PSTN): TDM enables multiple phone calls over a single copper wire by interleaving samples (e.g., 8 kbps per call in T1 lines).

Worked example: A TDM system with 4 users and 1 ms slots per user:

  • Cycle time: 4 ms (4 users × 1 ms).
  • If User 1 transmits at 100 kbps, their effective bandwidth is 25 kbps (100 kbps × 1/4 time share).

Variants:

  • Synchronous TDM (STDM): Fixed slots, even if some users are idle (inefficient).
  • Statistical TDM (STDM): Dynamically allocates slots to active users (used in modern networks).

1.3 Wavelength Division Multiplexing (WDM)

How it works: WDM is the optical equivalent of FDM, using different wavelengths (colors) of light to transmit multiple signals over a single fiber. Dense WDM (DWDM) packs 40+ channels into a fiber, while Coarse WDM (CWDM) uses fewer, wider-spaced channels.

Fiber Optic ChannelWavelength 1 (1550 nm)
DWDM: Multiple wavelengths in a single fiber (simplified)
Wavelength 1 (1550 nm): Channel 1 (Data)
Wavelength 2 (1552 nm): Channel 2 (Voice)
...
Wavelength 40 (1588 nm): Channel 40 (Video)

Visual:


Real-world example:

  • Internet backbone (e.g., NTC’s fiber networks): DWDM enables terabits per second by multiplexing hundreds of 10 Gbps channels over a single fiber.
  • Undersea cables (e.g., SEA-ME-WE): WDM carries international traffic between continents with minimal loss.

Worked example: A DWDM system with 80 channels, each at 10 Gbps:

  • Total capacity: 800 Gbps (80 × 10 Gbps).
  • If 20% of channels are reserved for emergency traffic (e.g., Ncell’s 911 services), 640 Gbps remains for commercial use.

1.4 Comparison Table: FDM vs. TDM vs. WDM

Feature FDM TDM WDM
Channel division Frequency bands Time slots Wavelengths (light colors)
Medium Copper, radio, fiber Copper, radio, fiber Fiber only
Simultaneity Yes (parallel) No (sequential) Yes (parallel)
Example Cable TV, mobile 4G bands GSM, T1 lines Internet backbone, DWDM
Advantage Simple, low latency Efficient for digital data Highest capacity (fiber)
Disadvantage Bandwidth fragmentation Idle slots waste capacity Expensive equipment

2. Switching Techniques: Circuit vs. Packet vs. Message

Switching determines how data travels through a network. The choice affects latency, cost, and flexibility.

2.1 Circuit Switching

How it works: A dedicated path is established for the entire duration of the communication (e.g., phone call). The circuit remains reserved even if no data is transmitted.

Dedicated PathDedicated PathDedicated PathSourceSwitch 1Switch 2Destination
Circuit switching: End-to-end dedicated path (e.g., phone call)
User A ---[Dedicated Path]---> User B

Visual:


Real-world example:

  • Traditional phone networks (PSTN): When you dial a number, a circuit is reserved from your phone to the recipient’s phone until you hang up.
  • ISDN (Integrated Services Digital Network): Used for fax machines and early VoIP, where a dedicated channel is allocated for the call.

Advantages:

  • Guaranteed bandwidth and low latency (ideal for real-time services).
  • Simple to implement for constant-bit-rate traffic (e.g., voice).

Disadvantages:

  • Inefficient: Bandwidth is wasted when no data is sent (e.g., silent pauses in a conversation).
  • No sharing: Resources cannot be reused for other connections.
  • Setup delay: Time to establish the circuit (e.g., dial-up connection time).

Worked example: A circuit-switched network with 1 Mbps capacity:

  • If User A makes a 64 kbps voice call, the entire 1 Mbps is reserved for 30 seconds, even if only 64 kbps is used.
  • Wasted bandwidth: 93.6% (936 kbps unused).

2.2 Packet Switching

How it works: Data is divided into small packets, each with a header (source/destination, sequence number). Packets take independent paths, are reassembled at the destination. Used by the internet and modern networks.

Packet 1Packet 1 (re-routed)Packet 2Packet 1 + Packet 2 (reassembled)SourceRouter 1Router 2Destination
Packet switching: Independent paths and reassembly
User A ---[Packet 1]---> Router 1 ---[Packet 3]---> User B
               |                     ^
               |                     |
               v                     |
        Router 2 ---[Packet 2]------|

Visual:


Real-world example:

  • Internet (e.g., eSewa transactions): Your payment request is split into packets, routed via multiple servers, and reassembled at the bank’s end.
  • WhatsApp messages: Text, images, and videos are packet-switched to deliver efficiently.

Phases of Packet Switching:

  1. Fragmentation: Large data is split into packets (e.g., 1500-byte MTU for Ethernet).
  2. Routing: Packets take different paths based on network conditions (e.g., shortest path, least congestion).
  3. Buffering: Routers hold packets temporarily if the next hop is busy.
  4. Reassembly: Destination device reassembles packets in order.

Worked example: Sending a 4 KB file via packet switching (MTU = 1500 bytes):

  • Packets: 3 (2 × 1500 bytes + 1 × 1000 bytes).
  • Path:
    • Packet 1: A → Router X → B (delay: 10 ms).
    • Packet 2: A → Router Y → B (delay: 12 ms).
    • Packet 3: A → Router X → Router Z → B (delay: 15 ms).
  • Reassembly at B: Ordered as Packet 1 → 2 → 3 (total delay: 15 ms).

Advantages:

  • Efficient: Bandwidth is shared (no wasted capacity).
  • Flexible: Can adapt to network failures (e.g., rerouting around a damaged fiber).
  • Scalable: Supports millions of users (e.g., YouTube streams).

Disadvantages:

  • Variable delay: Packets may arrive out of order or lost (requires retransmission).
  • Overhead: Headers add ~20–40 bytes per packet.

2.3 Message Switching

How it works: Entire messages are stored at intermediate nodes until the destination is ready. Rarely used today but historically important (e.g., early email systems).

Comparison Table: Switching Techniques

Feature Circuit Switching Packet Switching Message Switching
Path allocation Dedicated (end-to-end) Shared (per packet) Shared (per message)
Latency Low (fixed path) Variable (queuing delays) High (storage delays)
Bandwidth use Inefficient (wasted) Efficient (shared) Moderate (storage overhead)
Example Phone calls, ISDN Internet, WhatsApp Early email (ARPANET)
Best for Real-time (voice/video) Data (web, emails) Batch processing

3. Quality of Service (QoS): Ensuring Performance

QoS mechanisms prioritize critical traffic (e.g., video calls) over less urgent data (e.g., file downloads). Key techniques include prioritization, buffering, and traffic shaping.

3.1 QoS Techniques

  1. Prioritization:
    • Assigns higher priority to delay-sensitive traffic (e.g., VoIP, video).
    • Example: In a router, VoIP packets get precedence over FTP downloads.
[object Object][object Object][object Object]SourceRouter 1Router 2Destination
QoS in action: Prioritized paths for real-time traffic (e.g., VoIP)
  1. Buffering:

    • Stores packets temporarily to smooth out bursts (e.g., buffering in YouTube).
    • Risk: Excessive buffering causes delay (jitter).
  2. Traffic Shaping:

    • Controls the rate of traffic sent into a network to avoid congestion.
    • Example: Limiting a user’s upload speed to 1 Mbps during peak hours.
  3. Resource Reservation (RSVP):

    • Reserves bandwidth for specific flows (e.g., live streaming on Daraz).
  4. Congestion Avoidance:

    • Uses algorithms like Random Early Detection (RED) to drop packets before queues overflow.

Visual:


3.2 QoS in Real-World Systems

  • eSewa: During Diwali, transaction packets (e.g., festival bonuses) are prioritized to avoid timeouts.
  • Ncell’s 4G/5G: VoIP calls get lower latency than background app updates.
  • YouTube: Adaptive bitrate streaming adjusts video quality based on network conditions (QoS-driven).

Worked example: A router handles three flows:

  1. VoIP call (20 kbps, max delay: 100 ms).
  2. Video stream (1 Mbps, max delay: 500 ms).
  3. File download (10 Mbps, no delay constraints).

QoS policy:

  • Priority 1: VoIP (strict priority queue).
  • Priority 2: Video (weighted fair queueing).
  • Priority 3: File download (best-effort).

Result:

  • VoIP never waits; video gets 20% of bandwidth; file download fills remaining capacity.

4. Multiplexing and Switching in Layered Models

The OSI and TCP/IP models show how multiplexing and switching interact across layers.

ApplicationDataTransportSegmentNetworkPacketData LinkFramePhysicalBits
Multiplexing/switching in OSI model: Packets (Network) and frames (Data Link) carry multiplexed signals
Application (HTTP, DNS) --> Transport (TCP/UDP multiplexing) --> Network (IP routing) --> Data Link (MAC switching) --> Physical (FDM/TDM/WDM)

Key points:

  • Transport layer (Layer 4): TCP/UDP multiplex multiple apps (e.g., browser + WhatsApp) over one IP connection.
  • Network layer (Layer 3): IP routing (packet switching) determines paths.
  • Data link layer (Layer 2): Switches use MAC addresses to forward frames.

Visual:



## In the Real World

  1. eSewa’s Transaction Prioritization:

    • During peak hours (e.g., festival bonuses), eSewa uses QoS prioritization to ensure payment packets are processed before less urgent requests. This reduces timeouts for users trying to send money to relatives.
  2. Ncell’s 4G TDM/FDM:

    • Ncell’s 4G network uses TDM to assign time slots to multiple users on the same frequency and FDM to separate voice (1800 MHz) and data (2100 MHz) bands. This allows thousands of users to share the same cell tower efficiently.
  3. YouTube’s Adaptive Bitrate Streaming:

    • YouTube uses QoS techniques like traffic shaping and buffering to adjust video quality in real-time. If your network is congested (e.g., during Kathmandu traffic jams), YouTube switches to a lower bitrate to avoid buffering.
  4. Daraz’s Order Queue:

    • Daraz’s backend uses packet switching to route orders through multiple servers. During sales (e.g., Dashain), QoS prioritization ensures high-priority orders (e.g., same-day delivery) are processed before standard orders.
  5. NTC’s Fiber-Optic Backbone:

    • NTC’s national fiber network uses DWDM to multiplex hundreds of 10 Gbps channels over a single fiber, enabling high-speed internet across Nepal. This is critical for services like online banking and video conferencing.

## Exam Tip

  1. Differentiate multiplexing types:

    • FDM = frequency bands (e.g., cable TV).
    • TDM = time slots (e.g., GSM).
    • WDM = wavelengths (e.g., fiber optics).
    • Exam trick: Always draw a diagram for FDM/TDM/WDM questions.
  2. Packet switching phases:

    • Memorize: Fragmentation → Routing → Buffering → Reassembly.
    • Worked example: Trace a packet’s path with delays (e.g., "Packet 1 takes 10 ms, Packet 2 takes 12 ms...").
  3. QoS mechanisms:

    • Prioritization (VoIP > video > file transfer).
    • Buffering (YouTube’s playout buffer).
    • Traffic shaping (Ncell’s speed throttling).
    • Exam tip: Relate QoS to real systems (e.g., "How does eSewa ensure transactions don’t time out?").
  4. Switching comparisons:

    • Circuit = dedicated path (phone calls).
    • Packet = shared path (internet).
    • Message = store-and-forward (obsolete).
    • Table memorization: Use the comparison table above for quick recall.
  5. Layered models:

    • Multiplexing happens at Transport (TCP/UDP) and Physical (FDM/TDM) layers.
    • Switching happens at Data Link (MAC switching) and Network (IP routing) layers.
    • Exam tip: Draw the OSI model and label where multiplexing/switching occurs.
  6. Common pitfalls:

    • FDM vs. TDM: FDM is for analog (e.g., radio); TDM is for digital (e.g., GSM).
    • QoS vs. QoE: QoS is technical (bandwidth, delay); QoE is user experience (e.g., smooth video playback).
    • Packet loss: Can happen due to congestion (buffer overflow) or errors (corrupted packets).

Based on the TU BIT syllabus for Network and Data Communications (BIT254), unit 9.

Discussion

Loading…