UAV Drones Path Planning with Improved RRT and DWA Algorithms

In my research, I focus on the path planning problem of UAV drones in complex environments. Path planning is one of the most critical capabilities for autonomous UAV drones, because it directly determines whether a UAV drone can safely, efficiently, and smoothly travel from a start point to a goal point while avoiding static and dynamic obstacles. I have studied both global path planning, where the environment is assumed to be known in advance, and local dynamic path planning, where unknown or moving obstacles must be handled in real time. My work proposes a B-spline Goal Greedy Oriented Rapidly-exploring Random Tree (BGO-RRT) algorithm for global path planning, and a fusion of BGO-RRT-Connect with an Enhanced Speed Space and Angle Changing Dynamic Window Approach (EA-DWA) for dynamic path planning. Throughout this article, I use tables and formulas to summarize the key ideas, derivations, and experimental results, and I emphasize the role of UAV drones in modern applications.

The motivation for my research comes from the rapidly increasing use of UAV drones in civilian and military domains. UAV drones are now used for rescue, meteorology, transportation, exploration, agriculture, electronic countermeasures, reconnaissance, and communication relay. Because UAV drones often operate in cluttered and uncertain environments, a single global planner or a single local planner is rarely sufficient. I therefore combine global sampling-based planning with local dynamic obstacle avoidance, and I optimize both stages so that the final trajectory is short, smooth, and safe for real UAV drones.

Global Path Planning Foundations

I first review the classical global path planning algorithms that form the basis of my improved method. The main categories are graph-search-based algorithms such as Dijkstra and A*, and sampling-based algorithms such as Rapidly-exploring Random Tree (RRT) and Probabilistic Roadmap (PRM). Each of these algorithms has strengths and weaknesses when applied to UAV drones.

Dijkstra Algorithm

Dijkstra’s algorithm solves the single-source shortest path problem on a weighted directed graph. It uses a greedy strategy: at each step, it selects the unvisited node with the smallest tentative distance from the start node, marks it as visited, and relaxes all its neighbors. For UAV drones, Dijkstra can find the shortest path if the graph is correctly constructed, but it explores a large portion of the free space and is computationally expensive. The distance update rule is:

$$d(v) = \min(d(v), d(u) + w(u,v))$$

where \(d(v)\) is the tentative distance to node \(v\), \(u\) is the current node, and \(w(u,v)\) is the edge weight. Although Dijkstra guarantees optimality for non-negative weights, its search efficiency is low for large maps, which limits its direct use for real-time UAV drones path planning.

A* Algorithm

A* improves Dijkstra by adding a heuristic estimate of the remaining cost to the goal. The evaluation function is:

$$f(x) = g(x) + h(x)$$

where \(g(x)\) is the exact cost from the start to node \(x\), and \(h(x)\) is the heuristic estimate from \(x\) to the goal. If \(h(x)\) never overestimates the true cost, A* is optimal. For UAV drones, A* is often faster than Dijkstra, but it still depends on a discretized grid and may produce paths with sharp turns that are not dynamically feasible for UAV drones.

RRT Algorithm

RRT is a sampling-based algorithm that grows a tree from the start point by randomly sampling the free space. At each iteration, a random sample \(P_{rand}\) is generated, the nearest node \(P_{near}\) in the tree is found, and a new node \(P_{new}\) is created by extending from \(P_{near}\) toward \(P_{rand}\) by a step size \(\mu\). The basic extension is:

$$P_{new} = P_{near} + \mu \frac{P_{rand} – P_{near}}{\|P_{rand} – P_{near}\|}$$

RRT is probabilistically complete and can handle high-dimensional spaces, which makes it attractive for UAV drones. However, the original RRT has high search randomness, produces many redundant nodes, and generates paths with poor smoothness. These problems motivate my BGO-RRT algorithm.

PRM Algorithm

PRM builds a roadmap by randomly sampling the configuration space, removing samples in collision, and connecting nearby samples. A graph search is then performed on the roadmap. PRM is suitable for multi-query planning, but for UAV drones in unknown or dynamic environments, the roadmap must be rebuilt frequently, which is costly.

Local Path Planning Foundations

For local path planning, I focus on the Artificial Potential Field (APF) method and the Dynamic Window Approach (DWA). These methods allow UAV drones to react to local sensor information and avoid unexpected obstacles.

Artificial Potential Field

APF defines an attractive potential toward the goal and a repulsive potential from obstacles. The attractive potential and force are often written as:

$$U_{att}(P) = \frac{1}{2}\alpha D^2(P,P_g)$$

