Level structure: Difference between revisions
imported>GreenC bot Move 1 url. Wayback Medic 2.5 per WP:URLREQ#citeftp |
imported>Old Man Consequences stub sort |
||
| Line 1: | Line 1: | ||
{{Short description|Object in graph theory}} | |||
[[File:Graph level structure.svg|thumb|upright=1.3|An example for an undirected Graph with a vertex {{mvar|r}} and its corresponding level structure]] | [[File:Graph level structure.svg|thumb|upright=1.3|An example for an undirected Graph with a vertex {{mvar|r}} and its corresponding level structure]] | ||
{{hatnote|For the concept in algebraic geometry, see [[level structure (algebraic geometry)]]}} | {{hatnote|For the concept in algebraic geometry, see [[level structure (algebraic geometry)]]}} | ||
| Line 70: | Line 71: | ||
[[Category:Graph theory objects]] | [[Category:Graph theory objects]] | ||
{{graph-stub}} | |||
Latest revision as of 15:52, 11 November 2025
Script error: No such module "Hatnote". In the mathematical subfield of graph theory a level structure of a rooted graph is a partition of the vertices into subsets that have the same distance from a given root vertex.[1]
Definition and construction
Given a connected graph G = (V, E) with V the set of vertices and E the set of edges, and with a root vertex r, the level structure is a partition of the vertices into subsets Li called levels, consisting of the vertices at distance i from r. Equivalently, this set may be defined by setting L0 = {r}, and then, for i > 0, defining Li to be the set of vertices that are neighbors to vertices in Li − 1 but are not themselves in any earlier level.[1]
The level structure of a graph can be computed by a variant of breadth-first search:[2]Template:Rp
algorithm level-BFS(G, r):
Q ← {r}
for ℓ from 0 to ∞:
process(Q, ℓ) // the set Q holds all vertices at level ℓ
mark all vertices in Q as discovered
Q' ← {}
for u in Q:
for each edge (u, v):
if v is not yet marked:
add v to Q'
if Q' is empty:
return
Q ← Q'
Properties
In a level structure, each edge of G either has both of its endpoints within the same level, or its two endpoints are in consecutive levels.[1]
Applications
The partition of a graph into its level structure may be used as a heuristic for graph layout problems such as graph bandwidth.[1] The Cuthill–McKee algorithm is a refinement of this idea, based on an additional sorting step within each level.[3]
Level structures are also used in algorithms for sparse matrices,[4] and for constructing separators of planar graphs.[5]
References
<templatestyles src="Reflist/styles.css" />
Script error: No such module "Check for unknown parameters".