Abstract
In this article, we present an improved artificial potential field method of trajectory planning and obstacle avoidance for redundant manipulators. Specifically, we not only focused on the position for the manipulator end-effectors but also considered their posture in the course of trajectory planning and obstacle avoidance. We introduced boundaries for Cartesian space components to optimize the attractive field function. Moreover, the manipulator achieved a reasonable speed to move to the target pose, regardless of the difference between the initial pose and target pose. We proved the stability using Lyapunov stability theory by introducing velocity feedforward, when the manipulator moved along a continuous trajectory. Considering the shape of the manipulator joints and obstacles, we set up the collision detection model by projecting the obstacles to link coordinates. In this case, establishing the repulsive field between the nearest points on every joint and obstacles with the closest distance was sufficient for achieving obstacle avoidance for redundant manipulators. The simulation results based on a nine-degree-of-freedom hyper-redundant manipulator, which was designed and made in our laboratory, fully substantiated the efficacy and superiority of the proposed method.
Keywords
Introduction
Redundant manipulators are mostly intended for performing complex tasks in a restrictive environment, because they have a high number of degrees of freedom (DOFs), and the flexibility that results from a high number of DOF. In particular, their end-effectors are required to follow a desired trajectory; meanwhile, none of their joints will collide with obstacles in any cases. Many 1 –20 approaches have been proposed to solve the problems of trajectory planning and obstacle avoidance.
Considering redundant manipulators that work in Cartesian space, they have more than six DOFs. Hence, every desired task pose (position and posture) corresponds to infinite joint configurations. Moreover, when redundant manipulators perform the main task of tracking a desired trajectory, they are required to avoid joint limits and singularities, evade obstacles, and minimize the tracking error as far as possible. To solve these issues, global and local strategies have been developed by some researchers. Global path planning is a relatively well-studied research area 1 ; many global approaches were presented to solve these kinematic problems for redundant manipulators such as rapidly exploring random trees, 2,3 graph search algorithms, 4 optimization of predefined paths, 5 tangent graph-based planning, 6 mathematical programming and optimization, 7 and partially observable Markov decision processes. 8 A free path and the joint variables are obtained through the application of restrictions such as obstacles and joint limits. However, since complete trajectory information needs to be offered in advance, global methods are not suited to tasks that require continuous trajectory modification based on sensory feedback. 9 Local strategies are utilized by applying the deformation of the Jacobian matrix to acquire the trajectory online step by step based on current information. Conventionally, to minimize the joint velocity norm under the premise of the minimum tracking error of the end-effector, the Jacobian pseudoinverse is defined as the general solution of redundancy resolution. 10 The gradient projection method based on the Jacobian pseudoinverse is used to obtain the self-motion necessary to optimize the performance criteria, such as the avoidance of the joint limit and obstacle by defining a standard function and projecting it onto the null space of the Jacobian. 11,12 The weighted least-norm solution was suggested to minimize energy using the inertia matrix as the weighting matrix. 13 Additionally, it also can be used to avoid joint limits 14 and reduce joint torque. 15,16 Another option was developed as a so-called augmented Jacobian approach 17,18 and extended the Jacobian as a square matrix with additional tasks, such as performing cyclic tasks 19 and avoiding obstacles. 20 The artificial potential field method concerned in this article is a kind of local strategy that exerts virtual forces that are caused by attractive potentials or repulsive potentials on the manipulator link or end-effector. 21 Hence, the global dynamics model of the manipulator is required and the friction forces also cannot be neglected. Another kind of potential field method is to calculate the joint velocities by introducing the Jacobian pseudoinverse 22 and avoid collisions by controlling the joint velocities in the Jacobian nullspace. 23 The pseudo-distance between obstacles and links is defined to extend the Jacobian matrix to avoid collisions. 24 However, in these artificial potential field methods, stability is always demonstrated only in point-to-point motion but seldom considered while end-effector moving along a continuous trajectory. Furthermore, if the difference between the initial pose and target pose is too large, then the motion mode may be impossible because of demanding high speed or large torque. When repulsive potentials are used for obstacle avoidance, the volume of the link is often neglected, but the shape of the obstacle or its effect on manipulator motion is always expanded. The approximate method of obstacles reduces the motion space of manipulators in their restrictive work space, and neglecting the volume of the link may also increase the risk of failure to avoid obstacles. Additionally, most of these potential field methods are verified using planar robots, 22 –24 the verification and application of the method is seldom considered in Cartesian space, and the continuous change of posture is also neglected.
In this article, we propose an improved artificial potential field method to achieve trajectory planning and obstacle avoidance. Both position and posture are controlled simultaneously by defining an optimized six-dimensional attractive field in Cartesian space. Moreover, the product of the Jacobian pseudoinverse and desired speed is used as feedforward while manipulators move along a continuous trajectory. Obstacle avoidance is transformed by the collision detection problem, and only the repulsive potential field between the nearest two points on the obstacle and joint is considered. The attractive force caused by the attractive field and the repulsive force caused by the repulsive field are converted to joint torques using the Jacobian transpose. The torques are translated into joint velocities by constructing the virtual relationship between them to achieve trajectory and obstacle avoidance.
The remainder of this article is organized as follows. In “Trajectory planning based on attractive potential” section, we describe the trajectory planning method for a redundant manipulator, which can offer a reasonable motion form for the end-effector from the initial pose to the target pose. In “Obstacle avoidance based on repulsive potential” section, we present the obstacle avoidance algorithm that introduces the simplified geometric model of the manipulator link and only considers the repulsive potential action between the closest points on the obstacle and link. We discuss the simulation results and analysis of the proposed trajectory planning and obstacle avoidance algorithm for the redundant manipulator in “Simulation results” section. Finally, we present the conclusions.
Trajectory planning based on attractive potential
In actual applications, the desired trajectory is given in Cartesian space, whereas the manipulator can only be controlled in the joint space. Hence, the main issue in this field is to define the relation between Cartesian space and joint space. In this case, an approach based on the forward kinematic and the Jacobian transpose is employed.
The principle of trajectory planning based on attractive potential is shown in Figure 1. The schematic diagram of the n DOF robot is drawn during its initial pose and dotted line in the target pose; however, the configuration of the joint that corresponds to the target pose is not unique. From the graph, the relation between the two poses is obtained as
where xtar, xini, and Δx are the target pose, initial pose, and difference between the two poses, respectively, and they are all 6 × 1 vectors consisting of three translational and three rotational components. Thus, any pose of the end-effector can be written as
where

