# Optimization Algorithm for 3D Smooth Path of Robotic Arm in Dynamic Obstacle Environments
## 2 Basic Model  
In robotic path planning, generating an executable trajectory efficiently and smoothly in high-dimensional complex environments remains a critical challenge. RRT and APF are two representative path planning approaches, each with distinct advantages, but also inherent limitations. RRT is widely adopted due to its ability to explore high-dimensional spaces without requiring precise environmental modeling, making it highly scalable for complex environments. However, its lack of directionality often results in long and non-smooth trajectories, and in dynamic scenarios, frequent replanning leads to high computational overhead. On the other hand, APF constructs an attractive and repulsive potential field to generate continuous and smooth paths, making it well suited for real-time obstacle avoidance. However, APF tends to suffer from local minima when multiple obstacles are present. Given these characteristics, this study selects RRT and APF as fundamental models, leveraging their respective strengths to develop an efficient path planning strategy for both static and dynamic environments. This selection enables the proposed approach to handle complex environments while ensuring both smoothness and real-time adaptability, providing a solid theoretical foundation for robotic applications in dynamic obstacle avoidance. The rapidly exploring random tree (RRT) algorithm, as a random sampling algorithm, is fundamentally based on the idea of gradually growing a random tree from an initial point. At each step, a new node is randomly selected, and a straight-line or curved trajectory is emitted into the surrounding space. If this trajectory encounters an unobstructed area, its endpoint is added to the tree as a new node and connected to the nearest tree node. By continuously repeating this process, the tree gradually covers the target area until an effective path connecting the start point and the goal point is found. Due to it not having a requirement for precise environmental modeling, it is widely applied to solve robotic arm path planning problems in high-dimensional spaces and complex environments. In this thesis, based on the motion status of obstacles, grasping tasks are classified into intelligent grasping in static environments with obstacles and dynamic environments with obstacles, and two effective path planning algorithms for robotic arm grasping execution are respectively proposed. The rapidly exploring random tree (RRT) algorithm is a widely used sampling-based motion planning method, known for its probabilistic completeness and efficiency in high-dimensional spaces. However, due to its strong randomness and lack of directional guidance, RRT often generates suboptimal paths with unnecessary detours and irregular trajectories. To address these limitations, researchers have developed various optimization techniques. One of the most notable improvements is the RRT* algorithm, proposed by [PERSON] and [PERSON] [19]. RRT* extends the standard RRT by incorporating rewiring and parent node reselection mechanisms, ensuring that newly added nodes can be connected to the tree in a way that minimizes overall path cost. This modification makes RRT* asymptotically optimal, meaning that as the number of sampled points approaches infinity, the solution converges to the optimal path. Despite its theoretical guarantees, RRT* still suffers from low expansion efficiency and poor initial path smoothness due to its reliance on random sampling. Additionally, its performance in dynamic environments remains a challenge, as frequent replanning is required to handle moving obstacles efficiently. Addressing these issues remains a key focus in the development of improved motion planning strategies. Artificial potential field (APF) is a path planning technique based on physical concepts, which treats the robot as a particle guided by a virtual potential field. In robot motion planning, APF constructs a potential energy function that consists of two components: an attractive potential field and a repulsive potential field.