Home | About | Journals | Submit | Contact Us | Français |

**|**Sensors (Basel)**|**v.17(2); 2017 February**|**PMC5336121

Formats

Article sections

- Abstract
- 1. Introduction
- 2. System Overview
- 3. Binocular Stereo Vision Sensor System
- 4. Trajectory Planning For Binocular Stereo Sensors
- 5. Experiments and Analysis
- 6. Conclusions
- References

Authors

Related links

Sensors (Basel). 2017 February; 17(2): 393.

Published online 2017 February 17. doi: 10.3390/s17020393

PMCID: PMC5336121

Mianxiong Dong, Academic Editor, Zhi Liu, Academic Editor, Anfeng Liu, Academic Editor, and Didier El Baz, Academic Editor

Received 2016 December 12; Accepted 2017 February 9.

Copyright © 2017 by the authors.

Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

Although many researchers have begun to study the area of Cyber Physical Social Sensing (CPSS), few are focused on robotic sensors. We successfully utilize robots in CPSS, and propose a sensor trajectory planning method in this paper. Trajectory planning is a fundamental problem in mobile robotics. However, traditional methods are not suited for robotic sensors, because of their low efficiency, instability, and non-smooth-generated paths. This paper adopts an optimizing function to generate several intermediate points and regress these discrete points to a quintic polynomial which can output a smooth trajectory for the robotic sensor. Simulations demonstrate that our approach is robust and efficient, and can be well applied in the CPSS field.

With the huge developments in sensing and network technologies, Cyber Physical Social Sensing (CPSS) has attracted the attention of many researchers [1,2,3,4]. Although much research has been proposed to advance the field of CPSS, little research has focused on social robotic sensing. We successfully utilize robots in the CPSS area, and propose an effective robotic sensing method in the paper. As shown in Figure 1, we use some robots equipped with specially-designed eye-in-hand sensors to explore the world, and share the information among all robots using a wireless network and cloud platform. To move sensors accurately and smoothly, robots need to calculate their trajectory. Traditional methods, however, cannot be applied directly to robotic sensing in CPSS, mainly because the existing trajectory planning methods are not designed for sensing tasks. Historically, most trajectory planning methods are not suitable for eye-in-hand sensors because of their low efficiency due to the extra calculation of inverse kinematics, instability coming from inadequacy of the traditional methods with sensor performance optimization, and non-smooth-generated paths. To solve these problems, we propose a novel trajectory planning method to improve the sensing performance in CPSS.

Trajectory planning is a fundamental problem in robotics. Because of its limitations, both the velocity and acceleration of robotic drivers cannot achieve the ideal level. Robots are multi-variable and have highly nonlinear complex systems. It is extremely difficult to obtain a smooth trajectory to simultaneously meet the requirements of velocity, acceleration, and jerk. Some trajectory planning methods (e.g., C-space [5] and preprocessing algorithms) can find a smooth trajectory that satisfies the kinematic limits [6,7]. Most of these traditional methods, however, are focused merely on time and jerk optimization [8,9,10], and visual information is not used. In the past decade, significant progress has been made in machine vision technology [11], and it has been applied to trajectory planning methods to improve planning performance. Li et al. [12] adopted vision-guided robot control to build a visual feedback system for real-time measurement of the end-effector and the joint position. Among all machine vision methods, classic binocular stereo-vision—which captures the same image from two angles using two cameras—is used most widely for its simple configuration and high reliability, and this method is adopted as the visual system in this paper. Using the stereo-matched algorithm [11], the disparity between two images can be calculated. Following this calculation, the three-dimensional (3D) position and orientation of the objects can be obtained using the camera calibration technique, which illustrates the mapping relationship between the pixels in the digital image and the 3D position in the world coordinate system.

Trajectory planning methods use a series of transformation matrices [13,14,15] to obtain the position of each joint in one robot. When the reverse kinematics method is used to calculate the joint angle for a given manipulator position, the solution trajectory of relevant joints is usually not distinct. Therefore, the optimization objective must be determined to arrive at the optimal trajectory [16,17]. Another problem results form the joint positioning errors caused by weight distribution, load change, vibration, mechanical friction, and recoil, making it difficult to obtain an accurate robotic dynamics model in real-world applications. Instead of providing the complete trajectory (which would have some deviation in the actual robotic motion), our approach is to provide the next position that can be reached at the next time unit. We believe that it is not necessary to get an accurate rotation angle for each joint, and instead focus on how the end-effector of the robot reaches the object continually and smoothly to achieve better sensing performance. In practical applications, the working precision of the robot is confined by such factors as manipulator limitations and working environments, which cause various errors in the sensor’s motion. We use binocular stereo-vision to rectify these motion errors. Both velocity and acceleration of the joint must be continuous, and therefore, the proposed method introduces jerk restriction to avoid vibration and reduce mechanical wear. To make a smooth motion path of the equipped sensor, we adopt an optimizing function to generate several intermediate points and regress these discrete points to a quintic polynomial, which ultimately outputs a smooth trajectory for the sensor.

