1. Introduction
The continuous advancement of computers and intelligent technologies is driving robotic applications toward greater intelligence and diversification while simultaneously imposing higher demands on their overall performance [
1,
2]. The core task of robotic arm path planning is to search for a feasible trajectory that safely moves the arm from its initial configuration to a target configuration without collisions under kinematic constraints and obstacle avoidance requirements. To enable efficient motion in complex environments and precise task execution at the target location, advanced path planning algorithms are essential for generating viable trajectories. Consequently, path planning algorithms constitute a critical component in the development of robotic arm technologies [
3,
4].
Current path planning algorithms can be broadly categorized into (1) graph-based search methods, such as Dijkstra’s algorithm [
5], A* [
6], and D* [
7]; (2) sampling-based methods, including the Rapidly exploring Random Tree (RRT) and Probabilistic Roadmap (PRM); and (3) bio-inspired intelligent algorithms, such as genetic algorithms, ant colony optimization, particle swarm optimization, and neural network–based approaches—particularly those integrated with deep learning. Among these, the RRT algorithm stands out as a classical representative of sampling-based planners. Owing to its efficient exploration capability and strong adaptability to complex environments, RRT has gained widespread application and recognition in engineering practice [
8]. The RRT algorithm was first proposed by LaValle et al. in 1998 as a tree-structured, randomized planning method designed to efficiently address path planning problems in high-dimensional spaces. However, its inherent randomness leads to drawbacks such as long computation time and low convergence efficiency. To address these limitations, Wang et al. introduced a goal-biased sampling strategy. This approach uses a bias threshold compared against a random number to guide the random tree toward the goal direction with a certain probability, thereby reducing redundant nodes and improving search efficiency. Building upon basic RRT, Karaman et al. proposed the RRT* algorithm, which incorporates a rewiring mechanism. After inserting a new node, RRT* re-optimizes connections within its neighborhood by re-selecting parent nodes to progressively reduce path cost, ultimately achieving asymptotic optimality. Gammell et al. further advanced this with Informed RRT*, which introduces an ellipsoidal informed sampling strategy: once an initial feasible path is found, subsequent sampling is confined to an ellipse with the start and goal as foci, significantly accelerating convergence toward the optimal solution. Subsequent research has further extended RRT* for diverse scenarios. Qi et al. developed a Multi-Objective Dynamic RRT* (MOD-RRT*) for navigation in unknown dynamic environments [
9]. Qureshi et al. [
10] proposed P-RRT*, which integrates artificial potential fields into the RRT* framework, using attractive forces toward the goal to guide tree growth and enhance global search efficiency. GUO et al. [
11] proposed the DBVSB-P-RRT* algorithm, which incorporates an adaptive deflection sampling function, an adaptive attraction function based on the artificial potential field (APF), a variable-step expansion heuristic strategy, and a novel collision detection heuristic method. This algorithm possesses rapid planning capabilities, making it particularly suitable for path generation in emergency scenarios for mobile robots, enabling efficient output of trajectories that satisfy constraint conditions. However, this method offers limited improvement in path quality and is currently confined to two-dimensional path planning problems, without yet addressing relevant factors in multidimensional space planning. Zhen et al. [
12] proposed the HS-APF-RRT* algorithm, which integrates a hierarchical terrain sampling mechanism, a slope-aware artificial potential field, and a dynamic 8/16-neighborhood expansion strategy. This algorithm can plan the shortest and highest-quality paths in complex environments. It not only achieves initial feasible solutions faster and significantly reduces the number of iterations and energy consumption but also completely avoids hazardous areas, providing an efficient, safe, and robust solution for path planning in complex environments. Jeong et al. introduced Q-RRT*, which expands the parent selection range to include grandparent nodes during rewiring, significantly improving both search efficiency and path quality [
13]. Li et al. combined P-RRT* and Q-RRT* into PQ-RRT*, leveraging their complementary strengths to accelerate convergence and enhance planning efficiency [
14]. Wei et al. proposed Smooth RRT (S-RRT), which generates kinematically feasible and smooth trajectories through a maximum curvature-constrained optimization strategy; however, its reliance solely on goal bias during tree expansion limits its search efficiency and results in substantial deviation between the optimized and initial paths [
15]. Nasir et al. presented RRT*-Smart, which improves efficiency through path optimization and intelligent sampling, but it was validated only in 2D environments and still produces paths with redundant turns. Liao et al. [
16] proposed F-RRT*, which actively assigns the optimal parent node to each new sample to reduce cumulative path cost, yet its parent selection strategy exhibits limited adaptability in complex environments, leading to slow convergence. Cong et al. [
17] introduced FF-RRT*, which fuses F-RRT* with Fast-RRT* and refines the hybrid sampling strategy, effectively overcoming limitations of prior methods and reducing convergence time—though sampling efficiency remains suboptimal in obstacle-dense scenarios. Chai et al. [
18] proposed RJ-RRT, which employs a greedy sampling space reduction strategy to minimize redundant tree expansion; however, it may still suffer from slow convergence in environments with uneven obstacle distributions. Ganesan et al. [
19] developed a hybrid sampling-based RRT* variant that combines uniform and non-uniform sampling with dynamic sampling domain adjustment, effectively balancing exploration and exploitation to enhance planning efficiency and adaptability in complex environments. Qie et al. [
20] introduced Target-biased Fast RRT* (TF-RRT*), which biases samples toward the goal to accelerate convergence. Ji et al. [
21] proposed E-RRT*, which replaces straight-line connections with elliptical arcs to speed up convergence and incorporates HRM angle constraints to produce more kinematically compliant paths with reduced redundancy. Ding et al. [
22] presented EP-RRT, which integrates bidirectional search with dynamic region contraction: it first rapidly generates an initial path using an RRT-Connect-like dual-tree mechanism, then applies heuristic sampling within a shrinking region to iteratively prune redundant nodes and refine the path toward optimality. Chen et al. proposed a bidirectional RRT* variant that decouples path expansion from optimization [
23]. Chao et al. combined RRT* with grid-based search to create GB-RRT*, which enhances performance in narrow passages and complex obstacle fields without requiring a predefined roadmap [
24]. Liu Xiaosong et al. improved P-RRT* by refining the potential field guidance and introducing a dynamic step-size adjustment mechanism, significantly accelerating convergence. Cheng et al. [
25] proposed an RRT-Connect-based improvement featuring adaptive step size and four concurrent trees rooted at the start, goal, and two fixed sampling points, greatly enhancing spatial coverage and convergence speed. Song Junhui et al. integrated an Adaptive RRT* based on an Improved Potential function (AIP-RRT*) with a Dynamic Gravitational Field–Artificial Potential Field (DGF-APF) method, synergistically combining sampling guidance and gradient descent to overcome the local minima problem of APF and the randomness of RRT. Huang et al. [
26] proposed Agile-RRT*, which improves convergence via adaptive goal bias but is limited to 2D scenarios and lacks generalization to 3D or higher-dimensional spaces.
Based on existing research, this paper proposes an enhanced RRT* algorithm to address the limitations of the RRT* algorithm in terms of sampling guidance, search efficiency, and convergence speed. First, a dynamic ellipsoidal sampling strategy is introduced to adaptively shrink the sampling region, accelerating spatial exploration. Simultaneously, a bidirectional RRT* framework is adopted, enhancing convergence efficiency through alternating expansion from both the start and goal points. Second, a dynamic goal-biasing strategy is combined with a heuristic search mechanism to strengthen goal orientation while maintaining global exploration capability. The improved artificial potential field method is employed to guide the tree expansion direction, further reducing the number of iterations. The algorithm also integrates local rewiring optimization, which simultaneously optimizes path cost during node expansion, balancing path length, smoothness, and safety. Finally, path pruning technology is applied to remove redundant nodes, and the path is smoothed using a cubic B-spline interpolation algorithm, generating a final trajectory with continuous curvature suitable for execution.
4. Improved RRT* Algorithm
4.1. Dynamic Ellipsoidal Sampling Strategy
To address the issues of uneven distribution and low-quality samples in the traditional RRT algorithm’s random sampling strategy, this paper introduces a dynamic ellipsoidal sampling mechanism. This strategy adaptively adjusts the size and scope of the sampling ellipsoid based on the real-time progress of path search and environmental complexity, thereby enhancing the relevance and effectiveness of the sampled points.
4.1.1. Ellipsoidal Sampling Parameters
The 3D shape of the ellipsoid and its parametric representation in the plane are shown in
Figure 6 and
Figure 7, respectively.
where
and
are the foci of the ellipsoid,
is the distance between the two foci,
is the length of the major axis of the ellipsoid, and
is the center of the ellipsoid (i.e., the midpoint of the line segment joining the two foci).
4.1.2. Dynamic Adjustment Formula for Ellipsoid Parameters
The adjustment formula for the semi-major axis
is
The adjustment formula for the semi-minor axis
is
In the equation, is the semi-major axis of the ellipsoid, is the semi-minor axis of the ellipsoid, is the environmental complexity factor (related to obstacle penetrability), and is the iteration count. The adjustment period is defined as updating the parameters once every iterations (e.g., if = 100, parameters are updated after every 100 iterations). indicates how many iterations occur before updating the ellipsoid parameters; is the initial value of after each update cycle (determined by environmental complexity, with a new value defined after each update based on current environmental complexity); is the initial value of the semi-major axis at the beginning of each iteration cycle.
The environmental complexity factor
is defined as
In the formula, is the base complexity, set as ; represents the volumetric complexity, where is the total volume of obstacles within the local space, and is the volume of the local sphere; represents the numerical complexity, where is the number of obstacles within the local space, and is the reference number (i.e., the total number of obstacles); represents the historical sampling complexity, where is the number of failures (collisions or invalid expansions) in the recent sampling attempts, and is the total number of attempts in the recent sampling iterations (in this paper, , meaning the history of the most recent 20 sampling attempts is considered); and , , and are the weighting coefficients, set as , , and .
The dynamic initialization formula is
In the equation, is the ratio of the total volume of obstacles contained within the local space to the total volume of the entire space, is the number of obstacles contained within the local space, is the total number of obstacles in the environment, and is the dynamically initialized initial value of the ellipsoid’s semi-minor axis.
The local space is defined as a spherical region centered at
with radius
. The specific formula is as follows:
Here, is a proportional coefficient; it is recommended to set (with being approximately 0.7).
When the semi-major axis of the ellipsoid grows exponentially, expands synchronously, ensuring that the local region around always remains appropriately matched to the scale of the ellipsoid. The dynamic can more accurately match the local environmental requirements around .
4.1.3. Mathematical Principle of Ellipsoidal Sampling
The fundamental principle of ellipsoidal sampling is to sequentially apply scaling, rotation, and translation transformations to points within a unit sphere; these points are mapped into the interior space of the ellipsoid.
To obtain uniformly distributed random points within the unit sphere, uniform sampling in spherical coordinates can be employed: first generate a random azimuthal angle , polar angle , and radius ; then, convert the spherical coordinates to Cartesian coordinates .
Generating random point coordinates in the spherical coordinate system, i.e.,
In the equation, is a function that generates a uniformly distributed random number within the interval [0, 1].
The transformation from spherical coordinates to Cartesian coordinates is given by
The coordinate transformation process is as follows:
- (1)
Generate a local coordinate system, i.e.,
In the equation, , , and are basis vectors; is a unit vector, obtained by normalizing the vector from the start point to the goal point , i.e., ; is the component of in the y-direction; is the component of in the x-direction; is the projection of vector onto the -plane; is a predefined small positive number, representing a threshold value; and vector is obtained by the cross product of vector and vector .
- (2)
Construct the rotation matrix , i.e.,
In the equation, denotes the three-dimensional special orthogonal group.
- (3)
Generate the sample point, i.e.,
In the equation, , is the semi-axis length of the line segment passing through point and perpendicular to both the semi-major axis and semi-minor axis of the ellipsoid, and is the translation vector representing the center of the ellipsoid.
4.1.4. Analysis of the Dynamic Adjustment Mechanism
For the semi-major axis , the adjustment strategy is to grow exponentially with the number of iterations, thereby accelerating the search. The formula is , where is the threshold for adjusting the ellipsoid every iterations.
For the semi-minor axis , the adjustment strategy is that its initial value is determined by environmental complexity, and thereafter, it grows synchronously with the growth rate of . The formula is , where is the threshold for adjusting the ellipsoid every iterations.
For the aspect ratio (shape ratio), the adjustment strategy is that the initial ellipsoid eccentricity is positively correlated with obstacle distribution. The formula is , where is the initial ellipsoid flatness (eccentricity), and is the obstacle density.
4.1.5. Analysis of the Environmental Perception Mechanism
- (1)
The obstacle influence factor
is
- (2)
The mechanism of action is as follows:
For the term, the greater the proportion of total obstacle volume within the local space, the flatter the ellipsoid (i.e., the smaller ), which enhances axial search along the primary direction. For the term, the more obstacles intersected by the path, the flatter the ellipsoid, which avoids densely clustered obstacle regions.
4.1.6. Algorithm Characteristics Analysis
- (1)
Directed search: The major axis always points toward the target direction, accelerating the process of approaching the goal;
- (2)
Obstacle avoidance: Employs a dynamic contraction mechanism for the semi-minor axis , automatically narrowing the search width in regions with dense obstacles;
- (3)
Progressive optimality: The ellipsoid volume grows exponentially to balance explora-tion and exploitation, gradually covering the entire configuration space;
- (4)
Environmental adaptation: Based on real-time collision detection feedback, dynami-cally adjusts the sampling strategy according to the actual distribution of obstacles.
The dynamic ellipsoidal sampling strategy focuses the search initially on the region between the start and goal points and then gradually expands the search scope as the number of iterations increases and the proportion of obstacle volume decreases. If a feasible path remains difficult to find over a long period, the search will eventually cover the entire space, thereby significantly improving the likelihood of discovering challenging paths.
4.2. Dynamic Goal-Biased Strategy
The dynamic goal-biased strategy guides the random tree toward the goal in a greedy manner, thereby reducing redundant exploration caused by random sampling and improving path planning efficiency.
The dynamic goal-biased strategy consists of the following steps:
- (1)
Calculate the direction vector. Given the current nearest node
and the goal point
, the direction vector
is defined as their difference, i.e.,
- (2)
Adjust the step size
. If the magnitude (norm) of the direction vector exceeds the step size
, normalize it and then multiply by
; otherwise, use the direction vector directly, i.e.,
- (3)
Generate the new node, i.e.,
The path must satisfy collision-free and safety distance constraints: The path does not intersect any obstacles, .
During the algorithm expansion process, the dynamic goal-biased strategy prioritizes extending the path toward the target point , i.e., based on the current node , it attempts to generate a new node in the direction of the goal. If the target point is relatively far away, the node is extended by the predefined step size ; if the target point lies within the neighborhood, an attempt is made to establish a direct connection. All candidate path segments must pass collision detection and safety distance validation to ensure the generated path is safe and feasible. In obstacle-free environments, this strategy helps rapidly converge the path toward the goal, significantly improving search efficiency. In complex obstacle environments, however, the strategy must be combined with artificial potential field repulsive forces to assist in obstacle avoidance or leverage a reconnection mechanism to adjust the path direction and avoid local deadlock. The advantage of this strategy lies in its ability to effectively compress ineffective search space and accelerate the generation of feasible paths. Its drawback is that, when facing narrow passages or densely clustered obstacle regions, it may become trapped in local optima; therefore, it typically needs to be supplemented with random sampling or potential field guidance for additional exploration.
To address the issue that the dynamic target bias strategy is prone to falling into local optima in narrow passages or dense obstacle environments, this paper integrates it with the improved artificial potential field strategy described in
Section 4.5 for cooperative guidance. The specific collaborative mechanism is as follows:
- (1)
Direction vector synthesis:
When generating a new node, not only is the attraction in the direction of the target point considered, but the resultant force direction calculated by the artificial potential field is also simultaneously introduced. Let the target bias direction vector be
(Equation (20)) and the resultant force direction of the artificial potential field be
(Equation (36)). Then, the final extension direction
is obtained through weighted fusion as follows:
where
and
are the weighting coefficients for the target bias and potential field guidance, respectively, satisfying
. Initially, they are set as
and
to maintain strong target orientation. When it is detected that the path falls into local oscillation or repeated collisions, the coefficients are dynamically adjusted to
and
to enhance the obstacle avoidance effect of the potential field.
- (2)
Local minimum escape strategy:
If consecutive attempts (in this paper, ) at expansion fail due to collisions, the algorithm is judged to have fallen into a local minimum. At this point, the target bias is temporarily abandoned, and a pure artificial potential field-guided “escape exploration” is performed for several steps (e.g., 10 steps) until the local region is exited, after which the fusion strategy is restored.
Through the aforementioned collaborative mechanism, the dynamic target bias strategy effectively utilizes potential field information to avoid dense obstacles and narrow passages while maintaining efficient convergence toward the target, thereby significantly reducing the occurrence of local optima.
4.3. Heuristic Nearest Neighbor Selection Strategy
The heuristic nearest neighbor selection strategy accelerates path planning convergence by dynamically balancing heuristic guidance and random exploration.
This heuristic nearest neighbor selection strategy consists of two parts:
- (1)
Optimal node selection based on a heuristic function.
When selecting a heuristic node with probability
, the node with the smallest
value is chosen as the nearest neighbor.
where
represents the actual path cost from the start point to node (e.g., path length), and represents the heuristic function, typically the Euclidean distance .
- (2)
Nearest neighbor selection for randomly sampled points.
When selected with probability
, directly find the node that is geometrically closest to the random sample point
:
The heuristic nearest neighbor selection strategy must satisfy the following constraints:
- (1)
Probability weight adjustment.
The heuristic selection probability
is dynamically adjusted according to the number of iterations:
In the equation, represents the current iteration count, and represents the maximum number of iterations. In the early stages, the strategy favors random exploration (smaller ); in later stages, it shifts toward heuristic optimization.
- (2)
Path feasibility verification.
Regardless of which nearest neighbor is selected, the new node must satisfy: The path from to must not intersect any obstacles, .
The heuristic nearest neighbor selection strategy consists of two components: heuristic guidance and random exploration. When the heuristic selection probability is large, the strategy favors heuristic selection (choosing the node with the smallest value), guiding the tree to grow toward the goal direction, reducing redundant branches, and emphasizing local optimization (shortening path length). When is small (i.e., is large), the strategy favors random exploration (selecting the geometrically nearest node), maintaining exploration capability, avoiding getting trapped in local optima, and emphasizing global exploration (preventing feasible paths from being missed).
4.4. Random Sampling Expansion Strategy
By using random sampling to guide the tree to expand into unexplored regions, this approach avoids getting trapped in local minima while ensuring global search capability.
The expansion of random sample points consists of the following steps:
- (1)
Random sample point generation.
Uniformly randomly sample a point
in the configuration space
:
Here, represents a uniformly distributed random variable within the interval , and represent the spatial dimensions of the environment.
- (2)
Nearest neighbor node selection.
From all nodes in the tree, select the node
that is geometrically closest to
:
represents the Euclidean distance.
- (3)
Direction vector calculation.
Generate a unit direction vector from
to
and extend it by the step size
:
If , then directly take as the new node .
- (4)
Path feasibility verification.
The new node must satisfy the following conditions: The path from to must not intersect any obstacles, .
The random sampling expansion strategy is probabilistically complete: if a feasible path exists, it will be found with probability 1 within the maximum number of iterations. It balances exploration and exploitation—the randomness enables exploration of new regions, while the nearest neighbor strategy promotes local path optimization. Random sample points are generated using uniform sampling, which ensures candidate points are uniformly distributed over the entire configuration space, guaranteeing coverage of the entire free space. In complex environments (e.g., narrow passages), improved sampling strategies such as ellipsoidal sampling or Gaussian sampling can be adopted to enhance performance. By selecting the node in the tree nearest to the random sample point as the expansion base, the strategy ensures locally shortest path extensions and reduces time complexity. The step size controls the expansion speed: a smaller step size improves path accuracy but increases the number of iterations, whereas a larger step size may skip over narrow obstacles.
4.5. Improved Artificial Potential Field Strategy
By integrating the local obstacle avoidance capability of artificial potential fields with the global optimality of the RRT* algorithm, this approach addresses the problem of low planning efficiency exhibited by traditional RRT in environments with dense obstacles.
The core of the fusion strategy between artificial potential fields and the RRT* algorithm lies in computing the node expansion direction through a combination of the attractive force (guiding toward the goal) and repulsive force (avoiding obstacles) from the artificial potential field. The steps are as follows:
Compute the total direction vector
, i.e.,
In the equation, is the combined attractive force between the goal point and the random point, is the repulsive force generated by obstacles, and is the repulsive force generated by neighboring nodes (to prevent node clustering).
The formula for the attractive force is as follows.
The attractive force consists of a weighted direction combining the goal point and the random sample point, i.e.,
In the equation, and are the attractive force weights for the goal point and the random point, respectively; is the coordinate of the current node; is the goal point; and is the random point.
The repulsive force from obstacles is divided into a basic repulsive force and an additional repulsive force (to avoid local minima), i.e.,
Repulsive force formula (for obstacles) is as follows:
The basic repulsive force (repulsion effect) is
The additional repulsive force (goal-oriented correction) is
In the equation, is the obstacle repulsion constant, is the control exponent for repulsive force, governing its attenuation, is the distance from the current node to the obstacle surface, is the effective range of the repulsive force, is the distance from the current node to the goal, and is the unit direction vector pointing from the obstacle surface toward the current node.
The node repulsion formula (to prevent clustering) is as follows:
In the equation, is the node repulsion constant, is the distance between the current node and other nodes, is the radius of influence for the repulsive force, and is the unit direction vector pointing from other nodes toward the current node.
After combining all directional components, normalize the resulting vector and generate the candidate node, i.e.,
In the equation, is the expansion step size, is the coordinate of the candidate node, is the total direction vector, and is the magnitude (norm) of the total direction vector.
4.6. Reconnection Optimization Strategy
Through local reconnection optimization, the cumulative path cost of new nodes is reduced while balancing path length, smoothness, and safety. The reconnection strategy selects a better parent node for the new node by searching neighboring nodes and optimizing based on multi-objective cost.
The reconnection optimization strategy includes the following steps:
- (1)
Cumulative path cost.
The total path length from the root node (start point) to node
is
In the equation, represents the total path length from the root node (start point) to node , is the root node, and .
It can also be computed recursively:
- (2)
Comprehensive cost function.
When the new node
selects a parent node
, the comprehensive cost is
In the equation, represents the total path length from the root node (start point) to node ; represents the weight controlling the turning angle penalty term; represents the weight controlling the obstacle distance penalty term; represents the path turning angle (in radians), formed by the grandparent node , the candidate parent node , and the new node ; and represents the minimum distance from the path segment to obstacles.
- (3)
Turning angle penalty calculation.
The path turning angle is defined by the angle between vectors:
In the equation, , , and the penalty term encourages smoother paths and helps avoid sharp turns. Since may become zero, to ensure the numerical stability of the angle calculation, the algorithm constrains the minimum step length during node expansion to avoid node overlap. Additionally, when computing , a denominator protection mechanism is adopted: if (where is an extremely small positive number, such as ), is directly set to 0. In practical calculations, the denominator term is replaced by to avoid division-by-zero errors.
- (4)
Obstacle distance penalty.
The minimum distance
between the path segment and obstacles is mapped to a penalty term via an exponential function:
In the equation, represents the obstacle distance penalty. When (approaching an obstacle), the penalty approaches . When , the penalty can be neglected (safety distance is satisfied).
- (5)
Parent node selection condition.
Select the node with the minimum comprehensive cost within the neighborhood as the parent node:
In the equation, , where is the neighborhood radius.
The path must satisfy collision-free and safety distance constraints: The path from to must not intersect any obstacles, .
The reconnection optimization strategy restricts the search scope via the neighborhood radius, reducing computational load. The base path cost directly optimizes path length; the turning angle penalty reduces unnecessary turns in the path, enhancing motion feasibility (e.g., respecting UAV turning radius limits); and the obstacle distance penalty encourages paths to stay farther from obstacles, improving the safety margin while enforcing a safety distance constraint to prevent paths from closely hugging obstacles.
4.7. Path Pruning Strategy
After optimization using the aforementioned strategies, redundant nodes in the path are significantly reduced. Based on this, further path pruning is applied for final optimization. As shown in
Figure 8, the pruning principle is as follows: traverse the random tree path from either the start or end point and remove redundant nodes to obtain a shorter feasible path. In
Figure 8, the original path is represented by the red solid line segment. From point 1 to points 2, 3, and 4, no collisions occur; however, a collision occurs when reaching point 5. Therefore, point 1 is directly connected to the node preceding point 5 (i.e., point 4). Taking point 4 as the base, since no collisions occur between point 4 and points 5 or 6, point 4 is connected directly to point 6. The optimized path segments are shown as black dashed lines in the figure. Points 2, 3, and 5 are redundant nodes.
4.8. Path Smoothing
Although the pruned path is shortened, it introduces numerous sharp bends, resulting in a zigzag trajectory with frequent undulations. Such a path not only makes it difficult to ensure smooth operation of the robotic arm but also accelerates mechanical wear and shortens its service life. Therefore, path smoothing is crucial. In this paper, a smoothing method based on cubic B-spline basis functions is adopted to optimize the pruned path.
The formula for the cubic B-spline curve
is as follows:
In the equation,
represents the control points of the curve, and
represents the cubic B-spline basis functions. During the smoothing process, the specific coordinates of the control points
are first determined. Then, by substituting these control points and basis functions into Equation (43) according to Equation (44), the coordinates of all points conforming to the definition of the cubic B-spline curve can be computed. The effect of path smoothing is shown in
Figure 9.
4.9. Algorithm Flow
The algorithm flow of this paper is shown in
Figure 10.
Step 1: Initialize the environment and algorithm parameters and construct two separate random expansion trees rooted at the start point and the goal point, respectively.
Step 2: Employ a dynamic elliptical sampling strategy to generate sample points. Node expansion utilizes a dynamic goal-biasing strategy to enhance search efficiency and speed. Evaluate the relationship between (distance from the new node to obstacles) and (a predefined threshold). If , proceed to collision detection. Otherwise, direct the process to heuristic nearest neighbor selection to generate the nearest neighbor for both random sampling expansion and improved APF, then proceed with random sampling expansion. If a collision is detected, redirect to heuristic nearest neighbor selection for both strategies and resume random sampling expansion. If no collision occurs, perform reconnection optimization and rewiring, then determine whether the two random search trees have met. If they meet, a collision-free path is formed. Otherwise, resample and continue.
Step 3: Introduce the random sampling expansion strategy. Again, evaluate the relationship between and . If , proceed to collision detection. Otherwise, direct the process to the improved APF strategy. If a collision is detected, redirect to the improved APF strategy. If no collision occurs, perform reconnection optimization and rewiring, then check whether the two random search trees have met. If they meet, a collision-free path is formed. Otherwise, resample and continue.
Step 4: Introduce the improved artificial potential field (APF) strategy. Compute the total direction vector to determine the position of the new node. Evaluate the relationship between and . If , proceed to collision detection. Otherwise, resample. If a collision is detected, resample. If no collision occurs, perform reconnection optimization and rewiring.
Step 5: Determine whether the two newly generated nodes (one from each tree) have met. If not, continue iterating. If they meet, proceed to the next step.
Step 6: Merge the path points, apply the path pruning strategy combined with cubic B-spline smoothing for final path optimization, and conclude the robotic arm obstacle-avoidance path planning algorithm.
6. Physical Robot Experiment
To evaluate the effectiveness of the proposed algorithm in real-world applications, physical experiments were conducted using a JAKA robotic arm. In the experiment, a balloon was used to simulate an obstacle, and a square box served as the target location, establishing a test environment consistent with real-world operating conditions. The obstacle-avoidance path planning algorithm was executed on a host computer, which generated motion commands and transmitted them to the robot controller via the JAKA robot API, thereby driving the robotic arm to complete the obstacle-avoidance task.
Figure 15 illustrates the physical experimental setup. As shown, the robotic arm successfully avoided the obstacle and accurately reached the target position, demonstrating that the proposed algorithm is both feasible and practical in real-world scenarios.
Furthermore, to gain deeper insight into the performance of each joint of the robotic arm during motion, a plot of joint positions over time was generated (see
Figure 16). This figure clearly illustrates the motion trajectories of all six joints during path execution. It can be observed that joints 1, 4, and 5 exhibit more pronounced position changes, indicating their critical roles in overall motion coordination. Specifically, joints 4 and 5 are primarily responsible for adjusting the posture of the middle section of the arm, ensuring smooth transitions along the planned path. In contrast, joint 6 mainly focuses on fine-tuning the orientation of the end-effector. The smoothness of these trajectory curves further demonstrates the stability and good controllability of the improved RRT* algorithm in guiding robotic arm motion.
The experiment was repeated 30 times, and the statistical results—including average planning time, average path length, and the success rate of the robotic arm in completing the task—are summarized in
Table 18.
Experimental results demonstrate that the improved RRT* algorithm significantly outperforms all other algorithms across all performance metrics. Compared with RRT*, GB-RRT*, BI-RRT*, APF-RRT*, and BI-APF-RRT*, the improved RRT* algorithm reduces planning time by 58.46%, 46.75%, 36.49%, 39.78%, and 22.72%, respectively; shortens path length by 18.25%, 13.32%, 10.04%, 8.98%, and 5.21%, respectively; and increases the robotic arm’s task success rate by approximately 21.8%—rising from 78.2% (with the standard RRT*) to 100%. The reduction in planning time indicates that the improved RRT* algorithm optimizes both the sampling mechanism and node selection efficiency during path search. The shorter path length demonstrates its ability to generate higher-quality motion trajectories, thereby reducing motion redundancy. Moreover, the improved success rate further validates the enhanced robustness and reliability of the proposed algorithm, particularly in complex and obstacle-dense environments. Collectively, these experimental results confirm that the improved RRT* algorithm can efficiently plan paths, effectively avoid obstacles, and reliably guide the robotic arm to reach its target position safely and accurately.
7. Conclusions
To address several limitations of the standard RRT* algorithm when applied to robotic arm path planning—such as insufficient goal bias in random sampling, slow convergence, low path search efficiency, and lack of path smoothness—this paper presents a comprehensive study and proposes an improved RRT* algorithm. First, a dynamic ellipsoidal sampling strategy is introduced to adaptively shrink the sampling region, accelerating spatial exploration. The size of the ellipsoid is dynamically adjusted based on search progress and environmental complexity, thereby enhancing the quality of sampled points. Second, a bidirectional RRT* framework is adopted, where trees grow alternately from both the start and goal points, significantly improving convergence efficiency. Additionally, a dynamic goal-biased strategy is employed to greedily steer the random tree toward the goal, enhancing planning speed. A heuristic search mechanism is integrated with RRT* to dynamically balance heuristic guidance and random exploration, further accelerating convergence. Moreover, an enhanced artificial potential field (APF) method is used to guide tree expansion, effectively reducing the number of iterations required. To optimize local path quality, a local reconnection optimization strategy is applied to lower the accumulated cost to come of newly added nodes while simultaneously balancing path length, smoothness, and safety. Finally, path pruning removes redundant nodes, and cubic B-spline interpolation is used to smooth the final trajectory. During smoothing, the cubic B-spline algorithm refines the path to achieve optimal continuity and smoothness. Three-dimensional simulation results demonstrate that, compared with RRT*, GB-RRT* (goal-biased RRT*), BI-RRT* (bidirectional RRT*), APF-RRT*, and BI-APF-RRT*, the proposed improved RRT* algorithm exhibits significant advantages in both planning efficiency and path quality. Specifically, it achieves shorter planning times, fewer path nodes, and reduced path lengths while generating trajectories with superior smoothness and continuity—substantially enhancing the robotic arm’s path planning performance in 3D environments.