An Fusion of Whale and Sine Cosine Algorithms for solving optimization Functions

We developed a novel hybrid approach for solving global optimization, computer science, bio-medical and engineering real life applications that is based on the coupling of the Whale Optimizer and Sine Cosine Algorithms via a surrogate model. We relate the whale optimizer algorithm to balance between the exploitation and the exploration process in the proposed method. There exist confirmed techniques for searching approximate best optimal solutions, but our algorithm will further guarantee that such numerical and statistical solutions satisfy physical bounds of the standard and real life functions. Our experiments with the benchmark, bio-medical, computer science and engineering real life problems have illustrated the advantages of using a newly hybrid approach based on mixing Whale Optimizer and Sine Cosine algorithms. It holds considerable potential for reducing execution time for solving standard and real life problems and at the same time improving the quality of the solution.


Introduction
The use of nature inspired optimization algorithm has gained popularity in a wide variety of standard, scientific, engineering and bio-medical real life applications as those techniques have some advantages over deterministic global optimization techniques. Those advantages include the capability to handle uninmodal, multi-modal and fixed dimension multi-modal objective problems without the assumptions of differentiability, continuity and the lack of the need for a good initial guess. Several metahuristics have been proposed in the literature during last two decades but quest for an improved and efficient algorithm still continues. This manuscript proposes an efficient hybrid nature inspired optimization technique. The proposed algorithms have been tested on several benchmark and biomedical problems. It has been observed that the proposed algorithm outperforms several other algorithms like Particle Swarm Optimization (PSO) [1], Ant Lion Optimizer (ALO) [2], Whale Optimization Algorithm (WOA) [3], Hybrid Approach GWO (HAGWO) [4], Mean GWO (MGWO) [5], Grey Wolf Optimizer (GWO) [6] and Sine Cosine Algorithm (SCA) [7] in solving several real life problems. The numerical and graphical presentation of results have been used to show the effectiveness of the proposed algorithm. The results obtained have been compared with those obtained with in terms of solution quality, solution stability, convergence speed and ability to find the global optimum and it has been concluded that our algorithm is better to other recent metaheuristics. Recently, researchers have originated most number of population based nature inspired metaheuristics in order to search the best possible optimal solution of tested and real life problems. The first solution algorithm for the OPF problem was proposed by Dommel and Tinney [8], and since then most numbers of other metaheuristics have been presented, some of them are: Particle Swarm Optimization (PSO) [1], Ant Colony Optimization (ACO) [9], Genetic Algorithm (GA) [10,11], Differential Evolution (DE) [12,13], fuzzy based hybrid particle swarm optimization (fuzzy HPSO) [14], Whale Optimization Algorithm (WOA) [15], Hybrid Genetic Algorithm (HGA) [15], harmony search algorithm [16], Robust Optimization (RO) [17], Grey Wolf Optimization (GWO) [6], Tabu Search (TS) [18], Gravitational Search Algorithm (GSA) [19], Artificial Neural Network (ANN) [20], Sine Cosine Algorithm (SCA) [7], Ant Lion Optimizer (ALO) [2], adaptive group search optimization (AGSO) [21], biogeography based optimization algorithm (BBO) [22], krill herd algorithm (KHA) [23], Grasshopper Optimization Algorithm (GOA) [24], Multi-Verse Optimizer (MVO) [25], Moth Flame Optimizer (MFO) [26], Dragonfly Algorithm (DA) [27], Black-Hole-Based Optimization (BHBO) [28], Cuckoo Search (CS) [29] and In addition, in case of the hybrid convergence, nature inspired algorithm hybridizations using batch modeling are combinations amid evolutionary techniques and techniques of neighbourhood or course. A newly hybrid approach has been presented by Mafarja and Mirjalili [30] using of different feature selection techniques and Whale Optimization Algorithm (WOA). The main purpose of applying Simulated annealing here is to enhance the exploitation by finding the most promising regions located by Whale Optimization algorithm. The accuracy of the newly variants is tested on several standard functions and compared with three well-known wrapper feature selection methods in the literature. B. Bentouati et al. [31] presents a new power system planning strategy by combining pattern search algorithm (PS) with Whale Optimization Algorithm (WOA). The existing variant has been carried out on the IEEE 30−bus test system considering several objective functions, such as voltage profile improvement, generating fuel cost, emission reduction and minimization of total power losses are also verified. The obtained numerical and statistical solutions are verified with recently published population based metaheuristic variants. Simulation solutions clearly conceal the rapidity and the effectiveness of the presented approach for solving the OPF function.
R.M.R. Allah [32] developed a new approach based on hybridizing the multi-orthogonal search strategy (MOSS) with a sine cosine algorithm (SCA), called multi-orthogonal sine cosine algorithm (MOSCA), for solving engineering design functions. The newly approach integrates the advantages of the SCA and MOSS to eliminate SCA's disadvantages, like unbalanced exploitation and the trapping in local optima. The convergence performance of the newly approach is investigated by using it on eighteen standard functions and four engineering design functions. The numerical solutions reveal that newly existing approach is a promising variant and outperforms the other recent metaheuristics in most cases. O. E. Turgut [33] proposes a hybrid global optimization approach based on the combination of the merits of the sine-cosine algorithm (SCA) and backtracking search (BSA) to achieve the optimal design of a shell and tube evaporator. In order to verify the performance of the newly hybrid approach, ten standard optimization problems have been solved. Simulation solutions obtained from the newly hybrid variant have been verified with the literature optimizers including differential search, quantum-behaved particle swarm optimization, big bang-big crunch optimization, bat algorithm, backtracking search algorithm and intelligent tuned harmony search algorithm.