Generally, the robotic motion trajectory is described in Cartesian space or joint space. The trajectory represented in the joint angle space, however, offers several advantages [18]. First, the trajectory directly generated by the angle rotation avoids a lot of forward and inverse kinematics calculation—in particular for real-time applications. Second, the trajectory represented in Cartesian space will eventually be converted into the joint coordinates. If the trajectory is generated directly in the joint space, it is clear that the computation time can be reduced. To improve position accuracy, a visual sensor is used to compensate for errors and correct the trajectory.

Due to the accumulated error, the manipulator cannot reach the target to be processed when the manipulator is running on a predetermined trajectory. In order to improve the accuracy, we use the binocular stereo visual sensor to compensate and correct the trajectory. Therefore, the schematic of the trajectory planning method proposed in this paper is divided into a visual module and trajectory planning module, and Figure 2 shows the schematic of the trajectory planning method with the binocular stereo visual sensor. In our method, the planning trajectory is first generated according to the initial states and the end states of the manipulator. When the manipulator is running, the trajectory of the manipulator is corrected by acquiring the joint angles of the current joints and the positions of the distal end of the manipulator, which can improve the grasping accuracy of the manipulator. In order to compensate for the trajectory, we need to measure some parameters, in which the joint angles are obtained by the angle sensors, and the end position of the manipulator needs to use the binocular stereo visual sensor and the stereo vision algorithm. The stereoscopic vision algorithm can give the mapping from the pixel coordinates to the spatial coordinates. This provides us a great convenience to calculate the trajectory compensation values. Therefore, it can be seen that the binocular stereo visual sensor plays an great important role in improving the grasping progress of the target to be processed. After obtaining the trajectory of the angular space, the trajectory in the Cartesian space can be obtained by the forward kinematics of the manipulator.

After getting the trajectory represented in joint angle space, we can transform it into Cartesian space by robotic forward kinematics.

The proposed vision method is shown in Figure 3, which illustrates how the binocular vision sensor is used to improve the manipulator’s operation accuracy. Many other machine vision methods have been applied in trajectory planning. Classical binocular stereovision, however, is still widely used for its simplicity and effectiveness. This method uses two vision sensors to obtain different images of the same object from different angles. Then, the Cartesian coordinate of the target can be obtained by finding the difference between the two visual images.

Currently, RGB-Depth sensors and optical fiber sensors [19] are used widely to measure the Cartesian coordinate of the object. If, however, some obstacles appear between the sensor and the object, these sensors may fail to get the location and the orientation of the object. Further, additional computational costs are required to obtain the absolute object coordinates for trajectory planning. Because relative position is more important than absolute position to control the mobile robot and the equipped sensor, traditional binocular stereo-vision is adopted in the proposed method.

The proposed system was tested in a simulation environment called Robot Operating System (ROS). ROS is a software framework for robotic research and development, and has been a mainstream robotic simulation platform. This system integrates hardware abstraction, device drivers, libraries, visualizers, message-passing, package management, and many other convenient functions. The UR5 robot is a robot with six degrees of freedom (6-DOF). In our experiments, it is equipped with a mobile chassis and a binocular stereo vision sensor to conduct the performance evaluations.

To generate the transform vector that directly maps the end-effector to the target, the mapping relationship between the space positions and the pixel locations in the camera plane is required. Considering the influence of lens distortion, the transformation matrix from the camera coordinate to the world coordinate [14] can be expressed by a homogeneous transformation matrix, per Equation (1):

$${Z}_{c}{\left[u\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}v\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\right]}^{T}={M}^{*}{P}_{W}$$

(1)

where $\left(u,v\right)$ is a pixel of a point in the camera image plane, its homogeneous coordinates are ${\left(u,v,1\right)}^{T}$; ${P}_{W}$ is the world coordinate of a point, its homogeneous coordinates are described as ${\left[{X}_{w}\phantom{\rule{1.0pt}{0ex}}{Y}_{w}\phantom{\rule{1.0pt}{0ex}}{Z}_{w}\phantom{\rule{1.0pt}{0ex}}1\right]}^{T}$. The transformation matrix ${M}^{*}$ can be described as follows:

$${M}^{*}\phantom{\rule{4.pt}{0ex}}=\phantom{\rule{4.pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\left[\begin{array}{c}f/dx\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{u}_{0}\hfill \\ \phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}f/dy\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{v}_{0}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\hfill \\ \phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\hfill \end{array}\right]\left[\begin{array}{c}f\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\hfill \\ 0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}f\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\hfill \\ 0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\hfill \end{array}\right]\left[\begin{array}{c}{R}_{3\times 3}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{t}_{3\times 1}\hfill \\ \phantom{\rule{1.0pt}{0ex}}{0}_{1\times 3}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{4.0pt}{0ex}}1\hfill \end{array}\right]$$

(2)

