Forest

Context: FIT1058_MOC Β· an acyclic Graph (connectivity dropped) Β· a disjoint union of trees Β· edges for components

Quick Revision

  • 🎯 Objective: an acyclic graph, not required connected βž” a disjoint union of trees.
  • πŸ“¦ Core Components: each component a Tree βž” edges for components.
  • ⚑ Key Constraint: generalises the tree’s ; acyclicity is componentwise.

πŸ“ Core

1. The Forest

  • Definition βž” a graph with no cycles, not required connected.
  • Components βž” each connected + acyclic ⟹ a Tree; a forest is a disjoint union of trees.

2. Edge Count

  • Formula βž” vertices, components ⟹ exactly edges.
  • Proof βž” (each tree ).
  • Generalises βž” tree formula is .

3. Trees & Forests

  • Tree βŠ† forest βž” a tree is a one-component forest.
  • Componentwise βž” any cycle lives in one component.

Key identities:

βš–οΈ Core Decision Matrix

ObjectConnected?Edges
treeyes
forest ( comps)not required
isolated vertexβ€”0 (1-vertex tree)
acyclicyes (defining)β€”

When It Flips: a forest relaxes the Tree's connectivity but keeps acyclicity; Kruskal's Greedy Algorithm's partial result is always a forest, becoming a Spanning Tree once it connects up.

πŸ“Š Exam Execution Trace

Manual Execution Trace

Forest, 10 vertices, components 4,3,3:

Step / StateComponent
0 (Init)β€”β€”β€”
143
232
332

⚠️ Common Mistakes

  • πŸ’‘ Each extra component costs one fewer edge βž” (tree) β†’ ; edges are exactly what would merge the trees into one.

🧠 Active Recall