Anti-Slip Gait Planning for a Humanoid Robot in Fast Walking

: Humanoid robots are expected to have broad applications due to their biped mobility and human-like shape. To increase the walking speed, it is necessary to increase the power for driving the joints of legs. However, the resulting mass increasing of the legs leads to a rotational slip when a robot is walking fast. In this paper, a 3D three-mass model is proposed, in which both the trunk and thighs are regarded as an inverted pendulum, and the shanks and feet are considered as mass-points under no constraints with the trunk. Then based on the model, a friction constraint method is proposed to plan the trajectory of the swing leg in order to achieve the fastest walking speed without any rotational slip. Furthermore, the compensation for zero-moment point (ZMP) is calculated based on the 3D three-mass model, and the hip trajectory is obtained based on the compensated ZMP trajectory by using the preview control method, thus improving the robot’s overall ZMP follow-up e ﬀ ect. This planning method involves simple calculations but reliable results. Finally, simulations conﬁrm that the rotational slip is avoided while stable and fast walking is realized, with free joints of the waist and arms, which then could be planned for other tasks.


Introduction
Humanoid robots can enter non-structural environments that wheeled and crawler robots find difficulties to reach or pass through by virtue of their biped mobility advantages [1][2][3]. Their flexible hands and arms can use human tools. Furthermore, the human-like shape helps them to assimilate into human society. Therefore, humanoid robots are expected to have broad applications in rescue and relief, public service and family service, etc. Since the release of P2 by Honda in the late 1990s, research on humanoid robots has been a major area of interest, and significant progress has been made in mechanical structures, electrical systems, and control algorithms [4][5][6][7]. However, there have been many weaknesses and problems in humanoid robots so far, e.g., low walking speed, tipping over easily, and an inability to perform other tasks while walking. In the DAPPA Robotics Challenge (DRC), humanoid robots of several teams fell down while they were on the move or performing their duties. The first-ranked DRC-HUBO completed multiple tasks relying on the wheels mounted on the knees [8]. Therefore, in order to become practical, humanoid robots must achieve stable and fast walking, and have the ability to complete other tasks while traveling.
From the point of view of hardware, in order to achieve fast walking, it is necessary to increase the driving power of each joint of the legs. There are two options for implementation. One is to use a hydraulic drive which is similar to that used in the Boston Dynamics' Atlas robot [9]. In this option, since the power is transmitted from the body to the end actuator through the hydraulic line, the light weight of the leg is ensured [10]. However, the hydraulic system has shortcomings such as liquid leakage, high noise and a complicated system, so its further development is not optimistic. The other option is to use high-power motors or multiple motors in parallel. This configuration is easier with little noise, which is then employed in many laboratories. Figure 1 shows a typical motor-driven humanoid robot model. The robot has 6 degrees of freedom for each leg and a six-dimensional forcetorque (F-T) sensor for each ankle. In addition, there is always an inertial measurement unit (IMU) fixed inside the chest. P2, HRP-5P, BHR-5, et al. have the similar leg configuration and sensors [4][5][6]. In this type of structure, since the motor must be placed inside or near its corresponding joint, and the harmonic drive gear associated with it is also heavy, the weight of the leg is greatly increased. When the robot is walking fast, the swing leg creates a large yaw moment on the support leg. When a moment generated by the friction between the ground and the sole is insufficient to offset this yaw moment, rotational slip occurs to the robot. Rotational slip is very harmful, specifically, it will make the robot deviate from a predetermined travel route and motion state, causing the robot to become unstable or even tip over. Therefore, it is necessary to overcome the rotational slip by using motion planning or a control algorithm to improve the stability of fast walking. Traditional methods are to compensate for the yaw moment by planning motions of some joints. According to the recordings in current papers, rotation of the waist in the yaw direction is utilized to compensate the moment in some cases [11,12], or swinging of the arms is used to generate the reverse torque [13,14], or both of these two are employed at the same time [15,16]. Each method above could have certain effects, but joints of waists or arms that are used in these systems for moment compensation can't be planned for other tasks, which weakens the ability to multi-task while walking. To address these problems, R. Cisneros et al. proposed an on-line compensation scheme for the yaw moment, which allows using the motion of every single link of the robot to contribute to the compensation, and achieved good results in the simulation of the kicking action [17,18]. However, this method could only be used for force-controlled robots, and there is no simulation or experiment applied to the robots' walking. Therefore, none of the above methods satisfy the needs of fast-walking robots in real life. To overcome the shortcomings of these methods mentioned above, in this paper, we try to find a gait pattern with optimized yaw moment to satisfy the friction constraints. Joints of waist or arms are not used when gait planning, so they can be planned for other tasks. Traditional methods are to compensate for the yaw moment by planning motions of some joints. According to the recordings in current papers, rotation of the waist in the yaw direction is utilized to compensate the moment in some cases [11,12], or swinging of the arms is used to generate the reverse torque [13,14], or both of these two are employed at the same time [15,16]. Each method above could have certain effects, but joints of waists or arms that are used in these systems for moment compensation can't be planned for other tasks, which weakens the ability to multi-task while walking. To address these problems, R. Cisneros et al. proposed an on-line compensation scheme for the yaw moment, which allows using the motion of every single link of the robot to contribute to the compensation, and achieved good results in the simulation of the kicking action [17,18]. However, this method could only be used for force-controlled robots, and there is no simulation or experiment applied to the robots' walking. Therefore, none of the above methods satisfy the needs of fast-walking robots in real life. To overcome the shortcomings of these methods mentioned above, in this paper, we try to find a gait pattern with optimized yaw moment to satisfy the friction constraints. Joints of waist or arms are not used when gait planning, so they can be planned for other tasks.
In order to calculate the friction constraints and plan for the walking pattern, we need a reasonable calculation model. Multi-link model provides high precision, but it's too complicated to use to meet the needs of real-time control. An inverted pendulum model or inverted pendulum flywheel model is simple in structure and convenient in calculation, but they can only be applied to robots with lightweight legs [11,19]. That's because the mass of the inverted pendulum model is concentrated at one point, which is called the center of mass (CoM) and is usually mapped into the chest of the robot. The deviation of motion state between the model and the real robot grows with the growing of the leg's mass and the deviation also grows with the increasing of the walking speed, which adds difficulties to control strategies. Therefore, in this paper, learning from the achievements of predecessors, we proposed a 3D three-mass model. In our model, we regarded both trunk and thighs as an inverted pendulum, and the shanks and feet as mass-points under no constraints with the trunk. Then we used this model to calculate the friction constraints between the ground and the sole, as well as the pattern of the swing leg conveniently with enough precision.
Hip trajectory directly affects the stability of the robot. Q. Huang et al. proposed a method to plan the hip trajectory by traversing the search with 2 key parameters [20]. However, this method requires repeated calculations to obtain a higher stability gait, which is complicated and not practical. The preview control method proposed by S. Kajita directly takes the zero-moment point (ZMP) Equation as a constraint condition, and then obtains a smooth trajectory of CoM that takes into account both the robot's stability and the CoM's acceleration increment by means of quadratic optimization [21]. But it relies heavily on the accuracy of modeling, so it is very effective on humanoid robot with light legs but has poor performance in robots with heavy legs. However, as described above, under the current technical conditions, an increase in leg mass due to an increasing demand in driving power is unavoidable. Therefore, in this paper, we improved the preview control method based on the 3D three-mass model. We added compensation to the reference ZMP, and finally obtained a hip trajectory that enables the robot to achieve a large stability margin.
With the trajectories of swing leg and hip, we obtained the trajectory of every joint of legs by using inverse kinematics, which means complete gait planning. Simulation experiments have shown that both the motion of the swing leg and the ZMP trajectory have an effect on the rotational slip. The gait planning method proposed in this paper can effectively avoid the robot's rotational slip generated during fast walking. The actual ZMP follows well for the reference ZMP, thus ensuring the stability.
The rest of this paper is organized as follows: Section 2 proposes the 3D three-mass model; in Section 3, friction constraint is calculated and trajectory of the swing leg is planned; Section 4 records the planning of hip trajectory; and the simulations and conclusions are presented in Sections 5 and 6 respectively.