The matrix ${M}^{*}$ can be obtained easily by Zhang’s calibrating method [20]. In Equation (2), $\left({u}_{0},{v}_{0}\right)$ is the origin coordinate of the physical coordinates in camera image plane. $dx$ and $dy$ are the length and the width of a pixel, respectively. ${\mathit{R}}_{3\times 3}$ and ${t}_{3\times 1}$ are respectively the rotation matrix and the translation vector of the camera coordinate frame to the world coordinate system. In order to get the world coordinate of the point, the homogeneous coordinates of the point $\left[{X}_{c}\phantom{\rule{1.0pt}{0ex}}{Y}_{c}\phantom{\rule{1.0pt}{0ex}}{Z}_{c}\phantom{\rule{1.0pt}{0ex}}1\right]$ in camera coordinate system is needed. The coordinates $\left[{X}_{c}\phantom{\rule{1.0pt}{0ex}}{Y}_{c}\phantom{\rule{1.0pt}{0ex}}{Z}_{c}\phantom{\rule{1.0pt}{0ex}}1\right]$ is obtained by binocular stereo vision, which provides additional information about the objects and environments through the left and right cameras. If we obtain the perspective difference between the left and right camera images, we then can calculate the coordinates of the target point. The parallax principle of the binocular stereovision is shown in Figure 4; ${}^{l}p$ and ${}^{r}p$ are the points at which the target point ${}^{c}p$ is projected on the left and right camera planes, respectively. If *b* is the distance between the optical centers of the left and right cameras, the coordinates of ${}^{c}p$ in the left and right camera planes are $\left({x}_{left}=f\phantom{\rule{1.0pt}{0ex}}{X}_{c}/{Z}_{c},{y}_{left}=f\phantom{\rule{1.0pt}{0ex}}{Y}_{c}/{Z}_{c}\right)$ and $({x}_{right}=f({X}_{c}$$-b)/{Z}_{c},{y}_{right}=f\phantom{\rule{1.0pt}{0ex}}{Y}_{c}/{Z}_{c})$.

The visual disparity between the left and right image planes then can be obtained by $disp\phantom{\rule{3.33333pt}{0ex}}=\phantom{\rule{3.33333pt}{0ex}}{x}_{left}-{x}_{right}$. Finally, the coordinates of point ${}^{c}p$ in the camera coordinate system can be calculated [9] by Equation (3):

$${X}_{c}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}=\frac{b\xb7{x}_{left}}{disp},\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{Y}_{c}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}=\frac{b\xb7{y}_{left}}{disp}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}},\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{Z}_{c}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}=\frac{b\xb7f\phantom{\rule{1.0pt}{0ex}}}{disp}$$

(3)

Equation (3) shows the mathematical model of the transformation from the pixel to the Cartesian coordinate.

Generally, a trajectory is obtained by some calculations pertaining to the initial states and the final states (e.g., position, velocity, and acceleration) of the joints in the Cartesian coordinates. The points on the trajectory must then be mapped to a set of joint angles by inverse kinematics calculation. In fact, the robotic motion is actually the rotary movement of each of joints. Therefore, the trajectory represented in the joint coordinate system can describe the robotic motion more directly.

A smooth interpolation function is required to obtain a satisfactory joint trajectory connecting the initial joint angles and the final joint angles. Considering the constraints, a five-order interpolation function [9] is used to calculate the robotic trajectory. In this calculation, $\theta \left(t\right)$ is defined as a joint trajectory function that describes the relationship between the joint angle and time; ${t}_{b}$, ${\theta}_{b}$, ${\dot{\theta}}_{b}$, and ${\ddot{\theta}}_{b}$ represent the initial state of time, joint angle, angular velocity, and angular acceleration, respectively; and ${t}_{f}$, ${\theta}_{f}$, ${\dot{\theta}}_{f}$, and ${\ddot{\theta}}_{f}$ represent the final state of time, joint angle, angular velocity, and angular acceleration, respectively. The five-order interpolation function can be described as follows:

$$s\left(t\right)={\ell}_{0}+{\ell}_{1}t+{\ell}_{2}{t}^{2}+{\ell}_{3}{t}^{3}+{\ell}_{4}{t}^{4}+{\ell}_{5}{t}^{5}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}$$

(4)

Let ${T}_{f}={t}_{f}-{t}_{b}$. ${T}_{p}$—which is determined by the controller of the manipulator—is the trajectory sampling period, then the sampling number $num$ is $\frac{{T}_{f}}{{T}_{p}}$. Define *τ* as the sequence number of sample points, $\tau =\left(t-{t}_{b}\right)/{T}_{p}$, $\tau \in [0,num]$, then the trajectory can be represented by discrete sampling points as follows:

$$\theta \left(\tau \right)={\theta}_{b}+\left({\theta}_{f}-{\theta}_{b}\right)s\left(\tau \right)$$

(5)

The first derivative and the second derivative of Equation (5) can be expressed as

