11.1 Definition of Classical Planning
A classical problem specifies an initial state, a goal, and actions whose preconditions and effects define state transitions; actions are usually deterministic and fully observable.
AI · Knowledge, reasoning, and planning
Planning searches for a sequence of actions that transforms an initial state into a goal state. Watch a simple shortest-path planner use actions with preconditions and effects.
A classical problem specifies an initial state, a goal, and actions whose preconditions and effects define state transitions; actions are usually deterministic and fully observable.
Search can proceed forward through reachable states or backward from the goal. Planning representations such as STRIPS make action preconditions and add/delete effects explicit.
Relaxed problems—often ignoring negative effects—yield estimates of remaining work that guide search toward promising states.
High-level tasks can be decomposed into smaller subtasks until executable primitive actions remain.
When actions have multiple possible outcomes, a plan may need branches that condition later actions on observations.
Temporal planners account for action durations, deadlines, concurrency, and limited resources—not only ordering.
Planning methods trade off expressiveness and computational cost; domain structure and uncertainty determine which approach is suitable.
Interactive planner
Each move has a precondition (the destination is open) and effect (the agent changes cell). Breadth-first search finds a shortest route around walls.
Start at the green cell; walls are impassable.
Let V be the number of open grid cells and E the legal neighbor links; BFS visits each cell at most once and checks each link a constant number of times. The queue uses a head index (not repeated front-removal), and each cell has at most four neighbors. Let N be all displayed cells, including walls.
Search time: O(V + E); on this fixed-degree grid E = O(V), so O(V). Auxiliary space: O(V) for queue, seen set, and parent map. The returned plan is output storage O(L), where L ≤ V is its move count. Playback redraws all N cells per action, so its UI work is O(L·N) overall (and the grid DOM is O(N)); the search itself remains O(V + E). Here the board is 5×5 and walls are fixed. Bounds assume unit-cost moves and expected O(1) Set/Map operations.