How to model resources and their capacity in Gurobi
回答済みI seeking help to model a scenario where there are 4 systems and every system has a total computing, memory, storage, and bandwidth capacity.
Besides this, I have 4 jobs and each job has some requirements (used) such as computing, memory, storage, and bandwidth resources.
similarly, at any time some of the capacity might be used so we can say that we will also have available resources (total-used=available) such as computing, memory, storage, and bandwidth capacity.
I want to optimally map the jobs to the systems.
I have a basic idea of jobs and systems but I cannot model the resources such as computing, memory, storage and etc. Please push me in the right direction.
Regards
-
正式なコメント
This post is more than three years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum, or try Gurobot, our chatbot interface offering instant, expert-level support. -
Hi Muhammad,
I recommend looking into the literature to find relevant papers. You can search for keywords such as "resource constrained scheduling problem" or "cumulative scheduling problem".
To answer your question more concretely, let us define the following notation:
- \(p_{ij}\): processing time of job \(j\) on machine \(i\)
- \(c^s_{ij}\): job \(j\) consumes resource \(s\) at rate \(c^s_{ij}\) on machine \(i\)
- \(C^s\): resource \(s\) capacity
Further let us define \(x_{ijt}\) as a binary decision variable being equal to 1 if job \(j\) starts at time \(t\) on machine \(i\).
We first need to ensure each job starts once on one machine.
\[\sum_t \sum_i x_{ijt} = 1, ~~ \forall j\]
To enforce the resource capacity limit, we can define the constraint below where \(T_{ijt} = \{t^{\prime} | t - p_{ij} \leq t^{\prime} \leq t\}\) is the set of times at which job \(j\) in progress on machine \(i\) at time \(t\) might start processing at time \(t^{\prime}\).
\[\sum_i \sum_j \sum_{t^{\prime} \in T_{ijt}} c^s_{ij} x_{ijt^{\prime}} \leq C^s, ~~ \forall s, t\]
Best regards,
Maliheh
0
投稿コメントは受け付けていません。
コメント
2件のコメント