Model Course
Case Study
- Create a mixed-integer linear program (MILP) model that models this supply chain.
-
In the following quiz, we will ask you what the equivalents between the standard 2-Stage Warehouse Location Problem (WLP) and the supply chain are. You could also use this quiz as a help if you do not know how to model the supply chain directly. (Note: You should still try before doing the quiz!)
- Read through the data chapter and understand which data is used and how you can read it into a Python program.
- Take the given implementation, run it and analyse the results.
- Implement a second target function and create the Pareto front.

Indices:
Set of production sites: \(h \in H\)
Set of potential warehouse sites: \(i \in I\)
Set of customers: \(j \in J\)
Decision Variables:
\( \overline{x}_{hi} \) Transport quantity from production site \( h \) to facility \( i \)
\( x_{ij} \) Transport quantity from warehouse \( i \) to customer \( j \)
\( y_{p} \) Location decision for warehouse \( i \)
Parameters:
\( \overline{b}_{h} \) Capacity of production site \( h \)
\( b_{i} \) Capacity of warehouse \( i \)
\( \overline{c}_{hi} \) Transport cost from production site \( h \) to facility \( i \)
\( c_{ij} \) Transport cost from warehouse \( i \) to customer \( j \)
\( \overline{d}_{j} \) Demand of customer \( j \)
\( f_{i} \) Fixed cost of warehouse \( i \)
Target Function:
\( Min Z= \sum_{h,i} \overline{c}_{hi} \overline{x}_{hi} + \sum_{i,j} c_{ij} x_{ij} + \sum_{i} f_i y_i \)
Constraints:
No more can be supplied from a production site than capacity is available:
\( \sum_{i=1}^{I} \overline{x}_{hi} \leq \overline{b}_h, \forall h \)
The outflow from the warehouses is equal to the inflow into the warehouse:
\( \sum_{h=1}^{H} \overline{x}_{hi} - \sum_{j=1}^{J} x_{ij} = 0, \forall i \)
Capacity limitation of the warehouses must be respected:
\( \sum_{j=1}^{J} x_{ij} \leq b_i y_i, \forall i \)
Meeting demands for all customers:
\( \sum_{i=1}^{I} x_{ij} = d_j, \forall j \)
Non-negativity condition:
\( \overline{x}_{hi} \geq 0, \forall h,i \)
Non-negativity condition:
\( x_{ij} \geq 0, \forall i,j \)
Binary condition:
\( y_i \in \{0,1\}, \forall i \)