Dynamics Model
As a ratio of a leg's mass to the total mass of the robot increases, the effect of the legs' motion states on the overall motion state increases. Therefore, the inverted pendulum model that treats the robot as a mass point no longer works. To this end, J. H. Park et al. proposed a gravity compensation inverted pendulum model (GCIPM), which conducts calculations after separating the swing leg's mass from the total mass of the robot, thus increasing calculation accuracy [22]. T. Sato et al. further proposed a three-mass model for the humanoid robot, which divided the robot into a body, support leg and swing leg, and the adopted mass of these three parts to calculate the zero-moment point (ZMP) of the robot, which resulted in a smaller ZMP error and a walk mode with higher efficiency [23,24]. However, in his model, the legs' motion states were affected by the state of the body and feet in turn, increasing the computational complexity. In fact, shanks and feet have much greater effects on the whole body's dynamics than thighs due to their longer distances from the trunk. Therefore, we proposed a new 3D three-mass model to simulate the dynamics.
As shown in Figure 2, the 3D three-mass model divides a robot into three parts: the inverted pendulum, the swing leg and the support leg. The mass of the chest, head, arms, hips and thighs of the robot (namely the part in the red dotted rectangle in Figure 1) is considered to be all focused on the end of the inverted pendulum, which is recorded as the mass of the inverted pendulum m pend . We do not consider the relative motion between any two parts that constitute the inverted pendulum, so as to eliminate interference factors. The mass of the shank and foot is considered to be focused on the center of the ankle, which is recorded as the mass of the swing leg m swg or the mass of the support leg m sup . In order to reduce the amount of calculation, it is assumed that there is no kinematic constraint between the legs and the inverted pendulum. m total is the total mass of the robot, namely m total = m pend + m swg + m sup .
Appl. Sci. 2019, 9, x 4 of 15 the end of the inverted pendulum, which is recorded as the mass of the inverted pendulum . We do not consider the relative motion between any two parts that constitute the inverted pendulum, so as to eliminate interference factors. The mass of the shank and foot is considered to be focused on the center of the ankle, which is recorded as the mass of the swing leg or the mass of the support leg . In order to reduce the amount of calculation, it is assumed that there is no kinematic constraint between the legs and the inverted pendulum.
is the total mass of the robot, namely = + + .

