Physical Layer


  Analog v. Digital

Errors: General problems with signals

Manchester encoding

Routing

Switching

Phone lines

Coaxial cable

Fiber optic

Wireless

Power line communication



Analog v. Digital

  1. analog

  2. digital


2.1 Changing voltage (or other analog property) on a wire

This is applicable primarily to:
  1. Phone line
  2. Broadband phone line
  3. Coax cable
Some different but similar issues with:
  1. Fiber optics
  2. Wireless

Changing voltage to represent digital 0,1

X-axis is time.
Y-axis is voltage.

Any 2 separate values will do (to map to 0,1).
Don't have them too close so hard to measure at other end.


Higher frequency means higher bandwidth

Can send more 0s and 1s in shorter time.

Period - repeats every 1/n sec.
Frequency - n Hertz (n per sec).
Here: Frequency = rate of change of voltage.


Sines or cosines alone would just encode 010101..

Any single sine function:
A sin(B*x) + C
or cosine function:
D cos(E*x) + F
can only represent one pattern:
Strict alternating 010101...


Adding sines and cosines to represent any pattern

Fourier showed you can approximate any reasonably behaved continuous periodic (arbitrarily long period) function with a combination of sines and cosines:

a

+ b1 sin(c1x)
+ b2 sin(c2x)
+ b3 sin(c3x)
+ ...

+ d1 cos(e1x)
+ d2 cos(e2x)
+ d3 cos(e3x)
+ ...

We want to send some data pattern (e.g. 000010011110100010000011). This is always of finite length. We just imagine it as a repeating pattern of period this length. (Only going to receive the pattern for a finite window.)

The more terms used the better the approximation.
We won't go into detail of what the terms are here.


Modulator

Modulator (converts digital to analog signal) actually does do an addition like this.

n oscillators (inside the modulator) change voltage on their separate output lines with different f's, periodic.
These n output lines are combined and in the combination the voltage is summed. Summed voltage is output from modulator.


Example

This is heading towards encoding 01100100 (then repeat) ..
i.e. encode 01100100 in small interval (ASCII char "d").
Need (a lot) more terms.

Higher frequencies means more accuracy in shorter time.


Better example

Transmitting 01100010 (ASCII char "b").

As we go down, we're using higher frequencies (along with the low ones).

Higher frequencies means more accuracy in shorter time.



Errors: General problems with signals

Signals have problems with long distance and random errors.

  1. Attenuation - Signal loses energy with distance. Different frequencies lose energy by different amount, so the actual signal is distorted.

  2. Delay distortion - Different frequencies propagate at different speeds in the wire, so over long distance the signal is distorted.

  3. Noise - Thermal noise in a wire. Interference from other wires. Spikes in power.

Solutions

For problems 1. and 2.:

For all of them:


Limited f

Each cable has a hard limit on the frequencies it can transmit.
Usually, from 0 to some cut-off point n Hz will be transmitted with little distortion.

This is a limit on bandwidth: On the amount of data that can be represented (and hence transmitted) accurately in a short time.


Bandwidth

Bandwidth of a medium = The range of frequencies that pass through it with minimum attenuation.
It is a physical property of the medium.
Usually from 0 Hz to n Hz.

Bandwidth also used to refer to data-carrying capacity of the medium in bits-per-second (bps).

High f bandwidth means high data bandwidth.


De-modulator (Samples / sec)

At the receiving end, the receiver (the Demodulator) samples the line n times per second to read the signal.

Nyquist–Shannon sampling theorem: For any given bandwidth (i.e. range of frequencies) it is pointless to sample the line more than some constant times per second, since the higher f's such sampling could recover have already been filtered out.



4.3.2 Manchester Encoding

Problem: Sender and receiver running at different speeds. Receiver sampling speed not quite the same as sender output speed. Get out of synch about where the bit boundaries are, especially after long run of consecutive 0s or long run of consecutive 1s.
e.g. 106 1s in a row read as 105 1s, or 107 1s.

Solution: Manchester Encoding. - (b) below.
Each bit covers 2 time slots.
1 bit: Voltage high in first slot, low in second.
0 bit: Low, then high.
Every bit period has a transition in the middle - making it easy to spot them.

Differential Manchester encoding - (c) above
1 bit: No transition at start of interval.
0 bit: There is a transition.
In both cases, there is transition in middle as well.
Better noise immunity.

Manchester encoding used in Ethernet. You use it every day. I am using it now (in lecture).



2.2 Transmission media

  1. Guided - Copper wire, Fibre Optics
  2. Unguided - Wireless


2.2.1 Magnetic Media

Removable media - Magnetic tape, CD-RW, recordable DVD

Magnetic tape - IBM offers systems up to 5 petabytes.

You would never use these to move information about in your network, would you? Copy to removable media and just drive it across in a van??
A. Maybe yes.
In book, he gives example of a company that wants to back up say over a terabyte of data to another city, or even just another machine.
A machine 1 hour away by road can be backed up at in effect 400 Gbps.
Even 1 continent away (FedEx) can be backed up at in effect 20 Gbps.
Cost 3 cents per gigabyte.
No network can match this high speed or low cost.
(Though fiber optics are getting there. If have single dedicated leased line.)

Obviously, you can't use these for real-time interactive (on-line) network.



2.2.2 Phone lines

2.2.3 Coaxial cable

2.2.4 Fiber optic

2.3 Wireless


Power line communication


2.5.4 Multiplexing

On telephone backbone.
  1. Frequency Division Multiplexing - Frequency spectrum divided into bands. Each user has exclusive possession of a band.

  2. Time Division Multiplexing - Users take turns. Round-robin. Each gets entire bandwidth for short burst of time.
    e.g. T1 line (a popular leased line).

  3. Wavelength Division Multiplexing - FDM on a fiber optic cable. Up to 1 T bps.



2.5.5 Switching


Routing

What route through the network does my data take?

  1. Fixed routing (e.g. shortest path).

  2. Virtual circuit - path fixed for duration of session from A to B.

  3. Dynamic routing - messages assigned whatever paths are free. When traffic jams, traffic flows down duplicate paths.


Q. What is the shortest route?

  1. Model the network as a mathematical graph. Shortest route is the one with the least number of nodes/links?
    Not necessarily. Depends on bandwidth, traffic and machine loads on route.
    Might be better to send it on roundabout route (through more machines) if gets there quicker.

  2. Model the network on geographical distance. Shortest route is the one that travels the least geographical distance?
    Not necessarily. Depends on bandwidth, traffic and machine loads on route.
    Might be better to send it on roundabout route (long distance) if gets there quicker.

As traffic and machine loads keep changing, the answer to what is the best route keeps changing.


Switching

Does my communication session own all of the bandwidth on the route, or is it shared?

  1. Circuit switching - Part of network set up as temporary link between A and B.

  2. Message switching - Store-and-forward of arbitrary-size items. Message sent in its entirety to first switching office (router). Then passed on to next. And so on, until gets to destination.

  3. Packet switching - Store-and-forward of small, fixed-size items. Each message is divided into small fixed-size packets that (like pages in memory and blocks on disk) "flow" into whatever links can take them to, or just nearer to, the destination.



Packet switching




Another comparison. See 5.1.5.