1. Introduction
Recently, several biped robots have been studied as robots that can move on flat terrain as well as uneven and stepped terrain. Zero moment point (ZMP)-based robots such as ASIMO were once the mainstream [Reference Kajita, Kanehiro, Kaneko, Fujiwara, Harada, Yokoi and Hirukawa1–Reference Satoshi, Goswami and Vadakkepat4], but more recently, many researchers have turned to limit cycle walking robot that can achieve stable periodic gaits without relying on ZMP [Reference McGeer5–Reference Gong, Hartley, Da, Hereid, Harib, Huang and Grizzle11]. Passive dynamic walking proposed by McGeer is a pioneer of limit cycle walking robots [Reference McGeer5]. Passive dynamic walkers utilize their dynamics to achieve energy-efficient periodic walking on slopes. Many studies have been conducted on attaching motors and other devices to passive dynamic walkers to enable their walking on a flat terrain. Among these, the method of strong convergence to the desired trajectory using output-zeroing control is widely employed for limit cycle walking generation [Reference Grizzle, Abba and Plestan8–Reference Gong, Hartley, Da, Hereid, Harib, Huang and Grizzle11].
However, methods employing output-zeroing control have a weakness: while they are energy-efficient for walking with convergence to a limit cycle in an ideal environment, they are less efficient in a realistic environment with disturbance such as an uneven terrain. This is because when the state of a robot deviates from the desired trajectory due to a disturbance, the output-zeroing control cancels out the robot’s dynamics and converges it to the desired trajectory with a strong feedback.
To counter this, we propose NMPC to take the advantage of robot dynamics for achieving convergence to the desired trajectory and energy efficiency. Although NMPC is computationally expensive and difficult to implement within a control period, recent advances in computing environments and the algorithms for solving nonlinear optimization at high speeds have resulted in an active research on robots with NMPC [Reference Ohtsuka12–Reference Katayama, Doi and Ohtsuka17].
Therefore, we propose a method for limiting cycle walking generation based on NMPC. Our method produces walking that is more energy-efficient than the walking based on the conventional output-zeroing control method, as demonstrated through several simulation results. In the numerical simulation, we first present the results of a 2D walking analysis using MATLAB and then that of a 3D walking analysis using Unity [18]. The robot used in the simulation was made to walk on an uneven terrain, and various disturbances caused by leg collisions with irregular terrain affected the robot’s walking. This paper is organized as follows: Section 2 introduces the rimless wheel robot used in the walking analysis and describes its dynamics model. Next, we discuss the proposed controller based on NMPC and conventional output-zeroing control in Section 3. In Sections 4 and 5, we present the 2D walking analysis results on MATLAB and the 3D walking analysis results on Unity, respectively. Finally, we provide a conclusion and discuss future scope in Section 6.
2. 2D model of the rimless wheel robot
2.1. Equation of motion
Herein, we utilize a rimless wheel robot as a walking robot to simplify the analysis. For the rimless wheel robot, considering the next collision leg as the swing leg results in a walking system similar to that of a biped walking robot [Reference Asano and Kawamoto19–Reference Asano and Suguro24]. The model of the rimless wheel robot is shown in Fig. 1; the robot has a torso and can actuate it using a rotary actuator at the hip joint. The equation of the motion of the rimless wheel robot is expressed as:
where $\boldsymbol{q}=[\theta _{1},\,\theta _{2}]^{\textrm{T}}$ is the generalized coordinate vector, the inertial matrix $\boldsymbol{M}_{o}(\boldsymbol{q})\in \mathbb{R}$ $^{2\times 2}$ is represented as
the Coriolis, centrifugal, and gravitational force vectors $\boldsymbol{H}_{cg}(\boldsymbol{q},\dot{\boldsymbol{q}})\in \mathbb{R}$ $^{2}$ are represented as
$u_1$ is the input, and the driving matrix $\boldsymbol{S} \in \mathbb{R}$ $^{2}$ is represented as
2.2. Impact equation
In the 2D simulation on MATLAB, the collision between a leg and the ground is assumed instantaneous and inelastic. After each collision, the robot’s velocity is calculated using an impact equation [Reference Grizzle, Abba and Plestan8]. Further, the constraint equation $\boldsymbol{J}_I \in \mathbb{R}^{2 \times 4}$ of the robot when the leg tip touches the ground expressed as:
The impulse vector $\boldsymbol{\lambda }_I \in \mathbb{R}^{2}$ and the velocity vector immediately after impact $\dot{\boldsymbol{q}}_a^{+} \in \mathbb{R}^4$ are expressed as:
where
$\boldsymbol{q}_a =[\theta _1,\,\theta _2,\,x_1,\,z_1]^{\textrm{T}}$ is the augmented generalized variable, $x_1$ and $z_1$ denote the position of the stance leg, $\dot{\boldsymbol{q}}_a^{-} =[\dot{\theta }_1^-,\,\dot{\theta }_2^-,\,\dot{x}_1^-,\,\dot{z}_1^-]^{\textrm{T}}$ is the velocity immediately before impact, and $\boldsymbol{M}_a(\boldsymbol{q}_a)$ is the following inertia matrix in the augmented generalized variable.
where $M_{11} = I_1+m_2 l_1^2 m_h l_1^2$ , $M_{12} = m_2 l_1 a_2 \cos (\theta _1-\theta _2)$ , $M_{13} = (m_2 + m_h) l_1 \cos (\theta _1)$ , $M_{14} = -(m_2 + m_h) l_1 \sin (\theta _1)$ , $M_{22} =m_2 a_2^2$ , $M_{23} =-m_2 a_2 \cos (\theta _2)$ , $M_{24}= -m_2 a_2 \sin (\theta _2)$ , $M_{33}=m_2 + m_h$ , $M_{34}=0$ , $M_{44}= m_2 + m_h$ .
3. Controller
3.1. Generating limit cycle walking generation using NMPC
A robot with a torso, such as the rimless wheel robot, can generate propulsive force for walking by maintaining the forward-tilting torso posture. While the desired trajectory of the torso can be a continuous function, herein, we assumed a constant value ( $\theta _{2d} = \textit{const}$ ). When walking on an uneven terrain, the robot is susceptible to disturbances or state jumps that occur at unpredictable and irregular times intervals; for example, leg-ground collisions, gear backlash, obstacle contact, and leg-floor slippage. In other words, if we can realize a control that converges the torso posture to the desired trajectory with minimal energy consumption under these disturbances, periodically stable and energy-efficient walking can be achieved.
Therefore, NMPC is applied to optimize the convergence of the torso to the desired trajectory and its energy consumption within short prediction intervals because disturbances occur frequently within a gait cycle, making optimization over a long interval impractical. Additionally, short prediction intervals help reduce computational cost and facilitate implementation within a short control cycle of the walking robot. To solve this optimization problem within the control cycle, a fast algorithm is required; we use the C/GMRES method [Reference Ohtsuka12], which combines continuous deformation method and GMRES to solve nonlinear optimization problems at a high speed.
3.2. NMPC algorithm
The nonlinear system in a discrete time interval is obtained by
where $\boldsymbol{x}(k) \in{\mathbb R}^{n}$ is the state vector and $\boldsymbol{u}(k) \in{\mathbb R}^{m}$ is the input vector. Then, we set the following objective function:
where
$i=0, \cdots, N-1:$ $N$ is the number of the predictive steps, $\boldsymbol{x}_d$ is the desired state vector, $\boldsymbol{S}_f$ is the terminal weight, $\boldsymbol{Q}$ is the state weight, $\boldsymbol{R}$ is the input weight, and $\boldsymbol{x}_i(k)$ and $\boldsymbol{u}_i(k)$ are the state and input vectors, respectively, in the prediction interval $i$ -step. The Hamiltonian and optimal necessary conditions are obtained as follows:
where $\boldsymbol{\lambda }_i(k) \in{\mathbb R}^{n}$ is the companion variable vector at $i$ -step. The optimal control input is set as the actual input for the system, and then, the finite horizon is moved backward by a discrete interval. This sequence is repeated in the NMPC approach. In C/GMRES, $U(k) \in{\mathbb R}^{mN}$ and $F(\boldsymbol{U}(k),\boldsymbol{x}(k),k)\in{\mathbb R}^{mN}$ are defined by
where $H_u = \frac{\partial H}{\partial u}$ . The state and companion variable vectors can be obtained using Eqs. (13)–(16). Then, $\Delta \boldsymbol{U}(k)$ is obtained when $\boldsymbol{F}=0$ is solved using the C/GMRES algorithm. Finally, $\boldsymbol{u}(k+1)=\boldsymbol{u}(k)+\Delta T\Delta \boldsymbol{u}(k)$ can be calculated.
Moreover, we introduce an integrator to suppress the oscillation of the control input as the input is unstable when there are disturbances or state jumps [Reference Onodera and Yamakita13–Reference Odachi, Oyama and Yamakita15]. To achieve this, we designed an augmented system that includes the input as a part of the state. The augmented system for the rimless wheel robot is expressed as follows:
where
$y_1(k)$ is the output of the angle of the stance leg, $y_2(k)$ is the output of the angle of the torso, $y_3(k)$ is the output of the angular velocity of the stance leg, $y_4(k)$ is the output of the angular velocity of the torso, $\Delta T$ is the discrete interval, and $\Delta u_1$ is the differential value of the input. The objective function is defined as follows:
where
$\boldsymbol{y}_d(k)$ is the desired output vector. Then, the Hamiltonian condition is defined as
From Eq. (24), the optimal necessary condition is obtained by
The optimal control input, $\Delta u_1$ , can be calculated, and $u_1$ is obtained by integrating $\Delta u_1$ .
3.3. Output-zeroing control
For comparison with the proposed method, a conventional method of output-zeroing control is introduced here [Reference Westervelt, Grizzle, Chevallereau, Choi and Morris10]. This method is input-output linearization and output-zeroing control for the torso’s attitude control. Although the actual robot is 3D, the mathematical model for the control is defined as 2D since the rimless wheel robot performs 2D motion constrained to the sagittal plane. The affine system is defined as:
To converge the torso angle $\theta _{2}$ to the desired torso angle $\theta _{2d}$ , the output function is defined as
Differentiating this function with time yields the following functions.
Since the relative order of the system is two, the partially linearized feedback input for input-output linearization is given by
where $L_gL_fh$ and $L_{f}^2h$ are given by
Finally, we set the new control input $v$ as
4. 2D walking analysis in MATLAB
4.1. Setting for simulation
We conducted a 2D walking simulation using MATLAB to compare the performance of NMPC and output-zeroing control. This simulation assumed level ground, fully inelastic collisions, and no slippage, while disturbances were applied to each joint (the contact point of the support leg and the hip joint) as normally distributed random torques. Tables I, II, and III show physical and control parameters on MATLAB simulations. We set the initial state as $\boldsymbol{X}_0=[-0.20\,\,0.35\,\,1.50\,\,0.00]^{\textrm{T}}$ , and The desired values as $\theta _{2d} = 0.35$ rad and $\dot{\theta }_{2d} = 0$ rad/s. Furthermore, we analyzed the walking speed and the energy efficiency of walking (20 steps) using NMPC and output-zeroing control. The specific resistance (SR) metric was used to evaluate the energy efficiency, which is given by:
where $p$ [J/s] is the average input power, $M$ [kg] is the total weight of the robot, and $v_a$ [m/s] is the average walking speed. The average input power is defined as
where $T$ [s] is the total walking time.
4.2. Parameter setting for NMPC
The key points for determining the parameters in Table III are $S_f$ , $Q$ , $R$ , $T_f$ , and $N$ . First, $T_f$ is the length of the prediction interval and is set to a short value as demonstrated in Section 3.1. Various disturbances can occur at unexpected times during the robot’s gait. When the robot deviates from the target trajectory because of such disturbances, we aimed to realize an entrainment that quickly and efficiently pulls the robot’s state back to the target trajectory using NMPC. Therefore, herein, the generation of optimal entrainment to target trajectory by NMPC is main idea. In this study, $T_f=0.05$ was set by trial and error and $N$ is the number of divisions of this prediction interval, $T_f$ . Herein, this number of divisions is set to $N=5$ in terms of computation time. If a shorter computation time is desired, we have set $N=3$ or 5 ( $N=3$ in Section 5). For $S_f$ , $Q$ , $R$ a trial-and-error approach is used to find values for which the robot state converges sufficiently to the target values. From there, the input weight $R$ is increased to evaluate the values that improve energy efficiency. Other parameters are determined with reference to previous studies [Reference Ohtsuka12].
4.3. Walking using output-zeroing control
First, we analyzed the walking using the output-zeroing control. Figures 2 and 3 show the torso angle in walking without and with disturbance, respectively. The robot achieved periodic walking using output-zeroing control without and with disturbance, the walking speed was 0.757 m/s, the SR was 0.071 without disturbance, the walking speed was 0.806 m/s, and the SR was 0.158 with disturbance. The nature of the given disturbance caused a slight increase in the walking speed. Further, we confirmed that the disturbance greatly reduced the energy efficiency of walking.
4.4. Walking using NMPC
We analyzed the walking performance using NMPC under the same conditions as the output-zeroing control by including the same disturbances. Figures 4 and 5 show the torso angle in walking without and with disturbance, respectively. The robot achieved periodic walking using NMPC without and with disturbance, the walking speed was 0.772 m/s, the SR was 0.076 without disturbance, the walking speed was 0.824 m/s, and the SR was 0.084 with disturbance. The walking speed using NMPC was almost the same as observed in output-zeroing control. However, the energy efficiency was improved by nearly double. This can be attributed NMPC optimizing the energy consumption under the disturbances.
Then, we analyzed the SR values and walking speeds for the input weight of NMPC. Figures 6 and 7 show SR values and walking speeds with respect to the input weights of NMPC, respectively. We observed that SR values and walking speeds increase slightly with respect to the input weight. Further, Figs. 8 and 9 show SR values and walking speeds with respect to the input weight of NMPC in disturbance, respectively. These figures indicate that SR monotonically decreases with increasing input weight, while the walking speed is monotonically increases with the increasing input weight. The increase in walking speed is attributed to the nature of the disturbance; by increasing the input weights, the motion was designed to take advantage of the disturbance, which increased the walking speed and further optimized energy consumption. Table IV and Fig. 10 summarize the results of the above analysis. We observed no significant difference in the walking speed of output-zeroing control and NMPC under disturbances. However, there was a significant difference in their energy consumption in the presence of a disturbance. The NMPC produced energy-efficient walking even in the presence of disturbance.
5. 3D walking analysis in Unity
5.1. Simulation setting
To perform the walking analysis in an environment that closely resembles an actual environment, we carried out simulations in a 3D environment using Unity. We demonstrate the practicality of walking with NMPC through an uneven surface as shown in Fig. 11. This uneven surface was created using Terrain Toolkit 2017, with the environment set to “PATH OF THE FLESH” and the maximum ground altitude was set to $0.6$ m. The simulation communicated between Unity and MATLAB and the control input was computed by the same MATLAB program, as shown in Fig. 12. Table V shows the physical parameters of the robot in Unity. These parameters are those of our previous robots [Reference Hanazawa, Nishinami and Sagara22], and the robot inertia, $I_2$ , around the center of gravity of the body since the body is rectangular. Therefore, the inertia matrix, $M_o$ , is modified as follows:
Tables VI and VII show the control parameters of the output-zeroing control and NMPC in Unity, respectively. The desired values are $\theta _{2d}=0.65$ rad and $\dot{\theta }_{2d}=0$ rad/s, and the initial state is $\boldsymbol{x}_0=[0.00\,\,0.65\,\,8.0\,\,0.00]^{\textrm{T}}$ .
Figures 13 and 14 show the robot’s walking on a flat surface and on the uneven terrain for 20 s, respectively. Here, three types of uneven terrains (no. 1, 2, and 3) were created with random shapes, and a walking analysis was performed.
5.2. Walking by output-zeroing control in Unity
First, we analyze the walking using the output-zeroing control on the flat surface and the uneven terrain. Figures 15 and 16 show the torso angle during walking on a flat surface and on an uneven terrain no. 1, respectively. These figures show the robot performs periodic walking on the flat surface and on the uneven terrain. Table VIII and Fig. 17 show the SR values and the average speeds of walking. It was observed that walking on a flat surface is the most energy-efficient and the fastest. However, the walking speed and energy efficiency were reduced in all uneven terrains.
5.3. Walking using NMPC in Unity
Next, we analyzed walking using NMPC in Unity in the same conditions. Figures 18 and 19 show the torso angle in walking using NMPC on the flat surface and the uneven terrain no. 1, respectively. As with output-zeroing control, we observed that the robot can periodically walk on a flat surface and uneven terrain. Table IX and Fig. 20 show the SR values and average speeds for walking using NMPC. Unlike the output-zeroing control, the energy efficiency did not almost decrease while walking on uneven terrains.
Further, we analyzed the walking with varying input weights of NMPC. Figures 21 and 22 show the SR values of walking using the NMPC on the flat surface and on the uneven terrain no. 1 with respect to the input weight, respectively. Similarly, Figs. 23 and 24 show the walking speeds of the NMPC walking on the flat surface and on the uneven terrain no. 1 with respect to the input weight, respectively. We observed that, as the input weight increased, the walking performance improved. In this case, setting the input weight to a value >1 enabled energy-efficient walking. Finally, we compared the SR values and walking speeds obtained for the output-zeroing control and NMPC in Table X and Fig. 25. Comparing the output-zeroing control and NMPC on a flat surface and on the uneven terrain, it is found that NMPC outperforms the output-zeroing control in energy efficiency and walking speed. Therefore, it can be concluded that NMPC is upward compatible with output-zeroing control in this simulation case.
6. Conclusion and future works
This study proposes an NMPC-based method for achieving energy-efficient limit cycle walking in a disturbed environment. We first developed a 2D simulator using MATLAB and performed analyses under the assumption of a strictly perfect inelastic collision, which is common in walking analysis. Then, a 3D walking simulator was developed using Unity to verify the practicality of NMPC under uneven terrain conditions. In both environments, walking with the proposed method showed excellent performance. In particular, there was a significant difference between walking with and without disturbances. Although this paper was a comparison of two methods, such as NMPC and output-zeroing control, performance comparisons will be conducted with other gait generation methods in the future. Although this study is based on simulation results only, we will verify the practicality of the proposed method by conducting experiments on actual equipment. Additionally, since this study was conducted on the simplest rimless wheel robot, we would further analyze on a walking robot with a more complex mechanism.
Author contributions
Y. Hanazawa conceived and designed this study. Y. Hanazawa and H. Nishinami verified the usefulness of the proposed method. Y. Hanazawa wrote the article. S. Sagara provided technical support for the study.
Financial support
This research was partially supported by Kitakyushu Foundation for the Advancement of Industry, Science, and Technology.
Competing interests
Authors declare no competing interests exist.
Ethical approval
Not applicable.
Supplementary material
The supplementary material for this article can be found at https://doi.org/10.1017/S0263574723001522