Mechanical Engineering Design Optimization Using Reptile Search Algorithm

Optimization algorithms plays a vital role in mechanical engineering. In this paper we have demonstrated how the Reptile Search Algorithm (RSA) algorithm is able to solve classical engineering design problems. In the first part, the biological reference, as well as a detailed overview of the algorithm is given. Afterwards, the RSA algorithm and the potential to solve the machine engineering design class of problems is given. The source code for this algorithm was written using MATLAB R2020a software suite. The Reptile Search Algorithm (RSA) algorithm was used for optimization problems in the field of engineering design, such as: pressure vessel optimization, disk brake optimization and cantilever beam optimization. The statistical results and comparisons show that the RSA algorithm provides comparable results to other state-of-the-art algorithms used for this problem.


Introduction
N the research field of computer science, there exists a class of problems called NP-problems. The main characteristic of such problems is that the solution to such a problem can be verified within polynomial time complexity, while whether or not such a problem has a solution is unknown. This implies that finding a solution for such a problem is memory and time consuming in most cases.
Optimization problems fall into this category of problems. In this case, the problem is defined using the mathematical problem formulation, where one or more functions are to be minimized or maximized (this value is called the fitness value) under a given set of conditions and the set of variables [18]. Yet the exact optimal value for the fitness value is not known, therefore classifying optimization problems as NP.
One of the most popular methods for solving optimization problems are metaheuristics. What is meant by the term is a class of algorithms having a randomized approach to exploring the vast solution spaces, whose implementation heavily depends upon the problem that is to be solved. Metaheuristics can be split into two categories: single solution (s-type) and population based (p-type). In s-type metaheuristics, a single solution is modified in order to explore the solution space and solve the problem. The main advantage of s-type metaheuristics is that they are memory efficient and allow more creativity in creating new implementations. Yet, careful considerations should be taken while constructing such algorithms, so that the solution space be explored in the most efficient manner. P-type metaheuristics, on the other hand, uses a population of solutions which converges to the best solution of the population. Ofttimes, the algorithm is split in exploration phase, where the search space is explored, and the exploitation phase, where the population converges to the best solution of the population. The advantages to such algorithms are that the solution space is searched thoroughly in a systematic manner. However, these algorithms use more memory than the s-type metaheuristics, and there is not much space in carefully catering the algorithm to the problem that is solved.
To the best of our knowledge, there have not been attempts to solve mechanical design problems using s-type metaheuristics. Therefore, in this section, a brief overview of state-of-the-art p-type algorithms will be presented. In all of these algorithms, what is considered the prey is the current best solution, while all the other search agents are named after the species the algorithm draws inspiration from, unless stated otherwise.
The Honey Badger Algorithm (HBA) [1] is a p-type metaheuristic algorithm which draws inspiration from the behavior of the eponymous mammal species. In this algorithm, there is only one phase, where the constant called the density factor commands the algorithm's convergence. The movement of the badgers can either be in the cardoid shape (called the digging phase) or the badgers can "follow the honey guide bird" (called the honey phase). Which of these two types of movement is applied to the badgers is determined by a random number variable drawn from the uniform distribution.
The Harris' Hawks Algorithm (HHO) [2] draws its inspiration from an American bird of prey which hunts in flocks. In the case of this algorithm, the prey is called the rabbit. This algorithm has both phases of p-type metaheuristic algorithms. The energy parameter is what gradually decreases I with each iteration, and is what determines the transition from exploration to exploitation phase. In the exploration phase, the movement is predetermined, while in the exploitation phase, the hawks have 4 possible strategies for catching the rabbit, dependent upon current energy level and a random variable drawn from the uniform distribution.
The Grey Wolf Optimizer (GWO) [3] is based on the complex hierarchy of grey wolf packs. This algorithm has both phases of p-type metaheuristic algorithms. In the case of exploration phase, all wolves move towards the prey. The main characteristic of this algorithm is how it divides the population in its exploitation phase. Namely, the first, second, and third best solution are named alpha, beta, and delta wolf, while all the other search agents are called omega wolves. In the exploitation phase, the omega wolves move towards the position that is determined by mean of positions of alpha, beta and delta wolf.
The Marine Predator Algorithm (MPA) [4] is based upon the behavior of predator species in the seas and oceans. The main idea is that the predator population chases the prey population. This algorithm is split into three phases instead of the typical two, based three equal parts of number of iterations. The main difference is in constructing the initial solution, which divides the population into predator and prey. First, solutions are randomized to create the initial population of prey, used to determine the movement of the population. Then, the best solution is repeated to form the population of the elite, which represents the predator population. In each phase, the predator population moves faster with each iteration, while the prey population slows down its movement.
The Dingo Optimization Algorithm (DOA) [5] is based upon hunting behavior of dingoes. This algorithm is similar to the GWO algorithm in terms of phases and population division. The first difference is that the encircling phase guarantees that the prey will be surrounded from each part of the solution space. The second difference is that in the exploitation phase, the best, second best, and other search agents' movement happens independent of each other.
The Whale Optimization Algorithm (WOA) [6] is based upon the hunting behavior of humpback whales. There are two phases to this algorithm, but under certain range of values of a random variable, the whales go into encircling the prey. During the exploration phase, the whales move towards a random solution, while in the exploitation phase, the whales move towards the prey in a spiral-like fashion.
The Snake Optimization Algorithm (SOA) [7] is based upon the hunting behavior of snakes. There are the two usual phases of this algorithm, with an addition that there are additional ways of population movement in each phase. In this algorithm, the population is split into two equal parts, which represent the male and female part of the population. Snakes search for food, which represents the value which is increased as iterations pass, and represents the transition from exploration to exploitation. In addition to the movement in the exploration/exploitation phase, there is a chance that the snakes will fight or mate, which explores the solution space further than other algorithms.
The Tunicate Swarm Algorithm (TSA) [8] is inspired by small sea creatures, the tunicates, and their swarm behavior. This algorithm features only one phase, where the movement is decreased as iterations pass. The main characteristic of this algorithm is that, during movement, conflicts among the search agents are resolved, so that the search agents do not end up in the same space, and the tunicates move first towards the best neighbor, and, ultimately, towards the best search agent.
The Grasshopper Optimization Algorithm (GOA) [9] was inspired by the swarm behavior of grasshoppers. Unlike other algorithms, there is only one phase, and all of the population members are treated equally. The factors that affect movement of the search agents are: social forces, dependent upon the distances between a particular grasshopper and all the other grasshoppers, and two constant forces called gravity and wind advection. The social forces are used to bring the algorithm to convergence, reducing the strength of these forces with each iteration.
In this paper, mechanical design problems are solved using the new, state-of-the-art Reptile Search Algorithm (RSA) [10]. The problems that were solved are: pressure vessel, disk brake and cantilever beam.