Figure 2.
3D three-mass model. The robot is divided into 3 parts: the inverted pendulum, the swing leg and the support leg. There is no kinematic constraint between the legs and the inverted pendulum. and represent the zero-moment point (ZMP) of the inverted pendulum and the whole robot respectively. , represent the accelerations of the center of mass in three directions, respectively.
The ground's reactive force is the only external force the model is subjected to and it generates a moment at an arbitrary point P , , : Take the moment to the inverted pendulum as an example, its vector expression is: where ⃗ is inverted pendulum's velocity vector and ⃗ is a displacement vector from to , which represents the CoM of inverted pendulum. Then is decomposed into 3 components in 3 axes respectively: and is decomposed similarly: 3D three-mass model. The robot is divided into 3 parts: the inverted pendulum, the swing leg and the support leg. There is no kinematic constraint between the legs and the inverted pendulum. ZMP pend and ZMP total represent the zero-moment point (ZMP) of the inverted pendulum and the whole robot respectively. ..

y and
..
z represent the accelerations of the center of mass in three directions, respectively.
The ground's reactive force is the only external force the model is subjected to and it generates a moment M total at an arbitrary point P x p , y p , z p : Take the moment to the inverted pendulum as an example, its vector expression is: where .. −→ p pend is inverted pendulum's velocity vector and −→ PP pend is a displacement vector from P to P pend , which represents the CoM of inverted pendulum. Then M pend is decomposed into 3 components in 3 axes respectively: ..
x pend y pend − y p + m pend ..
y pend x pend − x p (5) and M swg is decomposed similarly: ..
x swg y swg − y p + m swg ..
Set the center of the ankle of the support leg to be the origin O and let point P coincide with O. Since the support foot does not move relative to the ground, the moment in yaw direction (around the z axis) generated by the ground for changing the motion of the support leg is negligible, i.e., M sup z ≈ 0. So we can get: where M total z , M pend z and M swg z are the moments in yaw direction generated by the ground for changing the motion of the whole robot, inverted pendulum and swing leg, respectively.