$$\dot{\theta}\left(\tau \right)=\left({\theta}_{f}-{\theta}_{b}\right)\frac{\dot{s}\left(\tau \right)}{{T}_{p}}\phantom{\rule{1.0pt}{0ex}}$$

(6)

$$\ddot{\theta}\left(\tau \right)=\left({\theta}_{f}-{\theta}_{b}\right)\frac{\ddot{s}\left(\tau \right)}{{{T}_{p}}^{2}}$$

(7)

In Equations (5)–(7), the initial and final states are known; let $\theta \left({t}_{b}\right)={\theta}_{b}$, $\dot{\theta}\left({t}_{b}\right)={\dot{\theta}}_{b}$, $\ddot{\theta}\left({t}_{b}\right)={\ddot{\theta}}_{b}$, $\theta \left({t}_{f}\right)={\theta}_{f}$, $\dot{\theta}\left({t}_{f}\right)={\dot{\theta}}_{f}$, $\ddot{\theta}\left({t}_{f}\right)={\ddot{\theta}}_{f}$, then putting the initial conditions and termination conditions into Equations (5)–(7), we can obtain

$$\left\{\begin{array}{c}s\left(0\right)=0\hfill \\ \dot{s}\left(0\right)={\dot{\theta}}_{b}{T}_{p}/\left({\theta}_{f}-{\theta}_{b}\right)\hfill \\ \ddot{s}\left(0\right)={\ddot{\theta}}_{b}{{T}_{p}}^{2}/\left({\theta}_{f}-{\theta}_{b}\right)\hfill \end{array}\right.\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\left\{\begin{array}{c}s\left(num\right)=1\hfill \\ \dot{s}\left(num\right)={\dot{\theta}}_{f}{T}_{p}/\left({\theta}_{f}-{\theta}_{b}\right)\hfill \\ \ddot{s}\left(num\right)={\ddot{\theta}}_{f}{{T}_{p}}^{2}/\left({\theta}_{f}-{\theta}_{b}\right)\hfill \end{array}\right.$$

(8)

Present Equation (8) as matrix by Equation (4) and initial conditions, we can get the following:

$$\underset{s}{\underbrace{\left(\begin{array}{c}s\left(0\right)\hfill \\ \dot{s}\left(0\right)\hfill \\ \ddot{s}\left(0\right)\hfill \\ s\left(num\right)\hfill \\ \dot{s}\left(num\right)\hfill \\ \ddot{s}\left(num\right)\hfill \end{array}\right)}}=\underset{M}{\underbrace{\left[\begin{array}{c}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\hfill \\ 0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\hfill \\ 0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}2\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\hfill \\ 1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{T}_{f}}{{T}_{p}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{2}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{3}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{4}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{5}\hfill \\ 0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{3.0pt}{0ex}}2\frac{{T}_{f}}{{T}_{p}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}3\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{2}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{3.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}4\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{3}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{4.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}5{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{4}\hfill \\ 0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}2\phantom{\rule{3.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}6\frac{{T}_{f}}{{T}_{p}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}12\phantom{\rule{1.0pt}{0ex}}{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{2}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{3.0pt}{0ex}}20{\left(\frac{{T}_{f}}{{T}_{p}}\right)}^{3}\phantom{\rule{1.0pt}{0ex}}\hfill \end{array}\right]}}\underset{\ell}{\underbrace{\left(\begin{array}{c}{\ell}_{0}\hfill \\ {\ell}_{1}\hfill \\ {\ell}_{2}\hfill \\ {\ell}_{3}\hfill \\ {\ell}_{4}\hfill \\ {\ell}_{5}\hfill \end{array}\right)}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}$$

(9)

So, vector can be expressed as follows:

$$\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\ell ={M}^{-1}{\left(0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\dot{\theta}}_{b}{T}_{p}}{{\theta}_{f}-{\theta}_{b}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\ddot{\theta}}_{b}{{T}_{p}}^{2}}{{\theta}_{f}-{\theta}_{b}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\dot{\theta}}_{f}{T}_{p}}{{\theta}_{f}-{\theta}_{b}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\ddot{\theta}}_{f}{{T}_{p}}^{2}}{{\theta}_{f}-{\theta}_{b}}\right)}^{T}$$

(10)

Then, the trajectory in joint coordinate can be obtained by Equations (5) and (10).

$$\theta \left(\tau \right)={\theta}_{b}+\left({\theta}_{f}-{\theta}_{b}\right){M}^{-1}{\left(0\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\dot{\theta}}_{b}{T}_{p}}{{\theta}_{f}-{\theta}_{b}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\ddot{\theta}}_{b}{{T}_{p}}^{2}}{{\theta}_{f}-{\theta}_{b}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\dot{\theta}}_{f}{T}_{p}}{{\theta}_{f}-{\theta}_{b}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\frac{{\ddot{\theta}}_{f}{{T}_{p}}^{2}}{{\theta}_{f}-{\theta}_{b}}\right)}^{T}\left[1\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\tau \phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\tau}^{2}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\tau}^{3}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\tau}^{4}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\tau}^{5}\phantom{\rule{1.0pt}{0ex}}\right]$$

