Encoding and Framing
Packet Switching
- Last Class:
- Layering structure of protocol stack
- Performance metrics and calculation
This Class
- Physical limit of PHY medium
- Engineering implementation of transmission
- At bit level
- At frame level
Focusing on a Link (Point-to-Point Channel)
- Simplest topology, consisting of two hosts and one link.
- Functions at the link level are examined.
Problems Addressed
- How fast can the data be transmitted? (scientific)
- In what form can the data be transmitted? (engineering)
- What if error happens? (very critical, both scientific and engineering)
Typical Communication System
- Compresses a stream of bits: use as little number of bits as possible to represent events
- Adds redundancy to detect/correct errors at the receiver (bits are mapped to codewords)
- Scrambles the bits of consecutive codewords to spread burst errors
- Converts a stream of bits to analog signals modulated for transmission over a medium
Generation of Data: Source Coding
Use binary bits (the code) to represent a physical phenomenon (outcomes).
Example: event x with 4 values: a (0.4), b (0.35), c (0.2), d (0.05)
The problem: coding efficiency!!!
- Equal possibility case: fixed-length coding
- Non-equal possibility case: variable-length coding e.g., Huffman coding (David Huffman, 1952 at MIT)
- Average code length: 1.85 bits/symbol
- The limit? (1.74 bits/symbol, the entropy of the symbol)
Entropy Formula:
- Where x is an arbitrary symbol from the source, and is the probability that x takes the value of i.
- Physical meaning of the entropy: the amount of uncertainty carried by x before its realization is revealed!
- Huffman code example:
- a: 0
- b: 10
- c: 110
- d: 111
Medium of the Link
- All practical links rely on some sort of radiation of energy propagating through a medium or, in some cases, through free space.
- Characterization of links by the medium they use:
- Typically copper wire in some form (as in Digital Subscriber Line (DSL) and coaxial cable)
- Optical fiber (as in both commercial fiber-to-the home services and many long-distance links in the Internet’s backbone)
- Air/free space (for wireless links)
Important Radio Characteristics
- Another important link characteristic is the frequency
- Measured in hertz, with which the electromagnetic waves oscillate
- Distance between the adjacent pair of maxima or minima of a wave measured in meters is called wavelength
- Speed of light divided by frequency gives the wavelength.
- Frequency on a copper cable range from 300Hz to 3300Hz; Wavelength for 300Hz wave through copper is speed of light on a copper / frequency
- 2/3 x 3 x /300 = 667 x meters. wavelength
The EM Spectrum
- Covers a wide range of frequencies from VLF (Very Low Frequency) at 10 Hz to Cosmic Rays at Hz.
- Includes:
- Radio Spectrum (3 kHz - 300 GHz)
- Optical Spectrum
- Infrared
- UV
- X-ray
- Gamma ray
- Cosmic-ray
- Different frequency bands are used for various applications like AM, FM, TV, Satellite communication, etc.
Frequency Allocation in U.S.
- Radio spectrum allocation chart showing different frequency bands and their designated uses in the United States.
- Various services are allocated different frequency ranges, including:
- Fixed
- Mobile
- Radiolocation
- Amateur
- Space operation
- Aeronautical
Bandwidth of a Channel
- A signal consists of components at a range of different frequencies
- Bandwidth of the channel (Hz): the range of frequencies that can pass the channel without being severely attenuated
Link Capacity
- Nyquist rate: Given an error-free medium of bandwidth B, the highest signal (symbol) rate (bauds) that can be carried is 2B.
- Bauds to bit/s: 1 baud = 1 symbol/s= log2M bit/s, M: signal levels (# of different symbols)
- Shannon’s Capacity Theorem
- C: capacity (maximum error-free bit transmission rate), unit in bit/s
- B: bandwidth of the link, unit in Hz
- S/N: received signal to noise ratio (ratio and db conversion)
- Can be used to evaluate the “error-free” bandwidth of a line