COMP 131 CSP Quiz Print your name clearly:___Solution___ 24

advertisement
COMP 131
CSP Quiz
24 September, 2015
Print your name clearly:___Solution___
Consider the following graphical representation of a CSP containing three variables A
(with domain {1,2,3}), B (with domain {2,3}), and C (with domain {0,2}), three binary
constraints (A<B, B>C, A>C) and three unary constraints (A!=2, B!=0, C!=1).
1. What does a solution to a CSP consist of?
Answer: A solution to a CSP consists of a consistent assignment to all the variables
of the CSP.
2. Which variable is not node consistent?
Answer: Node A is not node consistent since A=2 is still in domain(A)
3. Which variable is not arc consistent?
Answer: Node A isn’t arc consistent, since A=3 isn’t consistent with any value for B.
Node B is arc consistent, since {A=1,C=1} works for both values in B’s domain.
Node C is arc consistent, since C=0 is consistent with all values for A and B, and
C=2 is consistent with A=B=3.
4. Are A and B path consistent with respect to C?
Answer:
Yes, A and B are path consistent with respect to C, since choosing C=0 satisfies
(1) the unary constraints on C and
(2) the binary constraints between C and A and between C and B, for all values of A
and B that satisfy both the unary constraints on A and B, and the binary constraint
between A and B.

Download