Modeling a search space data structure for state - immutable! (const) (usually) data structure/model type for action - actions are how you get from one state to another valid-moves: state -> list next-state: state x action -> state (state,action) -> state "transition model" eval-state: state -> ??? bool (accept / not) enum (win / lose / draw / not-done) int (score) init-state: () -> state in A* 262 project: state: Location action: - N, S, E, W - or, just Location Amsterdam to Prague train trip w/ few transfers and doesn't take forever (--> covers the shortest physical distance?) state: city (i.e. the station that is in that city) action: (city, city) (source and destination of one train route) valid-moves: state -> list list of connected cities (train routes that exit source city) next-state: state x action -> state simply produces the "destination city" from that action init-state: () -> state Amsterdam! eval-state: state -> bool Is the city Prague? heuristic: state -> score **Is this city adjacent to Prague? -> 0, 1, 2 **What is the crow-flies distance from this city to Prague? Prove (cos(x+y))/(cos x cos y) === 1 - (tan x tan y) state: an equation of two trigonometric expressions action: a trig identity to apply valid-moves: which trig identities match some part of the state? next-state: state x action -> state apply the trig identity (action) to the current equation (state), produce new valid equation (state) init-state: (cos(x+y))/(cos x cos y) === 1 - (tan x tan y) eval-state: Are both sides of the === exactly the same? We have a sudoku starting board; solve it state: the current board: 2d array of int (1-9, 0 for blank) [9][9] action: (int num-to-place, pair(int x, int y)) valid-moves: list of (number, position) pairs we could place next-state: board after placing that number init-state: initial board w/ pre-filled numbers eval-state: is the board solved---is every space filled?