<latex>{\fontsize{16pt}\selectfont \textbf{Nonlinear MPC for Robotic Arms}} </latex>
<latex>{\fontsize{12pt}\selectfont \textbf{Brahayam Pontón}} </latex>
<latex>{\fontsize{10pt}\selectfont \textit{Semester Project RSC}} </latex>
<latex> {\fontsize{12pt}\selectfont \textbf{Abstract} </latex>
Differential Dynamic Programming, known as DDP, is a trajectory optimization algorithm used for determining optimal control policies for a nonlinear system. It is based on applying the Principle of Optimality around nominal trajectories, and iteratively computing improved trajectories.
The aim of this semester project is to use this technique to control a planar robotic arm of n-links and evaluate its performance, scalability of the algorithm for high number of degrees of freedom and real time constraints, and analyze suitability for the use on real robots where no perfect model of the robot and environment is available.
<latex> {\fontsize{12pt}\selectfont \textbf{How does DDP work?} </latex>
Differential Dynamic Programming is a numerical technique which does not look for a global optimal control policy, but instead, it is based on a second order approximation of the value function for determining optimal control policies for the current state. It has 3 basic steps:
<latex> {\fontsize{12pt}\selectfont \textbf{Some Improvements to DDP} </latex>
The improvements to be presented, were proposed in 1):
<latex> {\fontsize{12pt}\selectfont \textbf{Plant to be controlled} </latex> | <latex> {\fontsize{12pt}\selectfont \textbf{Cost Function} </latex> |
This algorithm is model-based, therefore, we need to explicitly formulate a description of the dynamics of the system, we are aiming to control. In this project, we used a planar robotic arm of n-links. | The cost function must contain the objectives that we are willing to achieve. The function used for evaluating the cost is given by: |
M(q) \ddot q + V(q,\dot q) + G(q) = \Gamma \end{equation*} where $q$ are the Generalized Joint Coordinates, $M(q)$ is the Mass matrix, $V(q,\dot q)$ is the Coriolis and Centrifugal forces matrix, $G(q)$ is the Gravity matrix and $\Gamma$ is the vector of Generalized forces. |\begin{equation*} \begin{split} \label{eq_cst_4} \ell (\textbf{x}, \textbf{u}, i) &= cost_X[x_i - x_t]^2 + cost_U[u_i]^2 \\* &+ cost_O \sum\limits_{j=1}^{obs} \mathcal{N} (x_i; x_j,\Sigma) \\* &+ cost_S \mathcal{N} (svx_i; 0,\sigma^2) \\* \end{split} \end{equation*} |
<latex> {\fontsize{12pt}\selectfont \textbf{Some Results} </latex>
The computational complexity for the derivatives is $\sim \BigO {N n^5}$, for the backward and forward passes $\sim \BigO {N n^3}$; where $N$ represents the number of timesteps used in the receding time horizon given by $N = Simulation Time / dt$. The other variable is $n$ which represents the dimension of the state vector of the dynamics. This shows that the biggest effort is in the compulation of the derivatives, as can be seen in the following figures.
It was also explored that DDP can easily handle model error regarding the mass and inertia properties. DDP is not sensitive to modelling errors in the mass and inertia properties of the several links. However, it is not able to handle appropriately errors in the length of the links. This means that the kinematic model should be accurate. The following Figures show the results for Go-to-Goal motion for the indicated errors in length. Numerical results can be found in the report.
1% model error in length | 10% model error in length | 20% model error in length | 50% model error in length |
---|---|---|---|
A remarkable result of DDP is that it can easily incorporate the description of obstacles in the cost function and in this way, it can plan in environments with static and dynamic obstacles. |
<latex> {\fontsize{12pt}\selectfont \textbf{Conclusions} </latex>
<latex> {\fontsize{12pt}\selectfont \textbf{Further Work} </latex>