Whale Optimizer Algorithm (WOA)
The whale optimization algorithm is a newly population based meta-heuristics approach proposed by Mirjalili at. el. [3]. This approach simulate bubble-net attacking technique of the humpback whales when they hunting their preys.
In this variant includes three operators to simulate the find for prey, encircling prey, and bubble-net foraging behavior of humpback whales.
• Encircling prey: Humpback whales can recognize the location of prey and then encircle them.
For the unknown position of the optimal design in the search area, the existing best agent possible 3 of 20 solution is the target prey or is near to the optimal in Whale Optimization Algorithm. Once the most excellent search candidate is defined, the next search candidates will thus make an effort to update their positions towards the finest search candidate. The restructured technique is represented by the following mathematical equations: Where t is the current generation, Aand Care coefficient vectors, X * is the position vector of the most excellent solution, and Xindicates the position vector of a solution, ||is the absolute value.
The vectors Aand Care mathematical calculated as below: Where components of aare linearly decreased from 2 to 0 over the course of generations and ris random vector in [0; 1] • Bubble-net attacking method: The humpback whales attach the prey with the bubble-net mechanism. This mechanism is mathematical respresented as follows: • Spiral updating position mechanism: In this mechanism, the distance amid the whale location and the prey location is calculated then the helix-shaped movement of humpback is created as shown in the equation: Where D = |X * (t) − X(t)|is the distance amid the prey (best possible solution) and the i th whale, bis a constant, lis a random number in [−1; 1].
Note: We suppose that there is fifty percent probability that whale either follow the shrinking encircling path during optimization procedure. Mathematical we modeled as belows: • Search for Prey: The vector Acan be apply for exploration to find for target and also takes the values > 1or < −1. The exploration can follows the followings mathematical equations: Where prepresent random number amid [0, 1].

Sine Cosine Algorithm (SCA)
Mirjaliliet al. [7] presented newly population based meta-heuristics called Sine Cosine Algorithm (SCA) simply based on Sine and Cosine function apply for exploitation and exploration phases in global optimization functions. This variant creates singular initial random agent best possible solutions in the search space and requires them to fluctuate outwards or towards the best possible result using following mathematical model based on sine and cosine functions.
Where: x t i current position,p 1 , p 2 , p 3 ∈ [0, 1] are random numbers and l i is targeted global optimal result. The above mathematical equations (9)-(10) uses 0.5 ≤ p 4 < 0.5 setting for exploitation and exploration.

