Moving to a different formalism... SEND + MORE MONEY

Similar documents
Week 8: Constraint Satisfaction Problems

Constraint Satisfaction Problems

Foundations of Artificial Intelligence

Solving Problems by Searching: Constraint Satisfaction Problems

Constraint Satisfaction Problems

Constraint Satisfaction Problems

Constraint Satisfaction Problems

Chapter 6 Constraint Satisfaction Problems

Constraint Satisfaction. CS 486/686: Introduction to Artificial Intelligence

Artificial Intelligence

Artificial Intelligence

Constraint Satisfaction Problems

Lars Schmidt-Thieme, Information Systems and Machine Learning Lab (ISMLL), University of Hildesheim, Germany, Course on Artificial Intelligence,

CS 343: Artificial Intelligence

Australia Western Australia Western Territory Northern Territory Northern Australia South Australia South Tasmania Queensland Tasmania Victoria

Constraint Satisfaction. AI Slides (5e) c Lin

Announcements. Homework 1: Search. Project 1: Search. Midterm date and time has been set:

What is Search For? CS 188: Artificial Intelligence. Constraint Satisfaction Problems

CS 188: Artificial Intelligence Fall 2011

Announcements. Homework 4. Project 3. Due tonight at 11:59pm. Due 3/8 at 4:00pm

Constraint Satisfaction Problems. Chapter 6

Constraint Satisfaction Problems

CS 188: Artificial Intelligence. What is Search For? Constraint Satisfaction Problems. Constraint Satisfaction Problems

Constraint Satisfaction Problems (CSPs)

Constraint Satisfaction Problems

Announcements. CS 188: Artificial Intelligence Fall 2010

Artificial Intelligence Constraint Satisfaction Problems

CSE 473: Artificial Intelligence

Constraint Satisfaction Problems

Constraint Satisfaction Problems Part 2

Constraint Satisfaction Problems

Outline. Best-first search

Constraint Satisfaction Problems

Constraint Satisfaction Problems. A Quick Overview (based on AIMA book slides)

Constraint Satisfaction Problems

CS 4100 // artificial intelligence

CS 188: Artificial Intelligence Fall 2008

Announcements. CS 188: Artificial Intelligence Fall Large Scale: Problems with A* What is Search For? Example: N-Queens

Lecture 6: Constraint Satisfaction Problems (CSPs)

Constraint Satisfaction Problems

CS 188: Artificial Intelligence. Recap: Search

What is Search For? CSE 473: Artificial Intelligence. Example: N-Queens. Example: N-Queens. Example: Map-Coloring 4/7/17

AI Fundamentals: Constraints Satisfaction Problems. Maria Simi

Iterative improvement algorithms. Today. Example: Travelling Salesperson Problem. Example: n-queens

Space of Search Strategies. CSE 573: Artificial Intelligence. Constraint Satisfaction. Recap: Search Problem. Example: Map-Coloring 11/30/2012

CS 4100/5100: Foundations of AI

Lecture 18. Questions? Monday, February 20 CS 430 Artificial Intelligence - Lecture 18 1

DIT411/TIN175, Artificial Intelligence. Peter Ljunglöf. 30 January, 2018

10/11/2017. Constraint Satisfaction Problems II. Review: CSP Representations. Heuristic 1: Most constrained variable

CS 771 Artificial Intelligence. Constraint Satisfaction Problem

CONSTRAINT SATISFACTION

Constraint Satisfaction

Constraint Satisfaction Problems. Chapter 6

Example: Map-Coloring. Constraint Satisfaction Problems Western Australia. Example: Map-Coloring contd. Outline. Constraint graph

Outline. Best-first search

CS W4701 Artificial Intelligence

Announcements. CS 188: Artificial Intelligence Spring Today. A* Review. Consistency. A* Graph Search Gone Wrong

Constraints. CSC 411: AI Fall NC State University 1 / 53. Constraints

