Skip to content
← All questions

How is the state-space tree expanded level by level in this example?

The tree is expanded breadth-first. After the root's children are created, the instructor treats that whole level as completed and then expands nodes from left to right across the current frontier. At each node, only jobs not already used on the path from the root are appended.

Conditions

  • The tree is explored level by level.
  • At each node, only jobs not already used on the path from the root are appended.
  • The clip shows structural expansion only, not pruning by bounds.

Reasoning, step by step

  1. Start from the root node representing the empty partial sequence.
  2. Create one child for each possible first job choice: J1J_1, J2J_2, J3J_3, J4J_4.
  3. Finish all immediate choices from the root, then expand node 2, then node 3, then node 4, then node 5.
  4. Continue similarly across the rest of the frontier until all displayed nodes reach depth 4.

Example

The instructor says, "Now this one level is completed. See, I have considered all the jobs one by one," and then proceeds to expand the next node on the frontier rather than diving deeper under the just-created children.

Common misconceptions

  • Assuming the tree is expanded depth-first, going down one branch to full depth before moving to siblings.
  • Thinking that all jobs can be appended at each node, ignoring those already used on the path.

Watch the explanation

Explore next

Answers are generated from source material and independently checked. Consult the original video or creator if something is unclear.