Reptile search algorithm
The Reptile Search Algorithm (RSA) [10] is based upon the hunting behavior of crocodiles. In nature, the prey is usually encircled and hunted by predators. This behavior in nature was used to inspire such algorithms, where essentially the encirclement phase of the hunt represents a random walk, that is used to search the solution space, while the very hunt represents the exploitation phase, thus bringing the algorithm to convergence.
The core for the inspiration of this algorithm are the manifold advantages of the predatory crocodile species. First, the crocodiles exhibit an anatomical advantage, where their body shape lowers the air and water resistance, enabling them fast movement. Second, crocodiles have advanced cognitive skills in recognizing the behavioral patterns of prey, and, consequently, exploiting their weaknesses in order to capture the prey. Finally, crocodiles hunt in herds, and each member of the herd carries out the same role in every hunt.
Where xij is the j-th dimension of the i-th solution of the population, rand is a random variable, UB and LB are upper and lower bounds, respectively.
After the initial solution is created, the crocodiles go into exploration phase. In this phase, the crocodiles go into the high walking movement strategy and the belly walking movement strategy, each taking up a half of the exploration phase. The movement of crocodiles in this phase is given by Eqs. (2) - (7).
Best j (t) represents the j-th dimension of the best solution, η (i,j) the hunting operator for the j-th position in the i-th solution, β the sensitivity parameter equal to 0.1, R (i,j) the reduce function, ES(t) the evolutionary sense function, P (i,j) the percentage difference between the j-th dimension of the ith solution and the best solution, and M(x i ) is the average position of the i-th solution. The hunting operator is used to control the exploration accuracy, the reduce function is used to reduce the search area, while the evolutionary sense adds to the randomness of the search. The variables denoted by r i (i being an integer) and ε represent random variables.
The hunting phase represents the latter half of the algorithm. In this phase there are also two movement strategies, which divide this phase into two equal parts, as it is the case in exploration phase. The movement in this phase is given by Eq. (8).
, , The main characteristic of this algorithm, which makes it stand out from the rest, is the splitting of each of the two phases into two equal sub-phases, thus varying search agent movement.

Optimization models
This section is dedicated to a detailed look into the engineering design problems that are being solved. For each problem, its basis, goal function, input variables, and condition are given. The code of the optimization algorithm was written in the Matlab R2020a software suite.

Optimization of pressure vessel
This problem corresponds to the weight minimization of a cylindrical pressure vessel (Fig.2) with two spherical heads. There are four design variables: the thickness of the pressure vessel (x 1 ), the thickness of the head (x 2 ), the inner radius of the vessel (x 3 ) and the length of the cylindrical component (x 4 ). 19.84  

Optimization of disk brake
The main objective of the disk brake optimization problem is minimizing the brake's mass. There are four variables that constitute the input to the metaheuristic algorithm for this problem (as shown in Fig.3): inner radius of the discs (x 1 ), outer radius of the discs (x 2 ), engaging force (x 3 ) and number of the friction surfaces (x 4 ).  x Optimization of cantilever beam Cantilever beam (Fig.4) is an important element in mechanical engineering, whose design is to be handled with utmost care. Minimization of the said beam's weight represents the main goal in design. The lengths of the five bearings are this problem's variables.
The considered variable ranges are described in Eq. (25).

Eexperimental analysis
In this section, the results obtained by using RSA on a set of selected engineering problems is given.
For the pressure vessel problem, the expected value for the goal function is 5885.3327, with the results shown in Table 1. In the case of this problem, RSA has given better results than those found in literature.
A detailed display of the results obtained by RSA and a comparison with several results obtained by other methods, for the problem of disk brake, are shown in Table 2. In this case, the RSA gives the same result as the PAHS algorithm, while PSA and GA give worse results.
For the cantilever beam design problem, the results shown in Table 3, along with the results obtained by ALO, MMA and GOA methods. In this case, the RSA gives the same result as the MMA algorithm, while ALO and GOA give better results.

Conclusion
This paper describes using Reptile search algorithm in order to solve metaheuristic problems from the class of engineering design problems. For this algorithm, the input parameters that were decided on are 10 search agents and 500 iterations. Letting the algorithm run for more iterations and use more search agents did not yield higher quality solutions. Since the execution time is important in order to run more tests, this combination of input parameters was chosen.
For the pressure vessel problem, the RSA algorithm performed better than other listed algorithms from the literature. As for the cantilever beam problem and disk brake problem, the results were shown to be near optimal.
In this field of study, there is always room for further improvements, namely in regard of the betterment of the optimization results.