Smooth and Accurate Trajectory Planning for Industrial Robots

This paper proposes a smooth and accurate trajectory planning for industrial robots using geodesics. The workspace of a robot is split into positional and orientational parts. A Riemannian metric is given on each space such that the desired motion is a geodesic for the given metric. By regarding joint variables as local coordinates of the position space and the orientation space, Cartesian trajectories are represented by joint trajectories. A smooth and accurate motion of the robot end-effector and smooth joint trajectories corresponding to the motion can be obtained by calculating geodesics on the position space and the orientation space. To demonstrate the effectiveness of the proposed method, simulation experiments are conducted using the PUMA 560 robot.


Introduction
Industrial robots are used in many different industrial applications, like handling, machining, arc welding, and painting. In some cases, such as machining, arc welding, and painting, it is important that a robot end-effector moves accurately and in a smooth continuous manner along a specified trajectory. For example, in a machining process a robot end-effector may be required to move a tool for cutting a three-dimensional surface smoothly.
Olabi et al. presented a method of trajectory planning adapted for continuous machining by robots [1]. In this method, a smooth motion law was generated by means of a parametric speed interpolator. Ning et al. proposed a method for trajectory generation based on dynamic movement primitives [2]. They generated smooth trajectories which satisfied position and velocity boundary conditions at start and end points with high precision. Boryga and Graboś presented a planning mode of manipulator motion trajectory with higher-degree polynomials [3]. Gasparetto and Zanotto developed a method for smooth trajectory planning of robot manipulators [4]. They worked out an objective function containing a term proportional to the integral of the squared jerk (to ensure that the trajectory is smooth) and the second term, proportional to the total execution time. Liu et al. presented a smooth trajectory planning method which was designed as a combination of the planning with multidegree splines in the Cartesian space and multidegree B-splines in the joint space [5]. Yang and Sukkarieh proposed an analytical continuous-curvature path-smoothing algorithm which was based upon parametric cubicB ezier curves [6].
However, the trajectory planning methods are often using interpolating functions, and the interpolating is performed either in the joint space or the Cartesian space. In joint space schemes, in order to obtain accurate trajectories, planning can be done by interpolating a sequence of via points, but the motion actually performed by the robot endeffector between these via points is not easily foreseeable. On the other hand, because of the nonlinearity of the inverse kinematics, a smooth trajectory in the Cartesian space may cause a nonsmooth joint motion when the interpolated data in the Cartesian space are mapped into the joint space and consequently a nonsmooth and inaccurate motion in the Cartesian space.
Since the end of the 20th century, geodesics have been introduced into robotics for path planning. Geodesic, which is the necessary condition of the shortest length between two points on a Riemannian manifold, is intrinsic and has no relation with coordinates [7]. The joints of a robot are regarded as linearly dependent in the geodesic method [8].
Rodnay and Rimon visualized the dynamic properties of a 2 DOFs (degrees of freedom) robot in the threedimensional Euclidean space [9]. They introduced geodesics on the dynamic surface to represent trajectories when the robot system made free motions. Using the notions of the Riemannian metric and the covariant derivative,Žefran et al. focused on the generation of smooth three-dimensional rigid body motions which were Cartesian space schemes in their paper [7]. Tchoń and Duleba addressed on inverting singular kinematics [10]. An advantage of their method was that the workspace locations generated by the method lay on a straight line. However, the method was based upon the socalled generalized Newton algorithm and the straight line was planned point by point using the inverse kinematics. Selig and Ovseevitch sought to combine the control and the trajectory planning and manipulate robots along helical trajectories [11]. They applied the Lie algebra and the Lie group which often made the planning abstruse, abstract, and not easy to put into practice. Zhang et al. regarded the arc length and the kinetic energy as Riemannian metrics to achieve the shortest path and the invariant kinetic energy trajectories, respectively [8,12]. But when they used the arc length as the Riemannian metric, they actually could not plan trajectories of robots with more than 3 DOFs and the orientation problem had not been tackled.
In order to overcome the above-mentioned problems, this paper proposes a smooth and accurate trajectory planning using geodesics. The workspace of a robot is split into positional and orientational parts. Riemannian metrics are then given on the two spaces such that the desired motions are geodesics for the given metrics. It allows them to generate trajectories that include the position and the orientation. By regarding joint variables as local coordinates of the position space and the orientation space and calculating geodesics on them, Cartesian trajectories are represented by joint trajectories. Because of the geometric characteristics of geodesics, Cartesian trajectories and corresponding joint trajectories are both smooth and accurate.
As mentioned above, the distance length and kinematic energy were regarded as Riemannian metrics, respectively, in previous studies. The proposed method splits the workspace into positional and orientational parts and uses two Riemannian metrics: the distance metric and the orientation metric. The shortest paths of a robot with more than 3 DOFs and orientation trajectories can be obtained using geodesics, while these are not considered adequately in the previous works. Traditional methods often require a constant solution to the inverse kinematics. The interpolating is performed either in the joint space or the Cartesian space, and the joint scheme and the Cartesian scheme are often separate. The constant solution to the inverse kinematics and the separation of joint schemes and Cartesian schemes may cause the planned trajectories nonsmooth or inaccurate. The immediate output of the geodesic method which selects joint variables as local coordinates is joint trajectories, and the Cartesian trajectory obtained by the forward kinematics is exactly the planning geodesic path. The geodesic method requires only the inverse kinematic solutions of endpoints.