Swing Leg Motion Planning
It can be seen from Equation (9) that the moment in yaw direction is to the inverted pendulum and the swing leg. Therefore, we firstly calculate the ground friction constraint and then examine the moments needed to drive the inverted pendulum and the swing leg, respectively.

Ground Friction Constraint
C. Zhu et al., revealed the relationship between rotational slip and translational slip, and gave the constraints to prevent the slip of the robot under various conditions [25,26]. In order to ensure the sole does not rotate or slip, the moment generated by the body on the support leg must be smaller than the maximum static friction moment T f max that the ground can provide, which is shown in Equation (10).
where A is the area of the sole of the support leg, µ s is the static friction coefficient between the sole and the ground, g is acceleration of gravity and r represents the distance from a point on the sole to the origin. Since a certain margin is required, the friction coefficient µ d used for calculating the threshold moment provided by the ground should be smaller than the static friction coefficient µ s . A humanoid robot modeled with a linear inverted pendulum usually keeps the mass point constant in the z direction when walking on a flat surface, thus .. z pend equals to 0. In addition, because the support leg is stationary relative to the ground, .. z sup also equals to 0. Therefore, the threshold moment is: If the sole of the robot is a rectangle with a length of a and a width of b, then after integral of Equation (11), we can get:

Inverted Pendulum Yaw Moment
When the height of the CoM is constant, given the initial position and velocity and taking x direction as an example, the motion of the 3D inverted pendulum can be expressed as follows: . therefore, ..
x pend (0) are the initial position and velocity of the inverted pendulum in x direction respectively, and t is the time.
Before we plan the gait, the ZMP and walking period T are usually specified. As shown in Figure 3, the step lengths in the x direction and the y direction are L x and L y respectively. Based on these parameters, the motion Equations of the inverted pendulum in the x direction are: ..
Similarly, the motion Equations of the inverted pendulum in the y direction can be obtained: ..
We can obtain the moment that is required to perform the motion of the inverted pendulum by substituting Equations (16)- (19) into Equation (5). The conclusion is M pend z = 0, which indicates that the the inverted pendulum does not produce a yaw moment on the ground, and only the swing leg is required to satisfy the frictional constraint.
Appl. Sci. 2019, 9, x 6 of 15 therefore, where, ≡ ⁄ , 0 and 0 are the initial position and velocity of the inverted pendulum in x direction respectively, and is the time.
Before we plan the gait, the ZMP and walking period are usually specified. As shown in Figure 3, the step lengths in the x direction and the y direction are and respectively. Based on these parameters, the motion Equations of the inverted pendulum in the x direction are: Similarly, the motion Equations of the inverted pendulum in the y direction can be obtained: We can obtain the moment that is required to perform the motion of the inverted pendulum by substituting Equations (16)- (19) into Equation (5). The conclusion is = 0, which indicates that the the inverted pendulum does not produce a yaw moment on the ground, and only the swing leg is required to satisfy the frictional constraint.

Swing Leg Motion Planning
The motion of the swing leg can be examined in x direction and z direction respectively (we assume ≡ 0 in this paper). Since the motion in the z direction has little effect on the needed moment in the yaw direction, it can be planned by conventional methods such as quartic interpolations. However, its motion in x direction has a significant influence on the needed moment in the yaw direction, and the frictional constraint must be satisfied. If the given period of the swing phase is < , firstly we set the time period for acceleration, swing at constant speed, and deceleration as , and , respectively. Therefore, the other constraints are  Figure 3. Setting of the landing points p 1 , p 2 , · · · , p N , which represent ZMPs for an inverted pendulum and determine the walking length L x and width L y . The rectangles represent the robot's footprints.

