Question: table [ [ Course , Lecture Time,Lab / Practical Time ] , [ CS 3 0 3 , Sun Tue Thu 1 1 ,

\table[[Course,Lecture Time,Lab/Practical Time],[CS303,Sun Tue Thu 11,12,MON WED 10,11,12,1],[CS600,Sun Tue Thu 12,1,MON WED 11,1,2],[CS101,Sun Tue Thu 10,11,12,1,2,3,None],[CS202,Everyday 10,11,None]]
\table[[Time,SUN TUE THU,MON WED],[10,,],[11,,],[12,,],[1,,],[2,,],[3,,]]
You also include the following set of constraints:
(1) Each class must be assigned to exactly one timeslot
(2) Each timeslot can be assigned to a maximum of one class
(3) No classes can be scheduled during the reserved timeslots
(4) The Mon Wed selection for CS2O2 must occur at the same time as the Sun Tue Thu selection.
Use the following abbreviations to facilitate writing your solution
CS101 Lecture L1
CS202 Lecture L2
CS303 Lecture L3
CS303 Lab P3
CS600 Lecture L6
CS600 Lab P6
Sun Tue Thu 1010S
Sun Tue Thu 1111S
Mon Wed 1010M
Mon Wed 1111M
and so on
A. Which of the following options is preferred to represent this as a CSP? Explain your answer:
using meeting times as variables and courses as the values of in the domains?
using courses as variables and the time slots as values?
B. Now using courses are variables and times as values, list the variable and the initial domain values. L1 is done for you As an example, continue with the others
\table[[Variable,Domain],[L1,10S 11S 12S 1S 2S 3S],[,]]
C. Update the table by removing the values that are incompatible with the constraint#3.
D. Simulate DFS with forward checking only on your variables and the reduced domains in part C above. Show your steps. How many times did you backtrack?
E. Write a python program so solve this CSP using forward-checking. The program should output a schedule of the 4 courses that doesn't violate any of the constraints.
\ table [ [ Course , Lecture Time,Lab / Practical

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!