Schematic of redundant manipulator end-effector movement under the influence of attractive potential field.
As mentioned above, force Fatt is caused by the attractive potential around the target pose. We describe how the attractive potential can be constructed directly on the end-effector of the manipulator. Attractive potential field Uatt is constructed to make the end-effector be attracted to the target pose; hence there are some criteria that should be satisfied by field Uatt. Clearly, Uatt should be increasing with the difference Δx. However, if only the linear relationship between Uatt and Δx is defined, then this will lead to stability problems, because there is a discontinuity near the origin at which attractive force Fatt caused by potential field Uatt tends to zero .25 To obtain a continuously differentiable potential field, such a field that grows quadratically with Δx is defined as
where
where
where ηt and ηr describe the boundary of translational and rotational components, respectively. Furthermore, Uatt can be defined as
and in this case Fatt is given as
The boundary is well defined for the two fields because both Uatt and Fatt are continuous in the entire field.
Specific attractive force Fatt can be obtained from the attractive potential as defined above. Additionally, Fatt acting on the end-effector is resolved to joint torque
where J is a 6 × n matrix, and n denotes the DOF of the manipulator, as a result, τ is an n × 1 vector. We assume that there are no joint motors only viscous dampers on the manipulator, thus, joint velocity
where B is the joint damping coefficient (all dampers are assumed to be the same). 26 The change in the joint angle is obtained through the joint speed integral, and based on this, we determine the trajectory to the target pose. The principle is as shown in Figure 2.

Block diagram of point-to-point trajectory planning for redundant manipulator.
Gain K is denoted as
The continuous trajectory planning principle is shown in Figure 3, if the desired trajectory is a circle. The motion, such that the end-effector moves along a circle, can be decomposed into a myriad of point-to-point motion. Assuming that the deviation between every two adjacent poses is sufficiently small, each movement can achieve a predetermined desired position, and the error converges. Current position information and desired position information are continuously updated as the arm moves. Its convergence is hardly directly guaranteed for the entire motion. To achieve this goal, the product of desired trajectory velocity
where

Schematic of continuous trajectory planning for redundant manipulators using an attractive potential field.

