## 3 Mathematical Model
### Variables  
* _w\({}_{ijkl}\)_: number of packages \(i\) that will move from \(j\) to \(k\) in the vehicle \(l\).
* _u\({}_{kl}\)_: order of customer visit \(k\) in the vehicle \(l\).
* _r\({}_{jl}\)_: start of customer service hours \(j\) in the vehicle \(l\).  
\[x_{jkl} =\begin{cases}1,&\text{if you move a package $i$ from $j$ to $k$ in the vehicle $l$.}\\ 0,&\text{otherwise.}\end{cases}\] \[y_{l} =\begin{cases}1,&\text{if the vehicle is assigned $l$.}\\ 0,&\text{otherwise.}\end{cases}\]  
The MILP formulation is as follow:  
\[\min\sum_{j\in J}\sum_{k\in K}\sum_{l=l1}cc_{l}\;tc_{jkl}\;x_{ijl}+\sum_{j\in J }\sum_{k\in K}\sum_{l\in L-\{l1\}}\;c_{l}\;td_{jkl}\;x_{ijl}+\sum_{l\in l}f_{ l}\;y_{l} \tag{1}\]  
The objective function (1) minimizes the cost per route of each vehicle.  
\[\sum_{j\in J}\sum_{l\in L}w_{ijkl}\geq d_{ik} \forall i,\forall k \tag{2}\]The restriction (2) guarantees customer demand.  
\[\sum_{i\in I}\sum_{j\in I}\sum_{k\in K}w_{ijkl}\ p_{i}\leq\ b_{l} \forall l \tag{3}\]  
The restriction (3) ensures that the capacity of the vehicles is not exceeded.  
\[\sum_{i\in I}\sum_{j\in I}\sum_{k\in K}w_{ijkl}\leq M_{l}\ y_{l} \forall l \tag{4}\]  
Indicates (4) that if a product is not shipped, the assigned vehicle is not used.  
\[\sum_{i\in I}w_{ijkl}\leq M_{2}\ x_{jkl} \forall j,\forall k,\forall l \tag{5}\]  
Indicates (5) whether the vehicle is used for the route when sending a product, for the use of drones.  
\[\sum_{j\in I}\sum_{k\in K}x_{jkl}\ t_{jkl}\leq t_{l} \forall_{l\in L-\{l1\}} \tag{6}\]  
The Equation (6) was used to ensure that the maximum flight time of UAVs is not exceeded, in the same way.  
\[\sum_{j\in I}\sum_{k\in K}x_{jkl}\ a_{jkl}\leq dist_{l} \forall_{l\in L-\{l1\}} \tag{7}\]  
The Equation (7) ensures that the maximum flight distance is not exceeded.  
\[\sum_{j\in I}\sum_{k\in K}x_{jkl}\leq\ y_{l} \forall l \tag{8}\]  
If a product is shipped, then the assigned vehicle is used 8.  
\[u_{jl}-u_{kl}+\|K\|\ x_{jkl}\leq\|K\|-1 \forall j,\forall k,\forall l \tag{9}\]  
The Equation (9) eliminate sub-tours  
\[\sum_{j\in I}\ x_{jkl}\leq 1 \forall k,\forall l \tag{10}\] \[\sum_{k\in K}\ x_{jkl}\leq 1 \forall j,\forall l \tag{11}\]  
The Equations (10) and (11) ensure that each of the transports can enter and exit once at each node  
\[\sum_{k\in K}\ x_{kjl}=\sum_{k\in K}x_{jkl} \forall j,\forall l \tag{12}\]  
The Equation (12) indicates the flow conservation.  
\[r_{jl}+s_{j}+tt_{jkl}-r_{kl}\leq(1-x_{jkl})M_{l} \forall j,\forall k,\forall l \tag{13}\] \[r_{jl}\geq uu_{j}\sum_{k\in K}\ x_{jkl} \forall j,\forall l\] (14) \[r_{jl}\leq v_{j}-s_{j}\sum_{k\in K}\ x_{jkl} \forall j,\forall l \tag{15}\]The Equations (13)-(15) guarantees the viability of the sequence for time conditions.  
\[w_{ijkl},u_{jl},r_{kl}\geq 0 \forall i,\forall j,\forall k,\forall l \tag{16}\] \[y_{l},x_{jkl}\left\{0,1\right\} \forall j,\forall k,\forall l \tag{17}\]  
The definitions of decision variables are provided (16) and (17).  
\(M_{l}\) and \(M_{2}\) are big numbers, therefore:  
\[M_{l}=\min\{b_{l},d_{i}k\}\] \[M_{2}=\max\{w_{ijkl}\}\]  
The following section explains the case study and the generation of the scenarios and instances for the experiments.