(11)

The relationship between the trajectories represented in the Cartesian space and the joint space can be expressed as follows:

$$X\left(t\right)=f\left(\theta \left(t\right)\right)$$

(12)

where $X\left(t\right)\phantom{\rule{1.0pt}{0ex}}$ and $\theta \left(t\right)$ are the trajectories in the Cartesian space and the joint space, respectively. The velocity is a constraint factor that needs to be considered, and the mapping relationship can be obtained by a derivative of Equation (12) as follows:

$$\dot{X}\left(t\right)=\frac{\partial f\left(\theta \left(t\right)\right)}{\partial t}=J\left(\theta \left(t\right)\right)\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\dot{\theta}\left(t\right)$$

(13)

The joint positions relative to the base of the manipulator, as well as the positional relationship between the end-effector and the target object are required to measure the target position. In the proposed method, the joint coordinates in the Cartesian space are used in each iteration, and the coordinates in the angular space are used to calculate the joint position in each iteration. The Cartesian coordinates of the joints are obtained by using the following forward kinematics equation. The 6-DOF robot is represented and modeled by the D-H method [14,15], the transformation matrix of link $j+1$ to link *j* is ${}_{j+1}^{j}A$, and the forward kinematics equations of the 6-DOF robot can be expressed as

$$T={}_{K}^{0}A={}_{1}^{0}A\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{}_{2}^{1}A\cdots \phantom{\rule{1.0pt}{0ex}}{}_{j+1}^{j}A\cdots $$

(14)

During the operation of the robot, the relative position of joint *j* can be obtained by using ${}_{j}^{0}A$. In the proposed method, ** b_{k}**,

Generally, traditional trajectory planning methods merely concentrate on the calculation of the end effector position using the joint angles. These methods calculate the position from joint angle readings through the direct kinematics model to estimate the actual position. However in most instances, these positions are not actually reached due to the mechanical error. A novel trajectory planning method is proposed in the paper to analyze current joint states. A schematic of the proposed method is shown in Figure 5. Suppose *k* is the joint ordinal; ** b${}_{k}$** (

$${c}_{k}={b}_{k}+{c}_{k+1}$$

(15)

where the penultimate joint ${{c}_{n}}_{-1}={{b}_{n}}_{-1}$.

The D-H parameters and joint angles are required to obtain the vectors shown in Figure 5. The joint angles can be obtained by the joint angle sensors. The Cartesian coordinates of the end-effector and target can be measured using the visual sensors. In Section 4.1, ${T}_{p}$ is defined as the sampling period, $num$ is the sampling times, and ${t}_{b}$ and ${t}_{f}$ represent the start and final time, respectively. So, the trajectory planning problem can be described as follows:

$${\theta}_{b}^{\left(k\right)}={\theta}^{\left(k\right)}\left(0\right);\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\omega}_{b}^{\left(k\right)}={\dot{\theta}}^{\left(k\right)}\left(0\right);\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\alpha}_{b}^{\left(k\right)}={\ddot{\theta}}^{\left(k\right)}\left(0\right)$$

(16)

$$\begin{array}{c}{\theta}_{f}^{\left(k\right)}={\theta}^{\left(k\right)}(num\xb7{T}_{p});\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\omega}_{f}^{\left(k\right)}={\dot{\theta}}^{\left(k\right)}(num\xb7{T}_{p});\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\hfill \\ \phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\alpha}_{f}^{\left(k\right)}={\ddot{\theta}}^{\left(k\right)}(num\xb7{T}_{p})\hfill \end{array}$$

(17)

$${\omega}^{\left(k\right)}\left(j{T}_{p}\right)\le {\omega}_{max}^{\left(k\right)}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}and\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}{\alpha}^{\left(k\right)}\left(j{T}_{p}\right)\le {\alpha}_{max}^{\left(k\right)},\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}j\in \left[0,num\right]$$

(18)

$$\left|\frac{{\alpha}^{\left(k\right)}\left(m{T}_{p}\right)-{\alpha}^{\left(k\right)}\left(n{T}_{p}\right)}{\left(m-n\right){T}_{p}}\right|\le {j}_{max},\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}0\le m,n\le num$$

(19)

If the second-order reciprocal of ${\theta}^{\left(k\right)}$ is continuous and satisfies Equations (16)–(19), then ${\theta}^{\left(k\right)}$ can be used as a trajectory solution that minimizes acceleration, shock acceleration, or run time. In the proposed method, a robot with *K* joints has ${2}^{K}$ motion patterns. The solved trajectory does not need to satisfy all of the previously mentioned optimization goals. In practice, the number of joints of the robot is usually small. For example, *K* is six in our simulation. Moreover, ** c${}_{k}$** is a major factor to control the rotation of the joint. Given a state of the manipulator, some

