Lab 4 2014

From 6.034 Wiki

(Difference between revisions)
Jump to: navigation, search
Line 78: Line 78:
* <tt>get_variable_j_name()</tt> - name of the j variable
* <tt>get_variable_j_name()</tt> - name of the j variable
* <tt>check(state, value_i=value, value_j=value)</tt> - checks the binary constraint for a given CSP state, with variable i set by value i, and variable j set by value j.  Returns False if the constraint fails.
* <tt>check(state, value_i=value, value_j=value)</tt> - checks the binary constraint for a given CSP state, with variable i set by value i, and variable j set by value j.  Returns False if the constraint fails.
 +
NOTE: in our implementation of CSPs, constraints are symmetrical; a constraint object exists for each "direction" of a constraint, so you can check for the presence of a constraint by substituting for i and/or j in the most convenient fashion for you. 
=== Testing ===
=== Testing ===

Revision as of 20:31, 23 October 2010


This problem set is due Friday, November 5th. If you have questions about it, ask the list 6034tas@csail.mit.edu.