SlideServe
Menu
Préférences
© SlideServe · v2026

Understanding Breadth-First Search: Algorithms and Applications in Networking

lev-fletcher avatar
13 diapositives · 336 Views · Nov 13, 2014

This seminar, led by Mohammad Reza Akhavan at Lulea University of Technology, covers Breadth-First Search (BFS) and its applications in networking algorithms. The session provides insights into rooted trees, spanning trees, and the BFS algorithm's mechanics. Attendees will learn how BFS visits nodes to determine graph connectivity, finds shortest paths, and detects cycles. The importance of labeling nodes based on distance from a root node is emphasized. Key resources include "Introduction to Distributed Algorithms" by Gerard Tel.

Understanding Breadth-First Search: Algorithms and Applications in Networking - slide 1
01 / 13Understanding Breadth-First Search: Algorithms and Applications in Networking
1 / 17

Télécharger la présentation

Understanding Breadth-First Search: Algorithms and Applications in Networking
Une image / un lien ci-dessous est fourni (tel quel) pour télécharger la présentation

Politique de téléchargement : le contenu du site vous est fourni TEL QUEL pour votre information et votre usage personnel ; il ne peut être vendu, concédé sous licence ni partagé sur d’autres sites sans l’accord de son auteur.Le contenu vous est fourni TEL QUEL, pour votre information et votre usage personnel uniquement. Téléchargez la présentation en cliquant sur ce lien. Lors du téléchargement, si vous ne parvenez pas à télécharger une présentation, l’éditeur a peut-être supprimé le fichier de son serveur.Pendant le téléchargement, si vous ne parvenez pas à obtenir une présentation, le fichier a peut-être été supprimé par l’éditeur.

F I N

Plus de contenu associé

Transcription de la présentation
  1. Breadth-First Search Seminar – Networking Algorithms CS and EE Dept. Lulea University of Technology 27 Jan. 2005 Mohammad Reza Akhavan

  2. Outline (BFS) • Rooted Tree • Spanning Tree • Breadth-First Search • BFS Algorithm • Example

  3. Rooted Tree • A rooted tree is a tree in which a special node is singled out. This node is called the "root“. A tree which is not rooted is sometimes called a free tree. Rooted Tree Free Tree

  4. Spanning Tree A spanning tree in a graph G with n nodes and m edges: • A sub-graph that connects all the nodes. • A sub-graph with no cycles. • A sub-graph with m=n-1 edges.

  5. Breadth-First Search • Visits all the nodes and edges of G • Determines whether G is connected • Computes the connected components of G • Find and report a path with the minimum number of edges between two given nodes • Find a simple cycle, if there is one • Provide the shortest path from a given root to all other nodes of the network

  6. BFS for Shortest Path (i=0) s 0 • The algorithm uses a mechanism for setting and getting “labels” of nodes and edges. • Nodes whose distance from s is 0 are labeled.

  7. BFS for Shortest Path (i=1) s 1 0 1 1 Nodes whose distance from s is 1 are labeled.

  8. BFS for Shortest Path (i=2) 1 s 0 2 2 1 2 1 Nodes whose distance from s is 2 are labeled.

  9. 1 s 0 2 2 3 1 2 1 BFS for Shortest Path (i=3) Nodes whose distance from s is 3 are labeled. The next iteration finds out that the whole graph is labeled and therefore the procedure stops.

  10. 1 s 0 2 2 3 1 2 1 s 1 0 2 2 3 1 2 1 The BFS Tree

  11. BFS Algorithm • The algorithm uses a mechanism for setting and getting “labels” of nodes and edges • Search a graph by increasing distance from the starting vertex (or from the starting vertices in case of several connected components). • Can think of creating one level after the other (by increasing depth).

  12. BFS – Asynchronies Mode 0 1 1 1 3 2 3 2 2 2 4 2 3 3 4 3 4 2 3 4 4 5 4 3 7 5 7 7 4 6 6

  13. References: • Introduction to Distributed Algorithms by Gerard Tel. • Google !