Download presentation
Presentation is loading. Please wait.
Published byVirgil Shields Modified over 9 years ago
1
Routing in Communication Networks Routing: Network layer protocol that guides information units to correct destinations. A complex collection of decision rules that work somewhat independently. - Determination of allowable path set for each origin - destination pair - Broadcast of routing related information to all network nodes - Determination of particular path per arrived call.
2
Routing Types Virtual circuit routing Datagram routing
3
Characteristics Performance indices Throughput Delay Under light load: throughput = offered load Under heavy load: throughput = offered load - rejected load
4
Routing interacts with flow control to maintain the performance Traffic experiences delay depending on routing Flow control rejects a portion of load depending on delay
5
Routing Types Revisited Virtual circuit vs. datagram Centralized vs. distributed Static vs. adaptive Hierarchical vs. non hierarchical
6
Broadcasting Send information from a node to all nodes in networks (e.g., announcing equipment and link failures) Send information from a node to some selected subset of nodes Examples of broadcasting method: Flooding A node send a packet to all of its neighbors. Each neighbor sends the received packet to its neighbors and so on. Loop back should be eliminated. Multiple transmissions must be eliminated. Not efficient.
7
Example: Spanning Tree Connected sub-graph of network including all nodes No cycles Packets transmitted over spanning tree More efficient than flooding Packets transmitted N-1 times (N = number of nodes)
8
Routing Examples Shortest path routing Each link has a link length (> 0). Path length is the sum of link lengths over the path. Shortest path routing routes each packet over a minimum length path (i.e.,a greedy algorithm). Minimum hop routing: If every link has a unit link cost. Optimal routing Routes are determined for all OD pairs simultaneously for the good of entire network. Can eliminate potential oscillations in the shortest path routing. Hot potato routing Minimize buffer requirements. Arrived packets are routed on an out-going link from the list of links. Packets may get out of sequence. Packets may experience long delay.
9
Cut-through routing Minimizes delay. Packets are allowed to go out on an out-going link as soon as initial few bits arrive. Error checking and ARQ cannot be done. Link reservation is needed while transmitting a packet. Speed mismatch among links can create overflows/congestions.
10
ARPANET routing Adaptive and distributed datagram routing Shortest path routing based on link delay as link length Shortest paths are calculated using Bellman-Ford algorithm. Link lengths are updated every 10 seconds. TYMNET routing Centralized and adaptive virtual circuit routing Supervisor determines the routing for all nodes. Shortest lath routing based on link load as link length SNA routing Network manager chooses virtual paths for each OD pair Circuit switched routing Like virtual circuit routing Typically implemented with hierarchy
11
Interconnected Network Routing Involves gateways, routers, and bridges between networks Non hierarchical routing Control becomes complex. Much information needs be stored at each node.
12
Hierarchical routing long distance routing Routing within sub-network Lower information storage at potentially lower performance
13
Graphical Model for Routing Use of Graph Theoretic Model Undirected graph G = (N, A) N = finite non empty set of nodes A = collection of pairs of distinct nodes from N called arc. N = {1,2,3,4} A = {(1,2), (2,3), (4,1), (2,4)} Note: No loop No multiple arcs between the same pair of nodes A node is also called a vertex. An arc is also called an edge, link, or branch. 12 3 4
14
Definition: A walk is a sequence of nodes (n 1, n 2, n 3,…,n l ) such that (n 1, n 2 ) (n 2, n 3 ),…(n l-1, n l ) are each an arc in G. Definition: A path is a walk with no repeated node. Definition: A cycle is a path with no repeated node expect for n 1 = n l. 1, 4, 2, 1, 4, 1 walk 1, 4, 2, 3 path 1, 2, 4, 1 cycle 1 2 4 3
15
Definition A graph is connected if from each node i, there is a path to any other nodes j. 1 2 3 5 4 unconnected graph
16
Lemma: Let G = (N,A) is a graph. S N and S N. Then G is connected if for any such S there is at least one arc (i, j) with i S and j S. Definition: g= (n, a) is a sub-graph of G=(N,A) if g is a graph and n N and a A. Definition: A tree is a connected graph with no cycle. Definition: A spanning tree of a graph G is a sub-graph of G that is a tree and that includes all nodes of G. S i S c j G
17
Spanning Tree Tree 1 2 3 4 5 7 6 Spanning Tree 2 1 5 4 3 6 7 1 2 3 4 5 6 7 G = (N, A)
18
Using the lemma, we can find an algorithm for generating a spanning tree of a connected graph G = (N,A). 1 2 4 3 1 2 1 1 22 3 3 4
19
Proof (that the algorithm above gives a spanning tree.): Note: In each step, we add one node and one arc. Since we start with one node and no arc, the algorithm must end with |N| nodes and |N |-1 arcs. We can use this algorithm to show that if G = (N, A) is connected then |A| |N|-1 and G is a tree if |A| = |N|-1.
20
Minimum Weight Spanning Tree (MST) For G = (N,A), let each arc (i, j) has some weight w ij. We want to find a spanning tree with the minimum sum of arc weights. Definition Any sub-tree of an MST is called a fragment. Definition An arc having one node in a fragment and the other one outside the fragment is called an outgoing arc. Fact Given a fragment F, let =(i, j) be a minimum weight outgoing arc form F where i F and j F. The F extended by the arc and node j is fragment. F MST 4 5 2 2 j 4 6 3 2 2 3 1 1 i
21
Kruskal’s Algorithm Start with each node being a fragment. Order the arc weights in an ascending order w 1, w 2, w 3, …,w |A|.. At each iteration, add an arc that has the minimum weight out of all arcs that are outgoing from all of the fragments. 16 5 8 49 2 3 7 Kruskal’s algorithm can be made distributed if MST is unique. (Each fragment adds the minimum weight outgoing arc and includes the fragment on the other side of that arc.) If MST is not unique, Kruskal’s algorithm cannot be made distributed.
22
Prim-Dijkstra Algorithm Start with a single node (which is a fragment). 16 5 8 49 2 3 7 The resulting MST may not be unique. It all arc weights are distinct, the MST is unique.
23
Directed Graph (Digraph) For a graph G = (N,A), let N be a finite non empty set of nodes and let A be a collection of ordered pairs of distinct nodes from N. (There is no loop as before.) Definition Given a digraph G = (N, A), a graph G´=(N´, A´) is (undirected) associated graph if N´= N and (i, j) A´ if (i,j) A or (j,i) A. Definition Walk, path, cycle in a digraph are those of the associated graph. Definition (n 1, n 2, n 3, …, n l ) is a directed walk in G if (n i, n i+1 ) is a directed arc in A for i=1, 2, 3,…, l-1. 1 2 3 4
24
Definition G= (N, A) is strongly connected if for each pair i N and j N, there is a directed path from i to j. Fact G is connected if the associated graph is connected. Definition For a given digraph G = (N, A), assign to each arc (i, j), some number d ij as the length of the arc. The length of a path is the sum of the lengths of the arcs that comprise the path. Problem Definition Shortest Path Problem is a problem that finds, for any two given nodes i and j, a path with the shortest path length.
25
Bellman – Ford Algorithm At each step, calculate the shortest path using h or less arcs. At the end of the first step, we have the shortest paths using one arcs. At the end of the second step, we have shortest paths using two or less arcs. And so on. Example:
26
Example 1 1 1 4 4 4 2 2 2 2 3 5 8 1 1 4 3 5 4 2 G = (N, A)
28
A path can contain at most |N|-1 arcs. Thus is the shortest path length from 1 to i. If for all i, is the shortest path length and we can stop the algorithm. At step h, the algorithm finds the shortest ( h) walk from 1 to i subject to constraint that node 1 is not repeated in the walk. Other nodes can potentially be repeated, however. If there is a negative length cycle, the algorithm will not converge. (We can have negative length arcs, but cannot have negative length cycles.) To get the shortest path, solve Bellman – Ford equations:
29
Dijkstra’s Algorithm All arc lengths must be positive Dijkstra’s algorithm is less computationally intensive than Bellman – Ford
30
Example Initial : 1 2 1 1 1 1 4 4 4 2 2 2 2 3 5 8 Find shortest path from node 1. At each step, we need to use
31
1 1 1 2 3 1 35 2 1 2 1
32
1 1 3 2 5 4 4 1 2
33
Floyd-Warshall Find shortest path between al pairs of nodes at the same time. Arc lengths can be negative. No negative length cycles allowed. Iterate on the number of intermediate nodes in a path:
34
Distributed Bellman - Ford Finds the shortest path to a given node (say node 1) from all other nodes. Bellman-Ford algorithm is given by Where N(i) is set of all neighbors of i. Note: An alternative (perhaps better known) version is to find shortest path fro node 1 to all other nodes. (1) can be implemented in distributed manner. 1. All nodes will execute (1) simultaneously. 2. Exchange the results of the computation with their neighbors. 3. Execute (1) again with index h incremented by 1. Initial condition:
35
Algorithm will end in N-1 steps. It is not easy to synchronize all the nodes. If the network changes (e.g., due to failures), re-synchronization is needed. Distributed version of Bellman-Ford. Execute indefinitely the following : Where is the latest estimate received from node are the latest arc length. More formal notation: At each time t, node i has
36
Main Components of Distributed Bellman-Ford
37
Main Assumptions for Proper Working of Distributed Bellman-Ford Algorithm Nodes never stop updating the own estimates and receiving messages from all their neighbors. All initial node estimates and are non negative. All estimates communicated to node before initial time and received after are non negative. Old distance information is eventually purged. With the assumptions above: Proposition : There is a time such that for all D i is the correct shortest distance.
38
Routing in ARPANET Original version (1969) Length of each link depends on the number of packets waiting in the link queue. Nodes exchange information on the shortest distance every 625 msec. Bellman-Ford algorithm is used for shortest paths. Prone to oscillation. Modified version (1979) Length of each link is proportional to the average delay. Link length is updated every 10 seconds. Nodes exchange information on the length of their outgoing links every 60 seconds. Shortest path is calculated by Dijkstra’s algorithm. Prone to oscillation.
39
Optimal Routing We want to quantify the traffic congestion in a network in terms of the arrival processes. One common performance measure is the sum of packet delays. Formal representation of network performance:
40
Notation
41
Optimal Routing Problem Minimize
43
Optimization Lemma Let f be differentiable convex function of the n- dimensional vector x={x 1, x 2, … x n ). Let. X be a convex set of vectors. Then x* X is an optimal solution of the problem: Minimize : f(x) Subject to : x X
44
Proof
46
Optimality Condition
47
Proof
48
Summery of Optimal Condition A set of path flows is optimal iff path flow is positive only on the paths with a minimum first derivative length. Also at the optimum path flow vector, the path along which the traffic r w is split must have equal length. Example: r x1x1 r x2x2 C2C2 C1C1
51
Example r r
53
1234 1 2 r
54
Feasible Direction Methods In optimal routing, there is a positive flow only on those paths with minimum first derivative length (MFDL). A path flow vector x is strictly sub optimal if there is a positive flow on a non NFDL path. Given a sub optimal path flow vector, we can improve the routing by shifting flows from non MFDL paths to MFDL paths. A path flow vector x={x p } that satisfies the constrains Suppose we have a non MFDL path flow vector x which is feasible.
56
Constraint Set Feasible descent directions at x Surface of equal cost
57
Frank – Wolfe Method
59
Example r=1 r
61
Topological Design Design a data network at minimum cost while maintaining the performance requirements. Assumptions Locations of terminal are known. Traffic level between each OD pair is known. Selection Topology of a communication sub network meeting the traffic demand. Topology of local access network Objectives Satisfy the average delay per packet constraint for a given routing scheme. Satisfy the reliability constraint with respect to node and link failures. Minimize cost. TT TTN NN N C C Access Network Subnet
62
Subnet Design Given Location of nodes Traffic demand between nodes Selections Capacity of links Flow of links Simplifications No reliability consideration Linear cost
65
Local Access Design Problem 1 Sub network is available. Design a network that connects a set of terminals to
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.