Background of Geodesic
To begin with, we provide a brief background on geodesics.

Manifold and Local Coordinate. A manifold
is a Hausdorff topological space for which each point has a neighborhood ⊂ homeomorphic to an open subset of the Euclidean space [13]. If : is the homeomorphism and denotes ( ) ≐ ( ( )) , we say that ( ; ) is a local coordinate system of and ( = , . . . , ) are local coordinates.

Riemannian
Manifold. Let ( , ) be a Riemannian manifold; that is, is an -dimensional differentiable manifold and is a Riemannian metric. A Riemannian metric is a symmetric, positive definite quadratic form. Let { } =1 be local coordinates in a neighborhood of a point of . The metric may be written in local coordinates as where ≐ ( / , / ) and , refer to the differential and the partial differential, respectively [14,15].
We say that is a geodesic if and only if it satisfies the geodesic equations The Christoffel symbols Γ are given in terms of the Riemannian metric by where is the element of the inverse Riemannian metric coefficient matrix [16].

Smooth and Accurate Trajectory Planning Using Geodesics
Once the link frames have been attached and the corresponding link parameters have been found, the kinematical equations are straightforwardly determined. Assume that the matrix of a robot end-effector is

Local Coordinates and the Selection Mode.
To combine joint space schemes and Cartesian space schemes, a relationship between the joint space and the Cartesian space should be established. A nature idea is to select the set of all joint variables as a coordinate system of the Cartesian space. The forward kinematics gives a description from the joint space to the Cartesian space. Specifically, given a set of joint angles, the position and the orientation of the tool frame relative to the base frame are definite. Conversely, given a coordinate which represents the position and the orientation of the tool frame relative to the base frame, the joint coordinates may be indefinite, because the inverse solution is not always unique or even existent. There is often no one-to-one mapping between the Cartesian space and the joint space. For this reason, the set of all joint variables cannot be regarded as a coordinate system of the Cartesian space.
Although joint variables cannot be regarded as coordinates of the Cartesian space, they can be selected as local coordinates. The workspace of a robot is split into its positional and orientational parts. Some joint variables are selected as local coordinates of the position space, and others are regarded as local coordinates of the orientation space.

Trajectory Planning for Linear Motions Using Geodesics.
A line is the only geodesic in the Euclidean space with the distance metric. The position space can be viewed as a Euclidean space and the distance metric of the position space is where is the derivative of the position vector = ( , , ). A manipulator trajectory planning approach in [8] was proposed by using this metric. But the position is only related to no more than three variables. For a robot whose DOFs are more than three, the trajectory planning approach using the metric only makes part of joints move while movements of others are unknown or still.
Normally, the orientation of the tool frame along a path is defined by the task and cannot be freely selected. On the orientation space, define the Riemannian metric as follows: where , , and are the derivatives of the orientation vectors = ( , , ), = ( , , ), and = ( , , ), respectively.
Both the dimensions of the position space and the orientation space are no more than three. Trajectories of a robot with no more than six DOFs can be planned. If a robot has more than six DOFs, an extra metric which focuses on task constraints or dynamic optimizations should be constructed to get redundant joint trajectories. The flow graph of the trajectory planning using geodesics is shown in Figure 1.

The Evaluation Criterion of the Riemannian Metric Selection.
The key point of the geodesic method is finding a suitable metric given the desired trajectory. First of all, a metric should be a symmetric, positive definite quadratic form. Secondly, a metric should be a measure of distance, energy, or other aspects that depend on the desired motions. Geodesic is the necessary condition of the shortest length which is measured by the metric. For example, is a distance metric which measures the distance and a geodesic corresponding to is the shortest path. Finally, the relationship between the amount of a robot DOFs and the dimension of the Riemannian manifold corresponding to the selected metric should be focused on. Often, little attention is devoted to the Riemannian manifold. When the amount of robot DOFs is more than the dimension of the Riemannian manifold, something goes wrong. To avoid a constant solution to the inverse kinematics, a geodesic is desired to be represented by joint trajectories, which can be implemented by choosing the joint variables as local coordinates. The amount of the DOFs should be no more than the dimension of the Riemannian manifold. If not, two or more Riemannian manifolds and their metrics should be constructed, which provides the possibility of multiobjective optimization.

