liveBook · Manning

Source node

As explained in Algorithms Every Programmer Should Know

A source node is the vertex from which a graph traversal or route computation begins.

A source node, or starting node, is the chosen vertex where a graph traversal or route computation begins. Unlike a tree's root, it is selected according to the problem. section 1.4.5

Route planning

For a Google Maps route, the source node is the user's current location; traversal expands outward from that vertex. section 1.4.5

How Algorithms Every Programmer Should Know covers it

How deep it goes
Defines the starting vertex as arbitrary and problem-dependent, but gives no criteria for choosing among candidates.
Examples
Uses a user's current location in Google Maps as the source for route calculation.
What you can do after
Apply graph traversal by choosing the problem-specific starting vertex, such as a user's current location.
How it connects
Connects graph traversal with breadth-first search, depth-first search, and route computation.

Also explained in

Compare how 4 books explain source node →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Algorithms Every Programmer Should Know. The section links point to the parts of the book it draws on.