$$F_{att}(P) = -\nabla U_{att}(P) = \alpha (P_g – P)$$

where \(\alpha\) is the attraction coefficient, \(P\) is the current position, and \(P_g\) is the goal. The repulsive potential and force are:

$$U_{rep}(P) = \begin{cases} \frac{1}{2}\lambda \left(\frac{1}{D(P,P_o)} – \frac{1}{D_0}\right)^2, & D(P,P_o) \le D_0 \\ 0, & D(P,P_o) > D_0 \end{cases}$$

$$F_{rep}(P) = \begin{cases} \lambda \left(\frac{1}{D(P,P_o)} – \frac{1}{D_0}\right)\frac{1}{D^2(P,P_o)}\frac{\partial D(P,P_o)}{\partial P}, & D(P,P_o) \le D_0 \\ 0, & D(P,P_o) > D_0 \end{cases}$$

APF is computationally efficient, but it can suffer from local minima and target unreachability. I use the attractive idea of APF in my BGO-RRT algorithm to guide random sampling toward the goal, but I do not rely on APF alone for global planning of UAV drones.

UAV Drones Dynamics Constraints

To make planned paths flyable by real UAV drones, I impose several dynamic constraints. These constraints ensure that the path respects the minimum flight distance, maximum turning angle, and maximum climb/dive angle of UAV drones.

Constraint Expression Meaning
Minimum flight distance \(\|P_{new} – P_{near}\| = \mu\) Each extension step equals the minimum distance before changing direction.
Maximum turning angle \(\cos\theta = \frac{s_1^T s_2}{\|s_1\|\|s_2\|} \ge \cos\theta_{max}\) The angle between consecutive path segments must not exceed \(\theta_{max}\).
Maximum climb/dive angle \(\phi = \arctan\left(\frac{|z_{new}-z_{near}|}{\sqrt{(x_{new}-x_{near})^2+(y_{new}-y_{near})^2}}\right) \le \phi_{max}\) The vertical angle must remain within the UAV drone’s capability.

These constraints are essential because UAV drones cannot execute sharp turns or vertical jumps. My smoothing and pruning steps explicitly account for them.

Sensor Model for Obstacle Detection

To detect obstacles, I use a monocular camera model. The pinhole geometry relates a 3D point \(P=[X,Y,Z]^T\) in the camera frame to its pixel coordinates \([u,v]^T\):

$$Z \begin{bmatrix} u \\ v \\ 1 \end{bmatrix} = \begin{bmatrix} f_x & 0 & c_x \\ 0 & f_y & c_y \\ 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} X \\ Y \\ Z \end{bmatrix} = K P$$

For a point in the world frame \(P_w\), the projection is:

$$s \begin{bmatrix} u \\ v \\ 1 \end{bmatrix} = K T P_w$$

where \(T\) is the transformation matrix and \(s\) is a scale factor. This sensor model allows UAV drones to estimate obstacle positions and update local planning.

BGO-RRT for Global Path Planning

I propose the BGO-RRT algorithm to address the high randomness, redundant paths, and poor smoothness of the traditional RRT for UAV drones. BGO-RRT has three main improvements: goal-oriented sampling using an attractive function, greedy pruning of redundant nodes, and cubic B-spline smoothing of sharp turns.

Goal-Oriented Sampling with an Attractive Function

In traditional RRT, random samples are uniform, so the tree may grow away from the goal. I introduce an attractive term inspired by APF. The new node is computed by combining the random direction and the goal direction:

$$P_{new,x} = P_{near,x} + \alpha \cos\theta + \mu \cos\gamma$$

$$P_{new,y} = P_{near,y} + \alpha \sin\theta + \mu \sin\gamma$$

where \(\theta\) is the direction from \(P_{near}\) to the random sample, \(\gamma\) is the direction from \(P_{near}\) to the goal, \(\alpha\) is the attraction coefficient, and \(\mu\) is the step size. Equivalently, I first compute an intermediate attractive point and then extend by \(\mu\):

$$P_{n+1} = P_n + \mu \frac{P_{att} – P_n}{\|P_{att} – P_n\|}$$

This reduces the randomness of the tree and makes UAV drones explore toward the goal more efficiently.

Greedy Pruning of Redundant Paths

After RRT produces a feasible path, I use a greedy algorithm to remove redundant nodes. Starting from the goal, I attempt to connect the current head node to earlier ancestors. If the straight line is collision-free, I skip the intermediate nodes. Otherwise, I keep the last collision-free ancestor and continue. The pruning process can be summarized as:

