Switching and Multiplexing

Switching and multiplexing are both techniques we use to make communication more economical and scaleable.

Switching

Fully connected networks don't scale well, but you still need to let any possible pair of nodes communicate.

Switching is the idea that you can dynamically configure a network which is less than fully connected in order to join any two nodes for communication.

Two ways to switch: you can establish your own dedicated path (circuit switching) or you can take whatever path is available at the time you send data (packet switching).

Circuit switching

Circuit switching maintains the idea of dedicated connections between two end points, but allows for sharing of channels within the network, and hence is much more scaleable. Circuit switching takes advantage of the fact that while everybody needs to be able to talk to everybody else, they aren't likely to all do so at the same time.

The telephone network is based on circuit switching. To make a phone call you ask the PSTN to establish a dedicated circuit for you. It does this by finding unused channels all along the way through the network and dedicates them to your call. When you actually start exchanging data (talking) all of your data follows the same path or circuit through the network. If you pause in your conversation the circuit you're using is idle, wasting bandwidth. But you never lose data because you have a guaranteed, reserved circuit, so it is impossible for the system to be too busy to handle your data.

<picture of switches and circuits>

Pros

Cons Questions Alternatives to circuit switching are message switching (store and forward) and packet switching.

Message Switching

Message switching is the way (at the high level, at least) that USENET articles are distributed. Each article is sent in its entirety from one news host to another before the next article is sent. During the time that an article is in transit no other article can be sent. The potentially large size of messages means that the routers can be busy for long periods handling one message, and the messages take a lot of storage.

Packet Switching

Packet switching alleviates the problems of circuit and message switching. A small upper bound is put on the maximum size of a packet sent through the network. No reserved channel is created ahead of time. Each packet belonging to a single message may take a different route through the network.

Since there is no reservation of capacity it is possible that congestion becomes a problem. Too many packets trying to get through the same router requires that the router be able to buffer packets. All buffers have finite size, so it is possible that packets are dropped.

<figure showing routers and queues in packet switched network>

Pros

Cons See ATM Switching for a continued discussion of switching.

Multiplexing

Long distance links use high capacity point-to-point connections with a single physical medium. Some means must be found of sharing the capacity to enable multiple simultaneous uses of the medium. The motivation is the same here as for time shared operating systems (one expensive resource shared by many people). Think of the links between the regional phone switches.

What is the relationship between switching and multiplexing?

There are three ways to divide (and hence share) a channel: time, frequency, code.

Frequency Division Multiplexing

Possible when a single source requires less than the total available bandwidth in the medium.

Frequency modulation lets data be moved to any particular part of the frequency spectrum of the channel. Multiple sources can thus share the same medium, by using different parts of the channel simultaneously.

FDM allows for full duplex modems, radio, and TV.

Carrier frequency is what shifts the spectrum of a channel

Individual TV signal also an example of FDM

<figure 2-24, block diagram of FDM>

Example: telephone system trunks

Wave Division Multiplexing

Just FDM in the context of optical fibers. Better because no interference properties of light.

Time Division Multiplexing

If the data rate of a medium is larger than the data rate (bps) of a source channel, then multiple channels can be sent by allotting different channels different slices of time. Multitasking in an OS is TDM of the CPU.

The multiple channels can be interleaved by bit, byte, or frame.

Synchronous TDM refers to the fact that a time slot is reserved for each source

The issues of link control (flow, error control) are handled per channel, independent of the TDM

Example: TDM Carrier System

Example: Cogent MANs

Statistical TDM

Tries to reduce the wasted capacity which is inevitable with TDM when not all channels have data during every slot.

A statistical multiplexer can support many more devices given the same data rate

The design of a stat TDM depends on the expected utilization of each channel

Potential problem: peak load could exceed capacity, since design is statistical Buffers must be provided to soak up the extra bits when over capacity.

CDMA Code Division Multiple Access

References GSM uses TDM and FDM to divide the channel and dedicate time/space to a user. The whole point is to avoid multiple stations transmitting on the same frequency at the same time. An alternative strategy is to use spread spectrum techniques so collisions aren't a problem. All conversations use all the available bandwidth at the same time.

Divide each bit interval into smaller units called chips. Real schemes use 64 or 128 chips per bit. Each chip is one of two signals (i.e. it is a binary digital signal).

Each station is given a unique m bit chip sequence. When the station wants to transmit a 1 bit, it sends the m bit sequence. When it wants to transmit a 0 bit, it sends the complement of its m bit sequence.

If you want to communicate b bits, then you must signal b*m chips

So a seemingly crazy thing has been done. If you want to communicate b bits/sec, you must signal b*m bits/sec. The signalling data rate is higher yet the communication rate is the same. A higher signalling rate obviously requires greater bandwidth in the channel. Instead of using FDM and limiting each conversation to one discrete part of the total spectrum, you allow all conversations to use the entire allocated frequency spectrum.

Here's an example using a 1 MHz bandwidth channel centered at 1000 MHz. Three different strategies will be used to share this channel among 100 simultaneous conversations.

FDM strategy

TDM strategy CDMA strategy Conclusion Background How it works, Tanenbaums example in Figure 4-16 With an ideal, noiseless channel, there is nothing that bounds the capacity of the channel with CDMA. You can just keep adding stations as long as you have unused orthogonal codes, and you can increase the code length when you need more.

With real, noisy channels you have a limit. There is also the problem of having all the chip signals synchronized in time. GPS is used in some systems to synchronize mobile and base stations.

Another problem is that the power in the signals is assumed to be equal. In a wireless network that won't be the case because the stations are different distances from the receiver. Power control is very important in CDMA.

Disadvantage over narrow band schemes

Advantages over narrow band schemes