Logo

Code Fellows

Navigation

  • index
  • next |
  • previous |
  • Python Dev Accelerator 2.0 documentation »
  • Monday »

Graph Traversal: Depth First Search¶

Motivation¶

  • Knight’s Tour
  • Maze Generation & Solving
  • Topological Sort
  • Detecting a cyclic graph

Definition¶

Given a graph G and starting vertex s, depth first explores all levels of a graph, backtracking to the nearest unvisited neighber when it reaches a visited vertex.

Attributes¶

  • {is_visited | is_dirty | color}
  • frontier

Operations¶

traverse(G, s)

Table Of Contents

  • Graph Traversal: Depth First Search
    • Motivation
    • Definition
    • Attributes
    • Operations

Previous topic

Graph Traversal: Breadth First Search

Next topic

Tuesday

Quick search

Enter search terms or a module, class or function name.

Navigation

  • index
  • next |
  • previous |
  • Python Dev Accelerator 2.0 documentation »
  • Monday »
© Copyright 2014, Cris Ewing. Created using Sphinx 1.3.5.