Motivation of this work
Despite the Whale Optimizer and Sine Cosine Algorithm are competent to reveal an efficient performance in comparison with other population based nature inspired variants, it is not fitting for highly complex functions and is still may face the difficulty of getting trapped in local optima.To overcome these limitation and to improve its search performance, a new hybrid WOA-SCA variant is proposed to solve standard benchmark and engineering design functions. The proposed variant is called Hybrid WOA-SCA. In this variant, we improve the performance of exploitation in Whale Optimizer algorithm with the performance of exploration in Sine Cosine Algorithm (SCA) to produce both approaches' strength.
By this method, it is intended to improve the global convergence by accelerating the search seeking instead of letting the algorithm running several iterations without any improvement. The performance of newly proposed variants have been verified with several standard functions and some engineering design functions. Experimental solutions confirm that the newly proposed variant is a robust search variant for various real life and standard optimization functions.

The Hybrid WOA-SCA algorithm
Hybridization is an enhancement in global optimization techniques in which operators from a certain technique are combined with other operators from another technique to produce more effective and reliable synergistic entity and get superior quality of results than that of the main parent technique.
Whale Optimizer Algorithm as well as most powerful techniques have disadvantage and advantages in terms of their global optimization behavior. An advantage of generation upgrading techniques is their good exploitation quality, that is, they exactly converge to a local optimum; however, they have no method for a strong exploration of the search area. In contrast, whale optimizer showed to have superior exploration performance, but has functions with the exploitation in a promising area of the search space.
We developed a novel hybrid technique that combines whale optimizer with sine cosine algorithms. Basis of this modification, we improve the performance of exploitation in Whale Optimizer algorithm with the performance of exploration in Sine Cosine Algorithm (SCA) to produce both approaches' strength. The HWOASCA approach was mathematically modeled as follows: In which newly hybrid variant the position of the agents has been improved by modifying the spiral updating position equation (14) using position update equation (11) of sine cosine algorithm for the purpose of extending the convergence performance of whale optimizer algorithm. The rest of the operations of whale optimizer algorithm are same. The following position update equations are developed in this regard.
where p 5 ∈ [0, 1]is a random number, D = |X * (t) − X(t)|indicates the distance of the ith whale to the pray, bis a constant, lis a random number in [−1; 1], X * is the position vector of the most excellent solution, and Xindicates the position vector of a solution.
6. Pseudo code of the HWOASCA algorithm find the fitness of each solution X * ˜t he best search member while (t < max _generation) for each solution update all constants if 1 (p < 0.5) if 2 (|A| < +1) update the direction of the solution by equation (2) else if 2 (|A| > +1) select a random search agent () update the direction of the current search member by the equation (8) end if 2 else if 1 (p > +1) update the direction of the current search member by the equation (13) end if 1 end for check if any search agent goes beyond the search area and amend it find the fitness of each search member updatedX * if there is a better solution

