Soft Constraints

| Constraint | Formal Expression | Penalty/ Violation
0 | Each TA should be funded (that is, they should teach at least one course) | ∀ta:TA ∞ instructs(ta,?,?) | 50

1

TAs should get their first choice course

∀ta:TA, c:Course ∞      prefers1(ta,c) → instructs(ta,c,?)

5

2 | TAs should get their first or second choice course | | 10
3 | TAs should get their first or second or third choice course | | 10
4 | TAs should have all their labs in the same course | ∀ta:TA, c:Course | instructs(ta,c,?) ∞ ~∃c2:Course | c2↑c ∞ instructs(ta,c2,?) | 20

5

TAs should have all their labs in no more than 2 courses

∀ta:TA, c,c2:Course | c2↑c  /\ instructs(ta,c,?) 
/\ instructs(ta,c2,?) ∞ ~∃c3:Course | c3↑c /\ c3↑c2 ∞ instructs(ta,c3,?)

35

6

TAs should not teach a lab for a course for which they don't know the subject matter

∀ta:TA, c:Course ∞      instructs(ta,c,?) → knows(ta,c)

30

7 | TAs should not teach two labs of distinct courses at the senior level | | 10
8 | TAs should not teach more than one more lab than the TA that teaches the least number of labs. | | 25
9 | TAs should all teach the same number of labs. | | 5

10

If the instructor requested particular TAs  for his/her course, each of the lecture the instructor is teaching for that course should be taught by  one of the requested TAs

∀i:Instructor, c:Course ∞    (∃ ta:TA ∞ prefers(i,c,ta)) → 
    ∀ lec:Lecture, lab:Lab |       instructs(i,c,lec) /\ has-lab(c,lec,lab) ∞         instructs(ta,c,lab)

10