ex3 - CS221 Exercise Set #3 1 CS 221 Exercise Set #3 : CSPs...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: CS221 Exercise Set #3 1 CS 221 Exercise Set #3 : CSPs and Supervised Learning 1. Job Shop Scheduling as a CSP Consider the task of scheduling a set of tasks in a machine shop (e.g., for assembling an airplane wing). Each task has a start time Start i and a fixed duration d i . We also have sequencing constraints between operations. If operation i precedes operation j , we can write the constraint Start i + d i Start j (1) A second kind of constraint is the resource constraint. In the simple setting, we list for each task i the set of resources that it requires R i . (Resources include things like machines and people needed to complete the task.) If two operations i and j require the same resource, then we have the constraint that: ( Start i + d i Start j ) ( Start j + d j Start i ) (2) For example, we might have several parts that need to be polished. The polishing machine would be a resource that is needed for several operations. Now, consider a more complex setting, where a given resource constraint for a task can be fulfilled by several actual resources. For example, either Pat or Mike might be able to polish a part. Note that the resources are not necessarily identical; for example, Pat might be able to weld whereas Mike might not. More precisely, assume we have a set R of actual resources. For each task i , the set of resource constraints is now defined by a set of sets R 1 i , . . . , R k i , where each R i R ; in order for task i to be performed, it requires the use of one resource in each R i . For example, our polishing task might be specified as R 1 1 = { Pat, Mike } , R 2 1 = { machine1, machine2 } , and R 3 1 = { Jan,Tom } . This task can be accomplished by assigning to it the resources Pat, machine2, and Tom. For simplicity, we assume that two different sets R i and R m i are disjoint; e.g., we cant have R 3 1 = { Pat,Tom } . Show how this task would be represented as a CSP. Specify exactly and formally what the variables are and what the constraints are. Use a formal specification of the constraints, along the lines of (1) and (2) above. 2. CSP algorithms This question will use CSP algorithms on a 6-queens problem. We use the formulation described in class, where we have a variable V i representing the row of the queen in column i . Remember that the 6-queens problem requires that we place all 6 queens on the board....
View Full Document

Page1 / 5

ex3 - CS221 Exercise Set #3 1 CS 221 Exercise Set #3 : CSPs...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online