ez314/Degree-Validator

Handle bypasses better

Closed this issue · 0 comments

ez314 commented

Bypasses should just be pre-assigned, and constraints/courses modified/replaced. The edge case is if someone wants some course to have the possibility of filling other constraints, but they don't know for sure if that's what they want long term. I think any user that wants this level of control can just assign the course manually by themselves.

Pre-assignment procedure:

  1. Figure out when bypasses are active. Take UNION(bypasses, constraints) to determine where hours should be assigned.
  2. Save these edges to be added to the returned graph.
  3. Copy these course and the constraints, and put them back into the original graph. Sort of like a copy-on-write.
  4. Subtract hours as specified by the bypasses, from both the course and the constraints
  5. Solve normally
  6. Add bypasses to maxflow-generated graph