## 4 Optimal Motion Planning Using Voronoi Partitions and Prediction Difference Maps
and  
\[CM_{V_{n,j}}=\frac{1}{M_{V_{n,j}}}\sum_{V_{n,j}}g\Psi_{n},\ \ for\ g\ \in V_{n,j}. \tag{14}\]  
Assuming that the sensors can move in any direction relative to its current location \(s_{n,j}\), we set the \(x\) and \(y\) direction of the sensor's trajectory as  
\[\widehat{x_{n}}=\frac{\left(CM_{V_{n,j}}-s_{n,j}\right)_{x}}{\left|\left(CM_{V _{n,j}}-s_{n,j}\right)_{x}\right|} \tag{15}\]  
and  
\[\widehat{y_{n}}=\frac{\left(CM_{V_{n,j}}-s_{n,j}\right)_{y}}{\left|\left(CM_{V _{n,j}}-s_{n,j}\right)_{y}\right|}\, \tag{16}\]  
which directs the sensors towards the centroid of each respective PDM-weighted Voronoi cell \(\Psi_{n}\). Subsequently, the change in sensor position is calculated by using  
\[\mathbf{u_{n}}=v\cdot(\ \widehat{x}_{n}+\widehat{y_{n}}), \tag{17}\]  
where \(v\) is the velocity of the UAV. Figure 2 shows an example of the spatial density function weighted Voronoi cells produced by a five-sensor survey. We developed a simulation framework for modeling survey routes by using multiple UAVs in Python to demonstrate the PDM-based motion planning procedure. The model takes as input the number of UAV sensors, velocity, dwell time per measurement location, and initial starting positions, which are then used to simulate the movement of the UAVs by using the direction given by the optimal motion planning procedure. Algorithm 1 provides the details for the recursive framework for the PDM-based motion planning procedure. ```
1. Initialize:\(s_{1}\),..., \(s_{n}\); \(\phi_{j=0}(g)=0\);\(l_{j=0}=1\)
2. Predict:\(\phi_{j}(g)\) with \(P_{j=0}\gets s_{1}\),..., \(s_{n}\);
3. \(c_{j=0}\gets c_{s_{1}}\),..., \(c_{s_{n}}\); \(P^{*};c^{*}_{j=0}\)
4. Optimize:\(l_{j}\)
5. While\(\phi_{j}(g)\) not converged:
6. Calculate:\(\Psi(g)\leftarrow\left|\phi_{j}(g)-\phi_{j-1}(g)\right|\)
7. For n in N sensors do
8. Compute:
9. \(V_{n,j}(S)\leftarrow\left\{g\in G\right.\left|\left.\left|g-s_{n,j}\right| \leq\left.\left|g-s_{m,j}\right|\right.\right|\ \text{, for all }s_{m,j}\in S\right\}\)
10. \(M_{V_{n,j}}\leftarrow\sum_{V_{n}}\Psi_{n}\)
11. \(CM_{V_{n,j}}\leftarrow\frac{1}{M_{V_{n,j}}}\sum_{V_{n,j}}g\cdot\Psi_{n}\)
12. \(\hat{x_{n}}\leftarrow\frac{\left(CM_{V_{n}}-s_{n}\right)_{x}}{\left|\left(CM_{V _{n}}-s_{n}\right)_{x}\right|}\); \(\hat{y_{n}}\leftarrow\frac{\left(CM_{V_{n}}-s_{n}\right)_{x}}{\left|\left(CM_{V _{n}}-s_{n}\right)_{y}\right|}\);
13. \(\mathbf{u_{n}}\leftarrow\mathbf{v}\cdot(\mathbf{x_{n}}+\mathbf{y_{n}})\)
14. \(s_{n}\leftarrow\left[(s_{n})_{x}+(u_{n})_{x}\ (s_{n})_{y}+(u_{n})_{y}\right]\)
15. For\(t\leq T_{d\text{\it dwell}}\): \(c(s_{n})\gets c(s_{n})+c(s_{n},\ t)\) \(c_{s_{n}}=\frac{c(s_{n})}{T}\)
16. Append:\(P\), \(\mathbf{s_{n}};\mathbf{c},\mathbf{c}_{s_{n}}\)
17. \(\phi_{j-1}\leftarrow\phi_{j}\);\(l_{j-1}=l_{j}\)
18. Predict:\(\phi_{j}(g)\) with \(P;c\ ;P^{*}\gets p_{ii};c^{*}\gets c_{p^{*}}l_{j}\)
```  
**Algorithm 1** Recursive Motion Planning  
Operational implementation of the proposed PDM-based motion planning procedure would involve establishing UAV/UGV-specific control parameters such as velocity, flight altitude for UAVs, and dwell times that will enable statistically confident count rates for the radiation detector of choice. The dwell times could be dynamically set for each observation location based on the real-time sensor data. Figure 2: The PDM weighted Voronoi cells for a five-sensor survey showing the current sensor location and the calculated center of mass for (**a**) sensor 1, (**b**) sensor 2, (**c**) sensor 3, (**d**) sensor 4, and (**e**) sensor 5. The color bar represents the absolute fractional difference between successive predicted maps.