# Proactive Mission Planning of Unmanned Aerial Vehicle Fleets Used in Offshore Wind Farm Maintenance
## 3 Model Formulation
### Declarative Model Description  
In the structure of the modeled system, four layers can be distinguished: WTs, vessels, service teams, and UAVs (see Figure 4). These layers interact with each other. For example, the location of the WTs (layer 1) determines the vessel's acceptable sailing routes (layer 2), which in turn determine the possible service team assignments and the schedule for WT servicing (layer 3). The adopted service schedule affects the plan for equipment delivery by UAVs (layer 4), which is also dependent on the weather conditions prevailing at sea (layer 1). These relationships are distinguished by the declarative model presented below. Figure 2: Proactive plan of service \(T_{10},T_{28},T_{50},T_{52},T_{68}\), and \(T_{90}\) by service teams \(W_{1},\ W_{2}\), and \(W_{3}\): schedule (**a**), vessel route (**b**). Figure 3: Reactive plan for the delivery of required equipment to \(T_{10},T_{28},T_{50},T_{52},T_{68}\), and \(T_{90}\): schedule (**a**), UAV route (**b**). The analytical representation of this model is directly provided by the declarative modeling paradigm. Constraints:  
* Constraints determining the permissible routes of the vessel: \[\sum_{j=1}^{NI}dx_{1,j}=1\] (1) \[\sum_{i=1}^{NI}dx_{i,1}=0\] (2) \[dx_{i,i}=0,\text{ for }i=1\ldots NI\] (3) \[\sum_{i=1}^{NI}dx_{i,j}=1,\text{ for }j=2\ldots NI\] (4) \[\sum_{j=1}^{NI}px_{1,j}=0\] (5) \[\sum_{i=1}^{NI}px_{i,1}=1\] (6) \[\left(\sum_{i=1}^{NI}dx_{i,j}=1\right)\Rightarrow\left(\sum_{i=1}^{NI}px_{i, j}=1\right),\text{ for }j=1\ldots NI\] (7) \[\sum_{j=1}^{NI}\left(dx_{i,j}+px_{i,j}\right)=\sum_{j=1}^{NI}\left(dx_{j,i}+ px_{j,i}\right),\text{ for }i=1\ldots NI\] (8)
* Constraints that, if fulfilled, guarantee the timely delivery and pick-up of service teams: Figure 3:0 (9)  
Figure 3:1 Layered model of the WT service mission planning problem. Figure 3:2  
Figure 3:3  
Figure 3:4  
Figure 3:5  
Figure 3:6  
Figure 3:7  
Figure 3:8 Figure 3:9 (31) \[\sum_{j=1}^{NI}dx_{1,j}=1\]0 (32) \[\sum_{j=1}^{NI}dx_{1,j}=1\]1 (33) \[\sum_{j=1}^{NI}dx_{1,j}=1\]2 (34) \[\sum_{j=1}^{NI}dx_{1,j}=1\]3 (35) \[\sum_{j=1}^{NI}dx_{1,j}=1\]4
* Cost constraints: \[\sum_{j=1}^{NI}dx_{1,j}=1\]5 (37) \[\sum_{j=1}^{NI}dx_{1,j}=1\]6 (38) \[\sum_{j=1}^{NI}dx_{1,j}=1\]7 (39) \[\sum_{j=1}^{NI}dx_{1,j}=1\]8 (40) \[\sum_{j=1}^{NI}dx_{1,j}=1\]9 (41) \[\sum_{i=1}^{NI}dx_{i,1}=0\]0 (42)
* Constraints determining the route and schedule of deliveries carried out by the UAVs: \[\sum_{i=1}^{NI}dx_{i,1}=0\]1 (43) \[\sum_{i=1}^{NI}dx_{i,1}=0\]2 (44) \[\sum_{i=1}^{NI}dx_{i,1}=0\]3 (46) \[\sum_{i=1}^{NI}dx_{i,1}=0\]4 (47) \[\sum_{i=1}^{NI}dx_{i,1}=0\]5 (48)\[\sum_{i=1}^{NI}dx_{i,1}=0\]6  
\[\sum_{i=1}^{NI}dx_{i,1}=0\]7  
\[\sum_{i=1}^{NI}dx_{i,1}=0\]8  
* Constraints on the amount of equipment to be supplied: \[\sum_{i=1}^{NI}dx_{i,1}=0\]9 (52) \[dx_{i,i}=0,\text{ for }i=1\ldots NI\]0 (53) \[dx_{i,i}=0,\text{ for }i=1\ldots NI\]1 (54)  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]2  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]3  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]4  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]5  
* Constraints that, if fulfilled, guarantee the implementation of the desired deliveries in the forecasted weather conditions: \[dx_{i,i}=0,\text{ for }i=1\ldots NI\]6 (59)  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]7  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]8  
\[dx_{i,i}=0,\text{ for }i=1\ldots NI\]9  
\[\sum_{i=1}^{NI}dx_{i,j}=1,\text{ for }j=2\ldots NI\]0  
where \(va_{i,j}(\theta,vw)\) and \(ut_{i,j}\) depend on the assumed goods delivery strategy. If the ground speed \(vg_{i,j}\) is constant, then an air speed \(va_{i,j}\) is calculated from  
\[\sum_{i=1}^{NI}dx_{i,j}=1,\text{ for }j=2\ldots NI\]1  
\[\sum_{i=1}^{NI}dx_{i,j}=1,\text{ for }j=2\ldots NI\]2  
The function \(\mathcal{F}(\theta)\) (used in (59)) represents the forecasted weather conditions during the UAV flight mission [38; 39]. A value of this function determines the maximal value of forecasted wind speed \(vw\) in direction \(\theta\).