Constraining displacement of moving prize colector in linear programming

33 Views Asked by At

This is a linear programming question. Suppose there is one collector that is mobile and can travel between different locations. Each location offers time variable prizes, the collector gains the correspondent prize of the location where he is at that time he is present.

The input to the problem is the following: the number of locations $L$, the set of locations $\mathcal{L}={1, \cdots , L}$, the number of discrete time intervals $T$, the set of time intervals $\mathcal{T}={1, \cdots , T}$, the prize set $P_{lt}, l \in \mathcal{L}, t \in \mathcal{T}$ (prize given by location $l$ at time $t$), and the required travel time $D_{lk}, l \in \mathcal{L}, k \in \mathcal{L}$ (number of time slots required to travel from location $l$ to $k$).

The output to the problem is where the collector is at all time intervals, he can be at a location or he can be traveling. This will be indicated by $w_{lt}, l \in \mathcal{L}, t \in \mathcal{T}$: if $w_{lt} = 1$, the collector is at $l$ during time slot $t$. Otherwise, $w_{lt} = 0$ (he can be at another location or he can be traveling).

We want to maximize the collected prizes, so the objective function is $$maximize \sum_{l \in \mathcal{L}} \sum_{t \in \mathcal{T}} P_{lt} w_{lt}$$

The first constraint I imagine is that the collector can be only at one location at a given time: $$\sum_{l \in \mathcal{L}} w_{lt} \le 1 , \forall t \in \mathcal{T}$$ (less or equal because he can be either at a location ($=1$) or traveling ($=0$))

My question is: which constraints should I write to guarantee that the travel time is respected?

For example, suppose $T=4$ and $L=2$. If $w_{11} = 1$ and $D_{12} = 2$, $w_{22}$ and $w_{23}$ cannot be 1, since 2 time slots are required to travel from location 1 to location 2. $w_{24} = 1$ or $w_{12} = 1$ are ok. How can I model that?

1

There are 1 best solutions below

0
On BEST ANSWER

I'm not sure it's the best way, but you could add the following constraints:$$w_{k,\tau}\le1-w_{\ell,t}\ \forall k,\ell\in\mathcal{L}\ni k\neq\ell;\forall t\in\mathcal{T};\forall\tau\in\left\{ t+1,\dots,t+D_{\ell,k}-1\right\}.$$That's quite a lot of constraints, so I might be inclined to add them lazily (in a loop, solve the LP using a subset of the constraints and, if any are violated, add them and use dual simplex to update the solution).