Computational Considerations.
Generally, when a Riemannian metric is given, put it in the form of the coefficient matrix

Advances in Mechanical Engineering
With the Riemannian metrics and , two sets of geodesic equations with the form as (3) are obtained. These equations and boundary conditions constitute simultaneous differential equations. The solutions of the simultaneous differential equations give the joint trajectories which represent the desired linear motion of the robot end-effector.
In many practical systems, the calculating time is a consideration. The computational efficiency is mainly related to the solution to geodesic equations which are secondorder nonlinear ordinary differential equations. The secondorder differential equations can be converted to a firstorder system. The differential equations are approximated by finite difference equations which are algebraic equations. Unlike initial value problems, a boundary value problem probably does not have a unique solution. Because of this, an initial guess for the desired solution should be provided [18].
For example, the function bvp4c in MATLAB solves two-point boundary value problems for ordinary differential equations [19]. bvp4c produces a solution that is continuous and has a continuous first derivative [20]. The solution is fourth-order accurate uniformly. Six-order accuracy can be got by a sixth-order solver bvp6c which not only supplies greater accuracy, but also performs more efficiently [21]. One also can write a C++ program to get the solution of the geodesic equations with high calculation speed and high accuracy.

Trajectory Planning for the PUMA 560 Robot Using
Geodesics. To illustrate the whole trajectory planning procedure using geodesics, the PUMA 560 robot is taken for example. The PUMA 560 robot and its link parameters are shown in Figure 2 and Table 1 The position = ( , , ) depends on 1 , 2 , and 3 which are selected as local coordinates of the position space. To control the position, we need to control the three joint variables. For a linear motion of the end-effector, we just need to construct a Riemannian metric and calculate the geodesics on the position space. The Riemannian metric is given by where is the derivative of the position vector , = ( ) 3×3 is the coefficient matrix corresponding to , and 11 = ( 1 3 − 1 ( 2 2 + 23 3 − 23 4 )) 2 + ( 1 2 + 1 ( 2 2 + 23 3 − 23 4 )) 2 , 12 = 21 = 2 ( 2 2 + 23 3 + 23 4 ) , 13 = 31 = 2 ( 23 3 + 23 4 ) , The corresponding geodesic is determined by (3) and (4). Equation (3) corresponding to the Riemannian metric is a 2-order differential equation group with 3 unknowns ( 1 , 2 , and 3 ). The geodesic is identified by given initial conditions or boundary conditions. Advances in Mechanical Engineering is the coefficient matrix corresponding to ℎ. Equation (3) corresponding to the Riemannian metric ℎ is a 2-order differential equation group. With the Riemannian metrics and ℎ, the trajectories can be obtained by solving the geodesic equations under boundary conditions. For example, when the robot moves linearly from the initial point to the end point , the coordinates of and are shown in Tables 2 and 3. The robot performs a linear motion from the initial point to the end point according to this planning. The trajectory of the end-effector determined by the geodesic method is shown in Figure 3(a). The velocity, acceleration, and jerk of the end-effector are shown in Figure 3(b). The orientation of the robot endeffector is shown in Figure 4. The joint trajectories are shown in Figure 5. As it can be seen, not only the position trajectories but also the orientation trajectories of the end-effector are smooth. The joint trajectories and their derivatives (velocity, acceleration, and jerk, resp.) are also smooth.  3.6. Results of the Simulations. The method described in this paper has been tested in simulations for the PUMA 560 robot. The results of the simulations declare that the motion of the robot end-effector is accurate and the trajectories and their derivatives are smooth as shown in Figure 3. The orientation of the end-effector is smooth as shown in Figure 4. The trajectories of the joints and their derivatives are smooth as shown in Figure 5. That is, the method can be used to plan smooth and accurate motions of end-effectors and corresponding smooth joint trajectories for industrial robots.

Conclusion and Future Work
A smooth and accurate trajectory planning for industrial robots using geodesics is presented in this paper. The main idea is to select a suitable metric for which a geodesic is the desired motion. The workspace of a robot is split into positional and orientational parts. A Riemannian metric is given on each space such that the desired motion is a geodesic. The geodesic equations are solved numerically and the results are used to control the robot. Simulations of this method using the PUMA 560 robot are given.
The method applies to robots with no more than 6 DOFs and focuses on linear motions. Future work will be directed towards constructing appropriate metrics to plan trajectories of robots with more than six or redundant DOFs and achieve geodesic planning of circular and other curve motions.