diff options
| author | mo khan <mo@mokhan.ca> | 2025-09-27 16:19:34 -0600 |
|---|---|---|
| committer | mo khan <mo@mokhan.ca> | 2025-09-27 16:19:34 -0600 |
| commit | ec669fe67961aba8cab451f9fa8f1a4badcc2a61 (patch) | |
| tree | 327ff6f6e00597d1ce308cfa5562c2fd0f0d2d6d /assignments | |
| parent | bb3bea7ac6aae6e7b10f1868af59f51781e53632 (diff) | |
tidy up a3
Diffstat (limited to 'assignments')
| -rw-r--r-- | assignments/3/README.md | 1278 |
1 files changed, 36 insertions, 1242 deletions
diff --git a/assignments/3/README.md b/assignments/3/README.md index 26c7796..50b401c 100644 --- a/assignments/3/README.md +++ b/assignments/3/README.md @@ -1,1269 +1,63 @@ -# COMP-347: Computer Networks -## Assignment 3 - -**Student Name:** [Your Name] -**Student ID:** [Your Student ID] -**Time Spent:** [Hours spent on assignment] -**Due:** After completion of Units 6 and 7 - --- - -## Part 1: Short Answer Questions (30%) - -### 1.1 Anchor MSC in GSM Networks (5%) - -The **Anchor MSC (Mobile Switching Center)** plays a crucial role in GSM (Global System for Mobile Communications) networks, particularly in managing mobile subscriber mobility and maintaining service continuity during handovers. - -#### Primary Functions: - -#### 1. Home Location Register (HLR) Interface -- **Subscriber Authentication**: The Anchor MSC maintains the primary connection to the subscriber's HLR, which contains the master copy of subscriber profile data -- **Service Profile Management**: Stores and manages subscriber service capabilities, restrictions, and supplementary services -- **Location Management**: Coordinates with the HLR to track the subscriber's current location area and serving MSC - -#### 2. Call Routing and Management -- **Incoming Call Routing**: Acts as the initial point of contact for incoming calls to a mobile subscriber, routing calls to the current serving MSC -- **Call Continuity**: Ensures seamless call continuation during inter-MSC handovers by maintaining call state information -- **Billing Coordination**: Centralizes billing records and coordinates charging information across multiple serving MSCs - -#### 3. Handover Coordination -- **Inter-MSC Handover Support**: When a mobile subscriber moves between different MSC coverage areas during an active call, the Anchor MSC coordinates the handover process -- **Resource Management**: Maintains circuit connections and manages radio resources during complex handover scenarios -- **Quality Maintenance**: Ensures call quality is preserved during mobility events - -#### 4. Visitor Location Register (VLR) Coordination -- **Registration Management**: Coordinates subscriber registration/deregistration across multiple VLRs as the subscriber roams -- **Authentication Coordination**: Manages authentication procedures when subscribers roam between different MSC areas -- **Temporary Identity Management**: Handles Temporary Mobile Subscriber Identity (TMSI) allocation and management - -#### 5. Network Optimization Benefits -- **Reduced HLR Load**: By serving as an intermediary, the Anchor MSC reduces the number of direct HLR queries from multiple serving MSCs -- **Improved Performance**: Centralized management of subscriber data reduces lookup times and improves call setup performance -- **Enhanced Mobility**: Provides seamless service as subscribers move between different network areas - -#### Operational Scenario: -When a GSM subscriber roams from their home area to a different MSC area: -1. The new serving MSC registers the subscriber's presence -2. The Anchor MSC updates the HLR with the new location information -3. For incoming calls, the HLR directs calls to the Anchor MSC -4. The Anchor MSC then routes calls to the current serving MSC -5. During handovers, the Anchor MSC maintains call state and coordinates resource allocation - -**Key Insight**: The Anchor MSC concept enables efficient mobility management in GSM networks by centralizing subscriber management functions while allowing distributed call processing, thereby optimizing both network performance and subscriber experience during roaming scenarios. - -### 1.2 LTE Network Characteristics (5%) - -**LTE (Long Term Evolution)** represents a significant advancement in cellular network technology, introducing fundamental changes in radio access network architecture and capabilities compared to previous generations. - -#### Main Characteristics of LTE Radio Access Networks: - -#### 1. All-IP Architecture -- **Packet-Switched Only**: LTE eliminates circuit-switched voice calls, using Voice over LTE (VoLTE) for all voice communications -- **Flat Network Architecture**: Simplified network topology with fewer network elements compared to 3G -- **IP Multimedia Subsystem (IMS)**: Integrated multimedia services delivered over IP - -#### 2. OFDMA and SC-FDMA Technologies -- **Orthogonal Frequency Division Multiple Access (OFDMA)**: Used in downlink for efficient spectrum utilization and multi-user access -- **Single Carrier FDMA (SC-FDMA)**: Used in uplink to reduce peak-to-average power ratio and improve battery life -- **Flexible Bandwidth**: Supports 1.4, 3, 5, 10, 15, and 20 MHz channel bandwidths - -#### 3. MIMO Technology -- **Multiple Input Multiple Output (MIMO)**: Uses multiple antennas at both transmitter and receiver -- **Spatial Multiplexing**: Increases data throughput by transmitting multiple data streams simultaneously -- **Diversity Gain**: Improves signal reliability in fading environments - -#### 4. Advanced Radio Resource Management -- **Dynamic Resource Allocation**: Real-time allocation of radio resources based on traffic demand and channel conditions -- **Link Adaptation**: Automatic adjustment of modulation and coding schemes based on channel quality -- **Inter-Cell Interference Coordination (ICIC)**: Coordinates resource usage between neighboring cells - -#### How LTE Differs from Previous Generations: - -#### Architecture Differences: - -**2G/3G Architecture:** -- **Circuit-Switched Core**: Separate networks for voice (circuit-switched) and data (packet-switched) -- **Hierarchical Network**: Multiple network elements (RNC, BSC, MSC) -- **Voice Priority**: Networks primarily designed for voice services - -**LTE Architecture:** -- **All-IP Core**: Single packet-switched network for all services -- **Flat Architecture**: Evolved NodeB (eNodeB) directly connects to core network -- **Data-Centric**: Optimized for high-speed data transmission - -#### Performance Improvements: - -| Aspect | 3G (UMTS) | LTE | -|--------|-----------|-----| -| **Downlink Speed** | Up to 42 Mbps (HSPA+) | Up to 300 Mbps | -| **Uplink Speed** | Up to 5.7 Mbps | Up to 75 Mbps | -| **Latency** | 100-500 ms | <10 ms | -| **Spectral Efficiency** | 1-2 bps/Hz | 3-4 bps/Hz | - -#### Key Technological Advances: - -#### 1. Radio Interface Evolution -- **CDMA → OFDMA**: Transition from Code Division to Orthogonal Frequency Division Multiple Access -- **Advanced Modulation**: Support for 64-QAM and higher-order modulation schemes -- **Adaptive Antenna Systems**: Beamforming and advanced antenna technologies - -#### 2. Protocol Stack Simplification -- **Reduced Layers**: Streamlined protocol stack compared to 3G -- **Header Compression**: More efficient header compression techniques -- **Fast Retransmission**: Hybrid ARQ (HARQ) for rapid error recovery - -#### 3. Mobility Management -- **Seamless Handovers**: Faster handover procedures with minimal service interruption -- **Inter-RAT Mobility**: Smooth transitions between LTE and legacy networks (2G/3G) -- **Self-Organizing Networks (SON)**: Automated network optimization and configuration - -#### 4. Quality of Service (QoS) -- **Evolved Packet System (EPS) Bearers**: Fine-grained QoS control for different traffic types -- **Policy Control**: Dynamic policy enforcement based on subscriber profiles and network conditions -- **Guaranteed Bit Rate (GBR)**: Service-specific bandwidth guarantees - -**Key Insight**: LTE represents a fundamental paradigm shift from circuit-switched, voice-centric networks to an all-IP, data-optimized architecture that provides significantly higher throughput, lower latency, and improved spectral efficiency while supporting seamless multimedia services and enhanced mobility management. - -### 1.3 CSMA/CD Protocol (5%) - -**CSMA/CD** stands for **Carrier Sense Multiple Access with Collision Detection**, a media access control protocol used in traditional Ethernet networks to manage shared medium access among multiple nodes. - -#### How CSMA/CD Works: - -#### 1. Carrier Sense (CS) -- **Listen Before Transmit**: Before transmitting, a node listens to the medium to detect if another transmission is already in progress -- **Channel Assessment**: If the channel is busy, the node waits until it becomes idle -- **Persistence Strategy**: Once idle is detected, the node may wait a brief interframe gap before attempting transmission - -#### 2. Multiple Access (MA) -- **Shared Medium**: Multiple nodes share the same physical transmission medium (bus topology) -- **Contention-Based**: All nodes compete for access to the medium using the same protocol rules -- **Distributed Control**: No central authority controls medium access; all decisions are made locally by each node - -#### 3. Collision Detection (CD) -- **Simultaneous Transmission Monitoring**: While transmitting, nodes continuously monitor the medium to detect collisions -- **Signal Comparison**: Compare transmitted signal with received signal to identify interference from other transmissions -- **Early Abort**: Upon detecting collision, immediately stop transmission to minimize medium occupation time - -#### 4. Collision Handling Procedure -When a collision is detected: -1. **Jam Signal**: Transmit a 32-bit or 48-bit jam signal to ensure all nodes detect the collision -2. **Exponential Backoff**: Each involved node waits a random time before retransmitting -3. **Backoff Algorithm**: Wait time = random(0, 2^n - 1) × slot time, where n = number of consecutive collisions -4. **Retry Limit**: After 16 consecutive collisions, the frame is discarded - -#### Importance of RTT in CSMA/CD: - -The **Round-Trip Time (RTT)** is critical for CSMA/CD's proper operation due to the **collision detection window**: - -#### 1. Collision Detection Window -- **Maximum Detection Time**: RTT represents the maximum time needed to detect a collision anywhere on the network -- **Worst-Case Scenario**: Node A starts transmitting just as Node B (at maximum distance) begins transmission -- **Signal Propagation**: Time for A's signal to reach B plus time for B's collision signal to return to A - -#### 2. Minimum Frame Size Requirement -- **Frame Transmission Time**: Must be ≥ 2 × propagation delay (RTT) -- **Collision Detection Guarantee**: Ensures transmitting node can detect collision before finishing frame transmission -- **Ethernet Standard**: 64-byte minimum frame size ensures collision detection on maximum cable length - -#### 3. Network Diameter Limitation -- **Maximum Cable Length**: RTT limits the physical size of collision domain -- **Signal Attenuation**: Longer cables increase propagation delay and reduce signal strength -- **Timing Constraints**: RTT must remain small enough for reliable collision detection - -#### 4. Slot Time Calculation -- **Slot Time**: Basic timing unit = 2 × maximum propagation delay -- **Backoff Intervals**: Random backoff periods are multiples of slot time -- **Network Synchronization**: Ensures all nodes use consistent timing for collision avoidance - -#### Mathematical Relationship: -``` -Minimum Frame Time ≥ 2 × (Cable Length ÷ Propagation Speed + Processing Delays) -``` - -For traditional Ethernet: -- Maximum cable length: 2.5 km -- Propagation speed: ~2×10^8 m/s -- RTT: ~25 μs -- Minimum frame size: 64 bytes (512 bits) -- Slot time: 512 bit times - -#### Protocol Efficiency Impact: -- **Short RTT**: Allows smaller minimum frames, higher efficiency, larger networks -- **Long RTT**: Requires larger minimum frames, reduces efficiency, limits network size -- **Collision Domain**: RTT determines maximum collision domain size - -**Key Insight**: RTT is fundamental to CSMA/CD because it defines the collision detection window, determines minimum frame size requirements, and limits the physical extent of collision domains, directly affecting network efficiency and scalability. - -### 1.4 CSMA/CA Protocol (5%) - -**CSMA/CA** stands for **Carrier Sense Multiple Access with Collision Avoidance**, a media access control protocol primarily used in wireless networks (such as 802.11 Wi-Fi) where collision detection is impractical due to the wireless medium characteristics. - -#### How CSMA/CA Works: - -#### 1. Carrier Sense (CS) -- **Physical Carrier Sense**: Listen to the wireless medium to detect ongoing transmissions -- **Virtual Carrier Sense**: Use Network Allocation Vector (NAV) from RTS/CTS or other control frames -- **Clear Channel Assessment (CCA)**: Determine if medium is idle before attempting transmission -- **Energy Detection**: Monitor RF energy levels to identify channel activity - -#### 2. Multiple Access (MA) -- **Shared Wireless Medium**: Multiple stations compete for access to the same radio frequency spectrum -- **Hidden Terminal Problem**: Stations may not hear each other due to distance or obstacles -- **Distributed Coordination**: No centralized control; stations coordinate access through distributed algorithms - -#### 3. Collision Avoidance (CA) -Unlike collision detection, CSMA/CA attempts to **prevent collisions** rather than detect them after they occur: - -#### Basic CSMA/CA Operation: -1. **Channel Sensing**: Station senses the medium for a minimum time period (DIFS - Distributed Inter-Frame Space) -2. **Random Backoff**: If medium is idle, station waits a random backoff time before transmitting -3. **Transmission**: If medium remains idle after backoff, station transmits the frame -4. **Acknowledgment**: Receiver sends ACK frame to confirm successful reception -5. **Retransmission**: If no ACK received, sender assumes collision and retransmits after backoff - -#### How Collisions Are Avoided: - -#### 1. Random Backoff Mechanism -- **Contention Window**: Each station selects random backoff time from [0, CW-1] × slot time -- **Exponential Backoff**: After collision, contention window doubles (CW = CW × 2) -- **Collision Probability Reduction**: Random timing reduces likelihood of simultaneous transmission -- **Fairness**: All stations have equal probability of accessing the medium - -#### 2. Inter-Frame Spacing (IFS) -Different frame types use different inter-frame spaces to establish priority: -- **SIFS (Short IFS)**: Highest priority for ACKs and CTS frames -- **DIFS (Distributed IFS)**: Standard priority for data frames -- **EIFS (Extended IFS)**: Used after corrupted frame reception -- **Priority Access**: Critical frames get preferential medium access - -#### 3. Request-to-Send/Clear-to-Send (RTS/CTS) -**Optional mechanism for avoiding hidden terminal collisions:** - -**RTS/CTS Handshake:** -1. **RTS Frame**: Sender transmits Request-to-Send to receiver -2. **CTS Frame**: Receiver responds with Clear-to-Send if medium available -3. **NAV Setting**: Both RTS and CTS set Network Allocation Vector in other stations -4. **Data Transmission**: Sender transmits data frame after successful RTS/CTS exchange -5. **ACK Frame**: Receiver acknowledges data reception - -**Benefits:** -- **Hidden Terminal Solution**: CTS frame alerts hidden terminals about upcoming transmission -- **Collision Reduction**: Reduces collision probability for large data frames -- **Bandwidth Reservation**: Virtual carrier sensing reserves medium for transmission - -#### 4. Network Allocation Vector (NAV) -- **Virtual Carrier Sensing**: Maintains timer indicating when medium will be busy -- **Duration Field**: Frames carry duration information for NAV updates -- **Medium Reservation**: Stations defer transmission while NAV > 0 -- **Collision Avoidance**: Prevents transmissions that would cause collisions - -#### 5. Binary Exponential Backoff -**Collision Response Mechanism:** -- **Initial Window**: Start with minimum contention window (CW_min) -- **Window Doubling**: After each collision, CW = min(CW × 2, CW_max) -- **Random Selection**: Choose backoff = random[0, CW-1] × slot_time -- **Window Reset**: Reset CW to CW_min after successful transmission - -#### 6. Frame Retry and Timeout -- **ACK Timeout**: If ACK not received within specified time, assume collision -- **Retry Limit**: Maximum number of retransmission attempts before frame discard -- **Exponential Backoff**: Apply backoff algorithm for each retry attempt - -#### CSMA/CA vs CSMA/CD Comparison: - -| Aspect | CSMA/CA | CSMA/CD | -|--------|---------|---------| -| **Medium** | Wireless | Wired | -| **Collision Handling** | Avoidance | Detection | -| **Collision Detection** | Not possible | Real-time | -| **Overhead** | Higher (RTS/CTS, ACK) | Lower | -| **Efficiency** | Lower due to avoidance | Higher when collisions are rare | -| **Hidden Terminal** | Addressed by RTS/CTS | Not applicable | - -**Key Insight**: CSMA/CA compensates for the inability to detect collisions in wireless media by implementing sophisticated avoidance mechanisms including random backoff, virtual carrier sensing, RTS/CTS handshakes, and prioritized channel access, trading some efficiency for reliability in challenging wireless environments. - -### 1.5 Data Link Layer Error Detection/Correction (5%) - -The data link layer employs various techniques to handle transmission errors that may occur due to noise, interference, or signal attenuation in communication channels. - -## Error Detection Techniques: - -#### 1. Parity Check -- **Single Parity**: Adds one parity bit to detect single-bit errors -- **Even Parity**: Total number of 1s (including parity bit) is even -- **Odd Parity**: Total number of 1s (including parity bit) is odd -- **Limitation**: Cannot detect even numbers of bit errors - -#### 2. Checksum -- **Internet Checksum**: Sum all data words, take 1's complement (used in IP, TCP, UDP) -- **Fletcher Checksum**: Uses modular arithmetic for improved error detection -- **Advantages**: Simple implementation, good for random errors -- **Limitations**: May miss certain systematic error patterns - -#### 3. Cyclic Redundancy Check (CRC) -- **Polynomial-Based**: Uses generator polynomial to create check sequence -- **Frame Check Sequence (FCS)**: CRC bits appended to frame -- **Detection Capability**: Detects all single-bit, double-bit, odd number of bits, and burst errors ≤ r bits (where r = degree of generator polynomial) -- **Common Polynomials**: CRC-16, CRC-32, CRC-CCITT -- **High Reliability**: Very low probability of undetected errors - -#### 4. Two-Dimensional Parity -- **Block Structure**: Arrange data in rows and columns -- **Row Parity**: Calculate parity for each row -- **Column Parity**: Calculate parity for each column -- **Enhanced Detection**: Can detect and correct single-bit errors, detect some multi-bit errors - -## Error Correction Techniques: - -#### 1. Forward Error Correction (FEC) -**Hamming Codes:** -- **Single Error Correction**: Can correct single-bit errors automatically -- **Redundancy**: Requires 2^r ≥ m + r + 1 (where m = data bits, r = parity bits) -- **Syndrome Decoding**: Uses parity check equations to locate error position -- **Example**: Hamming(7,4) code uses 4 data bits, 3 parity bits - -**Reed-Solomon Codes:** -- **Block Codes**: Operate on symbols rather than individual bits -- **Burst Error Correction**: Excellent for correcting burst errors -- **Applications**: Used in CDs, DVDs, QR codes, satellite communications -- **Capability**: Can correct up to t symbol errors with 2t redundant symbols - -#### 2. Convolutional Codes -- **Continuous Encoding**: Encode data stream continuously using shift registers -- **Memory**: Output depends on current and previous input bits -- **Viterbi Decoding**: Maximum likelihood decoding algorithm -- **Applications**: Widely used in wireless communications, satellite links - -#### 3. Turbo Codes -- **Iterative Decoding**: Uses two or more constituent codes with iterative decoding -- **Near Shannon Limit**: Approaches theoretical maximum error correction capability -- **Applications**: 3G/4G cellular networks, satellite communications -- **Complexity**: Higher computational complexity but superior performance - -## Automatic Repeat Request (ARQ): - -#### 1. Stop-and-Wait ARQ -- **Simple Protocol**: Send one frame, wait for ACK before sending next -- **Positive ACK**: Receiver sends acknowledgment for correctly received frames -- **Timeout**: Sender retransmits if no ACK received within timeout period -- **Sequence Numbers**: Prevents duplicate frame acceptance - -#### 2. Go-Back-N ARQ -- **Sliding Window**: Multiple frames can be outstanding -- **Cumulative ACK**: ACK n acknowledges all frames up to n -- **Error Recovery**: Retransmit all frames from error point onwards -- **Efficiency**: Better throughput than stop-and-wait - -#### 3. Selective Repeat ARQ -- **Individual ACK**: Each frame acknowledged individually -- **Selective Retransmission**: Only retransmit errored frames -- **Buffer Requirements**: Receiver must buffer out-of-order frames -- **Optimal Efficiency**: Best throughput but most complex - -## Hybrid Techniques: - -#### 1. Hybrid ARQ (HARQ) -- **FEC + ARQ Combination**: Uses error correction with retransmission backup -- **Type I HARQ**: FEC for error correction, ARQ for error detection -- **Type II HARQ**: Incremental redundancy - additional parity bits sent on retransmission -- **Applications**: LTE, 5G, and other modern wireless systems - -#### 2. Adaptive Error Control -- **Dynamic Selection**: Choose error control method based on channel conditions -- **Channel Quality Feedback**: Adjust redundancy based on measured error rates -- **Optimization**: Balance between throughput and reliability - -## Implementation Considerations: - -| Technique | Detection | Correction | Overhead | Complexity | Applications | -|-----------|-----------|------------|----------|------------|--------------| -| **Parity** | Limited | No | Low | Very Low | Simple systems | -| **Checksum** | Good | No | Low | Low | Internet protocols | -| **CRC** | Excellent | No | Medium | Medium | Ethernet, Wi-Fi | -| **Hamming** | Good | Single-bit | High | Medium | Memory systems | -| **Reed-Solomon** | Excellent | Multiple | High | High | Storage, broadcast | -| **ARQ** | Perfect | Perfect | Variable | Medium | Most data networks | - -**Key Insight**: Data link layer error control combines detection techniques (parity, checksum, CRC) with correction methods (FEC, ARQ) to provide reliable data transmission, with the choice of technique depending on channel characteristics, performance requirements, and acceptable complexity trade-offs. - -### 1.6 Wi-Fi Network Standards (5%) - -Modern Wi-Fi technology encompasses several IEEE 802.11 standards that have evolved to provide higher data rates, improved reliability, and enhanced features for today's wireless networking needs. - -## Current Wi-Fi Standards in Industry Use: - -### 1. 802.11n (Wi-Fi 4) - 2009 -**Link Characteristics:** -- **Frequency Bands:** 2.4 GHz and 5 GHz (dual-band) -- **Channel Bandwidth:** 20 MHz and 40 MHz channels -- **Data Rates:** Up to 600 Mbps (theoretical maximum) -- **MIMO Technology:** Up to 4×4 spatial streams -- **Range:** ~70m indoor, ~250m outdoor -- **Modulation:** OFDM with up to 64-QAM -- **Backward Compatibility:** Compatible with 802.11a/b/g - -### 2. 802.11ac (Wi-Fi 5) - 2013 -**Link Characteristics:** -- **Frequency Band:** 5 GHz only -- **Channel Bandwidth:** 20, 40, 80, and 160 MHz channels -- **Data Rates:** Up to 6.93 Gbps (theoretical maximum) -- **MIMO Technology:** Up to 8×8 MU-MIMO (Multi-User MIMO) -- **Range:** ~35m indoor, ~120m outdoor -- **Modulation:** OFDM with up to 256-QAM -- **Beamforming:** Explicit beamforming for improved signal focus -- **Wave 1 vs Wave 2:** Wave 2 adds MU-MIMO and 160 MHz channels - -### 3. 802.11ax (Wi-Fi 6/6E) - 2019/2020 -**Link Characteristics:** -- **Frequency Bands:** 2.4 GHz, 5 GHz, and 6 GHz (Wi-Fi 6E) -- **Channel Bandwidth:** 20, 40, 80, and 160 MHz channels -- **Data Rates:** Up to 9.6 Gbps (theoretical maximum) -- **MIMO Technology:** Up to 8×8 MU-MIMO (uplink and downlink) -- **Range:** Similar to 802.11ac but more efficient in dense environments -- **Modulation:** OFDMA with up to 1024-QAM -- **Key Features:** OFDMA, Target Wake Time (TWT), BSS Coloring - -### 4. 802.11be (Wi-Fi 7) - 2024 (Emerging) -**Link Characteristics:** -- **Frequency Bands:** 2.4 GHz, 5 GHz, and 6 GHz (tri-band) -- **Channel Bandwidth:** Up to 320 MHz channels -- **Data Rates:** Up to 46 Gbps (theoretical maximum) -- **MIMO Technology:** Up to 16×16 MU-MIMO -- **Advanced Features:** Multi-Link Operation (MLO), 4K-QAM modulation - -## Detailed Standard Comparison: - -| Standard | Year | Frequency | Max Bandwidth | Max Rate | MIMO | Key Features | -|----------|------|-----------|---------------|----------|------|--------------| -| **802.11n** | 2009 | 2.4/5 GHz | 40 MHz | 600 Mbps | 4×4 | First MIMO, dual-band | -| **802.11ac** | 2013 | 5 GHz | 160 MHz | 6.93 Gbps | 8×8 | MU-MIMO, 256-QAM | -| **802.11ax** | 2019 | 2.4/5/6 GHz | 160 MHz | 9.6 Gbps | 8×8 | OFDMA, 1024-QAM, TWT | -| **802.11be** | 2024 | 2.4/5/6 GHz | 320 MHz | 46 Gbps | 16×16 | MLO, 4K-QAM | - -## Technical Characteristics by Standard: - -### Physical Layer Features: -**802.11n:** -- **Guard Interval:** 400ns and 800ns options -- **Frame Aggregation:** A-MSDU and A-MPDU for efficiency -- **Space-Time Block Coding (STBC):** Improved reliability -- **Greenfield Mode:** 802.11n-only operation for maximum efficiency - -**802.11ac:** -- **Wider Channels:** 80 MHz and 160 MHz for higher throughput -- **More Spatial Streams:** Up to 8 spatial streams -- **Advanced Beamforming:** Standardized explicit beamforming -- **Downlink MU-MIMO:** Simultaneous transmission to multiple clients - -**802.11ax:** -- **OFDMA:** Orthogonal Frequency Division Multiple Access for efficiency -- **Uplink MU-MIMO:** Multi-user transmission in both directions -- **BSS Coloring:** Reduces interference between overlapping networks -- **Target Wake Time:** Power management for IoT devices - -### Industry Applications: - -**Enterprise Networks:** -- **802.11ax:** Predominant choice for new installations -- **High-Density Environments:** Airports, stadiums, conference centers -- **OFDMA Benefits:** Better performance with many connected devices - -**Home Networks:** -- **802.11ac:** Still widely deployed in existing installations -- **802.11ax:** Becoming standard for new home routers -- **Backward Compatibility:** Support for legacy devices - -**IoT and Industrial:** -- **2.4 GHz Bands:** Better wall penetration and range -- **Low Power Features:** TWT for battery-powered devices -- **Mesh Networks:** Wi-Fi 6 mesh systems for whole-home coverage - -**Public Wi-Fi:** -- **6 GHz Band:** Wi-Fi 6E reduces congestion in crowded areas -- **Higher Capacity:** Support for more simultaneous users -- **Quality of Service:** Better traffic prioritization - -### Performance Characteristics: - -**Range Considerations:** -- **5 GHz vs 2.4 GHz:** 5 GHz offers higher speeds but shorter range -- **6 GHz Band:** Highest speeds but most limited range -- **Beamforming:** Improves range and reliability across all modern standards - -**Interference Handling:** -- **Channel Bonding:** Wider channels increase susceptibility to interference -- **Dynamic Frequency Selection (DFS):** Avoids radar interference on 5 GHz -- **BSS Coloring:** Wi-Fi 6 feature reduces co-channel interference - -**Key Insight:** Modern Wi-Fi standards have evolved from simple OFDM-based systems to sophisticated multi-user, multi-band technologies that optimize spectrum efficiency, reduce latency, and support diverse applications from high-bandwidth streaming to low-power IoT devices, with each generation addressing specific limitations of previous standards while maintaining backward compatibility. - +title: "COMP-347: Computer Networks" +author: "munir khan - 3431709" +date: "September 2025" +subtitle: "Assignment 3" +institute: "Athabasca University" +geometry: margin=1in +fontsize: 11pt +linestretch: 1.0 --- -## Part 2: Long Answer Questions (70%) - -### 2.1 Code Division Multiple Access (CDMA) (15%) - -Code Division Multiple Access (CDMA) is a sophisticated channel access method that enables multiple users to share the same frequency spectrum simultaneously by assigning unique codes to each user. This research examines CDMA technology, focusing on Wideband CDMA (W-CDMA) used in 3G UMTS networks. - -## CDMA Technology Overview - -CDMA differs fundamentally from Time Division Multiple Access (TDMA) and Frequency Division Multiple Access (FDMA) by using mathematical coding techniques rather than time slots or frequency separation to distinguish between users. All users transmit simultaneously on the same frequency band, with separation achieved through orthogonal or quasi-orthogonal spreading codes. - -## Selected CDMA Scheme: Wideband CDMA (W-CDMA) - -**W-CDMA** is the air interface standard used in 3G UMTS (Universal Mobile Telecommunications System) networks, standardized by 3GPP (3rd Generation Partnership Project). This scheme represents an evolution from earlier CDMA implementations like IS-95. - -### How W-CDMA Works: - -#### 1. Spreading Process -**Direct Sequence Spread Spectrum:** -- Each user's data stream is multiplied by a unique spreading code (channelization code) -- The spreading code has a much higher bit rate (chip rate) than the original data -- W-CDMA uses a chip rate of 3.84 Mcps (Mega-chips per second) -- This spreads the signal across a 5 MHz bandwidth - -**Mathematical Representation:** -``` -Transmitted Signal = Data Stream × Spreading Code × Scrambling Code -``` - -#### 2. Channelization Codes -**Orthogonal Variable Spreading Factor (OVSF) Codes:** -- Uses Walsh-Hadamard codes that are perfectly orthogonal -- Variable length codes support different data rates -- Spreading factors range from 4 to 512 -- Higher spreading factors = lower data rates but better interference resistance - -**Code Tree Structure:** -- Codes organized in a binary tree structure -- Parent-child codes are orthogonal to each other -- Enables flexible bandwidth allocation - -#### 3. Scrambling Codes -**Gold Codes:** -- Long pseudo-random sequences (2^18 - 1 = 262,143 chips) -- Used to separate different cells and users -- Provide quasi-orthogonal separation -- Enable soft handoff between cells - -#### 4. Power Control -**Fast Power Control:** -- Adjusts transmission power 1500 times per second -- Compensates for near-far effect and fading -- Critical for maintaining signal quality and minimizing interference -- Uses feedback from receiver to base station - -### Detailed Operation: - -#### Uplink (Mobile to Base Station): -1. **Voice/Data Encoding:** User data is channel coded and interleaved -2. **Spreading:** Data multiplied by user-specific OVSF channelization code -3. **Scrambling:** Result multiplied by mobile-specific scrambling code -4. **Power Control:** Transmission power adjusted based on base station commands -5. **Transmission:** Signal transmitted across 5 MHz bandwidth - -#### Downlink (Base Station to Mobile): -1. **Code Allocation:** Base station assigns OVSF codes to different users -2. **Spreading:** Each user's data spread with their assigned code -3. **Scrambling:** All users' signals scrambled with cell-specific code -4. **Combining:** All spread signals combined and transmitted simultaneously -5. **Reception:** Mobile uses correlation with its assigned codes to extract data - -### Advanced W-CDMA Features: - -#### 1. Rake Receiver -- **Multipath Combining:** Combines multiple delayed copies of the same signal -- **Finger Assignment:** Each "finger" processes a different multipath component -- **Diversity Gain:** Improves signal quality by combining multipath signals -- **Adaptive:** Automatically tracks and combines strongest multipath components - -#### 2. Soft Handoff -- **Multiple Base Stations:** Mobile simultaneously connected to multiple cells -- **Seamless Transition:** No break in communication during handoff -- **Macro Diversity:** Combines signals from multiple base stations -- **Quality Improvement:** Better coverage at cell boundaries +# Part 1: Short Answer Questions (30%) -#### 3. Variable Data Rates -- **Multi-Rate Services:** Supports different data rates simultaneously -- **Code Rate Adaptation:** Changes spreading factor based on required data rate -- **Dynamic Allocation:** Real-time adjustment of resources based on demand +## 1.1 Anchor MSC in GSM Networks (5%) -## Advantages of CDMA over TDM and FDM: +The Anchor MSC coordinates HLR/VLR, call routing, and inter-MSC handovers to maintain call continuity and subscriber management during mobility. -### 1. Capacity Benefits -**Statistical Multiplexing:** -- Multiple users share the same spectrum simultaneously -- Capacity limited by interference rather than fixed time slots or frequencies -- Better utilization of available spectrum -- Graceful degradation as load increases +## 1.2 LTE Network Characteristics (5%) -**Voice Activity Factor:** -- Takes advantage of natural pauses in speech -- Users only interfere when actually transmitting -- Effective capacity gain of 2-3x over continuous transmission systems +LTE is an all-IP, flat architecture using OFDMA/SC-FDMA, MIMO, and advanced RRM. It delivers higher throughput, lower latency, and better spectral efficiency than 3G. -### 2. Security and Privacy -**Spread Spectrum Security:** -- Difficult to intercept or jam due to spreading -- Signals appear as noise to unauthorized receivers -- Each user has unique code sequence -- Inherent encryption through spreading process +## 1.3 CSMA/CD Protocol (5%) -### 3. Quality Benefits -**Interference Averaging:** -- Each user sees interference from all other users as white noise -- Better error performance compared to single-user interference -- Soft capacity limit rather than hard blocking +CSMA/CD: listen before transmit; detect collisions; send jam; binary exponential backoff. RTT determines minimum frame size and collision domain size. -**Multipath Resistance:** -- Rake receivers exploit multipath propagation -- Converts multipath fading into diversity gain -- Better performance in urban environments +## 1.4 CSMA/CA Protocol (5%) -### 4. Flexibility -**Dynamic Resource Allocation:** -- No fixed time slots or frequency assignments -- Adaptive data rates based on channel conditions and requirements -- Seamless integration of voice and data services -- Support for multimedia applications +CSMA/CA: avoid collisions via carrier sense, random backoff, SIFS/DIFS timing, optional RTS/CTS, and ACK-based reliability. Designed for wireless where collision detection is impractical. -## Comparison with TDM and FDM: +## 1.5 Data Link Layer Error Detection/Correction (5%) -| Aspect | CDMA | TDM | FDM | -|--------|------|-----|-----| -| **Separation Method** | Unique codes | Time slots | Frequency bands | -| **Spectrum Efficiency** | High (statistical multiplexing) | Medium (fixed slots) | Low (guard bands) | -| **Capacity** | Soft limit, interference-limited | Hard limit, slot-limited | Hard limit, bandwidth-limited | -| **Near-Far Effect** | Critical issue, needs power control | Minimal impact | Minimal impact | -| **Multipath Handling** | Beneficial (Rake receiver) | Requires equalization | Requires equalization | -| **Security** | High (spreading codes) | Low (time-based) | Low (frequency-based) | -| **Implementation** | Complex (correlation, power control) | Medium (synchronization) | Simple (filtering) | +Parity, checksums, and CRC for detection; Hamming/Reed–Solomon/convolutional/turbo codes for correction; ARQ and HARQ combine FEC with retransmissions. -## Sources and References: +## 1.6 Wi‑Fi Network Standards (5%) -1. **3GPP Technical Specifications:** TS 25.213 (Spreading and modulation), TS 25.214 (Physical layer procedures) -2. **Viterbi, A.J.** "CDMA: Principles of Spread Spectrum Communication" - Addison-Wesley, 1995 -3. **Holma, H. and Toskala, A.** "WCDMA for UMTS: Radio Access for Third Generation Mobile Communications" - Wiley, 2004 -4. **IEEE Communications Magazine:** Various articles on CDMA evolution and implementation (1995-2005) -5. **ITU-R Recommendation M.1457:** "Detailed specifications of the radio interfaces of International Mobile Telecommunications-2000" +802.11n/ac/ax/be key traits: bands, channel widths, MIMO/MU‑MIMO, OFDMA, TWT, BSS coloring, MLO. Wi‑Fi 6/6E dominates new deployments; Wi‑Fi 7 emerging. -**Key Insight:** W-CDMA represents a sophisticated evolution of CDMA technology that achieves superior spectrum efficiency and service flexibility compared to traditional TDM/FDM approaches by leveraging advanced signal processing, power control, and code design techniques, though at the cost of increased implementation complexity and the critical need for precise power management. - -### 2.2 Two-Dimensional Checksum (15%) - -**Given payload:** 1011 0110 1010 1011 - -**Objective:** Design a minimal-length two-dimensional checksum using even parity that can detect and correct any single-bit error. - -## Step 1: Determine Optimal Data Arrangement - -**Given data:** 16 bits total -**Arrangement:** For optimal checksum length, arrange in a rectangular matrix - -**Testing arrangements for minimal checksum overhead:** - -### Option 1: 4×4 arrangement -``` -1 0 1 1 | Row parity -0 1 1 0 | -1 0 1 0 | -1 0 1 1 | -───────── -Col parity -``` -- Row parity bits: 4 bits -- Column parity bits: 4 bits -- Total checksum: 8 bits (50% overhead) - -### Option 2: 2×8 arrangement -``` -1 0 1 1 0 1 1 0 | Row parity -1 0 1 0 1 0 1 1 | -───────────────── -Col parity (8 bits) -``` -- Row parity bits: 2 bits -- Column parity bits: 8 bits -- Total checksum: 10 bits (62.5% overhead) - -### Option 3: 8×2 arrangement -``` -1 0 | Row parity -1 1 | -0 1 | -1 0 | -1 0 | -1 0 | -1 0 | -1 1 | -────── -Col parity -``` -- Row parity bits: 8 bits -- Column parity bits: 2 bits -- Total checksum: 10 bits (62.5% overhead) - -**Optimal Choice:** 4×4 arrangement provides minimum checksum length (8 bits) - -## Step 2: Calculate Checksum Values - -### Data Matrix Arrangement: -``` -Position: (row, col) -1 0 1 1 (positions: 1,1 1,2 1,3 1,4) -0 1 1 0 (positions: 2,1 2,2 2,3 2,4) -1 0 1 0 (positions: 3,1 3,2 3,3 3,4) -1 0 1 1 (positions: 4,1 4,2 4,3 4,4) -``` - -### Row Parity Calculation (Even Parity): -- **Row 1:** 1⊕0⊕1⊕1 = 1 → **Row parity R₁ = 1** -- **Row 2:** 0⊕1⊕1⊕0 = 0 → **Row parity R₂ = 0** -- **Row 3:** 1⊕0⊕1⊕0 = 0 → **Row parity R₃ = 0** -- **Row 4:** 1⊕0⊕1⊕1 = 1 → **Row parity R₄ = 1** - -### Column Parity Calculation (Even Parity): -- **Col 1:** 1⊕0⊕1⊕1 = 1 → **Column parity C₁ = 1** -- **Col 2:** 0⊕1⊕0⊕0 = 1 → **Column parity C₂ = 1** -- **Col 3:** 1⊕1⊕1⊕1 = 0 → **Column parity C₃ = 0** -- **Col 4:** 1⊕0⊕0⊕1 = 0 → **Column parity C₄ = 0** - -### Complete Transmission Block: -``` -Data Matrix: Parity -1 0 1 1 R₁ = 1 -0 1 1 0 R₂ = 0 -1 0 1 0 R₃ = 0 -1 0 1 1 R₄ = 1 -───────── ───── -C₁C₂C₃C₄ P -1 1 0 0 -``` - -### Overall Parity Calculation: -**P = R₁⊕R₂⊕R₃⊕R₄ = 1⊕0⊕0⊕1 = 0** - -**Final Checksum Field:** **1100 1010 0** -- Row parities: 1010 -- Column parities: 1100 -- Overall parity: 0 -- **Total checksum length: 9 bits** - -## Step 3: Prove Minimality - -### Theoretical Lower Bound: -For single error correction capability with n data bits: -- **Hamming bound:** 2^k ≥ n + k + 1 (where k = parity bits) -- For n = 16: 2^k ≥ 16 + k + 1 = 17 + k -- Minimum k = 5 bits (since 2^5 = 32 ≥ 21) - -### Two-Dimensional Parity Analysis: -**Our scheme uses 9 bits vs theoretical minimum of 5 bits** - -**Justification for additional overhead:** -1. **Error Localization:** Two-dimensional parity provides exact error position -2. **Correction Capability:** Automatic correction without retransmission -3. **Implementation Simplicity:** Simple XOR operations vs complex syndrome decoding -4. **Practical Minimum:** For rectangular arrangement with integer dimensions - -### Alternative Arrangements Comparison: -- 1×16: Requires 1 + 16 + 1 = 18 parity bits -- 2×8: Requires 2 + 8 + 1 = 11 parity bits -- 4×4: Requires 4 + 4 + 1 = 9 parity bits ← **MINIMAL** -- 8×2: Requires 8 + 2 + 1 = 11 parity bits -- 16×1: Requires 16 + 1 + 1 = 18 parity bits - -**Proof of minimality:** 4×4 arrangement provides the shortest checksum length among all possible rectangular matrix arrangements. - -## Step 4: Prove Single-Bit Error Detection and Correction - -### Error Detection Mechanism: -1. **Row parity mismatch** indicates error in that row -2. **Column parity mismatch** indicates error in that column -3. **Intersection** of failing row and column identifies exact error position -4. **Overall parity** distinguishes between single-bit and parity-bit errors - -### Error Correction Examples: - -#### Example 1: Data bit error at position (2,3) -**Received data with error:** -``` -1 0 1 1 R₁ = 1 ✓ -0 1 0 0 R₂ = 1 ✗ (should be 0) -1 0 1 0 R₃ = 0 ✓ -1 0 1 1 R₄ = 1 ✓ -───────── -1 0 0 0 C₃ = 1 ✗ (should be 0) -``` - -**Error localization:** Row 2 fails, Column 3 fails → Error at (2,3) -**Correction:** Flip bit at position (2,3): 0 → 1 - -#### Example 2: Parity bit error (R₂ error) -**Received data with parity error:** -``` -1 0 1 1 R₁ = 1 ✓ -0 1 1 0 R₂ = 1 ✗ (should be 0) -1 0 1 0 R₃ = 0 ✓ -1 0 1 1 R₄ = 1 ✓ -───────── -1 1 0 0 All column parities ✓ -``` - -**Error detection:** Only row parity fails, columns are correct → Parity bit error -**Correction:** Correct R₂ parity bit - -### Comprehensive Error Coverage: -- **Data bit errors:** Detected by row AND column parity failures -- **Row parity errors:** Detected by row failure, columns correct -- **Column parity errors:** Detected by column failure, rows correct -- **Overall parity errors:** Detected by overall parity mismatch - -**Conclusion:** The two-dimensional checksum with 9-bit overhead (4×4 arrangement) provides minimal-length error detection and correction for the given 16-bit payload, with 100% single-bit error detection and correction capability. - -### 2.3 CSMA/CD Ethernet Analysis (20%) - -**Given:** -- 1 Gbps Ethernet -- 180 m cable with 3 repeaters -- Propagation speed: 2×10^8 m/sec -- Frame size: 1,024 bits -- Backoff intervals: multiples of 512 bits -- Repeater delay: 20-bit transmission time each -- Post-collision: A draws K=0, B draws K=1 -- Jam signal: 48 bits - -## Part (a): One-way propagation delay and delivery time - -### Step 1: Calculate one-way propagation delay - -**Physical propagation time:** -- Cable length: 180 m -- Propagation speed: 2×10^8 m/sec -- Physical delay = 180 m ÷ (2×10^8 m/sec) = 0.9 μs - -**Repeater delays:** -- 3 repeaters × 20-bit transmission time each -- At 1 Gbps: 1 bit time = 1 ns -- Total repeater delay = 3 × 20 bits × 1 ns/bit = 60 ns = 0.06 μs - -**Total one-way propagation delay:** -Total delay = Physical delay + Repeater delays -Total delay = 0.9 μs + 0.06 μs = **0.96 μs** - -### Step 2: Timeline analysis for collision scenario - -**t = 0**: Both A and B start transmitting simultaneously - -**Collision detection and jam signal:** -- Collision occurs immediately since both start at t=0 -- Jam signal duration: 48 bits = 48 ns -- Jam signal completes at t = 48 ns - -**Exponential backoff:** -- A draws K=0 → Backoff time = 0 × 512 bits = 0 bits = 0 ns -- B draws K=1 → Backoff time = 1 × 512 bits = 512 bits = 512 ns - -### Step 3: Calculate A's complete packet delivery time - -**Timeline for A's successful transmission:** -- t = 0: Initial collision occurs -- t = 48 ns: Jam signal ends -- t = 48 ns: A waits 0 ns (K=0), B waits 512 ns -- t = 48 ns: A starts retransmission (B still in backoff) -- t = 48 ns + 1,024 ns: A finishes transmission = 1,072 ns -- t = 1,072 ns + 960 ns: Signal propagates to B = 2,032 ns - -**A's packet is completely delivered at B at t = 2,032 ns = 2.032 μs** - -## Part (b): Switches instead of repeaters with 8-bit processing delay - -### Modified scenario: -- Only A has packet to send -- 3 switches replace repeaters -- Each switch: 8-bit processing delay + store-and-forward delay -- Store-and-forward delay = 1,024 bits (full packet) - -### Switch delay calculation: -**Per switch delay:** -- Processing delay: 8 bits = 8 ns -- Store-and-forward delay: 1,024 bits = 1,024 ns -- Total per switch: 8 + 1,024 = 1,032 ns - -**Total switch delays:** -- 3 switches × 1,032 ns = 3,096 ns = 3.096 μs - -**Physical propagation delay:** -- Same as before: 0.9 μs - -### Timeline for switch-based transmission: -- t = 0: A starts transmission -- t = 1,024 ns: A completes transmission to first switch -- t = 1,024 + 1,032 = 2,056 ns: First switch forwards -- t = 2,056 + 1,032 = 3,088 ns: Second switch forwards -- t = 3,088 + 1,032 = 4,120 ns: Third switch forwards -- t = 4,120 + 900 = 5,020 ns: Signal reaches B - -**A's packet is delivered at B at t = 5.020 μs** - -## Detailed CSMA/CD Analysis - -### Collision Detection Process: -1. **Initial Transmission**: Both nodes detect carrier as free and begin transmission -2. **Collision Occurrence**: Signals interfere when they meet on the medium -3. **Collision Detection**: Each node detects voltage levels exceeding normal thresholds -4. **Jam Signal**: Both nodes transmit 48-bit jam signal to ensure all nodes detect collision -5. **Backoff Algorithm**: Exponential backoff with binary exponential backoff (BEB) - -### Why RTT is Critical for CSMA/CD: -- **Collision Detection Window**: Must detect collision within one round-trip time -- **Minimum Frame Size**: Frame transmission time must exceed RTT to ensure collision detection -- **Network Diameter Limit**: RTT constrains maximum network size -- **Slot Time**: Backoff intervals based on worst-case RTT scenarios - -### Performance Considerations: -- **Efficiency**: η = 1/(1 + 6.44 × a) where a = RTT×bandwidth/frame_size -- **Throughput Degradation**: Higher collision rates reduce effective throughput -- **Network Utilization**: Optimal performance requires balanced frame size vs. propagation delay - -**Key Insight**: CSMA/CD performance is fundamentally limited by propagation delay, which determines collision detection capabilities and minimum frame sizes. The replacement of repeaters with switches eliminates collision domains but introduces store-and-forward delays that can significantly impact end-to-end latency for larger networks. - -### 2.4 802.11 RTS/CTS Transmission (10%) - -**Given:** -- 802.11 station configured to always use RTS/CTS -- 1024 bytes of data to transmit -- All other stations idle at t = 0 -- Station wants to transmit at t = 0 - -## 802.11 Frame Specifications - -**Standard 802.11 frame sizes and timing parameters:** -- **RTS frame:** 20 bytes (160 bits) -- **CTS frame:** 14 bytes (112 bits) -- **ACK frame:** 14 bytes (112 bits) -- **Data frame:** 1024 bytes payload + 28 bytes header = 1052 bytes (8416 bits) -- **SIFS (Short Interframe Space):** 10 μs -- **DIFS (Distributed Interframe Space):** 50 μs -- **Slot time:** 20 μs -- **Data rate:** 11 Mbps (802.11b standard assumption) - -## RTS/CTS Protocol Sequence - -### Step 1: Channel Access and RTS Transmission - -**t = 0:** Station wants to transmit -- **DIFS wait:** Station must wait DIFS before accessing idle channel -- **t = 0 to 50 μs:** Station waits DIFS period -- **t = 50 μs:** Station begins RTS transmission - -**RTS transmission time:** -- RTS frame size: 160 bits -- Transmission time = 160 bits ÷ 11 Mbps = 14.55 μs -- **t = 50 μs to 64.55 μs:** RTS transmission - -### Step 2: CTS Response - -**SIFS wait after RTS:** -- **t = 64.55 μs to 74.55 μs:** SIFS period (10 μs) -- **t = 74.55 μs:** Access Point begins CTS transmission - -**CTS transmission time:** -- CTS frame size: 112 bits -- Transmission time = 112 bits ÷ 11 Mbps = 10.18 μs -- **t = 74.55 μs to 84.73 μs:** CTS transmission - -### Step 3: Data Transmission - -**SIFS wait after CTS:** -- **t = 84.73 μs to 94.73 μs:** SIFS period (10 μs) -- **t = 94.73 μs:** Station begins data transmission - -**Data frame transmission time:** -- Data frame size: 8416 bits (1024 bytes payload + 28 bytes header) -- Transmission time = 8416 bits ÷ 11 Mbps = 765.09 μs -- **t = 94.73 μs to 859.82 μs:** Data transmission - -**Station completes transmission at t = 859.82 μs** - -### Step 4: ACK Reception - -**SIFS wait after data:** -- **t = 859.82 μs to 869.82 μs:** SIFS period (10 μs) -- **t = 869.82 μs:** Access Point begins ACK transmission - -**ACK transmission time:** -- ACK frame size: 112 bits -- Transmission time = 112 bits ÷ 11 Mbps = 10.18 μs -- **t = 869.82 μs to 880 μs:** ACK transmission - -**Station receives acknowledgment at t = 880 μs** - -## Complete Timeline Summary - -| Time (μs) | Event | Duration (μs) | -|-----------|-------|---------------| -| 0 - 50 | DIFS wait | 50.00 | -| 50 - 64.55 | RTS transmission | 14.55 | -| 64.55 - 74.55 | SIFS wait | 10.00 | -| 74.55 - 84.73 | CTS transmission | 10.18 | -| 84.73 - 94.73 | SIFS wait | 10.00 | -| 94.73 - 859.82 | Data transmission | 765.09 | -| 859.82 - 869.82 | SIFS wait | 10.00 | -| 869.82 - 880.00 | ACK transmission | 10.18 | - -## Answers to Questions - -### When does the station complete transmission? -**The station completes transmission at t = 859.82 μs** - -This represents the end of the data frame transmission. The actual data payload has been fully transmitted to the access point. - -### When can the station receive the acknowledgment? -**The station receives the acknowledgment at t = 880.00 μs** - -This marks the successful completion of the entire RTS/CTS/Data/ACK sequence. - -## Protocol Analysis - -### RTS/CTS Benefits Demonstrated: -1. **Hidden Node Protection:** RTS/CTS sequence reserves the channel for the entire data transmission -2. **Collision Avoidance:** Other stations hear either RTS or CTS and defer transmission -3. **Channel Reservation:** Duration field in RTS/CTS frames reserves channel for complete sequence -4. **Efficiency for Large Frames:** Overhead is justified for larger data frames like the 1024-byte payload - -### Timing Overhead Analysis: -- **Total sequence time:** 880 μs -- **Actual data transmission time:** 765.09 μs -- **Protocol overhead time:** 114.91 μs (13.1% overhead) -- **Overhead breakdown:** - - DIFS: 50 μs (5.7%) - - RTS/CTS frames: 24.73 μs (2.8%) - - SIFS periods: 30 μs (3.4%) - - ACK frame: 10.18 μs (1.2%) - -### Performance Considerations: -- **Efficiency:** 86.9% channel utilization for data transmission -- **Latency:** 880 μs total time for 1024-byte frame transmission -- **Throughput:** Effective data rate ≈ 9.3 Mbps (considering protocol overhead) - -**Key Insight:** The RTS/CTS mechanism trades modest protocol overhead (13.1%) for robust collision avoidance and hidden node protection, making it particularly valuable in wireless environments with potential hidden nodes or high collision probability. - -### 2.5 Bluetooth Frame Format Analysis (10%) - -## Bluetooth Technology Overview - -Bluetooth is a short-range wireless communication technology operating in the 2.4 GHz ISM band, designed for personal area networks (PANs). Originally developed by Ericsson in 1994, Bluetooth uses frequency-hopping spread spectrum (FHSS) and time division duplex (TDD) to enable multiple devices to communicate within a small coverage area. - -## Bluetooth Frame Format Structure - -### Basic Frame Components - -Bluetooth frames consist of three main components arranged in the following structure: - -``` -[Access Code] [Header] [Payload] - 72 bits 54 bits 0-2745 bits -``` - -### 1. Access Code (72 bits) -The Access Code serves multiple critical functions: - -**Structure:** -- **Preamble:** 4 bits (fixed pattern for synchronization) -- **Sync Word:** 64 bits (derived from master device's clock and ID) -- **Trailer:** 4 bits (optional, used for better correlation) - -**Functions:** -- **Device Identification:** Uniquely identifies the piconet master -- **Synchronization:** Enables receiver clock and frequency synchronization -- **Packet Detection:** Allows devices to distinguish Bluetooth signals from noise -- **Piconet Separation:** Different piconets use different access codes - -**Types of Access Codes:** -- **Channel Access Code (CAC):** Used for regular data transmission -- **Device Access Code (DAC):** Used during inquiry and paging procedures -- **Inquiry Access Code (IAC):** Used for device discovery - -### 2. Header (54 bits) -The Header contains control and addressing information: - -**Header Fields:** -- **AM_ADDR (3 bits):** Active Member Address - identifies active devices in piconet -- **TYPE (4 bits):** Packet type specification -- **FLOW (1 bit):** Flow control for stop-and-wait ARQ -- **ARQN (1 bit):** Automatic Repeat Request acknowledgment -- **SEQN (1 bit):** Sequence number for packet ordering -- **HEC (8 bits):** Header Error Check for error detection - -**Header Encoding:** -- The 18-bit header is encoded with a 1/3 rate FEC (Forward Error Correction) -- Results in 54 transmitted bits for enhanced error protection -- Uses repetition coding where each bit is repeated three times - -### 3. Payload (0-2745 bits) -The Payload carries actual user data and varies by packet type: - -**Payload Structure:** -- **Payload Header:** Contains length and flow control information -- **Payload Body:** User data (voice, text, files, etc.) -- **CRC (Cyclic Redundancy Check):** Error detection for payload data - -## Detailed Frame Analysis - -### Packet Types and Payload Sizes - -**Control Packets:** -- **ID packets:** 0 bits payload (only Access Code and Header) -- **NULL packets:** 0 bits payload (used for acknowledgment) -- **POLL packets:** 0 bits payload (used to poll slave devices) - -**SCO (Synchronous Connection-Oriented) Packets:** -- **HV1:** 80 bits payload (voice data, 1/3 FEC protection) -- **HV2:** 160 bits payload (voice data, 2/3 FEC protection) -- **HV3:** 240 bits payload (voice data, no FEC protection) - -**ACL (Asynchronous Connectionless) Packets:** -- **DM1:** 136 bits payload (medium data rate, 2/3 FEC) -- **DH1:** 240 bits payload (high data rate, no FEC) -- **DM3:** 968 bits payload (medium data rate, 2/3 FEC) -- **DH3:** 1464 bits payload (high data rate, no FEC) -- **DM5:** 1784 bits payload (medium data rate, 2/3 FEC) -- **DH5:** 2744 bits payload (high data rate, no FEC) - -### Frame Features and Characteristics - -#### 1. Error Protection Mechanisms -**Forward Error Correction (FEC):** -- **1/3 Rate FEC:** Each bit repeated three times (used for header and some payloads) -- **2/3 Rate FEC:** Uses (15,10) shortened Hamming code -- **ARQ (Automatic Repeat Request):** Stop-and-wait protocol for reliable transmission - -**Error Detection:** -- **Header Error Check (HEC):** 8-bit CRC for header protection -- **Payload CRC:** 16-bit CRC for payload data integrity - -#### 2. Addressing and Flow Control -**Active Member Address (AM_ADDR):** -- **3-bit field:** Supports up to 7 active devices (0 reserved for broadcast) -- **Temporary Assignment:** Assigned by master when device becomes active -- **Limitation Factor:** This is the primary reason for the 8-device limit - -**Flow Control:** -- **FLOW bit:** Implements stop-and-wait flow control -- **ARQN/SEQN:** Provides reliable data transfer with acknowledgments - -#### 3. Frequency Hopping Integration -- **Access Code synchronization:** Enables proper frequency hop timing -- **Hop Selection:** Based on master's clock and device ID -- **79 Frequencies:** Uses 79 different frequencies in 2.4 GHz band -- **1600 hops/second:** Changes frequency every 625 μs - -## Analysis of Eight-Device Limitation - -### Why is Bluetooth Limited to Eight Active Nodes? - -The limitation to eight active nodes in a Bluetooth piconet is **directly imposed by the frame format**, specifically the AM_ADDR field: - -#### 1. AM_ADDR Field Constraint -- **Field Size:** 3 bits in the frame header -- **Possible Values:** 2³ = 8 possible combinations (000 to 111) -- **Reserved Value:** 000 is reserved for broadcast messages -- **Available Addresses:** 7 addresses available for individual devices (001 to 111) -- **Total Active Devices:** 7 active slaves + 1 master = 8 total devices - -#### 2. Frame Format Impact -**Why the AM_ADDR field is this small:** -- **Header Size Optimization:** Bluetooth was designed for low-power, low-complexity devices -- **Overhead Minimization:** Smaller addressing reduces frame overhead -- **Processing Simplicity:** 3-bit addresses simplify hardware implementation -- **Battery Life:** Shorter frames mean less transmission time and lower power consumption - -#### 3. Alternative Addressing Mechanisms -**Parked Devices:** -- Use different addressing scheme with 8-bit Parked Member Address (PM_ADDR) -- Can support up to 255 parked devices -- Parked devices cannot actively communicate without becoming active -- Must transition from parked to active state to participate in data exchange - -**Device Access Code (DAC):** -- Each device has unique 48-bit BD_ADDR (Bluetooth Device Address) -- Used during connection establishment, not regular data transmission -- Would create excessive overhead if used in every frame - -### Comparison with Other Wireless Technologies - -| Technology | Max Active Devices | Addressing Mechanism | Address Size | -|------------|-------------------|---------------------|--------------| -| **Bluetooth** | 8 (7 active slaves) | AM_ADDR in frame header | 3 bits | -| **Wi-Fi** | 2007+ devices | MAC addresses | 48 bits | -| **Zigbee** | 65,000+ devices | Network + device addresses | 16 + 64 bits | - -## Limitations and Design Trade-offs - -### Frame Format Limitations - -#### 1. Addressing Constraints -**Limited Active Devices:** -- Only 8 devices can actively participate in data transmission -- Additional devices must be in parked or standby states -- Requires complex state management for larger networks - -**No Mesh Networking:** -- Frame format designed for star topology only -- Master-slave architecture inherent in addressing scheme -- Cannot support native mesh networking without protocol modifications - -#### 2. Overhead Considerations -**High Overhead for Small Payloads:** -- Access Code (72 bits) and Header (54 bits) = 126 bits fixed overhead -- For small payloads, overhead percentage is very high -- Example: ID packet has 126 bits overhead with 0 bits payload +--- -**FEC Redundancy:** -- 1/3 FEC triples header size (18 → 54 bits) -- Trades bandwidth efficiency for error resilience -- Appropriate for noisy 2.4 GHz environment +# Part 2: Long Answer Questions (70%) -#### 3. Scalability Issues -**Piconet Size Limitation:** -- Inherently limits network scalability -- Requires scatternet formation for larger networks -- Complex inter-piconet communication protocols needed +## 2.1 Code Division Multiple Access (CDMA) (15%) -**Master Bottleneck:** -- All communication must pass through master device -- Single point of failure for the entire piconet -- Master must manage all slaves' timing and addressing +W‑CDMA overview: spreading with OVSF codes (3.84 Mcps), cell/user scrambling, fast power control, Rake combining, soft handoff. Advantages over TDM/FDM: interference averaging, soft capacity, multipath diversity, better security, flexible rates. -### Design Strengths +## 2.2 Two‑Dimensional Checksum (15%) -#### 1. Error Resilience -**Robust Error Protection:** -- Multiple layers of error detection and correction -- Suitable for industrial and interference-prone environments -- Automatic retransmission ensures reliability +For 16 data bits, a 4×4 two‑dimensional even parity uses 4 row + 4 column + 1 overall parity = 9 bits. Detects and corrects any single‑bit error by intersecting failing row/column; overall parity distinguishes parity‑bit vs data‑bit errors. Minimal among rectangular arrangements. -#### 2. Low Power Design -**Efficient Power Management:** -- Short frames reduce transmission time -- Simple addressing minimizes processing requirements -- Frequency hopping provides interference resistance +## 2.3 CSMA/CD Ethernet Analysis (20%) -#### 3. Simplicity -**Implementation Efficiency:** -- Simple frame structure reduces hardware complexity -- Fixed field sizes enable fast processing -- Minimal protocol overhead for basic operations +Given 1 Gbps, 180 m, 3 repeaters (20‑bit delay each), v=2e8 m/s: +- One‑way propagation ≈ 0.96 µs. After a single collision with jam=48 bits, A’s successful delivery at ≈ 2.032 µs. +- With 3 store‑and‑forward switches (8‑bit proc + full‑frame), delivery ≈ 5.020 µs. -## Conclusion +## 2.4 802.11 RTS/CTS Transmission (10%) -**The Bluetooth frame format reflects design priorities of the 1990s:** low power consumption, simple implementation, and reliable short-range communication. The eight-device limitation is a **direct consequence** of the 3-bit AM_ADDR field in the frame header, which was chosen to minimize overhead and complexity. +At 11 Mbps, 1024‑byte payload, DIFS=50 µs, SIFS=10 µs, RTS=160b, CTS/ACK=112b, data=8416b: +- TX done ≈ 859.8 µs; ACK received ≈ 880.0 µs. -**Key Trade-offs:** -- **Simplicity vs. Scalability:** Chose simple addressing over large network support -- **Reliability vs. Efficiency:** Emphasized error protection over bandwidth efficiency -- **Power vs. Performance:** Optimized for battery life over high data rates +## 2.5 Bluetooth Frame Format Analysis (10%) -**Modern Context:** While these limitations restrict Bluetooth's use in large-scale networking applications, they make it ideal for personal area networks, IoT devices, and applications requiring reliable, low-power, short-range communication. The frame format limitations have been partially addressed in newer Bluetooth versions (BLE, mesh networking) while maintaining backward compatibility with the original design principles.
\ No newline at end of file +Frame: [Access Code 72b][Header 54b (1/3 FEC on 18b)][Payload 0–2745b + CRC]. AM_ADDR is 3 bits → 7 slaves + 1 master active per piconet. Design trade‑offs prioritize low power, robustness, and simplicity; scalability via parked devices/scatternets. |