$$cos{\vartheta}^{\left(k\right)}=\frac{pv\xb7{c}_{k}}{\u2225pv\u2225\xb7\u2225{c}_{k}\u2225}$$

(20)

Next, the angle increment of each joint $\Delta {\theta}^{\left(k\right)}$ needs to be determined. The effect of the joint rotation on the * pv* can be expressed by $\sum \left({c}_{k}\xb7sin{\vartheta}^{\left(k\right)}\right)$ and $\sum \left({c}_{k}\xb7cos{\vartheta}^{\left(k\right)}\right)$, where $\sum \left({c}_{k}\xb7sin{\vartheta}^{\left(k\right)}\right)$ represents the angle increment in the parallel orientation of

$$t{r}^{\left(k\right)}={\left[\sum \left(\u2225{c}_{k}\u2225\xb7\Delta {\theta}^{\left(k\right)}\xb7sin{\vartheta}^{\left(k\right)}\right),\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\sum \left(\u2225{c}_{k}\u2225\xb7\Delta {\theta}^{\left(k\right)}\xb7cos{\vartheta}^{\left(k\right)}\right)\right]}^{T}$$

(21)

In Equation (21), * pv*,

$$\Delta {\theta}^{\left(k\right)}=arg\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}max\left(t{r}^{\left(k\right)}\xb7pv\right)$$

(22)

Considering the influence of the restrictive conditions of speed, acceleration, and jerk, some important variables must be defined. Because the motion trajectory of the end-effector is affected by the rotation of the joints, two important factors will be considered when correcting the trajectory: (a) the current joint angles; and (b) the approach vector * pv*. To address these factors, two pivotal coefficients ${\xi}^{\left(k\right)}$ and ${\delta}^{\left(k\right)}$ are introduced; ${\xi}^{\left(k\right)}$ and ${\delta}^{\left(k\right)}$ are shown as Equations (23) and (24), respectively:

$${\xi}^{\left(k\right)}=\sqrt{1-{\left({\phi}^{\left(k\right)}\right)}^{2}}$$

(23)

where ${\phi}^{\left(k\right)}=\left({{\theta}^{\left(k\right)}}_{max}-{\theta}^{\left(k\right)}\right)/\left({{\theta}^{\left(k\right)}}_{max}-{{\theta}_{min}}^{\left(k\right)}\right)$, and ${\xi}^{\left(k\right)}$ is used to control the increment of joint angles at the next iteration (e.g., as the joint angle increases, the angular velocity should be slower when the angle value approaches the threshold).

$${\delta}^{\left(k\right)}=\u2225p{v}_{i}\u2225\left(1-exp\left(-\eta \frac{\u2225pv\u2225}{\u2225p{v}_{i}\u2225}-\gamma \right)\right)$$

(24)

${\delta}^{\left(k\right)}$ denotes the influence of the approach vector * pv* on the next point of the trajectory. A smaller step should be taken when the end-effector is closer to the target at the next moment;

$$\underset{\Delta {\theta}^{\left(k\right)}}{arg}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}max{\left(\left[\sum \left(\u2225{c}_{k}\u2225\xb7\frac{\Delta {\theta}^{\left(k\right)}}{{\xi}^{\left(k\right)}\xb7{\delta}^{\left(k\right)}}\xb7sin{\vartheta}^{\left(k\right)}\right),\sum \left(\u2225{c}_{k}\u2225\xb7\frac{\Delta {\theta}^{\left(k\right)}}{{\xi}^{\left(k\right)}\xb7{\delta}^{\left(k\right)}}\xb7cos{\vartheta}^{\left(k\right)}\right)\right]\xb7pv\right)}^{2}$$

(25)

Equation (25) is a convex function. The angle increment of each joint $\Delta {\theta}^{\left(k\right)}$ is obtained by solving Equation (25), and then is described in the coordinate system. After Equation (25) is solved, the polynomial function given in Equation (4) is used to fit these points. Considering the impacts of the joint angles, the link vectors, the approach vector, and the parameters defined in Equations (23) and (24), in the proposed method, the pseudo-code describing the proposed improved trajectory algorithm (Algorithm 1) is presented as follows:

Algorithm 1: Trajectory Planning |

At each iteration, ${\theta}^{\left(k\right)}\left(jT\right)$ is changing with a controller that makes the angle follow the desired angle increment rate. In this way, an adapted angle increment that is varied with the current condition can be obtained.

The proposed trajectory planning method is tested on the UR5 robot with 6-DOF. Figure 6 shows the kinematic model, and Table 1 gives the D-H parameters of UR5.

According to the D-H parameters of the UR5 robot, the transformation ${}_{k-1}^{k}A$ from link *k* to $k-1$ can be derived. Therefore, the vectors described in Figure 5 can be obtained by