Block diagram of continuous trajectory planning for redundant manipulators by introducing velocity feedforward.
We substitute
where K is chosen to be a diagonal matrix, and
where λ is considered as a small value when the configuration of the manipulator approaches the singularity, and zero otherwise. This not only ensures the stability of the entire system but also avoids the emergence of singular values.
Obstacle avoidance based on repulsive potential
To prevent a collision between the manipulator and obstacles, each particle of the obstacle surface is regarded as the repulsive potential field source. Additionally, the field should satisfy these following criteria: When the manipulator approaches the obstacle, the repulsive potential field works, thereby generating a repulsive force to compel the manipulator to move away from the obstacles; and when the manipulator is far away from obstacles, the fields exert little or no influence on manipulator motion. Based on these, the repulsive potential field function 23 is defined as
where d0 is the shortest distance boundary from the manipulator to the obstacles, and d is the shortest Euclidean distance between the origin of the repulsive field and the manipulator. From this, the relation between the magnitude of the force and the distance is obtained as
As described above, the relations among Urep, Frep, and d are defined. Because computing d directly in Cartesian space is quite complex, the obstacle is projected onto every link coordinate to compute d as shown in Figure 5. Each joint of the manipulator is regarded as a capsule body, and the obstacle avoidance problem of the entire manipulator is transformed into collision detections between n fixed capsule bodies and moving obstacles.

Schematic of collision detection between the joint and obstacle by projecting the obstacle to link coordinate.
To simplify the calculation, the scope of the manipulator movement affected by the obstacle should be identified. As shown in Figure 6(a), the capsule is projected onto any plane over line segment
where

Schematic of the range affected by the obstacle in joint space: (a) capsule horizontal projection, (b) capsule vertical projection.
The obstacle also has no effect on the movement.
When the motion of the manipulator is affected by the repulsive field, it is impossible that only one particle’s potential field acts on the manipulator. According to the theory of collision detection, two geometries will not collide, in any case, if their shortest distance is greater than zero. Hence, only considering the repulsive force between the two closest points on the joint and obstacle is adequate for attaining collision avoidance. When the shortest distance between the two points is less than d0, the point on the obstacle will produce a repulsive force to propel the point on the joint away from the obstacle. The shortest distance is guaranteed to be greater than zero, to achieve a single joint avoidance, and the entire manipulator will not collide with any obstacles.
For any points
And the shortest distance between the obstacle and joint is defined as
The manner in which the Euclidean distance between two complex objects in three-dimensional space is computed was studied thoroughly in the study by Gilbert et al.,
29
and it will not be described in detail in this article. It should be mentioned that the positions of two closest points,
And the force can be obtained as
Because

Schematic of the repulsive force acting the manipulator joint.
Obstacle avoidance algorithm.
However, there may be a line or plane that is closest to a joint, or even multiple obstacles could have the same distance to a joint, thus O may be also subjected to multiple forces. Moreover, there may be infinitely many parallel forces to synthesize an infinite force, therefore, only one is considered as the effective force. And forces that have the same magnitude and different directions are synthesized as new force
The repulsive forces acting on O were defined in the outline above. Such forces induce forces and torques on the manipulators joints, and motion would occur because of them. In particular, it is necessary to make explicit how these forces can be applied to drive every joint movement. Let O be the origin of the coordinate on the kth link. Consistent with equation (8),
where J is the Jacobian matrix of point O, which can be defined as a 6 × n vector matrix 26
where x1 to x6 express the pose of O in Cartesian space, and θk is the angle of the kth joint. According to equation (9),
And the gain Krep for
The obstacle avoidance trajectory planning principle is shown in Figure 8, where

Schematic of obstacle collision for redundant manipulators.
The velocity
In particular, this method not only achieves robot obstacle avoidance but also achieves every joint limit avoidance, if d0 is defined as the joint angle limit. However, it needs to be clear that the repulsive force of joint limit avoidance only acts on the corresponding joint as its torque.
Simulation results
Simulations not only proved the high accuracy of the proposed method in path tracking but also demonstrated its obstacle avoidance capability. The simulations were carried out on the 9-DOF redundant manipulator designed and made in our laboratory. The mechanical structure and schematic view of this manipulator are shown in Figure 9, and the Denavit–Hartenberg parameters of the manipulator are given in Table 1. Additionally, the angle of each joint only varied from

9-DOF manipulator: (a) manipulator structure and link coordinate systems, (b) hardware system of the manipulator. DOF: degree of freedom.
Denavit–Hartenberg parameters of the 9-DOF manipulator.
DOF: degree of freedom.

