Originally posted by: positionguy
Hello :)
I am super new to coding on this software and I am trying to learn how things work.
For the past few days I am trying to add an additional constraint to the existing example "sched_tasks".
What I want to do is the following:
Imagine there is a limited number of cars that the technicians need to go around to do the tasks, lets say 3.
A car is needed from the starting time of a task until the task finishes (which implies other people cannot use that car
for that period of time so the next task needs to wait for an available car to be scheduled).
What I figured out so far:
carNeeded (j, t) [0,1] - a boolean decision variable
if t >= starting time of task j && t <= finishing time of task j
then carNeeded == 1
forall t and j
sum(carNeeded [ j ][ t ] < capacity (or in our case 3)
I have problems putting this in the model and getting it to work, however.
Anyone willing to help out? :)
#CPLEXOptimizers#DecisionOptimization