Swing Leg Motion Planning
The motion of the swing leg can be examined in x direction and z direction respectively (we assume .. y swg ≡ 0 in this paper). Since the motion in the z direction has little effect on the needed moment in the yaw direction, it can be planned by conventional methods such as quartic interpolations. However, its motion in x direction has a significant influence on the needed moment in the yaw direction, and the frictional constraint must be satisfied.
If the given period of the swing phase is T swg T swg < T , firstly we set the time period for acceleration, swing at constant speed, and deceleration as T ac , T con and T de , respectively. Therefore, T ac + T con + T de = T swg (20) the other constraints are T ac 0 ..
where, υ con is the speed of the center of the swing leg's ankle in the constant speed period. T ac , T con and T de can be obtained from Equations (20)- (23). Further, the trajectory of the center of the swing leg's ankle in the x direction can be obtained: In addition, by substituting Equations (24) and (25) into Equations (6) and (7), we can obtain M swg x and M swg y .

Hip Motion Planning
In order to obtain the joints' trajectory, we still need to plan the hip trajectory after obtaining the trajectory of the ankles. The hip trajectory can be derived from the trajectory of the CoM of the inverted pendulum, because there is a fixed mapping relationship between them. We can derive the inverted pendulum trajectory by using a preview control method based on the planned ZMP trajectory. However, due to the swing leg's significant influence on ZMP, it is essential to compensate for the inverted pendulum's reference ZMP to help the whole robot to achieve a large stability margin.

ZMP Compensation
We firstly set the center of the support leg's ankle as the origin. According to the ZMP's definition, the inverted pendulum's position of ZMP is: ..

Preview Control
S. Kajita et al., have proposed a preview control method [21]. According to this theory, the performance index is specified as where e(i) is the servo error and e(i) ≡ p(i) − p re f (i), q e , R > 0, and Q x is a 3 × 3 symmetric non-negative definite matrix. k means time in a discrete system. ∆x(k) is the incremental state vector, and ∆x(k) ≡ x(k) − x(k − 1). ∆u(k) is the incremental input, and ∆u(k) ≡ u(k) − u(k − 1). The optimal controller which minimizes the performance index is given by: where G i , G x and G p ( j) are the gains calculated from the weights Q e , Q x , R and the system parameters (including sampling time, CoM height and acceleration of gravity). p re f k+ j is the ZMP reference previewed for future N L steps at every sampling time, which is discretized from the reference ZMP p re f x pend zmp , y pend zmp . According to the robot's initial state, the motion state vectors of the inverted pendulum's CoM, x pend . x pend ..
x pend and y pend . y pend .. y pend can be obtained. According to the actual position of the inverted pendulum's CoM in the robot, combined with the planned ankle trajectory, the inverse kinematics can be used to obtain the trajectory of each joint. Now the gait planning for preventing the rotational slip is completed.

