Presentation is loading. Please wait.

Presentation is loading. Please wait.

Summary The Problem The Dijkstra’s Shortest Path Algorithm

Similar presentations


Presentation on theme: "Summary The Problem The Dijkstra’s Shortest Path Algorithm"— Presentation transcript:

0 Part 4: Network Layer Part A: Algorithms
4/17/2017 Part 4: Network Layer Part A: Algorithms

1 Summary The Problem The Dijkstra’s Shortest Path Algorithm
Distance Vector Routing Link State Routing Hierarchical Routing Routing in Ad Hoc Networks

2 1. The Problem (1) Store-and-Forward Packet Switching
4/17/2017 Store-and-Forward Packet Switching Services Provided to the Transport Layer Connectionless Service Connection-Oriented Service Research on DTN, Localization

3 1. The Problem (2): Packet Switching
4/17/2017 fig 5-1 Research on DTN, Localization The environment of the network layer protocols.

4 1. The Problem (3): Connectionless Service
4/17/2017 Research on DTN, Localization Routing within a diagram subnet.

5 1. The Problem (4): Connection-Oriented Service
4/17/2017 Research on DTN, Localization Routing within a virtual-circuit subnet.

6 1. The Problem (5): Connectionless VS. Connection-Oriented
4/17/2017 Research on DTN, Localization

7 2 Shortest Path Algorithm
The first 5 steps used in computing the shortest path from A to D. The arrows indicate the working node.

8 3 Distance Vector Routing (1)
(a) A subnet. (b) Input from A, I, H, K, and the new routing table for J.

9 3 Distance Vector Routing (2)
The count-to-infinity problem.

10 3 Distance Vector Routing (3): Loop-Breaking Heuristics
Set infinity to a limited number, e.g. 16. Split horizon Split horizon with poison reverse

11 3 Example: D A E B C Initialization A C E B D A C E B D A C E B D A C
1 10 2 A B C E D A C E B D A C E B D A C E B D Initialization

12 D A E B C Direct Neighbours A C E B D 1 A C E B D 10 2 1 2 A C E B D 2
10 2 1 2 1 10 2 A B C E D A C E B D 2 2 A C E B D 10 A C E B D Direct Neighbours 2 2

13 D A E B C Neighbours of neighbours A C E B D 1 A C E B D 11 10 2 3 1 2
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 2 2 A C E B D 10 A C E B D 3 Neighbours of neighbours 11 2 2

14 D A E B C Neighbours of neighbours A C E B D 1 A C E B D 11 10 2 3 1 2
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 13 2 2 A C E B D 10 A C E B D 3 Neighbours of neighbours 13 13 11 2 13 2

15 D A E B C Stable convergence A C E B D 1 A C E B D 11 10 2 3 1 2 A C E
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 13 2 2 A C E B D 10 A C E B D 3 Stable convergence 13 13 11 2 13 2

16 D A E B C Good news: A new link! A C E B D 1 A C E B D 11 10 2 3 1 2 A
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 13 2 2 1 A C E B D 10 A C E B D 3 Good news: A new link! 13 13 11 2 13 2

17 D A E B C Direct endpoints know A C E B D 1 A C E B D 11 10 2 3 1 2 A
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 13 2 2 1 A C E B D 10 A C E B D 3 Direct endpoints know 1 1 11 2 13 2

18 D A E B C Neighbours know A C E B D 1 A C E B D 3 10 2 3 1 2 A C E B D
3 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 1 A C E B D 4 A C E B D 3 Neighbours know 1 1 3 2 3 2

19 D A E B C Neighbours of neighbours know A C E B D 1 A C E B D 3 4 2 3
3 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 1 A C E B D 4 A C E B D 3 Neighbours of neighbours know 1 1 3 2 3 2

20 D A E B C A happy and stable network A C E B D 1 A C E B D 3 4 2 3 1 2
3 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 1 A C E B D 4 A C E B D 3 A happy and stable network 1 1 3 2 3 2

