Representing problems with propositional schemas - Consider representing fact in Wumpus World, "there is a breeze next to a pit". - Very lengthy! PITij, BREEZEij - Need: compact way to specify a large set of clauses. Answer: SCHEMAS. - Introduce CONSTRUCTED PROPOSITIONS (predicate TERM TERM ...) each TERM is a CONSTANT or a VARIABLE. - Example of BREEZE using schemas with FORALL RANGE (forall VARIABLE (range LOW HIGH) TEST CLAUSE) - Example: 8-queens problems. -- What are the constraints in English? -- What propositions are needed? How many? -- "No queens attack" -- What is schema? -- How many clauses result? -- "At least one queen in each row" -- forall doesn't help! -- Introduce: (forsome VARIABLE (range LOW HIGH) TEST CLAUSE) -- Suppose we find a MODEL for these clauses. How do we read off the solution to the original 8-queens problem? - Another example: GRAPH COLORING. -- 4-color theorem -- Draw a map of NY, NJ, PA, MASS, VT, CONN -- Convert to a graph -- What variables need to represent coloring the graph? RED, BLUE, GREEN, YELLOW. -- Introduce: (define TYPE (CONSTANT CONSTANT ...)) -- Introduce: (forall VARIABLE TYPE TEST CLAUSE) - Homework: create SCHEMA for a CROSSWORD PUZZLE. Assignment should be done in TEAM of TWO or THREE. -- Match up. Who is left? Match them.