$$\text{while } P_{head} \neq P_{start}: \text{ find farthest ancestor } P_{anc} \text{ such that } \overline{P_{head}P_{anc}} \cap P_{obs} = \emptyset; \text{ connect } P_{head} \text{ to } P_{anc}; P_{head} \leftarrow P_{anc}$$

This significantly shortens the path and reduces unnecessary turns for UAV drones.

Cubic B-Spline Smoothing

Even after pruning, the path may contain curvature discontinuities. I use a cubic B-spline to smooth the remaining turning points. Given control points \(P_0, P_1, \dots, P_n\), the B-spline curve of order \(k\) is:

$$P(x) = \sum_{i=0}^{n} P_i B_{i,k}(x)$$

The Cox-de Boor recursion for the basis functions is:

$$B_{i,1}(x) = \begin{cases} 1, & x_i \le x < x_{i+1} \\ 0, & \text{otherwise} \end{cases}$$

$$B_{i,k}(x) = \frac{x – x_i}{x_{i+k-1} – x_i} B_{i,k-1}(x) + \frac{x_{i+k} – x}{x_{i+k} – x_{i+1}} B_{i+1,k-1}(x)$$

A cubic B-spline provides \(C^2\) continuity, which is suitable for the smooth flight of UAV drones. I choose cubic order because it balances smoothness and computational cost.

BGO-RRT Pseudocode and Summary

The overall BGO-RRT procedure can be summarized as follows:

Step Operation Purpose
1 Initialize tree with start node Begin global search
2 Generate random sample \(P_{rand}\) Explore free space
3 Find nearest node \(P_{near}\) Extend tree
4 Apply attractive function to get \(P_{att}\) Reduce randomness
5 Extend by step \(\mu\) to get \(P_{new}\) Create new node
6 Collision check \(P_{near}\) to \(P_{new}\) Ensure safety
7 If goal reached, add goal and stop Complete path
8 Prune redundant nodes with greedy algorithm Shorten path
9 Smooth with cubic B-spline Improve smoothness

Simulation and Data Analysis for BGO-RRT

I tested BGO-RRT against A*, traditional RRT, and ant colony optimization in narrow corridor and complex obstacle scenarios. The parameters are listed below.

Parameter Narrow Corridor Complex Obstacles
Map size 100 × 100 50 × 50
Start (10,15) (0,0)
Goal (90,85) (45,20)
Step size \(\mu\) 2 1
Attraction coefficient \(\alpha\) 2 1

The comparison results after 50 runs are given in the following tables.

Algorithm Total Nodes Planning Time (s) Failures
A* 3776 34.51 0
RRT 1014 13.49 9
Ant Colony — 9.45 12
BGO-RRT 709 6.82 0
Algorithm Total Nodes Planning Time (s) Failures
A* 702 16.19 0
RRT 866 9.29 2
Ant Colony — 8.32 0
BGO-RRT 654 7.62 0

In the narrow corridor scenario, BGO-RRT reduced total nodes by 30.07% compared with RRT and by 81.22% compared with A*. Its average planning time was 49.44% faster than RRT, 80.23% faster than A*, and 27.83% faster than ant colony optimization. In the complex obstacle scenario, BGO-RRT reduced total nodes by 24.48% compared with RRT, 6.84% compared with A*, and achieved faster planning than all baselines. Importantly, BGO-RRT had zero failures, while RRT and ant colony optimization failed in several runs. This demonstrates that my BGO-RRT is more reliable for UAV drones.

Dynamic Path Planning with RRT-Connect and EA-DWA

For dynamic environments, I combine BGO-RRT-Connect with an enhanced DWA. RRT-Connect grows two trees simultaneously, one from the start and one from the goal, and uses a greedy connection strategy. This speeds up global planning. However, RRT-Connect still suffers from randomness, so I apply the same goal-oriented sampling idea from BGO-RRT. The result is called BGO-RRT-Connect.

RRT-Connect Extension

The new node in RRT-Connect is generated as:

$$P_{new} = \begin{bmatrix} P_{near,x} + \mu \cos\theta \\ P_{near,y} + \mu \sin\theta \end{bmatrix}, \quad \theta = \arctan\left(\frac{P_{nearest,y} – P_{near,y}}{P_{nearest,x} – P_{near,x}}\right)$$

where \(P_{nearest}\) is the nearest node in the other tree. The two trees attempt to connect directly, which reduces the number of iterations. I further constrain the sampling strategy using the attractive function, so that both trees are biased toward the goal and toward each other.

Dynamic Window Approach

DWA samples linear and angular velocities \((v,w)\) in a dynamic window, predicts trajectories over a short horizon, and selects the best trajectory according to an objective function. The motion model for a UAV drone is:

$$\begin{bmatrix} x_{k+1} \\ y_{k+1} \\ \theta_{k+1} \end{bmatrix} = \begin{bmatrix} x_k \\ y_k \\ \theta_k \end{bmatrix} + \begin{bmatrix} \cos\theta_k & 0 \\ \sin\theta_k & 0 \\ 0 & 1 \end{bmatrix} \begin{bmatrix} v \\ w \end{bmatrix} \Delta t$$

The velocity sampling space is constrained by maximum/minimum velocities, acceleration limits, and obstacle distances:

$$V_a = \{(v,w) \mid v \in [0,v_{max}], w \in [0,w_{max}]\}$$

$$V_s = \{(v,w) \mid v \in [0, \sqrt{2 D(v,w) v_b}], w \in [0, \sqrt{2 D(v,w) w_b}]\}$$

$$V_d = \{(v,w) \mid v \in [v_c – v_b \Delta t, v_c + v_b \Delta t], w \in [w_c – w_b \Delta t, w_c + w_b \Delta t]\}$$

$$V_f = V_a \cap V_s \cap V_d$$

The traditional DWA objective function is:

$$C(v,w) = a_1 Heading(v,w) + a_2 Dis(v,w) + a_3 Vel(v,w)$$

I improve DWA in three ways: a dual danger range judgment, an improved speed space, and an enhanced evaluation function.

Dual Danger Range Judgment

I define two danger radii \(r_1\) and \(r_2\) with \(r_2 < r_1\). When the distance \(d\) between the UAV drone and an obstacle is greater than \(r_1\), the obstacle is safe. When \(r_2 < d \le r_1\), the obstacle is in the controllable danger zone, and the UAV drone reduces its speed to half of the initial speed. When \(d \le r_2\), the obstacle is in the extreme danger zone, and the UAV drone stops immediately and replans a local path. This strategy improves dynamic obstacle avoidance for UAV drones.

Improved Speed Space

Traditional DWA only considers the velocity reachable in the first prediction cycle. I compute the full reachable speed space over all prediction cycles, which gives more feasible trajectories. The improved speed space is:

$$V_p = \{(v_p,w_p) \mid v_p \in [\max(0, v_0 – v_{b,max} T), \min(v_{max}, v_0 + v_{b,max} T)], w_p \in [\max(-w_{max}, w_0 – w_{b,max} T), \min(w_{max}, w_0 + w_{b,max} T)]\}$$

where \(T\) is the prediction horizon. This allows the UAV drone to predict longer and smoother trajectories.

Improved Evaluation Function

I add an angle change evaluation term to the DWA objective:

$$Ang_i(v,w) = 180 – |\theta_{gi} – \theta_{si}|$$

where \(\theta_{gi}\) is the goal direction of the \(i\)-th predicted trajectory and \(\theta_{si}\) is the current heading. The improved objective is:

$$C(v,w) = a_1 Heading(v,w) + a_2 Dis(v,w) + a_3 Vel(v,w) + a_4 Ang(v,w)$$

All terms are normalized to avoid unit inconsistency. This evaluation function makes UAV drones prefer smoother turns and safer trajectories in complex environments.

Fusion of BGO-RRT-Connect and EA-DWA

I fuse the two improved algorithms by using BGO-RRT-Connect as the global planner and EA-DWA as the local planner. The global planner produces a safe and smooth global path. I then extract key points from this global path and use them as local goals for EA-DWA. This combines global optimality with local dynamic obstacle avoidance.

Key Point Extraction

Let the two trees of BGO-RRT-Connect produce node sets \(P_1\) and \(P_2\). Starting from the start point, I check three consecutive nodes. If they are collinear, the middle node is redundant and removed. Otherwise, I compute the distance from the line segment to the nearest obstacle. If the distance is greater than a safety threshold \(d\), I continue. If the distance is less than or equal to \(d\), the endpoint of the segment is added to the key point set \(P_c\). This process repeats until the goal is added. The key points guide EA-DWA efficiently.

Fusion Workflow

Stage Algorithm Role
1 BGO-RRT-Connect Generate global path with goal-oriented sampling and greedy connection
2 Key point extraction Select critical waypoints for local guidance
3 EA-DWA Perform local dynamic obstacle avoidance
4 Fusion Combine global optimality and local reactivity

Simulation and Data Analysis for Dynamic Planning

I evaluated BGO-RRT-Connect, EA-DWA, and the fusion algorithm in dynamic obstacle scenarios. The parameters are summarized below.