Constraint Satisfaction Problems. slides from: Padhraic Smyth, Bryan Low, S. Russell and P. Norvig, Jean-Claude Latombe

What is Search For? CS 188: Ar)ficial Intelligence. Constraint Sa)sfac)on Problems Sep 14, 2015

Artificial Intelligence

CS 188: Artificial Intelligence Spring Announcements

ARTIFICIAL INTELLIGENCE (CS 370D)

Constraint Satisfaction Problems

Games and Adversarial Search II Alpha-Beta Pruning (AIMA 5.3)

Artificial Intelligence

General Methods and Search Algorithms

Discussion Section Week 1

Announcements. CS 188: Artificial Intelligence Spring Today. Example: Map-Coloring. Example: Cryptarithmetic.

Constraint satisfaction problems. CS171, Winter 2018 Introduction to Artificial Intelligence Prof. Richard Lathrop

Today. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 5. Constraint Satisfaction Problems (CSP) CSP Definition

CS 188: Artificial Intelligence Spring Announcements

Spezielle Themen der Künstlichen Intelligenz

Introduction. 2D1380 Constraint Satisfaction Problems. Outline. Outline. Earlier lectures have considered search The goal is a final state

Constraint Satisfaction Problems (CSPs) Introduction and Backtracking Search

CS 188: Artificial Intelligence Fall 2011

Recap: Search Problem. CSE 473: Artificial Intelligence. Space of Search Strategies. Constraint Satisfaction. Example: N-Queens 4/9/2012

Constraint Satisfaction Problems

Artificial Intelligence

CONSTRAINT SATISFACTION

Foundations of Artificial Intelligence

What is Search For? CS 188: Artificial Intelligence. Example: Map Coloring. Example: N-Queens. Example: N-Queens. Constraint Satisfaction Problems

Reading: Chapter 6 (3 rd ed.); Chapter 5 (2 nd ed.) For next week: Thursday: Chapter 8

Constraint Satisfaction Problems Chapter 3, Section 7 and Chapter 4, Section 4.4 AIMA Slides cstuart Russell and Peter Norvig, 1998 Chapter 3, Section

Announcements. CS 188: Artificial Intelligence Fall Reminder: CSPs. Today. Example: 3-SAT. Example: Boolean Satisfiability.

CS 188: Artificial Intelligence Fall 2008

Comments about assign 1. Quick search recap. Constraint Satisfaction Problems (CSPs) Search uninformed BFS, DFS, IDS. Adversarial search

PROBLEM SOLVING AND SEARCH IN ARTIFICIAL INTELLIGENCE

Set 5: Constraint Satisfaction Problems

Map Colouring. Constraint Satisfaction. Map Colouring. Constraint Satisfaction

Material. Thought Question. Outline For Today. Example: Map-Coloring EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS

CS 188: Artificial Intelligence

Constraint satisfaction search. Combinatorial optimization search.

CONSTRAINT SATISFACTION

Example: Map coloring

05 - Constraints Programming

CS 188: Artificial Intelligence. Recap Search I

Mathematical Programming Formulations, Constraint Programming

DIT411/TIN175, Artificial Intelligence. Peter Ljunglöf. 6 February, 2018

Announcements. Reminder: CSPs. Today. Example: N-Queens. Example: Map-Coloring. Introduction to Artificial Intelligence

Transcription:

Moving to a different formalism... SEND + MORE -------- MONEY Consider search space for cryptarithmetic. DFS (depth-first search) Is this (DFS) how humans tackle the problem? Human problem solving appears much more sophisticated! For example, we derive new constraints on the fly. In a sense, we try to solve problems with little or no search! In example, we can immediately derive that M =1. It then follows that S =8orS = 9. Etc. (derive more!) And if not, what do humans do? Slide CS47 Constraint Satisfaction 1 Slide CS47 Constraint Satisfaction Constraint Satisfaction Problems (CSP) A powerful representation for (discrete) search problems. A Constraint Satisfaction Problem (CSP) is defined by: X is a set of n variables X 1,X,...,X n, each defined by a finite domain D 1,D,...,D n of possible values. C is a set of constraints C 1,C,...,C m. Each C i involves some subset of the variables; specifies the allowable combinations of values for that subset. A solution is an assignment of values to the variables that satisfies all constraints. Cryptarithmetic as a CSP TWO + TWO -------- FOUR Slide CS47 Constraint Satisfaction Slide CS47 Constraint Satisfaction 4

