DIJKSTRA - PowerPoint PPT Presentation

1 / 6
About This Presentation
Title:

DIJKSTRA

Description:

DIJKSTRA s Algorithm Definition fwd search Find the shortest paths from a given SOURCE node to ALL other nodes, by developing the paths in order of increasing path ... – PowerPoint PPT presentation

Number of Views:49
Avg rating:3.0/5.0
Slides: 7
Provided by: KalmanP6
Category:

less

Transcript and Presenter's Notes

Title: DIJKSTRA


1
DIJKSTRAs Algorithm
2
Definition fwd search
  • Find the shortest paths from a given SOURCE node
    to ALL other nodes, by developing the paths in
    order of increasing path length. The alg.
    Proceeds in stages.
  • N set of nodes in the network
  • S sourse node
  • M set of nodes so far incorporated by the alg
  • l(i,j) link cost from node i to jl(i,i)0
    l(i,j)? if the two nodes are not directly
    connected l(i,j)gt0 if they are directly
    connected
  • C1(n) least-cost paths from S to n

3
FWD. Search Algorithm
  • 1.Set MS for each node n?N-S, set
    C1(n)l(S,n)
  • 2. Find W ? N-M so that C1(w) in minimum, add W
    to M. Set C1(n) MIN? C1(n) and C1(w)l(w,n)
  • 3. Repeat 2. until MN

4
Definition bwd search
  • Find the shortest paths from a given DESTINATION
    node from ALL other nodes.
  • N set of nodes in the network
  • D destination node
  • M set of nodes so far incorporated by the alg
  • l(i,j) link cost from node i to jl(i,i)0
    l(i,j)? if the two nodes are not directly
    connected l(i,j)gt0 if they are directly
    connected
  • C2(n) least-cost paths from D to n

5
(No Transcript)
6
BWD. Search Algorithm
  • 1.Set C2(D)0 for each node n?N-D set C2(n) ?
  • 2. For each node n? N-D set C2(n) MIN? C2(n)
    and C2(w)l(n,w) (w ? N)
  • 3. Repeat 2. until no changes in C2
Write a Comment
User Comments (0)
About PowerShow.com