21 D A E B C Bad news: Link crash!! A C E B D 1 A C E B D 3 4 2 3 1 2 A C
3 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 A C E B D 4 A C E B D 3 Bad news: Link crash!! 1 1 3 2 3 2

22 D A E B C Direct endpoints know A C E B D 1 A C E B D 3 4 2 3 1 2 A C
3 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 A C E B D A C E B D 3 Direct endpoints know 2 2

23 D A E B C A C E B D 1 A C E B D 3 4 2 3 1 2 A C E B D 3 3 3 2 2 A C E
3 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 A C E B D 10 A C E B D 3 2 2

24 D A E B C Get help from neighbours A C E B D 1 A C E B D 3 4 2 3 1 2 A
3 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 3 2 2 A C E B D 10 A C E B D 3 Get help from neighbours 5 13 11 2 13 2

25 D A E B C Routing loop (due to inconsistent state info) A C E B D 1 A
7 4 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 7 2 2 A C E B D 10 A C E B D 3 Routing loop (due to inconsistent state info) 5 13 11 2 13 2

26 D A E B C A C E B D 1 A C E B D 7 8 2 3 1 2 A C E B D 3 3 7 2 2 A C E
7 8 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 7 2 2 A C E B D 10 A C E B D 3 9 13 11 2 13 2

27 D A E B C Counting to infinity… A C E B D 1 A C E B D 11 8 2 3 1 2 A C
11 8 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 11 2 2 A C E B D 10 A C E B D 3 Counting to infinity… 9 13 11 2 13 2

28 D A E B C A C E B D 1 A C E B D 11 10 2 3 1 2 A C E B D 3 3 11 2 2 A C
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 11 2 2 A C E B D 10 A C E B D 3 13 13 11 2 13 2

29 D A E B C A C E B D 1 A C E B D 11 10 2 3 1 2 A C E B D 3 3 13 2 2 A C
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 13 2 2 A C E B D 10 A C E B D 3 13 13 11 2 13 2

30 D A E B C Stability again A C E B D 1 A C E B D 11 10 2 3 1 2 A C E B
11 10 2 3 1 2 1 10 2 A B C E D A C E B D 3 3 13 2 2 A C E B D 10 A C E B D 3 Stability again 13 13 11 2 13 2

31 4 Link State Routing (1) 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.

32 4 Link State Routing (2): Learning about the Neighbors
Nine routers and a LAN. A graph model of (a).

33 4 Link State Routing (3): Measuring Line Cost
A subnet in which the East and West parts are connected by two lines.

34 4 Link State Routing (4): Building Link State Packets
(a) A subnet. (b) The link state packets for this subnet.

35 4 Link State Routing (5): Distributing the Link State Packets
The packet buffer for router B in the previous slide (Fig ).

36 5 Hierarchical Routing Hierarchical routing.

37 6. Routing in Ad Hoc Networks (1)
Possibilities when the routers are mobile: Military vehicles on battlefield. No infrastructure. A fleet of ships at sea. All moving all the time Emergency works at earthquake . The infrastructure destroyed. A gathering of people with notebook computers. In an area lacking

38 6. Routing in Ad Hoc Networks (2): Route Discovery
(a) Range of A's broadcast. (b) After B and D have received A's broadcast. (c) After C, F, and G have received A's broadcast. (d) After E, H, and I have received A's broadcast. Shaded nodes are new recipients. Arrows show possible reverse routes.

39 6. Routing in Ad Hoc Networks (3): Route Discovery
Format of a ROUTE REQUEST packet.

40 6. Routing in Ad Hoc Networks (4): Route Discovery
Format of a ROUTE REPLY packet.

41 6. Routing in Ad Hoc Networks (5): Route Maintenance
(a) D's routing table before G goes down. (b) The graph after G has gone down.


Download ppt "Summary The Problem The Dijkstra’s Shortest Path Algorithm"

Similar presentations


Ads by Google