Simulation
The above methods proposed in this paper are verified on the joint simulation platform composed of ADAMS 2017 and Simulink 2016b with a time step of 1ms, which balances the calculation accuracy and speed.
During the simulation, we made multiple calculations and adjustments. The finalized dynamics parameters of the simulation are listed in Table 1. These robot configuration parameters in Table 1 are chosen depending on the newly designed humanoid robot in Beijing Institute of Technology. It has a similar structure and the same number of degrees of freedom of the leg with P2, BHR-5 and HRP-5P [4][5][6], as shown in Figure 1. The advantage of the newly designed robot is the more powerful leg joints. At the same time, the ratio of the leg's mass to the total mass of the robot is larger. For this configuration, a walking step length of 0.44 m gives a small joint acceleration. Because of lack of stability control, long-distance walking introduces accidental factors, complicating the problem. So we set the number of walking steps to 6, which is enough to examine the effect of planning methods. In our previous experiments, the tested static friction coefficient µ s between the sole and the ground is 0.75. Since the friction coefficient µ d used for calculating the threshold moment T f cri should be smaller than the static friction coefficient, we set µ d as 0.5. Under the condition of satisfying the friction constraint, reducing the double-support phase time ratio is beneficial to reduce the maximum swing velocity and acceleration. However, the swing leg switches to the support leg during the double-support phase, and the robot switches the support leg at the same time, so the time of double-support phase cannot be too short. In order to achieve a smooth trajectory as well as high stability of foot landing and lifting, the swing leg's motion in the z direction is planned by quartic interpolation, so that the speed and acceleration tend to be zero at the moment of lifting and landing the foot. However, due to the inevitability of a slight collision between the sole and the ground, it is easy to generate a large shift of the ZMP, which requires the double-support phase to provide a large support region. Therefore, it is necessary to maintain a certain double-support phase time to provide a large ZMP stability margin. After trial and error, we set the double-support phase time ratio as 0.1. Under these conditions, the resulting calculated minimum walking step cycle is 0.528 s and maximum walking speed is about 3.0 km/h. Figure 4 shows the snapshots taken from the video of biped walking in simulation which are totally planned by our proposed method (Case 1). The robot obtains a stable walking pace without any slipping at a speed of 3.0 km/h.  For this configuration, a walking step length of 0.44 m gives a small joint acceleration. Because of lack of stability control, long-distance walking introduces accidental factors, complicating the problem. So we set the number of walking steps to 6, which is enough to examine the effect of planning methods. In our previous experiments, the tested static friction coefficient between the sole and the ground is 0.75. Since the friction coefficient used for calculating the threshold moment should be smaller than the static friction coefficient, we set as 0.5. Under the condition of satisfying the friction constraint, reducing the double-support phase time ratio is beneficial to reduce the maximum swing velocity and acceleration. However, the swing leg switches to the support leg during the double-support phase, and the robot switches the support leg at the same time, so the time of double-support phase cannot be too short. In order to achieve a smooth trajectory as well as high stability of foot landing and lifting, the swing leg's motion in the z direction is planned by quartic interpolation, so that the speed and acceleration tend to be zero at the moment of lifting and landing the foot. However, due to the inevitability of a slight collision between the sole and the ground, it is easy to generate a large shift of the ZMP, which requires the double-support phase to provide a large support region. Therefore, it is necessary to maintain a certain doublesupport phase time to provide a large ZMP stability margin. After trial and error, we set the doublesupport phase time ratio as 0.1. Under these conditions, the resulting calculated minimum walking step cycle is 0.528 s and maximum walking speed is about 3.0 km/h. Figure 4 shows the snapshots taken from the video of biped walking in simulation which are totally planned by our proposed method (Case 1). The robot obtains a stable walking pace without any slipping at a speed of 3.0 km/h.  In order to verify the superiority of our algorithm, we have also simulated three other cases. The following are the exact operations done in these four cases (see Supplementary Materials): Case 1: Plan the pattern exactly using the methods described in this article, namely, plan the swing leg's motion by the friction constraint method, and then compensate for the reference ZMP.
Case 2: Plan the swing leg's motion by the friction constraint method, but don't compensate for the reference ZMP. The purpose of setting Case 2 is to examine the effect of ZMP compensation on walking stability.
Case 3: Plan the swing leg's motion in x direction by quartic interpolation, and then compensate for the reference ZMP. The purpose of setting Case 3 is to examine the effect of the swing leg planning method on yaw moment.
Case 4: Plan the swing leg's motion in x direction by quartic interpolation, but don't compensate for the reference ZMP. The purpose of setting Case 4 is to demonstrate the shortcomings of traditional gait planning methods during fast walking.
Case 2-4 use the same parameters as those in Case 1 that are listed in Table 1. In Case 2 and Case 4, the hip trajectory is planned by using the preview control method proposed by S. Kajita based on the conventional linear inverted pendulum model [21]. In Case 3 and Case 4, the swing leg motion planning is inspired by the third spline interpolation method proposed by Q. Huang [20]. Below are comparison results among the four cases.
Firstly we have compared the ZMP following-up performances in Case 1 and Case 2, and the results are shown in Figure 5. The swing legs in Case 1 and Case 2 are planned in the same way, but the ZMP compensation is only performed in Case 1. In Case 2, the actual ZMP in the x direction is affected strongly by the motion of the swing leg: in the first half of the single-support phase of each step, the actual ZMP approaches the rear edge of the support rectangle, but in the latter half, it quickly moves to the front edge of the support rectangle and sometimes goes beyond it; and in the y direction, the swing leg has similar effects on the ZMP. The swing leg in Case 2 applies an additional torque in the roll direction to the trunk due to its gravity once it is off the ground, which biases the actual ZMP toward the inner edge of the support rectangle. Eventually, the swing leg touches the ground in advance, and the sole collides with the ground, causing the ZMP trajectory fluctuate drastically in double-support phase. While in case 1, the robot has a higher stability benefitting from the ZMP compensation. Whether in the x direction or the y direction, the actual ZMP trajectory is closer to the center line of the support rectangle and keeps itself inside the support polygon all the time. Therefore, the landing is smoother and the resulting impact force is smaller, which lead to smaller fluctuation in the ZMP trajectory.
Secondly, we have compared the moments required to walk as planned in Case 1 and Case 3. Case 1 and Case 3 differ in the planning method of the swing leg in x direction: Case 1 uses the friction constraint method proposed in this paper, while Case 3 uses the traditional quartic interpolation method. In order to ensure there is no slip occurring, we set the ground friction coefficient to be 2 and then examine the moment between the support leg and the ground during walking. Figure 6 shows the moment between the sole and ground in a single-support phase. It keeps within the permissible range in Case 1, but it is outside the permissible range from time to time in Case 3. The permissible range is calculated under the condition that µ s = 0.75 based on Equation (10). The results mean that in a single-support phase, friction moment provided by the ground is large enough to prevent rotational slip in Case 1, but in Case 3, the friction moment is not. Secondly, we have compared the moments required to walk as planned in Case 1 and Case 3. Case 1 and Case 3 differ in the planning method of the swing leg in x direction: Case 1 uses the friction constraint method proposed in this paper, while Case 3 uses the traditional quartic interpolation method. In order to ensure there is no slip occurring, we set the ground friction coefficient to be 2 and then examine the moment between the support leg and the ground during walking. Figure 6 shows the moment between the sole and ground in a single-support phase. It keeps within the permissible range in Case 1, but it is outside the permissible range from time to time in Case 3. The permissible range is calculated under the condition that = 0.75 based on Equation (10). The results mean that in a single-support phase, friction moment provided by the ground is large enough to prevent rotational slip in Case 1, but in Case 3, the friction moment is not. Finally, Figure 7 shows the yaw angles of the robot during travel in all the 4 cases, which are measured by the IMU. In Case 1, the maximum yaw angle of the robot is 0.36°, and the yaw angle at the last stop is −0.16°. Such a small yaw angle is negligible, indicating that the robot has almost no rotational slip during the whole motion. In Case 2, the robot shows a noticeable rotational slip and the maximum yaw angle and the final yaw angle are both −1.93°. The reason for this can be found from the ZMP trajectory in Figure 5b: the ZMP stability margin is low, the robot cannot always maintain the planned posture, and there is a tendency to roll and tilt forward and backward. In addition, the swing leg touches the ground in advance and collides with the ground. The shock  Finally, Figure 7 shows the yaw angles of the robot during travel in all the 4 cases, which are measured by the IMU. In Case 1, the maximum yaw angle of the robot is 0.36 • , and the yaw angle at the last stop is −0.16 • . Such a small yaw angle is negligible, indicating that the robot has almost no rotational slip during the whole motion. In Case 2, the robot shows a noticeable rotational slip and the maximum yaw angle and the final yaw angle are both −1.93 • . The reason for this can be found from the ZMP trajectory in Figure 5b: the ZMP stability margin is low, the robot cannot always maintain the planned posture, and there is a tendency to roll and tilt forward and backward. In addition, the swing leg touches the ground in advance and collides with the ground. The shock caused by the collision does not stop, even when the double-support phase ends. Therefore, the sole of the support leg does not always fit the ground: sometimes only its edge hits the ground, and sometimes only its tip touches the ground. So the required friction can't be provided, and the robot rotates with the swinging of the swing leg. In Case 3, the maximum yaw angle is −1.66 • and the final yaw angle is −1.35 • . The reason is that the planned trajectory cannot satisfy the frictional constraint between the sole and the ground all the time, which can be deduced in the curve for Case 3 in Figure 6. In Case 4, because the problems similar to those in Case 2 and Case 3 exist at the same time, the robot walks in an extremely unstable manner. The maximum yaw angle reaches −5.36 • , and the final yaw angle is −3.47 • in this case, which is very dangerous for real robots, since the number of walking steps is small in the simulation compared to the real walking situation. From more simulation experiments, we found that when the ratio of leg's mass to the total mass of the robot is larger than one sixth, slip is the key factor of restricting the walking speed. The performance of our method was outstanding compared with the conventional methods. However, if the ratio of the leg's mass to the total mass of the robot was smaller than one sixth, our method shows no advantages. Maybe some factors other than slip are more significant. As we know, most of the existing humanoid robots belong to the former. So our method is suitable for improving most of robots' performances in fast walking.

