# Valkyrie--Design and Development of Gaits for Quadruped Robot Using Particle Swarm Optimization
## 1 Introduction
Due to the non-linearity of the system, rather than using a conventional approach, this research focuses on developing a metaheuristic algorithm to achieve various gaits. Metaheuristic algorithms are computational intelligence paradigms used especially for the sophisticated solving of optimization problems [11]. This optimization is achieved by either minimizing or maximizing the solution through computing the fitness function. [PERSON] et al. [12] presented an algorithm that generates walking motions for quadruped robots by simultaneously optimizing over both the center of mass (CoM) trajectory and the footholds without the use of an explicit footstep planner. Given a desired goal state, the problem was solved using a non-linear programming solver, and their results proved that the algorithm was able to generate walking gaits for multiple steps in milliseconds. [PERSON] et al. [13] proposed a heuristic-based planning approach that enables a quadruped robot to successfully traverse a significantly rough environment in the absence of visual feedback. Their proposed framework included reflexes triggered in specific situations, and the possibility to estimate online an unknown time-varying disturbance and compensate for it. [PERSON] et al. [4] used a particle swarm optimization algorithm to find the best value of the stability margin during the robot walking gait. The quadruped robot kinematic model of the forward and inverse kinematics for each 3-DOF was calculated, which led to finding the minimum stability margins during walking on the vertical geometrical projection of the robot body. Their results demonstrated the best stability margins that guaranteed the preservation of robot COG within the support polygon. Similarly, [PERSON] et al. [5] presented an evolutionary algorithm for Sony-legged robots to learn good walking behaviors with little or no interaction with the designers. The algorithm was based on a hybrid approach that changes the probability of genetic operators concerning the performance of the operator's offspring. The resulting gait was proved to be a better solution than the non-interference training for movements over all types of surfaces. Unlike other evolutionary algorithms like genetic algorithm (GA), and ant colony optimization (ACO), PSO achieved global convergence in a stipulated period of time. The former results in overlapping while the latter does not provide guaranteed convergence as the number of iterations increases. The main goal of this paper is to develop robust gaits for the quadruped robot, and since the inverse kinematic equation can yield many solutions, it is necessary to determine an optimal value of joint angles to achieve efficient locomotion, which can be done by the use of metaheuristic algorithms. Thus, from literature studies and since PSO is simple, computationally efficient, has fewer parameters, and guarantees stable convergence [14; 15], we have narrowed down our focus to develop a PSO algorithm to achieve various gaits. Hence, this work primarily focuses on the development and investigation of gaits for a 2 DoF mammal-inspired quadruped robot incorporating 4 hip and 4 knee motors as its locomotion element. Forward and inverse kinematics were formulated to determine the joint angles and stability analysis was carried out to ensure that the CoM and CoG lay within the support polygon. Walk, trot, and Pace gaits were developed using the particle swarm optimization algorithm to minimize the errors and improve the performance of the robot due to its non-linearity. The fitness function was derived based on the Euclidean distance between the target and robot's current position, and kinematic equations were used to obtain the relation between joints and coordinates. Experimental studies were carried out quantitatively to determine the convergence characteristics of the control algorithm and to investigate the distance traveled by the robot for different target positions and gaits. The rest of this paper is organized as follows.