Outline What are CSPs? Standard search and CSPs Improvements. Constraint Satisfaction. Introduction. Introduction
|
|
- Toby Norris
- 6 years ago
- Views:
Transcription
1 Constraint Satisfaction CS 86/686 May 6, 006 University of Waterloo Outline What are CSPs? Standard search and CSPs Improvements acktracking acktracking + heuristics Forward checking Introduction In the last couple of lectures we have been solving problems by searching in a space of states reating states as black boxes, ignoring any structure inside them Using problem-specific routines oday we study problems where the state structure is important States: all arrangements of 0,,, or 8 queens on the board Initial state: 0 queens on the board Successor function: Add a queen to the board Goal test: 8 queens on the board with no two of them attacking each other 6x6x 57 x0 states States: all arrangements k queens (0 k 8), one per column in the leftmost k columns, with no queen attacking another Initial state: 0 queens on the board Successor function: Add a queen to the leftmost empty column such that it is not attacked Goal test: 8 queens on the board 057 States 5 Introduction Earlier search methods studied often make choices in an arbitrary order In many problems the same state can be reached independent of the order in which the moves are chosen (commutative actions) Can we solve problems efficiently by being smart in the order in which we take actions? 6
2 -queens Constraint Propagation -queens Constraint Propagation Place a queen in a square Place a queen in a square emove conflicting squares from consideration 7 emove conflicting squares from consideration 8 -queens Constraint Propagation -queens Constraint Propagation Place a queen in a square Place a queen in a square emove conflicting squares from consideration 9 emove conflicting squares from consideration 0 CSP Definition CSP Definition A constraint satisfaction problem (CSP) is defined by {,D,C} where ={,,, n } is a set of variables D={D,,D n } is the set of domains, D i is the domain of possible values for variable i C={C,,C m } is the set of constraints Each constraint involves some subset of the variables and specifies the allowable combinations of values for that subset A state is an assignment of values to some or all of the variables { i =x i, j =x j, } An assignment is consistent if it does not violate any constraints A solution is a complete, consistent assignment ( hard constraints ) Some CSPs also require an objective function to be optimized ( soft constraints )
3 Example : 8-ueens Example 8 queens 6 variables ij, i= to 8, j= to 8 Domain of each variable is {0,} Constraints ij = ik =0 for all k j ij = kj =0 for all k i Similar constraint for diagonals i,j ij =8 inary constraints relate two variables 8 variables i, i= to 8 Domain of each variable is {,,,8} Constraints i =k j k for all j i Similar constraints for diagonals inary constraints relate two variables Example - Map Coloring Example from and N, Annotations from Stanford CS Example - Street Puzzle 7 variables {,,,,,,} Each variable has the same domain: {red, green, blue} No two adjacent variables have the same value:,,,,,,,, Constraint graph 5 5 C i = {ed, Green, White, Yellow, lue} D i = {ea, Coffee, Milk, Fruit-juice, Water} J i = {Painter, Sculptor, Diplomat, iolinist, Doctor} he Englishman lives in the ed house he Spaniard has a Dog he Japanese is a Painter he Italian drinks ea he Norwegian lives in the first house on the left he owner of the Green house drinks Coffee he Green house is on the right of the White house he Sculptor breeds Snails he Diplomat lives in the Yellow house he owner of the middle house drinks Milk he Norwegian lives next door to the lue house he iolinist drinks Fruit juice he Fox is in the house next to the Doctor s he Horse is next to the Diplomat s Who owns the Zebra? Who drinks Water? 6 Example from and N, Annotations from Stanford CS Street Puzzle 5 C i = {ed, Green, White, Yellow, lue} D i = {ea, Coffee, Milk, Fruit-juice, Water} J i = {Painter, Sculptor, Diplomat, iolinist, Doctor} he Englishman lives in the ed house (N i = English) (C i = ed) he Spaniard has a Dog he Japanese is a Painter (N i = Japanese) (J i = Painter) he Italian drinks ea he Norwegian lives in the first house on the left (N = Norwegian) he owner of the Green house drinks Coffee he Green house is on the right of the White house he Sculptor breeds Snails he Diplomat lives in the Yellow house (C i = White) (C i+ = Green) he owner of the middle house drinks Milk (C 5 White) he Norwegian lives next door to the lue house (C Green) he iolinist drinks Fruit juice he Fox is in the house next to the Doctor s he Horse is next to the Diplomat s left as an exercise 7 Example from and N, Annotations from Stanford CS Street Puzzle 5 C i = {ed, Green, White, Yellow, lue} D i = {ea, Coffee, Milk, Fruit-juice, Water} J i = {Painter, Sculptor, Diplomat, iolinist, Doctor} he Englishman lives in the ed house (N i = English) (C i = ed) he Spaniard has a Dog he Japanese is a Painter (N i = Japanese) (J i = Painter) he Italian drinks ea he Norwegian lives in the first house on the left (N = Norwegian) he owner of the Green house drinks Coffee he Green house is on the right of the White house he Sculptor breeds Snails he Diplomat lives in the Yellow house (C i = White) (C i+ = Green) he owner of the middle house drinks Milk (C 5 White) he Norwegian lives next door to the lue house (C Green) he iolinist drinks Fruit juice he Fox is in the house next to the Doctor s he Horse is next to the Diplomat s unary constraints 8
4 Example from and N, Annotations from Stanford CS Street Puzzle 5 C i = {ed, Green, White, Yellow, lue} D i = {ea, Coffee, Milk, Fruit-juice, Water} J i = {Painter, Sculptor, Diplomat, iolinist, Doctor} i,j [,5], i j, N i N j he Englishman lives in the ed house he Spaniard has a Dog i,j [,5], i j, C i C j he Japanese is a Painter... he Italian drinks ea he Norwegian lives in the first house on the left he owner of the Green house drinks Coffee he Green house is on the right of the White house he Sculptor breeds Snails he Diplomat lives in the Yellow house he owner of the middle house drinks Milk he Norwegian lives next door to the lue house he iolinist drinks Fruit juice he Fox is in the house next to the Doctor s he Horse is next to the Diplomat s 9 Example from and N, Annotations from Stanford CS 5 Street Puzzle C i = {ed, Green, White, Yellow, lue} D i = {ea, Coffee, Milk, Fruit-juice, Water} J i = {Painter, Sculptor, Diplomat, iolinist, Doctor} he Englishman lives in the ed house he Spaniard has a Dog he Japanese is a Painter he Italian drinks ea he Norwegian lives in the first house on the left N = Norwegian he owner of the Green house drinks Coffee he Green house is on the right of the White house he Sculptor breeds Snails he Diplomat lives in the Yellow house he owner of the middle house drinks Milk D = Milk he Norwegian lives next door to the lue house he iolinist drinks Fruit juice he Fox is in the house next to the Doctor s he Horse is next to the Diplomat s 0 Example from and N, Annotations from Stanford CS Street Puzzle Example 5 - Scheduling 5 C i = {ed, Green, White, Yellow, lue} D i = {ea, Coffee, Milk, Fruit-juice, Water} J i = {Painter, Sculptor, Diplomat, iolinist, Doctor} he Englishman lives in the ed house C ed he Spaniard has a Dog A Dog he Japanese is a Painter he Italian drinks ea he Norwegian lives in the first house on the left N = Norwegian he owner of the Green house drinks Coffee he Green house is on the right of the White house he Sculptor breeds Snails he Diplomat lives in the Yellow house he owner of the middle house drinks Milk D = Milk he Norwegian lives next door to the lue house he iolinist drinks Fruit juice J iolinist he Fox is in the house next to the Doctor s he Horse is next to the Diplomat s Four tasks,,, and are related by time constraints: must be done during must be achieved before starts must overlap with must start after is complete Are the constraints compatible? What are the possible time relations between two tasks? What if the tasks use resources in limited supply? Example 6 - -Sat n oolean variables,,, n K constraints of the form i v j v k where i is either true or false NP-complete ecall G and LK Properties of CSPs ypes of variables Discrete and finite Map colouring, 8-queens, boolean CSPs Discrete variables with infinite domains Scheduling jobs in a calendar equire a constraint language (Job + Job ) Continuous domains Scheduling on the Hubble telescope Linear programming
5 Properties of CSPs ypes of contraints Unary constraint relates a variable to a single value ueensland=lue, Green inary constraints relates two variables Can use a constraint graph to represent CSPs with only binary constraints Higher order constraints involve three of more variables Alldiff(,, n ) Can use a constraint hypergraph to represent the problem 5 CSPs and search N variables,, n alid assignment: { =x,, k =x k } for 0 k n such that values satisfy constraints on the variables States: valid assignments Initial state: empty assignment Successor: { =x,, K =x k } { =x,, k =x k, k+ =x k+ } Goal test: complete assignment If all domains all have size d, then there are O(d n ) complete assignments 6 CSPs and commutativity CSPs are commutative! he order of application of any given set of actions has no effect on the outcome When assigning values to variables we reach the same partial assignment, no matter the order All CSP search algorithms generate successors by considering possible assignments for only a single variable at each node in the search tree CSPs and commutativity variables,, Let the current assignment be A={ =x } Pick variable Let domain of be {a,b,c} he successors of A are { =x, =a} { =x, =b} { =x, =c} 7 8 acktracking Search acktracking 0 Depth first search which chooses values for one variable at a time acktracks when a variable has no legal values to assign 9 0 5
6 acktracking acktracking 0 0 =blue =red =green =blue =red =green =blue =red =green acktracking acktracking and efficiency =blue =blue =red =blue =red 0 =red =green =green =green acktracking search is an uninformed search method Not very efficient We can do better by thinking about the following questions Which variable should be assigned next? In which order should its values be tried? Can we detect inevitable failure early (and avoid the same failure in other paths)? Most constrained variable Choose the variable which has the fewest legal moves AKA minimum remaining values (M) heuristic Most constraining variable Most constraining variable: choose the variable with the most constraints on remaining variables ie-breaker among most constrained variables D ={green, blue} D ={green, blue} D ={blue} D ={blue, red} is involved in 5 constraints D others ={red, green, blue} D others ={red,green,blue} 5 6 6
7 Least-constraining value Given a variable, choose the least constraining value: the one that rules out the fewest values in the remaining variables Forward checking he third questions was Is there a way to detect failure early? Forward checking Keep track of remaining legal values for unassigned variables erminate search when any variable has no legal values 7 8 Forward Checking in Map Coloring Forward Checking in Map Coloring Forward checking removes the value ed of and of 9 0 Forward Checking in Map Coloring Forward Checking in Map Coloring G G G G G G G G G 7
8 Forward Checking in Map Coloring Example: ueens Empty set: the current assignment {( ), ( G), ( )} does not lead to a solution X X G G G G X X Example: ueens Example: ueens X X X X {,,,} X X X X {,,,} {,,, } 5 6 Example: ueens Example: ueens X X {,,,} X X {,,,} X X X X {,,,} {,,, } {,,, } {,,, } 7 8 8
9 Example: ueens Example: ueens X X {,,,} X X {,,,} X X X X {,,,} {,,,} {,,, } {,,,} 9 50 Example: ueens Example: ueens X X {,,,} X X {,,,} X X X X {,,, } {,,,} {,,, } {,,,} 5 5 Example: ueens Example: ueens X X {,,,} X X {,,,} X X X X {,,, } {,,,} {,,, } {,,,} 5 5 9
10 Example: ueens Summary X X {,,, } X {,,,} X {,,,} What you should know How to formalize problems as CSPs acktracking search Heuristics ariable ordering alue ordering Forward checking Next class Adversarial search ussell and Norvig, Chapter
Constraint Satisfaction
Constraint Satisfaction CS 486/686 May 16, 2006 University of Waterloo 1 Outline What are CSPs? Standard search and CSPs Improvements Backtracking Backtracking + heuristics Forward checking 2 Introduction
More informationConstraint Satisfaction [RN2] Sec [RN3] Sec Outline
Constraint Satisfaction [RN2] Sec 5.1-5.2 [RN3] Sec 6.1-6.3 CS 486/686 Lecture 4: Jan 12, 2012 University of Waterloo 1 Outline What are CSPs? Standard search and CSPs Improvements Backtracking Backtracking
More informationWhat we will try to do...
Constraint Satisfaction Problems (CSP) (Where we postpone making difficult decisions until they become easy to make) R&N: Chap. 5 Slides from Jean-Claude Latombe at Stanford University (used with permission)
More informationConstraint Satisfaction Problems
Constraint Satisfaction Problems Chapter 5 AIMA2e Slides, Stuart Russell and Peter Norvig, Completed by Kazim Fouladi, Fall 2008 Chapter 5 1 Outline CSP examples Backtracking search for CSPs Problem structure
More informationChapter 6 Constraint Satisfaction Problems
Chapter 6 Constraint Satisfaction Problems CS5811 - Artificial Intelligence Nilufer Onder Department of Computer Science Michigan Technological University Outline CSP problem definition Backtracking search
More informationIntroduction to Arti Intelligence
Introduction to Arti Intelligence cial Lecture 4: Constraint satisfaction problems 1 / 48 Constraint satisfaction problems: Today Exploiting the representation of a state to accelerate search. Backtracking.
More informationOutline First-order logic. First-order Logic. Introduction. Recall: 4-Queens problem. First-order Logic. First-order Logic Syntax.
First-order Logic CS 486/686 Sept 25, 2008 University of Waterloo Outline First-order logic Syntax and semantics Inference Propositionalization with ground inference Lifted resolution 1 2 Introduction
More informationConstraint Satisfaction Problems - CSP. March 23, 2017
Constraint Satisfaction Problems - CSP March 23, 2017 Examples of Applications 8-puzzle blocks world (e.g.: Hanoi tower) n-queens cryptarithmetic missionaires and cannibals solitaire many others... n-queens
More informationFinding optimal configurations ( combinatorial optimization)
CS 1571 Introduction to AI Lecture 10 Finding optimal configurations ( combinatorial optimization) Milos Hauskrecht milos@cs.pitt.edu 539 Sennott Square Constraint satisfaction problem (CSP) Constraint
More informationConstraint satisfaction search. Combinatorial optimization search.
CS 1571 Introduction to AI Lecture 8 Constraint satisfaction search. Combinatorial optimization search. Milos Hauskrecht milos@cs.pitt.edu 539 Sennott Square Constraint satisfaction problem (CSP) Objective:
More informationLecture 9: Search 8. Victor R. Lesser. CMPSCI 683 Fall 2010
Lecture 9: Search 8 Victor R. Lesser CMPSCI 683 Fall 2010 ANNOUNCEMENTS REMEMBER LECTURE ON TUESDAY! EXAM ON OCTOBER 18 OPEN BOOK ALL MATERIAL COVERED IN LECTURES REQUIRED READINGS WILL MOST PROBABLY NOT
More informationArtificial Intelligence
Artificial Intelligence Constraint Satisfaction Vibhav Gogate The University of Texas at Dallas Some material courtesy of Rina Dechter, Alex Ihler and Stuart Russell Constraint Satisfaction Problems The
More informationCS 4100 // artificial intelligence. Recap/midterm review!
CS 4100 // artificial intelligence instructor: byron wallace Recap/midterm review! Attribution: many of these slides are modified versions of those distributed with the UC Berkeley CS188 materials Thanks
More informationCS360 Homework 12 Solution
CS360 Homework 12 Solution Constraint Satisfaction 1) Consider the following constraint satisfaction problem with variables x, y and z, each with domain {1, 2, 3}, and constraints C 1 and C 2, defined
More information1. Tony and his three best friends (Steven, Donna, and Randy) were each at a different table.
Question 1 (Class) Variables T 1, T 2, T 3, T 4 where T i {S D R T, F B A P} Constraints - 1. Tony and his three best friends (Steven, Donna, and Randy) were each at a different table. 2. There s only
More informationPOLYNOMIAL SPACE QSAT. Games. Polynomial space cont d
T-79.5103 / Autumn 2008 Polynomial Space 1 T-79.5103 / Autumn 2008 Polynomial Space 3 POLYNOMIAL SPACE Polynomial space cont d Polynomial space-bounded computation has a variety of alternative characterizations
More informationNP-Hardness reductions
NP-Hardness reductions Definition: P is the class of problems that can be solved in polynomial time, that is n c for a constant c Roughly, if a problem is in P then it's easy, and if it's not in P then
More informationPrinciples of AI Planning
Principles of AI Planning 5. Planning as search: progression and regression Albert-Ludwigs-Universität Freiburg Bernhard Nebel and Robert Mattmüller October 30th, 2013 Introduction Classification Planning
More informationAnnouncements. Solution to Assignment 3 is posted Assignment 4 is available. c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 8 1 / 25
Announcements Solution to Assignment 3 is posted Assignment 4 is available c D. Poole and A. Mackworth 2017 CPSC 322 Lecture 8 1 / 25 Review: So far... Constraint satisfaction problems defined in terms
More informationConstraint sat. prob. (Ch. 6)
Constraint sat. prob. (Ch. 6) ypes of constraints ry to do this job problem with: J1, J2 and J3 Jobs cannot overlap J3 takes 3 time units J2 takes 2 time units J1 takes 1 time unit J1 must happen before
More informationNotes for Lecture Notes 2
Stanford University CS254: Computational Complexity Notes 2 Luca Trevisan January 11, 2012 Notes for Lecture Notes 2 In this lecture we define NP, we state the P versus NP problem, we prove that its formulation
More informationPrinciples of AI Planning
Principles of 5. Planning as search: progression and regression Malte Helmert and Bernhard Nebel Albert-Ludwigs-Universität Freiburg May 4th, 2010 Planning as (classical) search Introduction Classification
More informationReasoning with Deterministic and Probabilistic graphical models Class 2: Inference in Constraint Networks Rina Dechter
Reasoning with Deterministic and Probabilistic graphical models Class 2: Inference in Constraint Networks Rina Dechter Road Map n Graphical models n Constraint networks Model n Inference n Search n Probabilistic
More informationCS 374: Algorithms & Models of Computation, Spring 2017 Greedy Algorithms Lecture 19 April 4, 2017 Chandra Chekuri (UIUC) CS374 1 Spring / 1
CS 374: Algorithms & Models of Computation, Spring 2017 Greedy Algorithms Lecture 19 April 4, 2017 Chandra Chekuri (UIUC) CS374 1 Spring 2017 1 / 1 Part I Greedy Algorithms: Tools and Techniques Chandra
More informationPropositional Logic. Methods & Tools for Software Engineering (MTSE) Fall Prof. Arie Gurfinkel
Propositional Logic Methods & Tools for Software Engineering (MTSE) Fall 2017 Prof. Arie Gurfinkel References Chpater 1 of Logic for Computer Scientists http://www.springerlink.com/content/978-0-8176-4762-9/
More informationConstraint Satisfaction 101
Constraint Satisfaction 101 Berthe Y. Choueiry (Shu-we-ri) Nov 14, 2006 Constraint Satisfaction 101 1 Constraint Processing Constraint Satisfaction Computational problem Constraint Satisfaction Problem
More informationLecture Notes on From Rules to Propositions
Lecture Notes on From Rules to Propositions 15-816: Linear Logic Frank Pfenning Lecture 2 January 18, 2012 We review the ideas of ephemeral truth and linear inference with another example from graph theory:
More informationIntroduction to Solving Combinatorial Problems with SAT
Introduction to Solving Combinatorial Problems with SAT Javier Larrosa December 19, 2014 Overview of the session Review of Propositional Logic The Conjunctive Normal Form (CNF) Modeling and solving combinatorial
More informationCSC242: Intro to AI. Lecture 7 Games of Imperfect Knowledge & Constraint Satisfaction
CSC242: Intro to AI Lecture 7 Games of Imperfect Knowledge & Constraint Satisfaction What is This? 25" 20" 15" 10" 5" 0" Quiz 1 25" B 20" 15" 10" F D C A 5" F 0" Moral Many people cannot learn from lectures
More informationSAT, NP, NP-Completeness
CS 473: Algorithms, Spring 2018 SAT, NP, NP-Completeness Lecture 22 April 13, 2018 Most slides are courtesy Prof. Chekuri Ruta (UIUC) CS473 1 Spring 2018 1 / 57 Part I Reductions Continued Ruta (UIUC)
More informationTemporal Constraint Networks
Ch. 6b p.1/49 Temporal Constraint Networks Addition to Chapter 6 Ch. 6b p.2/49 Outline Temporal reasoning Qualitative networks The interval algebra The point algebra Quantitative temporal networks Reference:
More informationCS100: DISCRETE STRUCTURES. Lecture 3 Matrices Ch 3 Pages:
CS100: DISCRETE STRUCTURES Lecture 3 Matrices Ch 3 Pages: 246-262 Matrices 2 Introduction DEFINITION 1: A matrix is a rectangular array of numbers. A matrix with m rows and n columns is called an m x n
More informationSecond Assignment (out on February 3) CS-E4800 Artificial Intelligence. Example of the modeling language for logic used in the 2nd assignment
Second Assignment (out on February 3) CS-E4800 Artificial Intelligence Jussi Rintanen Department of Computer Science Aalto University March 1, 2017 Second Assignment (out on February 3) Assignments emailed
More informationChapter 7 R&N ICS 271 Fall 2017 Kalev Kask
Set 6: Knowledge Representation: The Propositional Calculus Chapter 7 R&N ICS 271 Fall 2017 Kalev Kask Outline Representing knowledge using logic Agent that reason logically A knowledge based agent Representing
More informationGeometric Steiner Trees
Geometric Steiner Trees From the book: Optimal Interconnection Trees in the Plane By Marcus Brazil and Martin Zachariasen Part 3: Computational Complexity and the Steiner Tree Problem Marcus Brazil 2015
More informationSection Handout 5 Solutions
CS 188 Spring 2019 Section Handout 5 Solutions Approximate Q-Learning With feature vectors, we can treat values of states and q-states as linear value functions: V (s) = w 1 f 1 (s) + w 2 f 2 (s) +...
More informationFriday Four Square! Today at 4:15PM, Outside Gates
P and NP Friday Four Square! Today at 4:15PM, Outside Gates Recap from Last Time Regular Languages DCFLs CFLs Efficiently Decidable Languages R Undecidable Languages Time Complexity A step of a Turing
More informationCircuits. Lecture 11 Uniform Circuit Complexity
Circuits Lecture 11 Uniform Circuit Complexity 1 Recall 2 Recall Non-uniform complexity 2 Recall Non-uniform complexity P/1 Decidable 2 Recall Non-uniform complexity P/1 Decidable NP P/log NP = P 2 Recall
More informationCS-E4800 Artificial Intelligence
CS-E4800 Artificial Intelligence Jussi Rintanen Department of Computer Science Aalto University March 1, 2017 Second Assignment (out on February 3) Model your problem in the propositional logic (expressed
More informationTemporal Constraint Networks
Ch. 5b p.1/49 Temporal Constraint Networks Addition to Chapter 5 Ch. 5b p.2/49 Outline Temporal reasoning Qualitative networks The interval algebra The point algebra Quantitative temporal networks Reference:
More informationComplexity Theory Part II
Complexity Theory Part II Time Complexity The time complexity of a TM M is a function denoting the worst-case number of steps M takes on any input of length n. By convention, n denotes the length of the
More informationPROPOSITIONAL LOGIC. VL Logik: WS 2018/19
PROPOSITIONAL LOGIC VL Logik: WS 2018/19 (Version 2018.2) Martina Seidl (martina.seidl@jku.at), Armin Biere (biere@jku.at) Institut für Formale Modelle und Verifikation BOX Game: Rules 1. The game board
More informationThe exam is closed book, closed calculator, and closed notes except your one-page crib sheet.
CS 188 Fall 2015 Introduction to Artificial Intelligence Final You have approximately 2 hours and 50 minutes. The exam is closed book, closed calculator, and closed notes except your one-page crib sheet.
More informationMock Exam Künstliche Intelligenz-1. Different problems test different skills and knowledge, so do not get stuck on one problem.
Name: Matriculation Number: Mock Exam Künstliche Intelligenz-1 January 9., 2017 You have one hour(sharp) for the test; Write the solutions to the sheet. The estimated time for solving this exam is 53 minutes,
More informationMin-Max Message Passing and Local Consistency in Constraint Networks
Min-Max Message Passing and Local Consistency in Constraint Networks Hong Xu, T. K. Satish Kumar, and Sven Koenig University of Southern California, Los Angeles, CA 90089, USA hongx@usc.edu tkskwork@gmail.com
More informationMore NP-Complete Problems
CS 473: Algorithms, Spring 2018 More NP-Complete Problems Lecture 23 April 17, 2018 Most slides are courtesy Prof. Chekuri Ruta (UIUC) CS473 1 Spring 2018 1 / 57 Recap NP: languages/problems that have
More informationThe core of solving constraint problems using Constraint Programming (CP), with emphasis on:
What is it about? l Theory The core of solving constraint problems using Constraint Programming (CP), with emphasis on: l Modeling l Solving: Local consistency and propagation; Backtracking search + heuristics.
More informationUC Berkeley CS 170: Efficient Algorithms and Intractable Problems Handout 22 Lecturer: David Wagner April 24, Notes 22 for CS 170
UC Berkeley CS 170: Efficient Algorithms and Intractable Problems Handout 22 Lecturer: David Wagner April 24, 2003 Notes 22 for CS 170 1 NP-completeness of Circuit-SAT We will prove that the circuit satisfiability
More informationSummary. Local Search and cycle cut set. Local Search Strategies for CSP. Greedy Local Search. Local Search. and Cycle Cut Set. Strategies for CSP
Summary Greedy and cycle cut set Greedy... in short G.B. Shaw A life spent doing mistakes is not only more honorable, but more useful than a life spent doing nothing Reminder: Hill-climbing Algorithm function
More informationAlgorithms and Theory of Computation. Lecture 22: NP-Completeness (2)
Algorithms and Theory of Computation Lecture 22: NP-Completeness (2) Xiaohui Bei MAS 714 November 8, 2018 Nanyang Technological University MAS 714 November 8, 2018 1 / 20 Set Cover Set Cover Input: a set
More informationHW8. Due: November 1, 2018
CSCI 1010 Theory of Computation HW8 Due: November 1, 2018 Attach a fully filled-in cover sheet to the front of your printed homework Your name should not appear anywhere; the cover sheet and each individual
More information1 Computational Problems
Stanford University CS254: Computational Complexity Handout 2 Luca Trevisan March 31, 2010 Last revised 4/29/2010 In this lecture we define NP, we state the P versus NP problem, we prove that its formulation
More informationChapter 3: Proving NP-completeness Results
Chapter 3: Proving NP-completeness Results Six Basic NP-Complete Problems Some Techniques for Proving NP-Completeness Some Suggested Exercises 1.1 Six Basic NP-Complete Problems 3-SATISFIABILITY (3SAT)
More informationChapter 0 Introduction. Fourth Academic Year/ Elective Course Electrical Engineering Department College of Engineering University of Salahaddin
Chapter 0 Introduction Fourth Academic Year/ Elective Course Electrical Engineering Department College of Engineering University of Salahaddin October 2014 Automata Theory 2 of 22 Automata theory deals
More informationBernhard Nebel, Julien Hué, and Stefan Wölfl. June 27 & July 2/4, 2012
Bernhard Nebel, Julien Hué, and Stefan Wölfl Albert-Ludwigs-Universität Freiburg June 27 & July 2/4, 2012 vs. complexity For some restricted constraint languages we know some polynomial time algorithms
More informationPROBABILITY. Inference: constraint propagation
PROBABILITY Inference: constraint propagation! Use the constraints to reduce the number of legal values for a variable! Possible to find a solution without searching! Node consistency " A node is node-consistent
More informationName: UW CSE 473 Final Exam, Fall 2014
P1 P6 Instructions Please answer clearly and succinctly. If an explanation is requested, think carefully before writing. Points may be removed for rambling answers. If a question is unclear or ambiguous,
More informationWriting: Algorithms, Mathematics, Definitions
Writing: Algorithms, Mathematics, Definitions Javier Larrosa UPC Barcelona Tech. Javier Larrosa (UPC Barcelona Tech) Writing. 1 / 31 Algorithms In CS we often write algorithms (that we have previously
More information1 Primals and Duals: Zero Sum Games
CS 124 Section #11 Zero Sum Games; NP Completeness 4/15/17 1 Primals and Duals: Zero Sum Games We can represent various situations of conflict in life in terms of matrix games. For example, the game shown
More informationThe exam is closed book, closed calculator, and closed notes except your one-page crib sheet.
CS 188 Spring 2017 Introduction to Artificial Intelligence Midterm V2 You have approximately 80 minutes. The exam is closed book, closed calculator, and closed notes except your one-page crib sheet. Mark
More informationAn Introduction to SAT Solving
An Introduction to SAT Solving Applied Logic for Computer Science UWO December 3, 2017 Applied Logic for Computer Science An Introduction to SAT Solving UWO December 3, 2017 1 / 46 Plan 1 The Boolean satisfiability
More informationCS221 Practice Midterm
CS221 Practice Midterm Autumn 2012 1 ther Midterms The following pages are excerpts from similar classes midterms. The content is similar to what we ve been covering this quarter, so that it should be
More informationConsistency algorithms. Chapter 3
Consistency algorithms Chapter Fall 00 Consistency methods pproximation of inference: rc, path and i-consistecy Methods that transform the original network into tighter and tighter representations Fall
More informationAlternative Methods for Obtaining. Optimization Bounds. AFOSR Program Review, April Carnegie Mellon University. Grant FA
Alternative Methods for Obtaining Optimization Bounds J. N. Hooker Carnegie Mellon University AFOSR Program Review, April 2012 Grant FA9550-11-1-0180 Integrating OR and CP/AI Early support by AFOSR First
More informationAUTOMATED REASONING. Agostino Dovier. Udine, October 2, Università di Udine CLPLAB
AUTOMATED REASONING Agostino Dovier Università di Udine CLPLAB Udine, October 2, 2017 AGOSTINO DOVIER (CLPLAB) AUTOMATED REASONING UDINE, OCTOBER 2, 2017 1 / 28 COURSE PLACEMENT International Master Degree
More informationSpace and Nondeterminism
CS 221 Computational Complexity, Lecture 5 Feb 6, 2018 Space and Nondeterminism Instructor: Madhu Sudan 1 Scribe: Yong Wook Kwon Topic Overview Today we ll talk about space and non-determinism. For some
More informationShow that the following problems are NP-complete
Show that the following problems are NP-complete April 7, 2018 Below is a list of 30 exercises in which you are asked to prove that some problem is NP-complete. The goal is to better understand the theory
More informationFinal exam of ECE 457 Applied Artificial Intelligence for the Fall term 2007.
Fall 2007 / Page 1 Final exam of ECE 457 Applied Artificial Intelligence for the Fall term 2007. Don t panic. Be sure to write your name and student ID number on every page of the exam. The only materials
More informationCS6901: review of Theory of Computation and Algorithms
CS6901: review of Theory of Computation and Algorithms Any mechanically (automatically) discretely computation of problem solving contains at least three components: - problem description - computational
More information1 More finite deterministic automata
CS 125 Section #6 Finite automata October 18, 2016 1 More finite deterministic automata Exercise. Consider the following game with two players: Repeatedly flip a coin. On heads, player 1 gets a point.
More informationLecture 8: Complete Problems for Other Complexity Classes
IAS/PCMI Summer Session 2000 Clay Mathematics Undergraduate Program Basic Course on Computational Complexity Lecture 8: Complete Problems for Other Complexity Classes David Mix Barrington and Alexis Maciel
More informationU.C. Berkeley CS278: Computational Complexity Professor Luca Trevisan August 30, Notes for Lecture 1
U.C. Berkeley CS278: Computational Complexity Handout N1 Professor Luca Trevisan August 30, 2004 Notes for Lecture 1 This course assumes CS170, or equivalent, as a prerequisite. We will assume that the
More informationA* Search. 1 Dijkstra Shortest Path
A* Search Consider the eight puzzle. There are eight tiles numbered 1 through 8 on a 3 by three grid with nine locations so that one location is left empty. We can move by sliding a tile adjacent to the
More informationRecap from Last Time
NP-Completeness Recap from Last Time Analyzing NTMs When discussing deterministic TMs, the notion of time complexity is (reasonably) straightforward. Recall: One way of thinking about nondeterminism is
More informationAlgorithm Design Strategies V
Algorithm Design Strategies V Joaquim Madeira Version 0.0 October 2016 U. Aveiro, October 2016 1 Overview The 0-1 Knapsack Problem Revisited The Fractional Knapsack Problem Greedy Algorithms Example Coin
More informationTemporal Constraint Networks
Ch. 5b p.1/24 Temporal Constraint Networks Addition to Chapter 5 Ch. 5b p.2/24 Outline Qualitative networks The interval algebra The point algebra Quantitative temporal networks Reference: Chapter 12 of
More informationEssential facts about NP-completeness:
CMPSCI611: NP Completeness Lecture 17 Essential facts about NP-completeness: Any NP-complete problem can be solved by a simple, but exponentially slow algorithm. We don t have polynomial-time solutions
More informationImproving Repair-based Constraint Satisfaction Methods by Value Propagation
From: AAAI-94 Proceedings. Copyright 1994, AAAI (www.aaai.org). All rights reserved. Improving Repair-based Constraint Satisfaction Methods by Value Propagation Nobuhiro Yugami Yuiko Ohta Mirotaka Nara
More informationAutomatic Generation of Redundant Models for Permutation Constraint Satisfaction Problems
Manuscript Latex Source Click here to download Manuscript: article.tex 0 0 0 0 0 0 Automatic Generation of Redundant Models for Permutation Constraint Satisfaction Problems Y.C. Law and J.H.M. Lee Department
More informationClassical Propositional Logic
Classical Propositional Logic Peter Baumgartner http://users.cecs.anu.edu.au/~baumgart/ Ph: 02 6218 3717 Data61/CSIRO and ANU July 2017 1 / 71 Classical Logic and Reasoning Problems A 1 : Socrates is a
More informationLocal Search & Optimization
Local Search & Optimization CE417: Introduction to Artificial Intelligence Sharif University of Technology Spring 2017 Soleymani Artificial Intelligence: A Modern Approach, 3 rd Edition, Chapter 4 Outline
More informationAutomata-based Verification - III
CS3172: Advanced Algorithms Automata-based Verification - III Howard Barringer Room KB2.20/22: email: howard.barringer@manchester.ac.uk March 2005 Third Topic Infinite Word Automata Motivation Büchi Automata
More informationFinal Examination CS 540-2: Introduction to Artificial Intelligence
Final Examination CS 540-2: Introduction to Artificial Intelligence May 7, 2017 LAST NAME: SOLUTIONS FIRST NAME: Problem Score Max Score 1 14 2 10 3 6 4 10 5 11 6 9 7 8 9 10 8 12 12 8 Total 100 1 of 11
More informationUCSD CSE 21, Spring 2014 [Section B00] Mathematics for Algorithm and System Analysis
UCSD CSE 21, Spring 2014 [Section B00] Mathematics for Algorithm and System Analysis Lecture 10 Class URL: http://vlsicad.ucsd.edu/courses/cse21-s14/ Lecture 10 Notes Midterm Good job overall! = 81; =
More informationMethods for finding optimal configurations
CS 1571 Introduction to AI Lecture 9 Methods for finding optimal configurations Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Search for the optimal configuration Optimal configuration search:
More informationLogic in AI Chapter 7. Mausam (Based on slides of Dan Weld, Stuart Russell, Dieter Fox, Henry Kautz )
Logic in AI Chapter 7 Mausam (Based on slides of Dan Weld, Stuart Russell, Dieter Fox, Henry Kautz ) Knowledge Representation represent knowledge in a manner that facilitates inferencing (i.e. drawing
More informationQ = Set of states, IE661: Scheduling Theory (Fall 2003) Primer to Complexity Theory Satyaki Ghosh Dastidar
IE661: Scheduling Theory (Fall 2003) Primer to Complexity Theory Satyaki Ghosh Dastidar Turing Machine A Turing machine is an abstract representation of a computing device. It consists of a read/write
More informationAnnouncements. Friday Four Square! Problem Set 8 due right now. Problem Set 9 out, due next Friday at 2:15PM. Did you lose a phone in my office?
N P NP Completeness Announcements Friday Four Square! Today at 4:15PM, outside Gates. Problem Set 8 due right now. Problem Set 9 out, due next Friday at 2:15PM. Explore P, NP, and their connection. Did
More informationCOMP219: Artificial Intelligence. Lecture 20: Propositional Reasoning
COMP219: Artificial Intelligence Lecture 20: Propositional Reasoning 1 Overview Last time Logic for KR in general; Propositional Logic; Natural Deduction Today Entailment, satisfiability and validity Normal
More informationPropositional logic. Programming and Modal Logic
Propositional logic Programming and Modal Logic 2006-2007 4 Contents Syntax of propositional logic Semantics of propositional logic Semantic entailment Natural deduction proof system Soundness and completeness
More informationA Little Logic. Propositional Logic. Satisfiability Problems. Solving Sudokus. First Order Logic. Logic Programming
A Little Logic International Center for Computational Logic Technische Universität Dresden Germany Propositional Logic Satisfiability Problems Solving Sudokus First Order Logic Logic Programming A Little
More informationFormal Modeling with Propositional Logic
Formal Modeling with Propositional Logic Assaf Kfoury February 6, 2017 (last modified: September 3, 2018) Contents 1 The Pigeon Hole Principle 2 2 Graph Problems 3 2.1 Paths in Directed Graphs..................................
More informationmat.haus project Zurab Janelidze s Lectures on UNIVERSE OF SETS last updated 18 May 2017 Stellenbosch University 2017
Zurab Janelidze s Lectures on UNIVERSE OF SETS last updated 18 May 2017 Stellenbosch University 2017 Contents 1. Axiom-free universe of sets 1 2. Equality of sets and the empty set 2 3. Comprehension and
More information6.045: Automata, Computability, and Complexity (GITCS) Class 15 Nancy Lynch
6.045: Automata, Computability, and Complexity (GITCS) Class 15 Nancy Lynch Today: More Complexity Theory Polynomial-time reducibility, NP-completeness, and the Satisfiability (SAT) problem Topics: Introduction
More informationScheduling with Constraint Programming. Job Shop Cumulative Job Shop
Scheduling with Constraint Programming Job Shop Cumulative Job Shop CP vs MIP: Task Sequencing We need to sequence a set of tasks on a machine Each task i has a specific fixed processing time p i Each
More informationBBM402-Lecture 11: The Class NP
BBM402-Lecture 11: The Class NP Lecturer: Lale Özkahya Resources for the presentation: http://ocw.mit.edu/courses/electrical-engineering-andcomputer-science/6-045j-automata-computability-andcomplexity-spring-2011/syllabus/
More informationCSCI3390-Lecture 14: The class NP
CSCI3390-Lecture 14: The class NP 1 Problems and Witnesses All of the decision problems described below have the form: Is there a solution to X? where X is the given problem instance. If the instance is
More informationToward Quandle Dichotomy
Robert McGrail, Mona Merling, Mary Sharac, Japheth Wood Laboratory for Algebraic and Symbolic Computation Reem-Kayden Center for Science and Computation Bard College Annandale-on-Hudson, NY 12504 April
More informationCollege of Computer & Information Science Fall 2009 Northeastern University 22 September 2009
College of Computer & Information Science Fall 2009 Northeastern University 22 September 2009 CS 7880: Algorithmic Power Tools Scribe: Eric Miles Lecture Outline: General Lovász Local Lemma Two Simple
More information