End-effector of the 9-DOF redundant manipulator moving from the initial pose to the target pose: (a) joint angle profiles with the original attractive potential, (b) joint velocity profiles with the original attractive potential, (c) joint angle profiles with the optimized attractive potential, and (d) joint velocity profiles with the optimized attractive potential. DOF: degree of freedom.
The introduction of velocity feedforward greatly reduced the tracking error for a manipulator moving along a specific trajectory and end-effector posture changing according to certain rules. Here let the manipulator end-effector draw a circle with a radius of around the point
The gain matrix is selected as

End-effector of the 9-DOF redundant manipulator moving along the continuous trajectory: (a) joint angle profiles, (b) joint velocity profiles, (c) configurations of manipulator profiles. DOF: degree of freedom.

Tracking error of the end-effector moving along the continuous trajectory in Cartesian space.

Joint velocity caused by joint limit.
The proposed method performed better, if only position control was required. From the initial pose (600, 400, 0, 0, 0 ,0), the end-effector moved along the trajectory as follows
The tracking errors of y and z positions are shown in Figure 14, and the configuration variations of the manipulator are shown in Figure 15. It can be observed from the figure that the maximum tracking error was approximately

Tracking error of end-effector in position control.

Configurations of manipulator profiles in position control.
Obstacle avoidance simulations were conducted under the premise of the obstacle being simplified into a sphere. Considering the obstacle as a sphere, ensured that only a pair of the nearest points existed between the obstacle and each joint of the manipulator for every moment. As shown in Figure 16, the shortest distance d can be expressed as 31
where Q is the sphere center, and S is the shortest point on line oo. And the direction of repulsive force

Simplified schematic of collision detection.
In this case, repulsive force
In this regard, collision detection could be further simplified. The joint could be seen as line segment oo, and the radius of the spherical obstacle should be the sum of the original obstacle radius R and joint radius r; therefore, the radius of the spherical obstacle can be written as
Without obstacle avoidance, the configurations of the 9-DOF manipulator are shown in Figure 17. Additionally, the closest distance between the joint and the obstacle is shown in Figure 18. Because the minimum distance was less than zero for some time, it is obvious that the manipulator collided with the obstacle. To design an obstacle avoidance algorithm in this case, d0 and Krep were, respectively, considered as

Configuration profiles of the manipulator moving along a continuous trajectory without obstacle avoidance.

Closest distance between the joint and obstacle without obstacle avoidance.

Configuration profiles of the manipulator moving along a continuous trajectory with obstacle avoidance.

Closest distance between the joint and obstacle with obstacle avoidance.

Configuration profiles of the manipulator moving along a continuous trajectory without obstacle avoidance for multiple obstacles.

Configuration profiles of the manipulator moving along a continuous trajectory without obstacle avoidance for multiple obstacles.

Configuration profiles in position control without obstacle avoidance.

Configuration profiles in position control with obstacle avoidance.
Conclusions
By introducing the artificial potential field model, the main task, trajectory planning, and the subtasks, obstacle avoidance and joint limit avoidance, both can be donated as fictitious forces acting on end-effector or joint. The forces can be resolved to joint velocities to drive the manipulator. This make the complicated task such as obstacle avoidance and joint limit avoidance easier and the control process more clearly, because we only need to control the joint velocities.
The trajectory planned using the proposed method in this article could meet the joint velocity limits and angle limits. And its tracking error was less than 10–3 mm for translational components and less than 10–5 rad for rotational components. In the case of position control, the tracking error was smaller. The obstacle avoidance algorithm proposed could ensure that the manipulator avoided the obstacle when its end-effector performed certain tasks not only for single obstacle but also for multiple obstacles. The correctness and superiority of the trajectory planning algorithm and obstacle avoidance algorithm based on the artificial potential field were verified by simulation results. Obstacle avoidance was achieved through defining the relation between the fictitious force and the distance of the nearest points on the obstacle and the joint. So we could ignore the specific shape of the obstacle, as long as we could get the information of the obstacle surface point, the real-time obstacle avoidance could be achieved. In the future work, we can combine obstacle avoidance algorithms with vision to make it more widely used.
Footnotes
Declaration of conflicting interests
The author(s) declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.
Funding
The author(s) disclosed receipt of the following financial support for the research, authorship, and/or publication of this article: This work was financially supported by the National Natural Science Foundation of China (no. 11672290), Science and Technology Development Plan of Jilin province (2018020102GX), and Jilin Province and the Chinese Academy of Sciences cooperation in science and technology high-tech industrialization special funds project (2018SYHZ0004).