Parameter Value
Map size 10 × 10 for EA-DWA; 100 × 100 for fusion
Start (0,0)
Goal (10,8) for EA-DWA; (50,90) for fusion
Dynamic obstacle speed 1 m/s for EA-DWA; 2 m/s for fusion
Maximum linear velocity 2 m/s for EA-DWA; 6 m/s for fusion
Maximum angular velocity π/9 rad/s for EA-DWA; π/4 rad/s for fusion
Algorithm Path Length (m) Planning Time (s) Total Turning Angle (°) Failures
DWA 14.55 54.7 95 4
EA-DWA 13.64 43.2 68 0

For the dynamic obstacle scenario, EA-DWA reduced planning time by 21.03%, path length by 6.25%, and total turning angle by 28.42% compared with traditional DWA. Traditional DWA failed to detect fast obstacles approaching from behind, while EA-DWA successfully accelerated away when the obstacle entered the extreme danger zone. This shows that EA-DWA is safer for UAV drones.

Algorithm Planning Time (s) Path Length (m) Total Turning Angle (°) Failures
Fusion with traditional DWA 196.5 168.3 483.4 3
Reference algorithm A 185.7 147.7 455.2 0
Reference algorithm B 194.5 143.5 257 1
My fusion BGO-RRT-Connect + EA-DWA 178.1 140.7 253 0

When dynamic obstacles were added, my fusion algorithm achieved the shortest planning time, shortest path length, and smallest total turning angle among all compared methods. It also had zero failures, while the fusion with traditional DWA had three collisions and reference algorithm B had one collision. These results confirm that the integration of BGO-RRT-Connect and EA-DWA provides strong dynamic obstacle avoidance and high robustness for UAV drones.

Discussion

The experimental results show that my BGO-RRT algorithm significantly improves global path planning for UAV drones by reducing randomness, removing redundant nodes, and smoothing the path. The BGO-RRT-Connect extension further accelerates the global search. For local planning, EA-DWA enhances the traditional DWA with dual danger range judgment, improved speed space, and an additional angle change term. The fusion algorithm leverages the global path from BGO-RRT-Connect and the local reactivity of EA-DWA, producing paths that are both globally near-optimal and dynamically safe. This is particularly important for UAV drones operating in cluttered and unpredictable environments.

I also note that the choice of parameters, such as the attraction coefficient \(\alpha\), step size \(\mu\), danger radii \(r_1\) and \(r_2\), and evaluation weights \(a_1, a_2, a_3, a_4\), affects performance. In my simulations, I selected these parameters through repeated experiments. For future work, adaptive parameter tuning could further improve the performance of UAV drones in diverse scenarios.

Conclusion and Future Directions

In this article, I presented a comprehensive study of UAV drones path planning based on improved RRT and DWA algorithms. I first reviewed global and local planning foundations, including Dijkstra, A*, RRT, PRM, APF, and DWA. I then proposed BGO-RRT for global planning, which combines goal-oriented sampling, greedy pruning, and cubic B-spline smoothing. I also proposed BGO-RRT-Connect for faster global planning and EA-DWA for enhanced local dynamic obstacle avoidance. Finally, I fused BGO-RRT-Connect with EA-DWA by extracting key points from the global path and using them as local goals. Simulation results demonstrated that my methods outperform traditional RRT, A*, ant colony optimization, and traditional DWA in terms of planning time, path length, smoothness, and success rate.

For future research, I plan to extend my algorithms from 2D to 3D environments, because real UAV drones operate in three-dimensional space. I also intend to integrate my algorithms with a physical UAV drone platform and conduct real-world flight tests. This will allow me to validate the performance and stability of my methods under real sensor noise, wind disturbance, and communication constraints. I believe that further research on UAV drones path planning will continue to improve the autonomy, safety, and efficiency of UAV drones in both civilian and military applications.

Contribution Method Key Improvement Result
Global planning BGO-RRT Goal-oriented sampling, greedy pruning, B-spline smoothing Shorter, smoother, more reliable paths for UAV drones
Fast global planning BGO-RRT-Connect Bidirectional trees with goal-oriented sampling Fewer nodes and faster convergence
Local dynamic planning EA-DWA Dual danger range, improved speed space, angle evaluation Better dynamic obstacle avoidance and fewer failures
Fusion BGO-RRT-Connect + EA-DWA Key point extraction and global-local guidance Near-optimal global path with safe local avoidance

The tables and formulas in this article summarize the key derivations and experimental findings. I hope that my work provides a useful reference for researchers and engineers working on UAV drones path planning, and that it contributes to the development of safer and more autonomous UAV drones.

Scroll to Top