Title: Network and Communications
1Network and Communications
Chapter 5 Routing Algorithm Adopted from Chois
notes
Ju Wang
Virginia Commonwealth University
2Design Issues
Store and Forward Packet Switching
Store-and Forward packet Switching Services
Provided to the Transport layer Implementation of
Connectionless Service Implementation of
Connection oriented Service Comparison of Virtual
Circuit and Datagram Subnet
3Design Issues
Services Provided to the Transport
Layer Goals Independent on the router
technology Router information shielding(number,
type and topology) Global and uniform network
address
4Datagram Switching
5Label switching (virtual circuit)
Implementation of Connection Oriented
Service Virtual circuit subnet Every packet carry
virtual circuit id and follows same route
6Design Issues
Comparison of Virtual Circuits and Datagram subnet
7Routing Algorithms
NL Goal Routing packets from the source to
destination Algorithm and data structure ?
Decision per packets Why? Best route
What about VC? Session routing
Routing algorithm is desirable if Correctness,
simplicity, robustness, stability,fairness,
optimality
8Fairness and optimality? Contradictory goals
Correctness?
Robustness To topology and traffic change
Simplicity
What to optimize? Mean packet delay? Network
throughput? Minimize the number of hop
Stability Need to converge to equilibrium
9Routing AlgorithmsPrinciple of optimality
If J is on the optimal path from I to K, then the
optimal path from J to K also falls along the
same route Proof
So what?
No cycles guarantee the bounded-hop delivery in
real life?
10Routing AlgorithmsShortest path Routing
11Routing AlgorithmsFlooding
Send packet to every outgoing line except the one
it arrives duplicated redundant packet - hop
count
12Routing AlgorithmsDistance Vector Routing
(Bellman Ford)
Problem?
13(No Transcript)
14Routing AlgorithmsLink State Routing
- Each router must do the following
- Discover its neighbors, learn their network
address. - Measure the delay or cost to each of its
neighbors. - Construct a packet telling all it has just
learned. - Send this packet to all other routers.
- Compute the shortest path to every other router
Computing the New Route using Dijkstra
15(No Transcript)
16Routing AlgorithmsHierarchical Routing
Save space! At the cost of path length (1A to 5C)
17Routing AlgorithmsBroadcasting, Multicasting
- Spanning tree
- Given
- Graph G (V,E)
- Edge weights w w(e) is weight for edge e.
- Find a spanning tree T which has minimum weight,
i.e., minimum spanning tree - Recall, a spanning tree is a subgraph that is a
tree that includes all the nodes.
18Examples
8
7
4
9
Spanning Tree 42
2
4
11
14
6
10
7
8
1
2
1
2
19Kruskals Algorithm Basic Idea
- Start with a collection of subtrees
- Actually, each node is a subtree
- Find the lightest edge joining two subtrees
- Keep doing this until there is a single subtree
20Kruskals Algorithm Basic Idea
21Prims Algorithm Basic Idea
- Start with a single subtree of ONE node
- Grow this subtree by adding the lightest
- edge coming out of it.
- Keep doing this until the subtree is a
- spanning tree.
22Prims Algorithm Basic Idea