Presentation on theme: "Section 3 CS182 Intelligent Machines: Reasoning, Actions and Plans."— Presentation transcript:
Section 3 CS182 Intelligent Machines: Reasoning, Actions and Plans
A Variation of Tic-Tac-Toe Diagonal row (5 point!), vertical row (3 point!) and horizontal row (1 point!) Suppose you play and it’s your turn now:
Solve the Game
Alpha-Beta Pruning By Hand!
Evaluation Function Sometimes we really can’t make it to the terminal nodes… Cut-off tests and evaluation functions – How likely is this node to lead to a win? Evaluation function for Tic-tac-toe? -How many rows/columns your crosses/circles spread? -Among all diagonal/vertical/horizontal rows, how many are still reachable? -Winning patterns?
Constraint Satisfaction Problem: Can we graduate?
CSP for course requirements (1) Alby-Bach University (ABU) wants to start a new degree program: B.S in Judgment Day Prevention (JDP). Suppose the degree program is associated with the following courses: Fundamental Data Structures and Algorithms Principles of Programming Artificial Intelligence: Representation and Problem- Solving Machine Learning Logic and Computation Graph Theory Accounting Organizational Behavior Information Warfare
CSP for course requirements (2) In order to graduate from the degree program, one must complete the following four requirements: Algorithms Requirement: ( AND ) OR ( AND ) OR ( AND ) Machine Learning Requirement: OR OR Communications Requirement: OR OR Information Warfare Requirement: OR
CSP for course requirements (3) In addition, the department imposes the following restrictions: Information Aggressiveness Restriction: So that they can’t make their programs TOO smart, students can take only one class from the set , , and Basic Arithmetic Restriction: Students can’t take both and Organization Restriction: Students can’t take both and Finally, courses cannot be used to count towards multiple graduation requirements - so if you use to fulfill part of the Algorithms requirement it can’t count towards either the Machine Learning Requirement or the Information Warfare Requirement.
Model the problem as CSP (1) What are the variables? o AR_1 o AR_2 o MLR o CR o IWR
Model the problem as CSP (2) What are the domains? o AR_1: , , , , o AR_2: , , , , o MLR: , , o CR: , , o IWR: ,
Model the problem as CSP (3) What are the constraints? o IAR: 1 of , , and can be assigned to the 5 variables. o BAR: 1 of and can be assigned to the 5 variables o OR: 1 of and can be assigned to the 5 variables o No double counting: if a variable is assigned to one variable it can’t be assigned to another variable o Hidden constraint between AR_1 and AR_2
Forward Checking and Constraint Propagation (1) Suppose John has already taken towards his Information Warfare Requirement and towards his Algorithms Requirement. Use forward checking and constraint propagation to determine other classes he must take to graduate Can he graduate?
Forward Checking and Constraint Propagation (1) AR 1 has been set to and IWR has been set to Forward checking can then be used as follows: AR 2 domain goes from ,15-381,15-681, to due to IAR. MLR domain goes to due to IAR. CR goes to , due to BAR. Constraint propagation can then MLR domain has a single member, so we select AR 2 also has a single member, so we can select So we have a schedule which satisfies AR 1, AR 2, MLR, and CR. But to satisfy the CR we have to select between and (we can’t pick both) we would need to do some search here to pick between them