The first question is whether seniority is a hard constraint (if a senior staffer does not get leave, nobody below them does) or aspirational (client would like to respect seniority but it is not an absolute requirement).
The hard constraint case should be fairly easy to formulate (depending on the specifics of your model). For instance, suppose that x[i,j] is a binary variable taking value 1 if staff member i gets leave at time j. If staff member k is the next staffer after i in descending priority order, you can just add a constraint saying sum(j) x[k,j] <= sum(j) x[i,j], which means staffer k does not get leave until staffer i assigned a leave time. The specific formulation will depend on the rest of your model, but the concept should be clear: constraint all variables related to assigning leave to a staffer to zero unless the next higher priority staffer has been given leave.
For the "aspirational" case, you are looking at a multiobjective model. There are a number of ways to handle multiple objectives. One would be a lexicographic approach (which recent versions of CPLEX directly support). Set objective 1 to be maximization of the number of staff awarded leaves. Set objective 2 (lower priority) to be minimization of the number of staff denied leave when at least one lower seniority person got leave (= number of cranky staff). CPLEX will find a solution that achieves a maximum number L of leaves granted, and then look for a solution with a minimal number of discontented staff subject to the requirement that L staff members get leave.
------------------------------
Paul Rubin
Professor Emeritus
Michigan State University
------------------------------
Original Message:
Sent: Mon June 13, 2022 03:04 AM
From: Shah
Subject: Priority sequence into an MIP formulation?
Hi all,
I'm trying to solve a staff leave allocation problem. User would like to have the allocation based on seniority of staff. That means, final allocation should not have senior staffs unallocated if staffs junior to him is allocated. Seniority rank here is a sequence of natural numbers starting from 1,2,3 and so on.
The isuue that I'm facing is that while trying to maximize allocations, model couldn't really focus on this seniority aspect. Any thoughts? guidance?
------------------------------
Thanks,
Shah
------------------------------
#DecisionOptimization