Decision Optimization

 View Only
  • 1.  Workers assignment

    Posted Tue April 20, 2021 04:47 PM
    Hello,
    i am working on a problem to optimize workers' assignments in scheduling. i need to pick the optimum group of workers to perform each project task based on their health metrics

    is there any examples or documentation can help me 
    thank you so much

    ------------------------------
    zinab abuwarda
    ------------------------------

    #DecisionOptimization


  • 2.  RE: Workers assignment

    Posted Wed April 21, 2021 02:04 AM
    Edited by System Fri January 20, 2023 04:47 PM
    Hi

    you could start with the following example


    House building with worker skills

    This is a problem of building five houses in different locations; the masonry, roofing, painting, etc. must be scheduled. Some tasks must necessarily take place before others and these requirements are expressed through precedence constraints.

    There are three workers, and each worker has a given skill level for each task. Each task requires one worker; the worker assigned must have a non-null skill level for the task. A worker can be assigned to only one task at a time.

    Each house has a deadline. The objective is to maximize the skill levels of the workers assigned to the tasks.

    To access this example, go to: examples/opl/sched_optional.


    or if your workers work in shifts

    The nurses example


    The nurses example describes a nurse scheduling problem: the hospital Human Resources department needs to create work schedules for nurses and nurse teams. A good schedule is an optimal one, that is, a schedule that meets as many of the hospital's overall goals as possible. If some of these goals prove incompatible, then the solution consists in nevertheless finding a schedule that will work out, in other words, a feasible schedule. The goals include:

    • staffing each hospital department with the proper number of nurses at all times

    • matching a nurse's skills, such as a Board Certification in Cardiac Care, with the requirements of the department

    • establishing a minimum and maximum number of hours worked per week.

      Maximizing fairness in how nurses are allocated to shifts, that is, making sure that no nurses are scheduled for 50 hours a week when others are scheduled for only 25 hours.

    • incorporating best practice guidelines, such as trying to schedule nurses with compatible skills or with a proven history of working well together on the same team

    • taking into account individual nurse preferences for days off as much as possible

    • keeping salary costs to a reasonable level



    ------------------------------
    [Alex] [Fleischer]
    [EMEA CPLEX Optimization Technical Sales]
    [IBM]
    ------------------------------



  • 3.  RE: Workers assignment

    Posted Thu April 22, 2021 03:52 PM
    Hello Alex 

    Thank you so much. The first example is helpful, and I just noticed that the second one is not CP.
    However, my problem is to assign construction workers to activities based on their physical capabilities. i need to optimize which set of workers should be assigned to which group. for example, I have 20 workers at the first working day and two activities are running each of them need 9 workers. and I need to choose which workers should be working in which activities. i used the alternative constraint as explained in example of "schedule optional" but the results were assigning 1 worker for each activity

    please advise me
    thank you so much

    ------------------------------
    zinab abuwarda
    ------------------------------



  • 4.  RE: Workers assignment

    Posted Fri April 23, 2021 02:08 AM
    The signature of the alternative constraint is:

    alternative(x, Y, c)

    Where x is an interval variable, Y an array of interval variables and c an integer cardinality (constant or variable).
    The constraints states that whenever x is present, exactly c intervals in Y must be present (all the other ones are absent) and the c present intervals start and end at the same values as interval x. When x is absent, all the intervals in Y are absent.

    See : https://www.ibm.com/docs/en/icos/20.1.0?topic=c-constraints-groups-interval-variables-in-cp-optimizer-1

    There is a default value of 1 for c but you can specify any value.

    Note that this type of model should be used only in case you really need the allocation of activities to individual workers in the problem. This is the case when the workers have different characteristics (like skills) so that the set of workers cannot be partitioned into subset of equivalent workers with the same characteristics (in which case, a model with cumul function will be more compact and more efficient). And even in case of detailed allocation of activities to workers, some redundant constraints using cumul functions on pools of workers may help.




    ------------------------------
    Philippe Laborie
    ------------------------------