$$\left\{\begin{array}{c}{b}_{k}={b}_{k-1}\phantom{\rule{1.0pt}{0ex}}\phantom{\rule{1.0pt}{0ex}}\xb7{}_{k-1}^{k}A\hfill \\ {c}_{k}={b}_{k}+{c}_{k+1}\hfill \end{array}\right.\phantom{\rule{1.0pt}{0ex}}$$

(26)

Supposing $k=6$ and ${c}_{k}={b}_{k}$, the Cartesian coordinates of the object ${p}_{target}$ and the end-effector ${p}_{end-effector}$ in the base coordinate system can be obtained by using the left and right cameras’ calibration. The approach vector can be calculated by $pv={p}_{target}-{p}_{end-effector}$. After all unknown parameters are obtained, the real-time trajectory can be calculated by Algorithm 1. The calibration of the camera is divided into two steps. The first step is the calibration of the single camera, and the second step is the stereo calibration of the left and right cameras. The camera’s internal and external parameters can be obtained using the principles of stereo imaging and camera calibration described in Section 3. After completing the stereo calibration, the relative position between the left and right cameras will not change; otherwise, the left and right cameras will need to be calibrated again. The Cartesian coordinate of the target object in the world coordinate system is usually calculated by analyzing the visual disparity between the left and right image planes.

In order to verify the effectiveness of our approach, we compare this method with the time optimal algorithm [21]. The UR5 robotic—as shown in Figure 7—is controlled to reach the same target position from the same starting state in these two methods, respectively. Table 2 shows the initial state and the terminate states of the joint angles. In the simulation, the rotation of the sixth joint has little impact on the position of the end-effector. Therefore, its motion is ignored.

The trajectories are recorded to compare these two methods. Figure 8 shows the initial and final states of UR5 at different viewing angles. The initial and final states are indicated by yellow and gray, respectively. Figure 9 shows the variation of each joint angle during the motion. Figure 10 shows the angular velocity of each joint. All angular velocities are less then 3.14 rad/s. Figure 10a–e represent the trajectories of the first, second, third, fourth, and fifth joint, respectively. As shown in Figure 9 and Figure 10, both the angular velocity and angle variation show smooth curves with the proposed trajectory planning method.

Figure 11 shows the acceleration curve of each joint. The dotted line indicates the time-optimal method. The solid line indicates the acceleration curve of the proposed method, which is controlled and adjusted by the visual system. These solid lines are fitted with the smoothing process of fifth-order interpolation. In this experiment, sampling time is 20 ms, and the operation time of the proposed method and time-optimal method are 2.1 and 1.9 s, respectively. For better comparison, the operation time of the time-optimal method is extended from 1.9 s to 2.1 s in Figure 11. Figure 12 shows the trajectory calculated by Equation (11).

Although the time-optimal method is faster than the proposed method by 0.2 s, there is always some offset between the final position of the end-effector and the target object, which is caused by the errors of mechanical movement and the camera calibration. The proposed method, however, can adjust the robotic motion according to the relative position between the end-effector and the target object to avoid motion and calibration errors, and is therefore able to greatly reduce the position errors. Table 3 shows five records of the comparison test, demonstrating that the proposed method is much better than the time-optimal method at motion precision, which is reflected by the absolute errors.

This paper presents an effective robotic sensor planning method for CPSS which differs from traditional polynomial interpolation and inverse trajectory planning methods. This method fully considers the positions and conditions of robotic joints. The influences of the joint angles, link vectors, and approach vectors are analyzed to improve planning performance. An optimization function is adopted to generate several intermediate points, which are regressed to a quantic polynomial. Ultimately, a smooth trajectory can be generated for the robotic sensor. Experimental results demonstrate that the proposed method is feasible and effective.

This research was funded by the National Natural Science Foundation (Project No. 61171141, 61573145), the Public Research and Capacity Building of Guangdong Province (Project No. 2014B010104001) and the Basic and Applied Basic Research of Guangdong Province (Project No. 2015A030308018), the authors are greatly thanks to these grants.

Author Contributions

Hong Tang and Liangzhi Li conceived and designed the experiments; Hong Tang and Nanfeng Xiao performed the experiments; Hong Tang analyzed the data; Nanfeng Xiao contributed materials and analysis tools; Hong Tang wrote the paper.

Conflicts of Interest

The authors declare no conflict of interest. The founding sponsors had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript, and in the decision to publish the results.

1. Dong M., Ota K., Liu A. RMER: Reliable and Energy-Efficient Data Collection for Large-Scale Wireless Sensor Networks. IEEE Internet Things J. 2016;3:511–519. doi: 10.1109/JIOT.2016.2517405. [Cross Ref]

2. Liu Y., Dong M., Ota K., Liu A. ActiveTrust: Secure and Trustable Routing in Wireless Sensor Networks. IEEE Trans. Inf. For. Secur. 2016;11:2013–2027. doi: 10.1109/TIFS.2016.2570740. [Cross Ref]

3. Dong M., Ota K., Yang L.T., Liu A., Guo M. LSCD: A Low-Storage Clone Detection Protocol for Cyber-Physical Systems. IEEE Trans. Comput.-Aided Des. Integr. Circuits Syst. 2016;35:712–723. doi: 10.1109/TCAD.2016.2539327. [Cross Ref]

4. Liu X., Dong M., Ota K., Hung P., Liu A. Service Pricing Decision in Cyber-Physical Systems: Insights from Game Theory. IEEE Trans. Serv. Comput. 2016;9:186–198. doi: 10.1109/TSC.2015.2449314. [Cross Ref]

5. Korayem M., Nikoobin A. Maximum payload for flexible joint manipulators in point-to-point task using optimal control approach. Int. J. Adv. Manuf. Technol. 2008;38:1045–1060. doi: 10.1007/s00170-007-1137-2. [Cross Ref]

6. Menasri R., Oulhadj H., Daachi B., Nakib A., Siarry P. A genetic algorithm designed for robot trajectory planning; Proceedings of the 2014 IEEE International Conference on Systems, Man, and Cybernetics (SMC); San Diego, CA, USA. 5–8 October 2014; pp. 228–233.

7. Zefran M., Kumar V., Croke C.B. On the generation of smooth three-dimensional rigid body motions. IEEE Trans. Robot. Autom. 1998;14:576–589. doi: 10.1109/70.704225. [Cross Ref]

8. Kröger T., Wahl F.M. Online trajectory generation: Basic concepts for instantaneous reactions to unforeseen events. IEEE Trans. Robot. 2010;26:94–111. doi: 10.1109/TRO.2009.2035744. [Cross Ref]

9. Gasparetto A., Zanotto V. A new method for smooth trajectory planning of robot manipulators. Mech. Mach. Theory. 2007;42:455–471. doi: 10.1016/j.mechmachtheory.2006.04.002. [Cross Ref]

10. Piazzi A., Visioli A. Global minimum-jerk trajectory planning of robot manipulators. IEEE Trans. Ind. Electron. 2000;47:140–149. doi: 10.1109/41.824136. [Cross Ref]

11. Kanade T., Okutomi M. A stereo matching algorithm with an adaptive window: Theory and experiment. IEEE Trans. Pattern Anal. Mach. Intell. 1994;16:920–932. doi: 10.1109/34.310690. [Cross Ref]

12. Li Z. Ph.D. Thesis. Concordia University; Montreal, QC, Canada: 2007. Visual Servoing in Robotic Manufacturing Systems for Accurate Positioning.

13. Murray R.M., Li Z., Sastry S.S., Sastry S.S. A Mathematical Introduction to Robotic Manipulation. CRC Press; Boca Raton, FL, USA: 1994.

14. Nan-feng X. Intelligent Robot. South China University of Technology Press; Guangzhou, China: 2008. pp. 104–105.

15. Craig J.J. Introduction to Robotics: Mechanics and Control. Volume 3 Pearson Prentice Hall; Upper Saddle River, NJ, USA: 2005.

16. Marani G., Kim J., Yuh J., Chung W.K. A real-time approach for singularity avoidance in resolved motion rate control of robotic manipulators; Proceedings of the ICRA’02 IEEE International Conference on Robotics and Automation; Atlanta, GA, USA. 11–15 May 2002; pp. 1973–1978.

17. Zorjan M., Hugel V. Generalized humanoid leg inverse kinematics to deal with singularities; Proceedings of the 2013 IEEE International Conference on Robotics and Automation (ICRA); Karlsruhe, Germany. 6–10 May 2013; pp. 4791–4796.

18. Li L., Xiao N. Volumetric view planning for 3D reconstruction with multiple manipulators. Ind. Robot Int. J. 2015;42:533–543. doi: 10.1108/IR-05-2015-0110. [Cross Ref]

19. Dutta T. Evaluation of the Kinect™ sensor for 3-D kinematic measurement in the workplace. Appl. Ergon. 2012;43:645–649. doi: 10.1016/j.apergo.2011.09.011. [PubMed] [Cross Ref]

20. Zhang Z. Flexible camera calibration by viewing a plane from unknown orientations; Proceedings of the Seventh IEEE International Conference on Computer Vision; Kerkyra, Greece. 20–27 September 1999; pp. 666–673.

21. Liu H., Lai X., Wu W. Time-optimal and jerk-continuous trajectory planning for robot manipulators with kinematic constraints. Robot. Comput. Integr. Manuf. 2013;29:309–317. doi: 10.1016/j.rcim.2012.08.002. [Cross Ref]

Articles from Sensors (Basel, Switzerland) are provided here courtesy of **Multidisciplinary Digital Publishing Institute (MDPI)**

PubMed Central Canada is a service of the Canadian Institutes of Health Research (CIHR) working in partnership with the National Research Council's national science library in cooperation with the National Center for Biotechnology Information at the U.S. National Library of Medicine(NCBI/NLM). It includes content provided to the PubMed Central International archive by participating publishers. |