# Adaptive Path Planning for UAV-Based Pollution Sampling
## 4 Experiments and Results
### Optimization Criteria  
The criteria employed by the GPP are designed to produce numerical values that are inversely proportional to the optimality of the solution. In other words, the further the solution deviates from the optimal one, the higher the criterion value, and, consequently, the cost function value increases. Table 1 explains the criteria used by the GPP. It is important to highlight that only a subset of these criteria is applied based on the selected scenario of the mission. Additionally, the set of criteria can be extended with others, such as considerations for aircraft t \begin{table}
\begin{tabular}{l l l l} \hline \hline \# & **Criterion** & **Necessity** & **Comment** \\ \hline
1 & Obstacle Avoidance & Required & Ensures that the UAV avoids infeasible regions, penalizing any path that violates obstacle constraints. \\
2 & Shortest Path & Optional & Minimizes the total distance traveled between control waypoints to reduce time and resources. \\
3 & Wind Adaptation & Optional & Modifies the path based on wind conditions, applying heuristic adjustments to maintain stability. \\
4 & Energy Efficiency & Optional & Considers energy usage during flight, adding cost for routes with higher consumption. \\
5 & Pollutant Sampling Focus & Optional & Adjusts the path to prioritize areas with the highest pollutant concentrations. \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Detailed criteria and their impact on UAV path planning in GPP. The vertical difference between the positions of the waypoints \(\mathbf{w}_{n}^{\mathcal{D}}\) and \(\mathbf{w}_{n+1}^{\mathcal{D}}\), situated along a Dubins path \(\mathcal{D}\), is denoted as \(\Delta_{n}^{v}\) and defined as  
\[\Delta_{n}^{v}=|z_{n}-z_{n+1}|,\mathbf{w}_{n}^{\mathcal{D}}= \begin{bmatrix}x_{ n}&y_{n}&z_{n}&\chi_{n}\end{bmatrix} ,\mathbf{w}_{n}^{\mathcal{D}}\in \mathcal{D}, \tag{13}\]  
where \(z_{n}\) represents the absolute altitude of the waypoint \(\mathbf{w}_{n}^{\mathcal{D}}\) within the inertial reference frame \(\mathcal{F}^{i}\). Consequently, \(\Delta_{n}^{h}\) represents the horizontal separation between consecutive waypoints:  
\[\Delta_{n}^{h}=\sqrt{(x_{n}-x_{n+1})^{2}+(y_{n}-y_{n+1})^{2}},\mathbf{w}_{n}^{ \mathcal{D}}= \begin{bmatrix}x_{n}&y_{n}&z_{n}&\chi_{n}\end{bmatrix} ,\mathbf{w} _{n}^{\mathcal{D}}\in\mathcal{D}. \tag{14}\]  
Here, \(x_{n}\) and \(y_{n}\) represent the absolute coordinates of waypoint \(\mathbf{w}_{n}^{\mathcal{D}}\) in the inertial reference frame \(\mathcal{F}^{i}\), measured along the \(x\) and \(y\) axes, respectively. The wind direction \(\chi_{wn}\) in vehicle reference frame \(\mathcal{F}^{v}\) and the wind speed \(v_{wn}\) are measured at waypoint \(\mathbf{w}_{n}^{\mathcal{D}}\). The wind direction of \(0^{\circ}\) aligns with the positive X-axis, \(90^{\circ}\) with the positive Y-axis, and so forth, using the same reference system as the UAV's heading. Let \(\Delta_{n}^{\chi}\) denote the relative angle between the line segment \(\overline{\mathbf{w}_{n}^{\mathcal{D}}\mathbf{w}_{n+1}^{\mathcal{D}}}\) and the wind direction \(\chi_{wn}\):  
\[\Delta_{n}^{\chi}=\angle\left(\overline{\mathbf{w}_{n}^{\mathcal{D}}\mathbf{ w}_{n+1}^{\mathcal{D}}}\right)-\chi_{wn}, \tag{15}\]  
where \(\Delta_{n}^{\chi}\), \(\angle\left(\overline{\mathbf{w}n^{\mathcal{D}}\mathbf{w}n+1^{\mathcal{D}}}\right)\), and \(\chi_{wn}\) are expressed in the inertial reference frame \(\mathcal{F}^{i}\). A normal (Gaussian) distribution is used to model the cost associated with wind effects:  
\[\mathcal{N}(x,\mu,\sigma)=\frac{1}{\sigma\sqrt{2\pi}}e^{-\frac{1}{2}\left( \frac{x-\mu}{\sigma}\right)^{2}}, \tag{16}\]  
where \(\mu\) denotes mean and \(\sigma\) is standard deviation of the Gaussian distribution. For clarity, characteristic wind components are defined individually. Two Gaussian distributions represent crosswind and are centered on either side of the aircraft, specifically at \(\pm\frac{\pi}{2}\).