'Excel Solver issues
I want to setup a system by which employees have a set number of points that they can use to weight against each holiday, basically if they don't want to work on a certain holiday they would set a large number of points on that day. We would then setup holiday assignments such that there are two people on each holiday and each person works 2 holidays; there are 8 employees with 8 "holidays", so the matrix is 8x8.
I setup a preference array that has a preference number for each employee, call it P. I setup an assignment array for year 1, call it Y1. I then take SUM(P*Y1) to get the total points for Year 1.
I solve to minimize SUM(P*Y1), subject to the constraints above: 2 holidays/employee, 2 employees/holiday. Assignments are integers <=1. The solver gives a solution that looks reasonable.
I then repeat the formula above, but I use a new assignment array for year 2, Y2. I then setup a matrix of Y1+Y2, giving the total points over two years. I also setup a matrix of Y1*Y2=0, ie no repeat assignments.
I use Solver to minimize SUM(PY1+PY2) by changing the year 2 assignments, Y2. Again, with the constraints of 2 employees per holiday, 2 holidays per employee. I expect it to give me the second lowest point total possible. It does not, it gives me the same solution as in Y1, and Y1Y2<>0. Is this my math, or is it the Solver? It gives the absolute minimum without following the constraint of not repeating any values, ie Y1Y2=0.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