The steps of HWOASCA algorithm
• Step 1: The WOA starts by setting the all parameter values (crowd size n, coefficients Aand C, the parameter a and maximum number of generations (max _generation). • Step 2: Initialize the generation counter t.
• Step 3: The first crowd is generated randomly and all search member in the crowd is evaluated by calculating its fitness function. • Step 4: Allocate the best search member.
• Step 5: The all following steps are repeated until the termination condition satisfied.
Step 5.1: The generation counter is increasing t = t + 1.
Step 5.3: Update the position of current search member by using the equations (14). • Step 6: The best search member is updated. • Step 7: The overall process is repeated until termination condition satisfied. • Step 8: Produce the best found search member (solution) so far.

Standard Benchmark functions
The convergence, numerical, statistical, and time consuming performance of proposed variant have been verified with several standard benchmark and real life engineering applications and experimental results obtained are compared with recent nature inspired techniques. These standard benchmark functions have been divided into three different parts i.e. Unimodal, Multimodal and fixed dimension multimodal are listed in Appendix ( Table A, Table B and Table C).

The performance of the newly proposed hybrid variant
In figures 1, we verify the general performance of the recent nature inspired algorithms with the newly proposed variant in order to test the efficiency of the proposed variant on number of generations. We set the similar parameter values for the entire algorithms to make fair comparison. We illustrate the results in figures 1 by plotting the worst optimal values of problem values against the number of iterations for simplified model of the molecule with distinct size from 20 to 100 dimension.
The figures proves that the benchmark function values quickly decrease as the number of iterations increases for newly hybrid algorithm results than those of the other nature inspired algorithms. In figures 1, PSO, ALO, WOA, HAGWO, MGWO, GWO and SCA algorithms suffers from the slow convergence, gets stuck in the partitioning procedure, nevertheless and many local minima and invoking the sine cosine algorithm in the proposed variant avoid trapping in local minima and accelerate the search.

Experiment and Results
We test the performance of the newly proposed variant on the several standard benchark and real life engineering functions on with different number of generations then we compared it against PSO, ALO, WOA, HAGWO, MGWO, GWO and SCA in MATLAB R2013a.
In the following subsections, we report more details the parameter settings of the newly hybrid and all other existing variants.   Table 1 to Table 6. The all existing variants, have to be run at least more than ten times to find the best global optimial solutions. It is again a common technique that a variant is run on a standard problem several times and best solutions, min and max objective values, average and standard deviation of the superior are obtained in the last iteration. Therefore, all obtained results evidence high rate of exploitation capability of the HWOASCA algorithm. Further, the experimental numerical and statistical results of the newly hybrid algorithm and other metaheuristics on multimodal problems are represented in Table 3-4 and performance plotted in Figure 3. We examine that the newly existing algorithm performs superior to other population based nature inspired techniques i.e. PSO, ALO, WOA, HAGWO, MGWO, GWO and SCA. The optimal solutions obtained in Table 3-4 strongly confirm that high exploration of HWOASCA algorithm is competent to explore the search area widely and give promising regions of the search space.     Table 3. 5-6. Numerical results of multimodal benchmark functions  Finally, the accuracy of the all existing metaheuristics have been tested on fixed-dimension multimodal functions and obtained results are presented in Table 5     MGWO, GWO and SCA in terms of min and max objective function values, standard deviation and average value. The results are consistent with those of the standard benchmark functions. On the basis of obtained results, we prove that the newly hybrid approach provides highly competitive optimal results verified with other recent nature inspired meta-heuristics, for these standard functions.

Clustering Problem in Wireless sensor network
In this text also we considered the accuracy of the existing variant on the clustering problem in wireless sensor network, which is most difficult and NP hard function. The all simulation results proven that the newly hybrid approach is gives most effective for these types of real life application due to fewer chances to get stuck at local minima and fast convergence. It can be concluded that the newly hybrid variant is competent to outperform the recent well known nature inspired metaheuristics in the literature.

Bio-Medical Real life Applications
In this section two dataset biomedical applications: (i) Breast Cancer and (ii) Heart are employed (Mirjalili, S. [14]). These dataset problems have been solved by HWOASCAvariant and compared with PSO, ALO, WOA, HAGWO, MGWO, GWO and SCA approaches. Distinct parameter settings have been applied for running code of all metaheuristics and these parameter settings are given in Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 15 October 2020 doi:10.20944/preprints202010.0319.v1 Table 6. 11-12. Statistical results of fixed-dimension multimodal benchmark functions    Table D] [15]. The convergence performance of the all techniques have been verified in terms of min and max objective values, standard deviation, average and classification rate[ Table 14].
The all results optained in Table 8, prove that the proposed variant as comparison to others gives the best quality of optimal solutions on the biomedical problems.The simulation results of proposed Preprints (www.preprints.org) | NOT PEER-REVIEWED | Posted: 15 October 2020 doi:10.20944/preprints202010.0319.v1  5. Comparison of variants on the best optimal cost of FF variant prove that it has the highest capability to avoid the local optima and is considerably better than other approaches i.e. PSO, ALO, WOA, HAGWO, MGWO, GWO and SCA.