Variables: T = {0,...,9}; W = {0,...,9}; O = {0,...,9}; F = {0,...,9}; U = {0,...,9}; R = {0,...,9}; Constraints: O + O = R +10 X 1 X 1 + W + W = U +10 X X + T + T = O +10 X X = F TWO+TWO=FOUR; each letter has a different digit (F T,F U, etc); Map-Coloring Problem Western Australia WA Northern Territory South Australia NT SA Queensland New South Wales Victoria Tasmania Q Victoria V NSW T Slide CS47 Constraint Satisfaction 5 Slide CS47 Constraint Satisfaction 6 Cryptarithmetic Constraint Graph T W O + T W O F O U R (a) F T U W R X X X 1 (b) O Constraint Satisfaction Problems (CSP) For a given CSP the problem is one of the following: find all solutions find one solution just a feasible solution, or a reasonably good feasible solution, or the optimal solution given an objective function determine if a solution exists Slide CS47 Constraint Satisfaction 7 Slide CS47 Constraint Satisfaction 8

How to View a CSP as a Search Problem? Initial State state in which all the variables are unassigned. Successor function assign a value to a variable from a set of possible values. Goal test check if all the variables are assigned and all the constraints are satisfied. Path cost assumes constant cost for each step Branching Factor Hypothesis 1 any unassigned variable at a given state can be assigned a value by an operator: branching factor as high as sum of size of all domains. Better approach since order of variable assignment not relevant, consider as the successors of a node just the different values of a single unassigned variable: max branching factor = max size of domain. Maximum Depth of Search Tree n the number of variables; all the solutions are at depth n. What are the implications in terms of using DFS vs. BFS? Slide CS47 Constraint Satisfaction 9 Slide CS47 Constraint Satisfaction 10 CSP Goal Decomposed into Constraints Example How to exploit it? Backtracking search: a DFS that chooses values for variables one at a time, checking for consistency with the constraints. An uninformed search Q=red Q=blue NT=blue WA=green WA=blue Slide CS47 Constraint Satisfaction 11 Slide CS47 Constraint Satisfaction 1

Constraint propagation: looking ahead Forward Checking each time variable is instantiated, delete from domains of the uninstantiated variables all of those values that conflict with current variable assignment. Arc Consistency state is arc-consistent, if every variable has some value that is consistent with each of its constraints (consider pairs of variables) K-Consistency generalizes arc-consistency. Consistency of groups of K variables. Constraint propagation: looking ahead Variable and value ordering: Minimum remaining values (MRV): choose the variable with the fewest possible values. Degree heuristic: assign a value to the variable that is involved in the largest number of constraints on other unassigned variables. Least-constraining value heuristic: choose a value that rules out the smallest number of values in variables connected to the current variable by constraints. Slide CS47 Constraint Satisfaction 1 Slide CS47 Constraint Satisfaction 14 Local Search for CSPs 1 1 0 Comparison of CSP Algorithms Problem BT BT+MRV BT+FC BT+FC+ Min-Conf USA (>1,000K) (>1,000K) K 60 64 n-queens (>40,000K) 1,500K (>40,000K) 817K 4K Slide CS47 Constraint Satisfaction 15 Slide CS47 Constraint Satisfaction 16

Dramatic recent progress in Constraint Satisfaction. For example, methods can now handle problems with 10,000 to 100,000 variables, and up to 1,000,000 constraints. Slide CS47 Constraint Satisfaction 17