2
$\begingroup$

I want to create a transportation model. I have identified importing and exporting countries with their estimated demand and supply. The cost of transportation per one uni is already calculated for each ex- and importer. Some exporters transport the hydrogen by ship and others by pipeline.

The problem I have is that I need to introduce losses when it is transported by ship. About 20% is lost and won't reach the importer. For pipeline transport there is no losses. I am having trouble to implement this into the objective function or the constraints. Is there a way to integrate this into the model?

enter image description here

$\endgroup$
2
  • $\begingroup$ Is the shipping loss really 20% Maybe the loss is stochastic? is that variability significant relative to what you care about? $\endgroup$ Commented Jun 15, 2023 at 13:36
  • 1
    $\begingroup$ generalized transportation problem $\endgroup$
    – RobPratt
    Commented Jun 15, 2023 at 22:31

2 Answers 2

2
$\begingroup$

You can add an index to the $x$ variables to indicate whether transport is via pipeline or by ship: $x_{ij}^k$ denotes the quantity shipped on link $(i,j)$ via transport mode $k\in\{\mbox{pipeline, ship}\}$.

The problem becomes: $$ \min \sum_k\sum_i\sum_jc_{ij}^kx_{ij}^k $$ subject to

  • supply constraints: $$ \sum_k\sum_jx_{ij}^k \le a_i \quad \forall i \tag{1} $$
  • demand constraints: $$ \sum_k\sum_ix_{ij}^k \ge b_j \quad \forall j \tag{2} $$

To take into account $20\%$ loss when transported by ship, you can consider that a dummy copy of node $j$ absorbs the $20\%$ loss. Constraints $(2)$ should be modified as follows:

$$ \sum_k\sum_ix_{ij}^k \ge b_j + 0.2\sum_ix_{ij}^{\mbox{ship}}\quad \forall j \tag{3} $$

Alternatively, as proposed by @Sune, you could simply say that only $80\%$ of the shipped quantity reaches the destination:

$$ \sum_ix_{ij}^{\mbox{pipeline}} + 0.8\sum_ix_{ij}^{\mbox{ship}} \ge b_j \quad \forall j \tag{4} $$

Both constraints are of course equivalent, as $$ \sum_k\sum_ix_{ij}^k = \sum_ix_{ij}^{\mbox{pipeline}} +0.8\sum_ix_{ij}^{\mbox{ship}} +0.2\sum_ix_{ij}^{\mbox{ship}} \tag{5} $$

$\endgroup$
5
  • $\begingroup$ Would this be easier, if you simply say that only 80% of the shipped quantity reaches the destination? Using your variables, it could be something like $\sum_{i} x_{ij}^{pipeline}+0.8 \sum_{i} x_{ij}^{ship}\geq b_j$ $\endgroup$
    – Sune
    Commented Jun 15, 2023 at 10:53
  • 1
    $\begingroup$ Yes that looks good to me! I will add it as an alternative. $\endgroup$
    – Kuifje
    Commented Jun 15, 2023 at 11:43
  • 1
    $\begingroup$ yes, in this case don't define the option that is not available. Likewise, if a link does not exist in the initial transportation problem, variable $x_{ij}$ is not defined for this link. In other words, $x_{ij}^k$ is defined only when possible, not for all $i,j,k$. $\endgroup$
    – Kuifje
    Commented Jun 15, 2023 at 12:57
  • $\begingroup$ if you really don't want to work with index $k$, you could write constraint $(4)$ as follows: $$\sum_{i|(i,j)\mbox{is via pipeline}}x_{ij} + 0.8\sum_{i|(i,j)\mbox{is via ship}} x_{ij}\ge b_j$$ $\endgroup$
    – Kuifje
    Commented Jun 15, 2023 at 13:18
  • 1
    $\begingroup$ @anton You might even generalise it a bit and define a parameter $0 \leq \alpha_{ij} \leq 1$ denoting the proportion lost one arc $(i,j)$ and then define the constraints as $\sum_{i} (1-\alpha_{ij})x_{ij}\geq b_j$ for all $j=1,\dots,m$. Then you would have $\alpha_{ij}=0.2$ if the transport mode from $i$ to $j$ is by ship, and $\alpha_{ij}=0$ if it is by pipeline. $\endgroup$
    – Sune
    Commented Jun 15, 2023 at 19:07
0
$\begingroup$

You can try as below as: $\sum_{i}(x_{i,j}P_i + 0.8x_{i,j}(1-P_i)) \ge b_j \quad \forall j$
where known parameter $P_i = \begin{cases} 1, \text{if transport by pipe from i} \\ 0, \text{by ship} \end{cases}$

Edit: correction made as suggested below.

$\endgroup$
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.