HWOASCA algorithm for a tension/compression spring
In this section, the accuracy of HWOASCA algorithm was also tested with four constrained engineering design application like tension/compression spring Mirjalili, S. et al. [3] and comparison with the optimal solutions of GA, ES, PSO, SCA and WOA metaheuristics.
The main motive of this test function is to reduce or minimize the weight of the tension/compression spring. Optimum design must satisfy constraints on deflection, surge frequency and deflection. There are three design variables: number of active coils (N), mean coil diameter (D) and wire diameter (d). The mathematical optimization function is formulated as bellows: Subject to Variable range 0.05 ≤ y 1 ≤ 2.00, 0.25 ≤ y 2 ≤ 1.30, 2.0 ≤ y 3 ≤ 15.0 (20) This function was solved using different metaheuristics like Genetic Algorithm (GA) [35], Evolution Strategy (ES) [36], Particle Swarm Optimization (PSO) [3] and Whale Optimizer algorithm (WOA) [3].
The optimal solution of newly existing variant and sine cosine algorithm are compared with literature in Table 9. A several penalty problem constraint handling technique was utilized in order to perform a reasonable comparison with literature [34]. It can be notice that HWOASCA variant outperforms all others metaheuristics.
In this section, the performance of the existing variant has been also tested with economic dispatch problem and comparsion with the generation cost of Mean  The purpose of ED problem is to reduce the total fuel cost of power plants subject to the operating constraints of a power system. Commonly, it can be formulated with an two constraints and objective function (Park, J.B., [42] and Deep, K. and Bansal, J.C., [54]): where, C T : Total generation cost, C i : Cost function of generatori,P i : Power output of function generator i, Nnumber of generators and l i , m i , n i : are cost coefficients of generatori. (a) Equality constraints where P D and P L are total system demand and transmission loss of the system.
where P i,min and P i,max are minimum and maximum power output unit. The generation cost function C i (P i ) may be written as: where e i and f i are the cost coefficient of generatori. The results obtained by Table 10, illustrate the performance of the newly hybrid variant and other recent metaheuristics in the terms of least generation cost, mean and standard deviation. The results are also compared with newly published economic dispatch problem solutions. From Table 10, it is clear that HMOASCA variant gives a superior quality of results and signifies HWOASCA's higher efficiency to find the solution of economic dispatch problem as compared to other meta heuristics.
Further the generation cost obtained by difference metaheuristics has been compared by Figure 6. On the basis of experimental results and performance plotted by Figure 6, it can be observed that for power system economic dispatch problem of greater size with higher non-linearities, the HWOASCA algorithm is proved to be the best approach among all the variants.

Conclusion and future work
In this article, we propose a new hybrid whale optimizer algorithm with Sine Cosine algorithm in order to find the best possible solutions of the twenty two standard benchmark problems and real life applications. We call the newly proposed variant by Whale Optimizer algorithm and Sine Cosine algorithm (HWOASCA). We relate the whale optimizer algorithm to balance between the exploitation and the exploration process in the newly proposed variant. The obtained optimal solutions proved that the newly hybrid variant benefits form high exploration in comparison to the recent metaheuristics.
Further, we also tested the clustering problem in wireless senor network, breast cancer, heart dataset problem, tension/compression spring and economic dispatch problems is verified the performance of the existing variant with recent metaheuristics. The results show that the HWOASCA algorithms is found to be highly effective for real life applications due to fast convergence and fewer chances to get stuck at local minima. Hence the HWOASCA algorithm is able to outperform the recent well known and powerful nature inspired metaheuristics in the literature. The solutions prove the capability and advantage of HWOASCA to existing metaheuristic variants and it has an capability to become and helpful tool for solving real life optimization applications.
The future work will be concentrated on two parts: (i) composite functions, aircraft's wings, feature selection, Structural Damage Detection, the gear train design problem, Welded beam design, Cantilever beam, Pressure vessel design problem, bionic car problem, and mechanicial engineering problems (ii) Developing newly modified population based nature inspired metaheuristics for these tasks. To end with, we expectation that this work will encourage young researchers and other scientists, who are working on recent evolutionary metaheuristics concepts.
Author Contributions: Narinder Singh designed the numerical experiments, developed code and prepared the manuscript. Both the authors revised and finalized the final draft of manuscript.
Funding: This research received no external funding.

Conflicts of Interest:
The authors declare that there is no conflict of interest.