Conclusions
In order to increase walking speed of the humanoid robot, it is necessary to increase the driving power of the leg joints, which in turn leads to an increase of leg weight. This paper aims to overcome the rotational slip of a motor-driven high-power humanoid robot during its fast walking through a gait planning algorithm with free joints of the waist and arms for multitasking during walking. The main contributions are as follows. Firstly, a 3D three-mass model applicable to fast-walking robots with heavy legs was proposed. Then based on this model, the maximum moment provided by the ground friction during walking was calculated, which was then used as a constraint to plan the swing leg motion. After that, the influence of the swing leg on ZMP was calculated, and thus the original reference ZMP trajectory was compensated for to obtain a new one. Based on the compensated ZMP trajectory, the preview control method was adopted to plan the trajectory of the CoM of the inverted  From more simulation experiments, we found that when the ratio of leg's mass to the total mass of the robot is larger than one sixth, slip is the key factor of restricting the walking speed. The performance of our method was outstanding compared with the conventional methods. However, if the ratio of the leg's mass to the total mass of the robot was smaller than one sixth, our method shows no advantages. Maybe some factors other than slip are more significant. As we know, most of the existing humanoid robots belong to the former. So our method is suitable for improving most of robots' performances in fast walking.

Conclusions
In order to increase walking speed of the humanoid robot, it is necessary to increase the driving power of the leg joints, which in turn leads to an increase of leg weight. This paper aims to overcome the rotational slip of a motor-driven high-power humanoid robot during its fast walking through a gait planning algorithm with free joints of the waist and arms for multitasking during walking. The main contributions are as follows. Firstly, a 3D three-mass model applicable to fast-walking robots with heavy legs was proposed. Then based on this model, the maximum moment provided by the ground friction during walking was calculated, which was then used as a constraint to plan the swing leg motion. After that, the influence of the swing leg on ZMP was calculated, and thus the original reference ZMP trajectory was compensated for to obtain a new one. Based on the compensated ZMP trajectory, the preview control method was adopted to plan the trajectory of the CoM of the inverted pendulum. Finally, the trajectories of all the joints of the legs could be obtained by inverse kinematics.
In this paper, the effectiveness of the proposed algorithm was verified by simulation, and the conclusions are as follows.

1)
For a humanoid robot with heavy legs, it is the motion of the swing leg that causes rotational slip and strongly affects the overall ZMP of the robot; 2) By using the friction constraint method proposed in this paper to plan the swing leg motion, the maximum walking speed without rotating slip can be obtained; 3) If the ZMP variation caused by the swing leg motion is compensated to the reference ZMP, the actual ZMP of the robot will follow the reference ZMP better, as a result the robot maintains its posture better and the leg lands more stably, avoiding the rotational slip caused by the sole not being attached to the ground; 4) We can only obtain a fast walking gait without rotational slip if we use both the friction constraint method and the ZMP compensation method proposed in this paper sequentially.
Looking towards future work, some research needs to evolve the off-line methods proposed in this paper to on-line methods, while other research needs to apply these methods to real robots. Since there are model errors between the actual robot and the simulation model, the motors have servo error, and the ground is not an ideal plane, a series of engineering problems in application need to be solved. Furthermore, if the walking distance is long, there will be an accumulation of errors, which means a stability control method is required.