# A Master-Slave Salp Swarm Algorithm Optimizer for Hybrid Energy Storage System Control Strategy in Electric Vehicles

Authors: Fabian Cheruiyot; Davies Segera
Journal: Journal of Energy
 (2022)

---

## Abstract

Pure electric vehicles provide an enticing ecofriendly alternative to traditional fossil fuel combustion engine locomotives. Batteries have primarily been used to store energy in electric vehicles; however, peak load demand and transient power leading to decreased battery lifespan have bred interest in hybrid energy storage systems in electric vehicles. Management of energy drawn from a hybrid energy storage system (HESS) in electric vehicles is a real-time multistage optimization problem aimed at minimizing energy consumption while aptly distributing energy drawn from the battery and capacitor to enhance the battery life cycle. This paper explores the feasibility of a master-slave salp swarm optimization algorithm (MSSSA) (metaheuristic algorithm) in a HESS control strategy for electric vehicles. Introducing a master-slave learning approach to the salp swarm algorithm (SSA) improves its performance by increasing its convergence rate while maintaining a balance between exploration and exploitation phases of the algorithm. A comparison of the MSSSA results with the SSA (salp swarm algorithm), DA (dynamic algorithm), WOA (whale optimization algorithm), MFO (moth flame optimization algorithm), GA (genetic algorithm), and PSO (particle swarm optimization algorithm) on benchmark test functions and dynamic program simulation of an electric vehicle’s HESS control strategy and shows preeminence of the MSSSA control strategy for HESS.


---

## Body

## 1. Introduction

Electric vehicles are undoubtedly the future of the automobile industry. Owing to their energy saving ability and lack of exhaust pollution, electric vehicles have high potential of replacing combustion fuel vehicles. However, pure electric vehicles are still plagued with limitations such as poor energy consumption, long charging periods, and short battery range. In interest, to extend the mileage and energy efficiency of EVs led to the incorporation of hybrid energy storage systems (HESS) composed of batteries and capacitors. HESS incorporates the advantages of both batteries and capacitors for an optimal balance between capacity, charge/discharge time, and life cycles. To maintain this balance, management and control systems for HESS have been explored in energy distribution based on the working conditions of an EV [1].With emphasis on real time-energy consumption optimization, fuzzy control is at the core of these management and control systems applied by the industry. Recent developments in machine learning and the development of metaheuristic algorithms have seen scholars take on optimization algorithms research in management and control systems of HESS [2].These algorithms are particularly promising in the engineering field as they are able to abstractly solve optimization problems, significantly reducing time and resource taken to solve them despite presenting variable performances.Metaheuristic nature-inspired optimization algorithms have become a fervent field in extreme learning machine (ELM). ELM is an extremely fast training method for single hidden layer feed forward networks (SLFN), the most prevalent artificial neural network (ANN) [3]. As suggested in the name “nature-inspired,” these algorithms are inspired from natural phenomena with optimization evident at the core of the living organisms’ survival mechanisms. These algorithms include the following: genetic algorithm (GA), grey wolf optimizer (GWO), dragon-fly algorithm, whale optimization algorithm, and ant colony optimization (ACO) [4].Over the years, attempts to improve ELM performance led to the development of metaheuristic algorithms. These techniques have become popular owing to their flexibility in solving diverse problems, their higher immunity to being trapped in a local minimum, and that they apply a gradient-free mechanism, hence more likely to converge at a solution faster [3]. Since they are nature-inspired, metaheuristic algorithms can optimally arrive at a solution without traversing the entire problem search space, therefore achieving both speed and reducing computation costs [5].The salp swarm algorithm (SSA) proposed by Mirjalili et al. in 2017 mimics the behavior of a swarm of salps in nature [6]. Salps are aquatic creatures with a resemblance to the jellyfish’s transparent body, however, with a distinctive barrel body shape. In deep oceans, salps exist in swarms known as salp chains. The swarming nature of salps is evident as they form collaborative chains during foraging activities in the deep ocean. Swarming of salps is believed to aid in gaining kinetic energy as they pursue a moving food source.In electrical engineering, practical optimization problems such HESS control involve determining the optimal parameters based on one or more linear/nonlinear equality/inequality constraints [7]. Implementation of stochastic optimization methods has become popular in the field. The salp swarm algorithm has been used in parameter identification for electrical engineering optimization problems and proven to outperform other methods in terms of accuracy while maintaining prediction stability. However, SSA has similar limitations to other metaheuristic algorithms such as slow convergence due to its low exploitation ability [8].In the case of real-time optimization problems, fuzzy control has predominantly been adopted ensuing from the necessity of speed in these operations. This method compromises on performance for speed. Fuzzy control is also rigid as logic rules have to be preemptively defined for varying working conditions. Contrast to this, metaheuristic algorithms are generally slower. Nevertheless, these algorithms have been proven to have significant performance lead whilst being versatile and pliable to the nature and conditions of the problem.This paper proposes Master-Slave Salp Swarm Optimizer for real-time optimization of HESS control strategy of pure EVs. In computing, the term master slave was adopted referring to the asymmetric control/communication models. In this model, devices or processes are grouped into one master and several slave groups. The master controls one or more processes or devices (known as slaves) and acts as a communication hub between the slaves [9]. Introducing a master-slave approach to the optimization algorithm is endeavored towards improving the ability to maintain balance between the exploration and exploitation phases of the SSA, thus improving its ability to skip local optimum points reaching the global optimum solution faster by eliminating trap solutions [10, 11]. By implementing an improved adaptive power distribution learning algorithm in a simulated environment, the theoretical minimum energy consumption from a management and control system for a HESS can be calculated [12].


## 2. Literature Review

The concept of design and implementation of electric vehicles dates back a hundred years ago. A major roadblock to commercial production and application of electric vehicles has been their range limitation [2]. To overcome this limitation, the development of hybrid vehicles began in the early 2000s. However, in the late 2000s, improvement in battery manufacturing technology has seen the concept of pure electric vehicles, augmented from experimental to a reality and future of the motor industry [13].Pure electric vehicles existing today have a practical range of about 160 km to 600 km, which is a significant surge [14] but still insufficient to contend with combustion engine vehicle sufficiency. To achieve this, the application of HESS in EVs was explored [1]. HESS are composed of two or more types of energy storage devices/technologies that complement each other (typically batteries and capacitors) [15]. Their complementary nature enables them to outperform any conventional single component energy storage device such as batteries, fuel cells, and super capacitors [16]. Improving this range not only hinges to further enhancement of energy storage systems in electric vehicles but also the management and control of energy distribution for the best efficiency in different working conditions.Composite power supply structures (HESS) are commonly classified under three categories. These include active, semiactive, and passive [15]. Active composite power supply consists of two integrated DC/DC converters serially connected with batteries and capacitors. For passive HESS, a battery and ultracapacitor are directly connected in parallel and the voltage of the two synchronized in real time. The energy distribution between the two is not adjustable, thus constant for full capacity and high-power output conditions. Semiactive HESS is a compromise between performance and cost having only one DC/DC converter with a variety of control strategies being applicable. Semiactive structures are of two types: battery end load and capacitor end load.With optimization in mind, a new battery/ultracapacitor HESS for electric vehicles was proposed [16, 17]. The system incorporates the use of a controlled energy pump in the form of a small DC/DC converter to keep the ultracapacitor’s voltage higher compared to the battery voltage in conventional urban drive conditions. For connections, a modulator takes the place of the DC/DC convertor, thus resolving the problem of large voltage fluxes emanating from the ultracapacitor power transmission. This system allows for energy control and optimization without affecting the performance of the drive motor [2].


### 2.1. HESS Energy Optimization

In an ideal situation, the input and output power of a system are equal; meaning, the change in acceleration of an electric vehicle directly reflects the change in power drawn from HESS [12]. Practically, lithium-ion batteries and ultracapacitors are used as electrical energy carriers with varying remaining stored energy in an ever-changing operating environment. The trend in energy consumed over working time has a close relationship with the operating mode, ambient temperature, and switching losses associated. Energy management strategy research is focused on the optimization of EV energy consumption without fundamentally changing the base components and the framework of HESS [18]. The proposed optimization in HESS is based on calculation of the suboptimal current to control it and minimize the working current and battery fluctuations in EVs. HESS energy optimization has further been represented as three optimization problems [1, 12, 19]:
(i)
Minimization of battery current fluctuation: high amount of fluctuations in the battery current magnitude causes an increase in the battery’s internal resistance. Consequently, this reduces the battery longevity(ii)
Minimization of energy loss in HESS due to ultracapacitor ESR that lowers the battery discharge time: as a result, extending the battery discharge phase depends on reducing energy loss(iii)
Dual-objective real-time minimization, for optimal performance: there is a need to minimize both battery current fluctuations and capacitor energy losses while meeting vehicle energy requirements in different working conditions


### 2.2. Fuzzy Control Strategy for HESS

HESS working has two states, charging and discharging. During the drive cycle, HESS devices are being alternately being discharged and charged [17], considering the regenerative braking which has been integrated in pure electric vehicles. Under different working conditions, the power demand is different and so is the control strategy formulation required [1]. The power demand can be split into two: peak power and average power. Since instantaneous high current discharge must be prevented, ultracapacitors are responsible for the peak power and average power drawn from lithium-ion batteries [15]. Ultracapacitors are also responsible for ensuring the maximum possible energy is recovered during braking.While the power demand is greater than 0, the HESS is discharging, and the control strategy follows that both the UC and battery are discharged at the same rate; however, the lithium-ion battery must also supply power to the ultracapacitor ensuring that it always has enough energy to meet peak power demand fluctuations [15, 16].
(i)
While the power demand is very small and the power stored in the battery is or moderate or higher, the battery discharges alone or separately where as if the power demand is small and the ultracapacitor stored energy is higher or moderate, both discharge together; otherwise, the battery discharges separately(ii)
While the power demand is moderate and both the battery and ultracapacitor stored energy are higher, both discharge together; otherwise, the lithium-ion battery discharges alone. If the battery energy is low, both the capacitor and battery discharge together(iii)
While the power demand is high and the battery stored energy and the capacitor energy are moderate or higher, both will discharge together. Otherwise, the capacitor will discharge separatelyWhile the power demand is less than 0, the HESS is in charging mode, and the control strategy is based on the residual capacities of the battery and ultracapacitor. The capacitor is charged as frequently as the battery, and the battery not only takes the input power required for the vehicle operation but also the input power of the ultracapacitor to ensure that enough energy is available to cope with large power fluctuations in the drive cycle. Typically, both are charged together; however, in conditions where a maximum amount of energy needs to be stored over a short period, i.e., in the case of regenerative braking, the ultracapacitor is charged separately [19].Management of flow energy from and to different sources separately was achieved by a combination of fuzzy control and shape control. Studies focused on an online predictive control strategy proposed a dual-loop online intelligent planning (DOIP) method for speed forecasting and energy control [13]. Optimal control behavior was thus determined by being able to learn the speed and acceleration of an electric vehicle under different conditions. Fuzzy control in electric vehicle HESS is used to set different control variables that control different components thus improving the energy efficiency by establishing a range of fuzzy logic/rules [18]. The rules can be grouped into a set of two: fuzzy control rules for the output power consumed in driving and fuzzy logic rules for power recovery when braking [12, 18].Fuzzy controllers have been essential in HESS control strategies as they are able to cover a number of constraints by incorporating multiple fuzzy logic rules. Optimization of these controllers, however, becomes complex considering the sheer number of parameters composed of boundaries and variables that constitute the logic rules [12]. This increases the time required for optimization significantly lending the application of metaheuristic optimization algorithms impractical or otherwise expensive considering the required compute power to speed up these computations to a fraction of a second.


### 2.3. Algorithm Optimization

Applying algorithm optimization requires the problem to be modelled mathematically [7]. Optimization is the process for training the model iteratively to result in a minimum and maximum function evaluation. Optimization algorithms are split into two phases: exploration phase and exploitation phase [11]. In the exploration phase, the solutions are gravitated towards the different regions of the problem search space by sudden changes. This is aimed at identifying promising areas in the search space and to avoid local solutions. In the exploitation phase, the goal is to improve the accuracy by gradually changing solutions [20]. The results of every iteration are compared by changing the hyperparameters until an optimum result is achieved. Maxima is the largest value of a function and minima the smallest value within a given range. A global maxima and minima are the maximum and minimum values of a function, respectively, in the entire domain of a given function, where as local maxima and minima are given for a function within a particular range. There can only be one global maxima and global minima but more than one local maximum and minima.Gradient descent is an optimization algorithm that finds out the local minima of a differentiable function. It minimizes a given function based on the learning rate. Learning rate is a hyperparameter determining the step size at each iteration while moving towards the minima of a function. Gradient descent has high time complexity, thus the need for implementation of stochastic gradient descent. Stochastic stands for probabilistic; therefore, random points from a population are selected, reducing the time complexity and allowing for faster convergence [20]. Metaheuristic algorithms such as the SSA discussed in this paper fall under this classification.


### 2.4. Salp Swarm Algorithm

The salp swarm algorithm (SSA) proposed by Mirjalili et al. in 2017 mimics the behavior of a swarm of salps in nature. Salps are aquatic creatures with a resemblance to the jellyfish’s transparent body, however, are barrel shaped. In deep oceans, salps exist in swarms known as salp chains as illustrated in Figure1. The swarming nature of salps is evident as they form collaborative chains during foraging activities in the deep ocean. Swarming of salps is believed to aid in gaining kinetic energy as they pursue a moving food source [6].Figure 1
Salp (a). Salp chain (b).In mathematical modelling, the salp chain is divided into two: leader and the rest are followers. The position of a salp is defined in a search space of dimensiond, where d is defined as the number of variables for a given problem. The swarms’ target is a food source expressed as F. The leader attacks in the direction of F and the followers update their position towards the rest of the salps or the leader either directly or indirectly. A salp chain, X, in dimension d consists of N number of agents and can thus be expressed in a matrix form of N∗d(1)Xi=x11x21⋯xd1x12x22⋯xd2∙∙∙∙∙⋯∙∙∙∙x1Nx2N⋯xdN.The leader updates its position in thej-th dimension, Xj1, according to the equation below:
(2)Xj1=Fj+c1ubj+lbjc2+lbjC3≥0.5Fj−c1ubj−lbjc2+lbjC3<0.5,where Fj is the position vector of the food source, ubj is the superior limit of the j-th dimension, lbj is the inferior limit of the j-th dimension, and c1 and c2 are random values in the range {0-1}. The main parameter of the algorithm is c1, expressed as
(3)c1=2e−4lLmax2,with l being the number of the current iteration, and Lmax is the maximum number of iterations. The followers’ position is updated utilizing Newton’s laws of motion:
(4)xji=12at2+v0t.Witha=vfin/v0 where v0=initialspeed and v is expressed as v=x−x0/t considering v0=0 and the discrepancy between iterations to be 1, the above expression can be written as
(5)xji=xji+xji−12,where i≥2. From these equations, a salp chain is simulated.The SSA pseudocode, Algorithm1 starts by initiating multiple salps with random positions and calculates the fitness of each to find the one with the highest fitness and assigns it to F. The leader will then be iteratively followed by the chain of salps using equation (v); meanwhile, c1 is updated by equation (3) for each iteration, and equation (2) updates the leader’s position till the last iteration [6].Algorithm 1: SSA Algorithm pseudocode.
Initialize the salp population xi (i=1, 2, ..., n) considering ub and lbwhile (end condition is not satisfied)Calculate the fitness of each search agent (salp)F=the best search agentUpdate c1 by Eq. (iii)for each salp (xi)if (i= =1)Update the position of the leading salp by Eq. (ii)elseUpdate the position of the follower salp by Eq. (v)endendAmend the salps based on the upper and lower bounds of variablesendreturn F


## 2.1. HESS Energy Optimization

In an ideal situation, the input and output power of a system are equal; meaning, the change in acceleration of an electric vehicle directly reflects the change in power drawn from HESS [12]. Practically, lithium-ion batteries and ultracapacitors are used as electrical energy carriers with varying remaining stored energy in an ever-changing operating environment. The trend in energy consumed over working time has a close relationship with the operating mode, ambient temperature, and switching losses associated. Energy management strategy research is focused on the optimization of EV energy consumption without fundamentally changing the base components and the framework of HESS [18]. The proposed optimization in HESS is based on calculation of the suboptimal current to control it and minimize the working current and battery fluctuations in EVs. HESS energy optimization has further been represented as three optimization problems [1, 12, 19]:
(i)
Minimization of battery current fluctuation: high amount of fluctuations in the battery current magnitude causes an increase in the battery’s internal resistance. Consequently, this reduces the battery longevity(ii)
Minimization of energy loss in HESS due to ultracapacitor ESR that lowers the battery discharge time: as a result, extending the battery discharge phase depends on reducing energy loss(iii)
Dual-objective real-time minimization, for optimal performance: there is a need to minimize both battery current fluctuations and capacitor energy losses while meeting vehicle energy requirements in different working conditions


## 2.2. Fuzzy Control Strategy for HESS

HESS working has two states, charging and discharging. During the drive cycle, HESS devices are being alternately being discharged and charged [17], considering the regenerative braking which has been integrated in pure electric vehicles. Under different working conditions, the power demand is different and so is the control strategy formulation required [1]. The power demand can be split into two: peak power and average power. Since instantaneous high current discharge must be prevented, ultracapacitors are responsible for the peak power and average power drawn from lithium-ion batteries [15]. Ultracapacitors are also responsible for ensuring the maximum possible energy is recovered during braking.While the power demand is greater than 0, the HESS is discharging, and the control strategy follows that both the UC and battery are discharged at the same rate; however, the lithium-ion battery must also supply power to the ultracapacitor ensuring that it always has enough energy to meet peak power demand fluctuations [15, 16].
(i)
While the power demand is very small and the power stored in the battery is or moderate or higher, the battery discharges alone or separately where as if the power demand is small and the ultracapacitor stored energy is higher or moderate, both discharge together; otherwise, the battery discharges separately(ii)
While the power demand is moderate and both the battery and ultracapacitor stored energy are higher, both discharge together; otherwise, the lithium-ion battery discharges alone. If the battery energy is low, both the capacitor and battery discharge together(iii)
While the power demand is high and the battery stored energy and the capacitor energy are moderate or higher, both will discharge together. Otherwise, the capacitor will discharge separatelyWhile the power demand is less than 0, the HESS is in charging mode, and the control strategy is based on the residual capacities of the battery and ultracapacitor. The capacitor is charged as frequently as the battery, and the battery not only takes the input power required for the vehicle operation but also the input power of the ultracapacitor to ensure that enough energy is available to cope with large power fluctuations in the drive cycle. Typically, both are charged together; however, in conditions where a maximum amount of energy needs to be stored over a short period, i.e., in the case of regenerative braking, the ultracapacitor is charged separately [19].Management of flow energy from and to different sources separately was achieved by a combination of fuzzy control and shape control. Studies focused on an online predictive control strategy proposed a dual-loop online intelligent planning (DOIP) method for speed forecasting and energy control [13]. Optimal control behavior was thus determined by being able to learn the speed and acceleration of an electric vehicle under different conditions. Fuzzy control in electric vehicle HESS is used to set different control variables that control different components thus improving the energy efficiency by establishing a range of fuzzy logic/rules [18]. The rules can be grouped into a set of two: fuzzy control rules for the output power consumed in driving and fuzzy logic rules for power recovery when braking [12, 18].Fuzzy controllers have been essential in HESS control strategies as they are able to cover a number of constraints by incorporating multiple fuzzy logic rules. Optimization of these controllers, however, becomes complex considering the sheer number of parameters composed of boundaries and variables that constitute the logic rules [12]. This increases the time required for optimization significantly lending the application of metaheuristic optimization algorithms impractical or otherwise expensive considering the required compute power to speed up these computations to a fraction of a second.


## 2.3. Algorithm Optimization

Applying algorithm optimization requires the problem to be modelled mathematically [7]. Optimization is the process for training the model iteratively to result in a minimum and maximum function evaluation. Optimization algorithms are split into two phases: exploration phase and exploitation phase [11]. In the exploration phase, the solutions are gravitated towards the different regions of the problem search space by sudden changes. This is aimed at identifying promising areas in the search space and to avoid local solutions. In the exploitation phase, the goal is to improve the accuracy by gradually changing solutions [20]. The results of every iteration are compared by changing the hyperparameters until an optimum result is achieved. Maxima is the largest value of a function and minima the smallest value within a given range. A global maxima and minima are the maximum and minimum values of a function, respectively, in the entire domain of a given function, where as local maxima and minima are given for a function within a particular range. There can only be one global maxima and global minima but more than one local maximum and minima.Gradient descent is an optimization algorithm that finds out the local minima of a differentiable function. It minimizes a given function based on the learning rate. Learning rate is a hyperparameter determining the step size at each iteration while moving towards the minima of a function. Gradient descent has high time complexity, thus the need for implementation of stochastic gradient descent. Stochastic stands for probabilistic; therefore, random points from a population are selected, reducing the time complexity and allowing for faster convergence [20]. Metaheuristic algorithms such as the SSA discussed in this paper fall under this classification.


## 2.4. Salp Swarm Algorithm

The salp swarm algorithm (SSA) proposed by Mirjalili et al. in 2017 mimics the behavior of a swarm of salps in nature. Salps are aquatic creatures with a resemblance to the jellyfish’s transparent body, however, are barrel shaped. In deep oceans, salps exist in swarms known as salp chains as illustrated in Figure1. The swarming nature of salps is evident as they form collaborative chains during foraging activities in the deep ocean. Swarming of salps is believed to aid in gaining kinetic energy as they pursue a moving food source [6].Figure 1
Salp (a). Salp chain (b).In mathematical modelling, the salp chain is divided into two: leader and the rest are followers. The position of a salp is defined in a search space of dimensiond, where d is defined as the number of variables for a given problem. The swarms’ target is a food source expressed as F. The leader attacks in the direction of F and the followers update their position towards the rest of the salps or the leader either directly or indirectly. A salp chain, X, in dimension d consists of N number of agents and can thus be expressed in a matrix form of N∗d(1)Xi=x11x21⋯xd1x12x22⋯xd2∙∙∙∙∙⋯∙∙∙∙x1Nx2N⋯xdN.The leader updates its position in thej-th dimension, Xj1, according to the equation below:
(2)Xj1=Fj+c1ubj+lbjc2+lbjC3≥0.5Fj−c1ubj−lbjc2+lbjC3<0.5,where Fj is the position vector of the food source, ubj is the superior limit of the j-th dimension, lbj is the inferior limit of the j-th dimension, and c1 and c2 are random values in the range {0-1}. The main parameter of the algorithm is c1, expressed as
(3)c1=2e−4lLmax2,with l being the number of the current iteration, and Lmax is the maximum number of iterations. The followers’ position is updated utilizing Newton’s laws of motion:
(4)xji=12at2+v0t.Witha=vfin/v0 where v0=initialspeed and v is expressed as v=x−x0/t considering v0=0 and the discrepancy between iterations to be 1, the above expression can be written as
(5)xji=xji+xji−12,where i≥2. From these equations, a salp chain is simulated.The SSA pseudocode, Algorithm1 starts by initiating multiple salps with random positions and calculates the fitness of each to find the one with the highest fitness and assigns it to F. The leader will then be iteratively followed by the chain of salps using equation (v); meanwhile, c1 is updated by equation (3) for each iteration, and equation (2) updates the leader’s position till the last iteration [6].Algorithm 1: SSA Algorithm pseudocode.
Initialize the salp population xi (i=1, 2, ..., n) considering ub and lbwhile (end condition is not satisfied)Calculate the fitness of each search agent (salp)F=the best search agentUpdate c1 by Eq. (iii)for each salp (xi)if (i= =1)Update the position of the leading salp by Eq. (ii)elseUpdate the position of the follower salp by Eq. (v)endendAmend the salps based on the upper and lower bounds of variablesendreturn F


## 3. Methodology

### 3.1. Master-Slave Salp Swarm Algorithm

This paper proposes the master-slave salp swarm algorithm, Algorithm2 following the SSA nature; however, the salp population is split into a master and slave population based on fitness such that the top half forms the master population and the bottom half, the slave population. Each slave salp learns from a salp in the master population [9]. The selection of these pairs is randomized where the slaves learn from the master population based on the learning equation were (Lq) expressed below:
(6)Lq=r1∗Xm−Xsc1,where r1 is the random variable [0, 1], Xm is the master salp position, and Xs is the slave salp position.Algorithm 2: MSSSA pseudocode.
Initialize the salp population xi (i=1, 2, ..., n) considering ub and lbwhile (end condition is not satisfied)Calculate the fitness of each search agent (salp)Sort the salps in ascending order of fitness and make the bottom half the slave population.The slave population learn from the master population by equations (vi) and (vii)F=the best search agentUpdate c1 by Eq. (iii)for each salp (xi)if (i= =1)Update the position of the leading salp by Eq. (ii)elseUpdate the position of the follower salp by Eq. (v)endendAmend the salps based on the upper and lower bounds of variablesendreturn Fc1=2e−4l/Lmax, where l is the current iteration, and Lmax is the maximum iterations.The slaves are updated by the equation:(7)Xs=Xm−Lq.The novelty of master-slave learning approach improves the exploitation phase of the SSA thus improving the convergence relative to the number of iterations. This is presumed to improve the relative performance of the SSA, however, runs the risk of limiting the algorithms exploration phase while still slightly increasing its complexity in terms of number of operations. A flowchart of the MSSSA is illustrated in Figure2.Figure 2
Master-slave salp swarm algorithm flowchart.With coefficientsr1 and c1 in the learning equation, Lq provides a random generally decreasing learning rate which is aimed at maintaining a balance between the exploration and exploitation phase of MS-SSA. These two features improve the algorithms performance over the others, especially where the luxury of high number of iterations cannot be afforded.


### 3.2. HESS Modeling

To test the viability of the MSSSA in the real-time optimization of energy distribution for HEES in electric vehicles, a basic model of the system is illustrated in Figure3.Figure 3
A basic EV HESS model.The hybrid energy storage system consists of a lithium-ion battery module in parallel with an ultracapacitor module [16]. Lithium-ion batteries have high storage capacity, hence favorable in powering electric vehicles today. However, lithium-ion batteries degrade with usage over time, and this is accelerated by fast discharging or charging over short periods of time [15]. Drawing large amounts of current may lead to overheating and thus the need for current regulation. Ultracapacitors on the other hand have limited capacity but have the advantage of having very fast charging and discharge time without degrading. The incorporation of HESS in EVs is aimed at seizing the advantages of both to supply sufficient power required in a driving cycle while minimizing battery degradation [1]. Drawn from this knowledge, a suitable control strategy is modeled as in Figure 4 below.Figure 4
HESS control strategy block diagram.


#### 3.2.1. Battery Model

Typically, EV battery module consists of a number of cells connected in series and parallel. The result is a high voltage, high-capacity module ranging from 200 V to 500 V and 20 kWh to 100 kWh. A simple model adapted consists of the battery as a voltage source and its internal resistance serially connected [21]. The voltage output depends on the state of charge as illustrated in (Figure 5).Figure 5
Li-ion battery discharge voltage curve.The SOC (state of charge) of the battery is given by the expression(8)SOCbat=QbatQn=QbatQinitial∗SOCbatinitial,where Qbat is the current amount of energy stored in the battery module, and Qn is the nominal capacity of the battery module. The battery voltage Vbat at 90% to 15% is approximated with the relation
(9)Vbat=Vbat−∆SOCbat∗K,where K is a constant of approximate value 0.0007.Current drawn (Ibat) is calculated where a given load Pbat is applied to the terminals such that the total power drawn from the battery is expressed by
(10)Vbat∗Ibat=Ibat2∗Rbat+Pbat,where Rbat is the battery’s internal resistance.Solving forIbat from equation (10) results in a quadratic equation expressed as
(11)Ibat=Vbat±Vbat2−4Rbat−Pb2Rb.


#### 3.2.2. Ultracapacitor Model

Ultracapacitors have much higher capacitance (about 400 F in EV HESS) compared to typical capacitors with low voltage limits at about 3 V per capacitor [22]. They have the advantage of storing significantly large amounts of energy per unit volume compared to electrolytic capacitors with higher charge and discharge power. They have very long-life cycles; hence, life decay can be neglected in the implementation of UCs (ultracapacitors) to store charge in EVs [18].The voltage at the ultracapacitor terminals varies linearly with its state of charge. This voltage can be calculated from the energy stored in the UC and the capacitance by(12)Vuc=0.5∗QucCuc+0.25∗QucCuc2−Puc∗Ruc,where Quc is energy stored by the UC, Cuc is the capacitance of the UC module, Puc is the capacitor load, and Ruc is the UC modules internal Resistance.Given that UCs are applied where large power is required over a short period of time, the current drawn can be approximated neglecting the internal resistance of the module (equation (5)).
(13)Iuc=PucVuc.State of charge of the UC is calculated as(14)SOCuc=QucQucn=QucQucinit∗SOCucinit.


### 3.3. Objective Modelling

Control and optimization of HESS in EVs are achieved by a controller whose functions include energy demand distribution between the UC and battery modules, charge, and discharge rate regulation to enhance the battery’s life cycle and minimization of energy loss in the system [1].During vehicle operations, the power required is determined from the vehicles’ mass, acceleration, drag, and losses in the mechanical system driving the vehicle [23]. Aerodynamic drag is one of the major inhibitions to acceleration through air and is expressed as
(15)Drag=Cd∗ρ∗v22∗A,where Cd is the drag coefficient, approximately, ρ is the air density, v is the vehicles velocity, and A is the reference area.During acceleration, the force required is given by(16)F=m∗a,where m is the mass of the vehicle, and a is its desired acceleration.With efficiency of the system as ἠ, the energy demand can thus be calculated by multiplying the sum ofF and drag with velocity and time. Over a period of 1 sec, Edemand is expressed by
(17)Edemand=m∗at+Cd∗ρ∗vt22∗A∗vt∗ἠ.This energy demand has to be met by the sum of the battery power and UC power. Taking a period time of 1 sec, the energy demand (Edemand) is equal to the sum of Pbat and Puc, ignoring the system’s losses.
(18)Edemand=Pbat+Puc.Outputs of the battery and ultracapacitor depend on the SOC of the battery/UC and the power demand such that the current limits of the battery are not exceeded [12]. To describe this, the energy distribution factors Kbat and Kuc were proposed as follows [12]:
(19)Pbat=Kbat∗Edemand,Puc=Kuc∗Edemand,Kuc=1−Kbat.The mathematical model of the objective function is described as(20)miny=fx.With energy consumption per unit distance as the evaluation standard, it is expressed as(21)fx=fitness=energydistance.Consumption of energy in HESS is composed pf various components including motor losses, line losses, DC/DC converter loss, capacitor, and battery losses. The main losses considered for optimization are the capacitor and battery losses, i.e.,(22)Energy=Pbat+Puc+Ebatl+Eucl,Ebatl=Ibat2t∗Rbat,Eucl=Iuc2t∗Ruc.Pbat and Puc represent the output power of the battery and the ultracapacitor, respectively, with Ebatl and Eucl, representing the losses due to the battery and ultracapacitor, respectively. These are calculated from the working currents of the HESS components as shown (6) above.The algorithm optimization function can be concisely expressed as(23)fx=fitness=Ebat+Eucdistance,where Ebat is the energy drawn from the battery with battery loss considered, and Euc is the energy drawn from the UC with UC loss considered.With the assumption that when SOC of the battery and UC are both high, i.e., close to 1, SOC has little to no impact on the energy distribution between the battery and the UC. Consequently, the only constraint is the current limits, and the optimization objective constraints are(24)Ibat,min≤Ibat≤Ibat,max,Iuc,min≤Iuc≤Iuc,4Rb∗Puc≤Vbat2.The optimization objective thus can be expressed as(25)Econ=min∑Ebatt+Euct,where
(26)Ebat=Ibatt∗Vbatt∗cosθbt+Rbat,(27)Euc=Iuct∗Vuct∗cosθuct+Ruc.θb and θuc are the current phase angle of the currents Ibat and Iuc, respectively.


## 3.1. Master-Slave Salp Swarm Algorithm

This paper proposes the master-slave salp swarm algorithm, Algorithm2 following the SSA nature; however, the salp population is split into a master and slave population based on fitness such that the top half forms the master population and the bottom half, the slave population. Each slave salp learns from a salp in the master population [9]. The selection of these pairs is randomized where the slaves learn from the master population based on the learning equation were (Lq) expressed below:
(6)Lq=r1∗Xm−Xsc1,where r1 is the random variable [0, 1], Xm is the master salp position, and Xs is the slave salp position.Algorithm 2: MSSSA pseudocode.
Initialize the salp population xi (i=1, 2, ..., n) considering ub and lbwhile (end condition is not satisfied)Calculate the fitness of each search agent (salp)Sort the salps in ascending order of fitness and make the bottom half the slave population.The slave population learn from the master population by equations (vi) and (vii)F=the best search agentUpdate c1 by Eq. (iii)for each salp (xi)if (i= =1)Update the position of the leading salp by Eq. (ii)elseUpdate the position of the follower salp by Eq. (v)endendAmend the salps based on the upper and lower bounds of variablesendreturn Fc1=2e−4l/Lmax, where l is the current iteration, and Lmax is the maximum iterations.The slaves are updated by the equation:(7)Xs=Xm−Lq.The novelty of master-slave learning approach improves the exploitation phase of the SSA thus improving the convergence relative to the number of iterations. This is presumed to improve the relative performance of the SSA, however, runs the risk of limiting the algorithms exploration phase while still slightly increasing its complexity in terms of number of operations. A flowchart of the MSSSA is illustrated in Figure2.Figure 2
Master-slave salp swarm algorithm flowchart.With coefficientsr1 and c1 in the learning equation, Lq provides a random generally decreasing learning rate which is aimed at maintaining a balance between the exploration and exploitation phase of MS-SSA. These two features improve the algorithms performance over the others, especially where the luxury of high number of iterations cannot be afforded.


## 3.2. HESS Modeling

To test the viability of the MSSSA in the real-time optimization of energy distribution for HEES in electric vehicles, a basic model of the system is illustrated in Figure3.Figure 3
A basic EV HESS model.The hybrid energy storage system consists of a lithium-ion battery module in parallel with an ultracapacitor module [16]. Lithium-ion batteries have high storage capacity, hence favorable in powering electric vehicles today. However, lithium-ion batteries degrade with usage over time, and this is accelerated by fast discharging or charging over short periods of time [15]. Drawing large amounts of current may lead to overheating and thus the need for current regulation. Ultracapacitors on the other hand have limited capacity but have the advantage of having very fast charging and discharge time without degrading. The incorporation of HESS in EVs is aimed at seizing the advantages of both to supply sufficient power required in a driving cycle while minimizing battery degradation [1]. Drawn from this knowledge, a suitable control strategy is modeled as in Figure 4 below.Figure 4
HESS control strategy block diagram.


### 3.2.1. Battery Model

Typically, EV battery module consists of a number of cells connected in series and parallel. The result is a high voltage, high-capacity module ranging from 200 V to 500 V and 20 kWh to 100 kWh. A simple model adapted consists of the battery as a voltage source and its internal resistance serially connected [21]. The voltage output depends on the state of charge as illustrated in (Figure 5).Figure 5
Li-ion battery discharge voltage curve.The SOC (state of charge) of the battery is given by the expression(8)SOCbat=QbatQn=QbatQinitial∗SOCbatinitial,where Qbat is the current amount of energy stored in the battery module, and Qn is the nominal capacity of the battery module. The battery voltage Vbat at 90% to 15% is approximated with the relation
(9)Vbat=Vbat−∆SOCbat∗K,where K is a constant of approximate value 0.0007.Current drawn (Ibat) is calculated where a given load Pbat is applied to the terminals such that the total power drawn from the battery is expressed by
(10)Vbat∗Ibat=Ibat2∗Rbat+Pbat,where Rbat is the battery’s internal resistance.Solving forIbat from equation (10) results in a quadratic equation expressed as
(11)Ibat=Vbat±Vbat2−4Rbat−Pb2Rb.


### 3.2.2. Ultracapacitor Model

Ultracapacitors have much higher capacitance (about 400 F in EV HESS) compared to typical capacitors with low voltage limits at about 3 V per capacitor [22]. They have the advantage of storing significantly large amounts of energy per unit volume compared to electrolytic capacitors with higher charge and discharge power. They have very long-life cycles; hence, life decay can be neglected in the implementation of UCs (ultracapacitors) to store charge in EVs [18].The voltage at the ultracapacitor terminals varies linearly with its state of charge. This voltage can be calculated from the energy stored in the UC and the capacitance by(12)Vuc=0.5∗QucCuc+0.25∗QucCuc2−Puc∗Ruc,where Quc is energy stored by the UC, Cuc is the capacitance of the UC module, Puc is the capacitor load, and Ruc is the UC modules internal Resistance.Given that UCs are applied where large power is required over a short period of time, the current drawn can be approximated neglecting the internal resistance of the module (equation (5)).
(13)Iuc=PucVuc.State of charge of the UC is calculated as(14)SOCuc=QucQucn=QucQucinit∗SOCucinit.


## 3.2.1. Battery Model

Typically, EV battery module consists of a number of cells connected in series and parallel. The result is a high voltage, high-capacity module ranging from 200 V to 500 V and 20 kWh to 100 kWh. A simple model adapted consists of the battery as a voltage source and its internal resistance serially connected [21]. The voltage output depends on the state of charge as illustrated in (Figure 5).Figure 5
Li-ion battery discharge voltage curve.The SOC (state of charge) of the battery is given by the expression(8)SOCbat=QbatQn=QbatQinitial∗SOCbatinitial,where Qbat is the current amount of energy stored in the battery module, and Qn is the nominal capacity of the battery module. The battery voltage Vbat at 90% to 15% is approximated with the relation
(9)Vbat=Vbat−∆SOCbat∗K,where K is a constant of approximate value 0.0007.Current drawn (Ibat) is calculated where a given load Pbat is applied to the terminals such that the total power drawn from the battery is expressed by
(10)Vbat∗Ibat=Ibat2∗Rbat+Pbat,where Rbat is the battery’s internal resistance.Solving forIbat from equation (10) results in a quadratic equation expressed as
(11)Ibat=Vbat±Vbat2−4Rbat−Pb2Rb.


## 3.2.2. Ultracapacitor Model

Ultracapacitors have much higher capacitance (about 400 F in EV HESS) compared to typical capacitors with low voltage limits at about 3 V per capacitor [22]. They have the advantage of storing significantly large amounts of energy per unit volume compared to electrolytic capacitors with higher charge and discharge power. They have very long-life cycles; hence, life decay can be neglected in the implementation of UCs (ultracapacitors) to store charge in EVs [18].The voltage at the ultracapacitor terminals varies linearly with its state of charge. This voltage can be calculated from the energy stored in the UC and the capacitance by(12)Vuc=0.5∗QucCuc+0.25∗QucCuc2−Puc∗Ruc,where Quc is energy stored by the UC, Cuc is the capacitance of the UC module, Puc is the capacitor load, and Ruc is the UC modules internal Resistance.Given that UCs are applied where large power is required over a short period of time, the current drawn can be approximated neglecting the internal resistance of the module (equation (5)).
(13)Iuc=PucVuc.State of charge of the UC is calculated as(14)SOCuc=QucQucn=QucQucinit∗SOCucinit.


## 3.3. Objective Modelling

Control and optimization of HESS in EVs are achieved by a controller whose functions include energy demand distribution between the UC and battery modules, charge, and discharge rate regulation to enhance the battery’s life cycle and minimization of energy loss in the system [1].During vehicle operations, the power required is determined from the vehicles’ mass, acceleration, drag, and losses in the mechanical system driving the vehicle [23]. Aerodynamic drag is one of the major inhibitions to acceleration through air and is expressed as
(15)Drag=Cd∗ρ∗v22∗A,where Cd is the drag coefficient, approximately, ρ is the air density, v is the vehicles velocity, and A is the reference area.During acceleration, the force required is given by(16)F=m∗a,where m is the mass of the vehicle, and a is its desired acceleration.With efficiency of the system as ἠ, the energy demand can thus be calculated by multiplying the sum ofF and drag with velocity and time. Over a period of 1 sec, Edemand is expressed by
(17)Edemand=m∗at+Cd∗ρ∗vt22∗A∗vt∗ἠ.This energy demand has to be met by the sum of the battery power and UC power. Taking a period time of 1 sec, the energy demand (Edemand) is equal to the sum of Pbat and Puc, ignoring the system’s losses.
(18)Edemand=Pbat+Puc.Outputs of the battery and ultracapacitor depend on the SOC of the battery/UC and the power demand such that the current limits of the battery are not exceeded [12]. To describe this, the energy distribution factors Kbat and Kuc were proposed as follows [12]:
(19)Pbat=Kbat∗Edemand,Puc=Kuc∗Edemand,Kuc=1−Kbat.The mathematical model of the objective function is described as(20)miny=fx.With energy consumption per unit distance as the evaluation standard, it is expressed as(21)fx=fitness=energydistance.Consumption of energy in HESS is composed pf various components including motor losses, line losses, DC/DC converter loss, capacitor, and battery losses. The main losses considered for optimization are the capacitor and battery losses, i.e.,(22)Energy=Pbat+Puc+Ebatl+Eucl,Ebatl=Ibat2t∗Rbat,Eucl=Iuc2t∗Ruc.Pbat and Puc represent the output power of the battery and the ultracapacitor, respectively, with Ebatl and Eucl, representing the losses due to the battery and ultracapacitor, respectively. These are calculated from the working currents of the HESS components as shown (6) above.The algorithm optimization function can be concisely expressed as(23)fx=fitness=Ebat+Eucdistance,where Ebat is the energy drawn from the battery with battery loss considered, and Euc is the energy drawn from the UC with UC loss considered.With the assumption that when SOC of the battery and UC are both high, i.e., close to 1, SOC has little to no impact on the energy distribution between the battery and the UC. Consequently, the only constraint is the current limits, and the optimization objective constraints are(24)Ibat,min≤Ibat≤Ibat,max,Iuc,min≤Iuc≤Iuc,4Rb∗Puc≤Vbat2.The optimization objective thus can be expressed as(25)Econ=min∑Ebatt+Euct,where
(26)Ebat=Ibatt∗Vbatt∗cosθbt+Rbat,(27)Euc=Iuct∗Vuct∗cosθuct+Ruc.θb and θuc are the current phase angle of the currents Ibat and Iuc, respectively.


## 4. Data Collection

### 4.1. Benchmark Functions

To analyze the performance of the MSSSA, it is essential to collect its performance data and that of standard metaheuristic optimization algorithms such as PSO, DA, GA, and WOA.A comprehensive evaluation of the MSSSA on continuous domain problems is given by testing on a set of 23 benchmark functions. These functions are classified into three:(i)
Unimodal functions (F1-F7), which are high-dimensional functions with only one global minimum, thus relatively easier to solve compared to the rest of the test functions(ii)
High-dimensional multimodal functions (F8-F13) which have a number of local minima, thus the most difficult to solve(iii)
Low-dimensional multimodal functions (F14-F23) which have a smaller number of dimensions, thus fewer local minima compared to high-dimensional test functions [24]The best scores of the selected algorithms were collected for each of the twenty-three standard benchmark functions over ten independent runs. The average score and standard deviation are then calculated to provide a comparison metric for the algorithm’s performance.For fair comparison of the selected algorithms and the inclusion of high-dimensional multimodal functions, a high number of search agents and iterations are required [6] and for these tests which are given as
(i)
No.ofsearchagents=60(ii)
Maximumiterations=1000Since they are stochastic algorithms, results obtained may significantly vary on every run. Performance can only be comparatively analyzed over a significant number of runs [6, 10, 11], for this study.
(iii)
Numberof=1000


### 4.2. Dynamic Programing for HESS in EVs

Optimization of EV HESS control is a multistage decision-making problem, and these problems are split into subproblems solved consecutively in discrete time. To obtain the best control performance and compare the performances more accurately, dynamic programming is used for benchmark evaluation [25].Theoretical minimum energy consumption over a period is calculated by simulating the energy demand for the HESS drive cycle. In this paper, to analyze the control strategy performance, the energy demand for a period of 120 seconds is generated from the speed and acceleration matrix as in Figure6.Figure 6
EV speed vs. time plot.The EV energy demand is calculated by equation (16) resulting in the plot Figure 7 below.Figure 7
EV energy demand vs. time plot.Optimization is done at every second instance as demand changes with time thus necessitating high speed performance for real time optimization. To minimize time taken for optimization, the max number iteration is set to 100, number of search agentsN=60, with the EV and HESS parameters given as follows:Vehiclemassm=3600kgDragcoefficientCd=0.208AirdensityDens=1.225kg/m3ReferenceareaArea=2.34m2UCcapacitanceCuc=400FBatteryvoltageVbat=350VCapacitorvoltageVuc=36VBatteryinternalresistanceRb=20000ΩUltracapacitorinternalresistanceRuc=700ΩInitialenergystoredinbatteryQbat=19800000000JInitialenergystoredinultracapacitorQuc=3600000JThe simulation is set for a minimal time duration since the SOC constraints have not been considered. To enforce current limitations, after initial optimization iteration, the battery current required is compared to the threshold maximum current from which the boundaries are adjusted as follows:Code 1
If Ibat>Ibat(max)ub=0.3elselb=0.9This is to ensure that energy from capacitors is only used to meet high power demand.Data on energy consumption and current distribution were collected for 10 runs of the simulated drive cycle to analyze the theoretical performance of the MSSSA for HESS control.


## 4.1. Benchmark Functions

To analyze the performance of the MSSSA, it is essential to collect its performance data and that of standard metaheuristic optimization algorithms such as PSO, DA, GA, and WOA.A comprehensive evaluation of the MSSSA on continuous domain problems is given by testing on a set of 23 benchmark functions. These functions are classified into three:(i)
Unimodal functions (F1-F7), which are high-dimensional functions with only one global minimum, thus relatively easier to solve compared to the rest of the test functions(ii)
High-dimensional multimodal functions (F8-F13) which have a number of local minima, thus the most difficult to solve(iii)
Low-dimensional multimodal functions (F14-F23) which have a smaller number of dimensions, thus fewer local minima compared to high-dimensional test functions [24]The best scores of the selected algorithms were collected for each of the twenty-three standard benchmark functions over ten independent runs. The average score and standard deviation are then calculated to provide a comparison metric for the algorithm’s performance.For fair comparison of the selected algorithms and the inclusion of high-dimensional multimodal functions, a high number of search agents and iterations are required [6] and for these tests which are given as
(i)
No.ofsearchagents=60(ii)
Maximumiterations=1000Since they are stochastic algorithms, results obtained may significantly vary on every run. Performance can only be comparatively analyzed over a significant number of runs [6, 10, 11], for this study.
(iii)
Numberof=1000


## 4.2. Dynamic Programing for HESS in EVs

Optimization of EV HESS control is a multistage decision-making problem, and these problems are split into subproblems solved consecutively in discrete time. To obtain the best control performance and compare the performances more accurately, dynamic programming is used for benchmark evaluation [25].Theoretical minimum energy consumption over a period is calculated by simulating the energy demand for the HESS drive cycle. In this paper, to analyze the control strategy performance, the energy demand for a period of 120 seconds is generated from the speed and acceleration matrix as in Figure6.Figure 6
EV speed vs. time plot.The EV energy demand is calculated by equation (16) resulting in the plot Figure 7 below.Figure 7
EV energy demand vs. time plot.Optimization is done at every second instance as demand changes with time thus necessitating high speed performance for real time optimization. To minimize time taken for optimization, the max number iteration is set to 100, number of search agentsN=60, with the EV and HESS parameters given as follows:Vehiclemassm=3600kgDragcoefficientCd=0.208AirdensityDens=1.225kg/m3ReferenceareaArea=2.34m2UCcapacitanceCuc=400FBatteryvoltageVbat=350VCapacitorvoltageVuc=36VBatteryinternalresistanceRb=20000ΩUltracapacitorinternalresistanceRuc=700ΩInitialenergystoredinbatteryQbat=19800000000JInitialenergystoredinultracapacitorQuc=3600000JThe simulation is set for a minimal time duration since the SOC constraints have not been considered. To enforce current limitations, after initial optimization iteration, the battery current required is compared to the threshold maximum current from which the boundaries are adjusted as follows:Code 1
If Ibat>Ibat(max)ub=0.3elselb=0.9This is to ensure that energy from capacitors is only used to meet high power demand.Data on energy consumption and current distribution were collected for 10 runs of the simulated drive cycle to analyze the theoretical performance of the MSSSA for HESS control.


## 5. Results, Analysis, and Discussion

In this section, the data collected based on the criterion specified in Section4 are given and analyzed based on performance metrics for optimization algorithms and HESS control. These tests were performed on a HP EliteBook Folio 1020 G1 with the following:
(i)
Intel(R) Core (TM) M-5Y71 CPU @ 1.20GHz (4 CPUs)(ii)
~1.4 GHz Processor(iii)
8192 MB RAMResults from the Benchmark tests were as summarised in Table1 below. Comparing the average scores for the test functions, the MSSSA outperforms the SSA in functions F2, F3, F5, F7, F8, F10, F11, F12, and F13. Both are seen to achieve the global minimum for test functions F16, F22, and F23.Table 1
Benchmark test function results.
MSSSASSAWOAGAMFOPSODASpheref1Best score4.98E-094.89E-091.23E-1891.80E+019.48E-064.30E-021.46E-02Worst score1.05E-081.31E-082.79E-1802.00E+011.00E+044.79E-011.01E+02Mean8.22E-097.64E-092.92E-1811.92E+012.00E+031.52E-011.45E+01Standard deviation1.64E-092.34E-090.00E+006.32E-014.22E+031.31E-013.14E+01Schwefel’s problem 2.22f2Best score4.77E-064.26E-065.93E-1231.40E+013.50E-201.81E-014.08E-01Worst score7.54E-061.25E-052.20E-1141.90E+012.55E-187.39E-013.92E+00Mean6.10E-066.95E-064.42E-1151.64E+014.57E-195.03E-011.92E+00Standard deviation9.15E-072.26E-069.18E-1151.84E+007.66E-191.43E-011.33E+00Schwefel’s problem 1.2f3Best score9.93E-105.90E-102.40E-092.20E+012.24E-133.65E+013.40E-03Worst score5.47E-101.98E-094.34E-012.50E+011.41E-098.70E+011.20E+00Mean8.68E-101.04E-091.04E-012.35E+012.51E-105.09E+011.98E-01Standard deviation3.92E-104.01E-101.59E-019.72E-014.78E-101.46E+013.62E-01Schwefel’s problem 2.21f4Best score9.92E-068.94E-060.00E+001.40E+011.61E-101.06E+001.97E-01Worst score1.92E-051.93E-053.00E+012.00E+011.48E-011.85E+007.95E+00Mean1.51E-051.32E-053.06E+001.57E+011.48E-021.34E+003.58E+00Standard deviation3.14E-062.97E-069.46E+001.89E+004.67E-022.68E-012.36E+00Generalized Rosenbrock’s functionf5Best score3.94E+003.45E+005.72E+000.00E+004.39E+009.88E+017.57E+00Worst score1.49E+031.43E+036.59E+000.00E+009.00E+044.82E+028.41E+02Mean1.78E+022.01E+026.01E+000.00E+009.61E+032.37E+021.92E+02Standard deviation4.65E+024.52E+022.60E-010.00E+002.83E+041.34E+022.76E+02Step functionf6Best score3.67E-102.96E-101.12E-044.35E+010.00E+003.98E-028.00E-04Worst score8.84E-108.77E-109.30E-065.55E+017.61E-313.51E-017.83E+00Mean5.97E-105.92E-105.20E-055.09E+011.18E-311.46E-018.79E-01Standard deviation1.69E-101.84E-103.50E-054.12E+002.34E-318.25E-022.45E+00Quadrtic function with noisef7Best score1.70E-031.10E-030.00E+002.10E+011.06E-036.20E-012.60E-03Worst score9.10E-039.50E-033.70E-032.58E+017.04E-032.49E+002.42E-02Mean4.07E-034.60E-039.30E-042.31E+012.23E-031.10E+001.03E-02Standard deviation2.28E-033.27E-031.13E-031.54E+001.85E-035.47E-016.07E-03Generalized Schwefel’s problem 2.26f8Best score-3.02E+03-3.42E+03-4.19E+03-9.26E+00-3.71E+03-7.73E+03-3.37E+00Worst score-2.27E+03-2.61E+03-2.50E+03-5.05E+00-2.76E+03-5.03E+03-2.13E+00Mean-2.72E+03-2.97E+03-3.39E+03-6.65E+00-3.36E+03-6.51E+03-2.70E+00Standard deviation2.29E+022.27E+025.39E+021.56E+003.23E+028.66E+023.40E-01Generalized Rastrigin’s functionf9Best score3.98E+002.98E+00NA2.65E+026.96E+005.83E+015.61E+00Worst score2.19E+013.18E+01NA2.65E+024.28E+011.35E+024.68E+01Mean1.53E+011.65E+01NA2.65E+022.06E+019.15E+012.60E+01Standard deviation5.57E+009.22E+00NA0.00E+001.11E+012.42E+011.37E+01Generalized Griewank functionf10Best score8.60E-067.57E-068.88E-160.00E+004.44E-152.23E-011.65E+00Worst score1.30E-052.32E+004.44E-150.00E+004.44E-151.62E+009.36E+00Mean1.11E-053.47E-013.02E-150.00E+004.44E-157.62E-013.66E+00Standard deviation1.21E-067.81E-011.83E-150.00E+008.32E-314.72E-012.34E+00Generalized penalized functionf11Best score7.13E-029.85E-020.00E+001.01E+003.45E-021.12E-028.62E-02Worst score4.90E-016.27E-012.45E-011.01E+002.83E-016.17E-029.00E-01Mean2.33E-012.50E-015.97E-021.01E+001.19E-012.97E-024.73E-01Standard deviation1.19E-011.64E-019.24E-022.53E-048.09E-021.49E-022.55E-01Generalized penalized functionf12Best score4.17E-123.75E-121.39E-063.22E+014.71E-322.00E-043.00E-04Worst score3.11E-016.22E-012.46E-053.22E+013.11E-011.70E-036.19E+00Mean3.11E-029.33E-029.79E-063.22E+016.22E-028.20E-041.56E+00Standard deviation9.83E-022.10E-017.30E-060.00E+001.31E-014.76E-041.79E+00Generalized penalized functionf13Best score1.82E-112.88E-110.00E+001.00E-011.35E-325.30E-032.48E-01Worst score6.11E-111.10E-021.10E-021.00E-011.10E-021.16E-018.36E+00Mean3.71E-112.20E-031.13E-031.00E-013.30E-033.62E-022.06E+00Standard deviation1.59E-114.63E-033.47E-031.46E-175.31E-033.27E-022.72E+00Shekel’s foxhole functionf14Best score9.98E-019.98E-019.98E-01NA9.98E-019.98E-019.98E-01Worst score9.98E-019.98E-012.98E+00NA1.99E+005.93E+009.98E-01Mean9.98E-019.98E-011.20E+00#DIV/0!1.10E+001.69E+009.98E-01Standard deviation0.00E+000.00E+006.27E-01#DIV/0!3.14E-011.55E+000.00E+00Shekel’s foxhole functionf15Best score3.84E-045.40E-043.00E-041.48E-017.11E-045.00E-047.00E-04Worst score8.07E-041.32E-037.00E-049.68E+027.83E-043.20E-038.30E-03Mean1.22E-031.76E-031.20E-039.68E+021.49E-039.80E-048.30E-03Standard deviation2.26E-043.57E-042.77E-044.07E+022.33E-048.00E-042.96E-03Six-hump camel back functionf16Best score-1.03E+00-1.03E+00-1.03E+000.00E+00-1.03E+00-1.03E+00-1.03E+00Worst score-1.03E+00-1.03E+00-1.03E+003.23E+00-1.03E+00-1.03E+00-1.03E+00Mean-1.03E+00-1.03E+00-1.03E+001.64E+00-1.03E+00-1.03E+00-1.03E+00Standard deviation2.34E-162.34E-162.34E-161.47E+002.34E-162.34E-162.34E-16Branin functionf17Best scoreNANA3.98E-013.58E+013.98E-013.98E-013.98E-01Worst scoreNANA3.98E-015.56E+013.98E-013.98E-013.98E-01MeanNANA3.98E-014.53E+013.98E-013.98E-013.98E-01Standard deviationNANA0.00E+008.11E+000.00E+000.00E+000.00E+00Goldstein-Price functionf18Best score3.00E+003.00E+003.00E+006.00E+023.00E+003.00E+003.00E+00Worst score2.35E+013.00E+003.00E+002.86E+043.00E+003.00E+003.00E+00Mean8.05E+003.00E+003.00E+009.42E+033.00E+003.00E+003.00E+00Standard deviation7.94E+000.00E+000.00E+001.33E+040.00E+000.00E+000.00E+00Hartman’s familyf19Best score-3.86E+00-3.86E+00-3.86E+00NA-3.86E+00-3.86E+00-3.86E+00Worst score-3.29E+00-3.86E+00-3.86E+00NA-3.86E+00-3.86E+00-3.86E+00Mean-3.61E+00-3.86E+00-3.86E+00NA-3.86E+00-3.86E+00-3.86E+00Standard deviation1.82E-010.00E+006.73E-04NA0.00E+000.00E+000.00E+00Hartman’s familyf20Best score-3.32E+00-3.32E+00-3.32E+00NA-3.20E+00-3.32E+00-3.32E+00Worst score-2.28E+00-3.20E+00-3.15E+00NA-3.14E+00-3.20E+00-3.05E+00Mean-3.02E+00-3.21E+00-3.27E+00NA-3.19E+00-3.27E+00-3.23E+00Standard deviation3.88E-013.77E-027.06E-02NA2.65E-026.14E-021.01E-01Shekel’s familyf21Best score-1.02E+01-1.02E+01-1.02E+01NA-1.02E+01-1.02E+01-1.02E+01Worst score-5.10E+00-2.63E+00-1.02E+01NA-2.68E+00-5.06E+00-5.10E+00Mean-9.14E+00-9.40E+00-1.02E+01NA-6.87E+00-8.13E+00-9.65E+00Standard deviation2.13E+002.38E+001.71E-04NA2.92E+002.61E+001.60E+00Shekel’s familyf22Best score-1.04E+01-1.04E+01-1.04E+01NA-1.04E+01-1.04E+01-1.04E+01Worst score-5.09E+00-5.13E+00-5.09E+00NA-2.77E+00-5.13E+00-2.77E+00Mean-9.87E+00-9.88E+00-9.34E+00NA-9.11E+00-9.88E+00-9.11E+00Standard deviation1.68E+001.67E+002.24E+00NA2.78E+001.67E+002.78E+00Shekel’s familyf23Best score-1.05E+01-1.05E+01-1.05E+01NA-1.05E+01-1.05E+010.00E+00Worst score-1.05E+01-1.05E+01-1.05E+01NA-2.87E+00-5.13E+000.00E+00Mean-1.05E+01-1.05E+01-1.05E+01NA-7.80E+00-1.00E+010.00E+00Standard deviation0.00E+000.00E+002.80E-04NA3.59E+001.71E+000.00E+00The Wilcoxon rank-sum test (a nonparametric test of the null hypothesis), i.e., for randomly generated sets of score values by two optimization algorithmsX and Y, the probability of X>Y equals the probability Y>X. p gives the p values of a Wilcoxon rank sum test, and h gives the logical value that indicates if the null hypothesis holds (0) or is rejected (1) at 5% significance level [26]. The results of the Wilcoxon rank sum test for the test function data of the MSSSA are given in Table 2 below.Table 2
MSSSA Wilcoxon rank sum test results.
SSAWOAGAMFOPSODAF1p0.2730.00020.00010.00020.00020.0002h011111zval1.09613.7418-3.7979-3.7433-3.7418-3.7418Rank sum12015555555555F2p0.38470.00020.00020.00020.00020.0002h111111zval-2.06933.7418-3.75033.7418-3.7418-3.7418Rank sum82155551555555F3p0.62321.83E-041.61E-041.61E-040.00581.83E-04h011111zval-0.4914-3.7418-3.7732-3.77322.7591-3.7418Rank sum9855555514255F4p0.2410.02561.73E-040.00281.77E-041.82E-04h011111zval1.1726-2.2317-3.7562.987-3.7503-3.7433Rank sum12175551455555F5p0.42740.0538NA0.85010.01016.39E-05h00NA011zval0.79371.9283NA-0.1891-2.57113.9981Rank sum116131NA10270155F6p9.70E-011.83E-041.74E-041.82E-041.81E-041.03E-04h011111zval3.78E-02-3.74E+00-3.75E+003.74E+00-3.74E+00-1.48E+00Rank sum10655551555555F7p10.00111.82E-040.0141.83E-041h011110zval03.2542-3.74332.4568-3.74180Rank sum105148.55513855105F8p4.09E-022.57E-021.75E-041.30E-031.82E-041.82E-04h111111zval2.04E+002.23E+00-3.75E+003.22E+003.74E+00-3.74E+00Rank sum132.51355514815555F9p8.80E-01NA6.29E-054.03E-011.81E-042.56E-02h0NA1011zval-1.52E-01NA-4.00E+00-8.36E-01-3.74E+00-2.23E+00Rank sum102.5NA55935575F10p5.96E-011.40E-04NA6.34E-051.82E-042.80E-03h01NA111zval-5.30E-013.81E+00NA4.00E+00-3.74E+00-2.99E+00Rank sum97.5155NA1555565F11p4.73E-012.40E-016.39E-052.57E-021.83E-042.11E-02h001111zval-7.18E-012.95E+00-4.00E+002.23E+003.74E+00-2.31E+00Rank sum95845513515574F12p3.08E-012.80E-036.39E-052.54E-022.80E−031.00E-03h111111zval-1.06E+00-2.99E+00-4.00E+002.24E+00-2.99E+00-3.29E+00Rank sum8765551356561F13p3.93E-017.40E-014.88E-051.29E-018.15E-051.24E-04h001011zval-8.54E-013.32E-01-4.06E+001.52E+00-3.94E+00-3.84E+00Rank sum113132661436666F14pNA3.68E-01NA3.68E-019.33E-021.47E-02h00NA001zvalNA-9.00E-01NA-9.00E-01-1.68E+00-2.44E+00Rank sum105100NA1009580F15p9.30E-032.62E-021.22E-044.34E-024.59E-011.00E-03h111101zval-2.60E+002.22E+00-3.84E+00-2.02E+00-7.40E-01-3.29E+00Rank sum86.5153669211074F16pNANA5.59E-05NANANAh001012zvalNANA-4.03E+00NANANARank sum10510555105106107F17pNANANANANANAhNANANANANANAzvalNANANANANANARank sumNANANANANANAF18p1.49E-021.49E-021.52E-041.49E-021.49E-021.49E-02h111111zval2.43E+002.43E+00-3.79E+002.43E+002.43E+002.43E+00Rank sum13013055130130130F19p7.47E-047.47E-04NA7.47E-047.47E-047.47E-04h11NA111zval3.37E+003.37E+00NA3.37E+003.37E+003.37E+00Rank sum145145NA145145145F20p7.89E-011.33E-01NA7.65E-019.21E-029.38E-01h00NA000zval2.68E-011.50E+00NA-2.99E-011.68E+00-7.72E-02Rank sum108.5124NA101126103.5F21p0.67010.1675NA0.04350.32220.3662h00NA100zval0.4261.3803NA-2.0186-0.9899-0.9036Rank sum109115NA819495F22p10.5828NA0.584210.6264h00NA000zval0-0.5493NA-0.54720-0.4869Rank sum105.5100NA100105100.5F23pNANANA0.03480.36811.59E-05h01NA101zvalNANANA-2.1102-0.94.3153Rank sum105106NA85100155The rank-sum test shows the MSSSA has lower median values for functions F2, F3, F7, F11, and F15 compared to the SSA. From the table, there is a small improvement of the MSSSA over the SSA in the rest of the benchmark functions scores. This is given by the rank sum value where a rank sum value less than 105 the MSSSA score is likely to be less than that of the algorithm in comparison; however,h=0 as this is of less than 5% significance. For the low-dimensional multimodal functions F16, F20, F21, F22, and F23, the rank sum test shows no significant performance analytic data as majority of the select optimization algorithms result in global maxima for these functions.Comparison of the mean scores of the MSSSA and the standard algorithms is given in a performance rank table, Table3 given as follows.Table 3
MSSSA performance rank.
Benchmark functionMSSSA performance rankF13F22F31F43F41F64F73F81F91F103F113F123F131F141F152F161F182F192F205F214F222F231


### 5.1. EV HESS Control Simulation Results

To analyze the efficiency of an MSSSA-based control strategy for HESS in electric vehicles, the theoretical energy consumed and current distributions curves were obtained from the simulation as highlighted in Table4.Table 4
HESS EV energy consumption.
MSSSAMin.5.90E+06Max.5.90E+06Avg.5.90E+06SSAMin.6.77E+06Max.7.66E+06Avg.7.21E+06MFOMin.6.39E+06Max.6.80E+06Avg.6.57E+06PSOMin.6.34E+06Max.6.53E+06Avg.6.37E+06DAMin.6.54E+06Max.7.42E+06Avg.7.00E+06Energy consumption is best optimized by the MSSSA as evident in the average values above. A visual representation of energy consumption over time is given by Figure8.Figure 8
Energy consumption against time.An essential function of HESS control strategy apart from energy consumption optimization is the current distribution. A good control strategy maintains the battery discharge rate within the desired limits, reducing current transients and at the same time while keeping the capacitor discharge low at low power demand.Figure9 Below displays the current distribution curve over time for the metaheuristic optimization-based control strategies.Figure 9
(a) MSSSA current distribution. (b) SSA current distribution. (c) MFO current distribution. (d) PSO current distribution. (e) DA current distribution.
(a)(b)(c)(d)(e)For MSSSA optimized control, battery current has less transients compared to the SSA, MFO, and DA. Better optimization of energy consumption means lesser demand at every state; thus, current limit constraint are exceeded fewer times. Overall, the MSSSA achieves the best energy distribution with the best optimization consistently outperforming the SSA, DA, PSO, and MFO algorithms.Speed of the optimization process is critical for the viability of using metaheuristic algorithms as a control strategy. Ideally, this should take a fraction of a second with hardware limitations considered. Run time for the HESS control for each instance was recorded and a summary given in Table5.Table 5
HESS optimization speed test results.
MSSSASSAMFOPSODAMin time (s)0.0266580.0190280.0242430.0208051.221294Max time (s)0.1907260.0945310.0920770.09180115.44288Avg.0.0557610.0433620.0561420.0513555.450881Std. Dev.0.0197760.0162420.0140430.0167324.923087SSA as evident has the best average time followed by the PSO, MSSSA, and MFO, respectively. DA has the worst time performance at an average of over 5 seconds. The MSSSA performance is theoretically practical in real-time applications of a metaheuristic optimization-based controller.This however remains abstract as no fabricated tests were done and constraints such as SOCs and functions, i.e., regenerative braking in EVs has not been considered in the scope of this paper [12, 16–18].From the results of the test scenarios, we are able to merit the algorithms improved linearity on the two accounts: being an optimization algorithm, the cost function is at the core of the MS-SSA function and design. From the benchmark test functions and EV HESS simulation, the MS-SSA returns the best and second-best score in a 14 out of 23 applicable test problems explored. This puts the functions performance compared to the other selected algorithms at 60%.The algorithm introduces a dynamic learning rate, and the learning rate can be said to be random but fundamentally governed by the positional difference of the search agents relative to the global minima. This means that though random, that initially, the learning rate is large and immensely decreases as it approaches the minima.Unlike conventional algorithms, the MS-SSA convergence rate varies with the number of iterations enabling it to minimize error improving performance particularly where limitation on number of iterations is needed. The coupling of this algorithm with the dynamic model for real-time optimization of EV HESS has the advantages of improved performance in terms of energy consumption over fuzzy control whilst being fast enough to meet the speed requirements.


## 5.1. EV HESS Control Simulation Results

To analyze the efficiency of an MSSSA-based control strategy for HESS in electric vehicles, the theoretical energy consumed and current distributions curves were obtained from the simulation as highlighted in Table4.Table 4
HESS EV energy consumption.
MSSSAMin.5.90E+06Max.5.90E+06Avg.5.90E+06SSAMin.6.77E+06Max.7.66E+06Avg.7.21E+06MFOMin.6.39E+06Max.6.80E+06Avg.6.57E+06PSOMin.6.34E+06Max.6.53E+06Avg.6.37E+06DAMin.6.54E+06Max.7.42E+06Avg.7.00E+06Energy consumption is best optimized by the MSSSA as evident in the average values above. A visual representation of energy consumption over time is given by Figure8.Figure 8
Energy consumption against time.An essential function of HESS control strategy apart from energy consumption optimization is the current distribution. A good control strategy maintains the battery discharge rate within the desired limits, reducing current transients and at the same time while keeping the capacitor discharge low at low power demand.Figure9 Below displays the current distribution curve over time for the metaheuristic optimization-based control strategies.Figure 9
(a) MSSSA current distribution. (b) SSA current distribution. (c) MFO current distribution. (d) PSO current distribution. (e) DA current distribution.
(a)(b)(c)(d)(e)For MSSSA optimized control, battery current has less transients compared to the SSA, MFO, and DA. Better optimization of energy consumption means lesser demand at every state; thus, current limit constraint are exceeded fewer times. Overall, the MSSSA achieves the best energy distribution with the best optimization consistently outperforming the SSA, DA, PSO, and MFO algorithms.Speed of the optimization process is critical for the viability of using metaheuristic algorithms as a control strategy. Ideally, this should take a fraction of a second with hardware limitations considered. Run time for the HESS control for each instance was recorded and a summary given in Table5.Table 5
HESS optimization speed test results.
MSSSASSAMFOPSODAMin time (s)0.0266580.0190280.0242430.0208051.221294Max time (s)0.1907260.0945310.0920770.09180115.44288Avg.0.0557610.0433620.0561420.0513555.450881Std. Dev.0.0197760.0162420.0140430.0167324.923087SSA as evident has the best average time followed by the PSO, MSSSA, and MFO, respectively. DA has the worst time performance at an average of over 5 seconds. The MSSSA performance is theoretically practical in real-time applications of a metaheuristic optimization-based controller.This however remains abstract as no fabricated tests were done and constraints such as SOCs and functions, i.e., regenerative braking in EVs has not been considered in the scope of this paper [12, 16–18].From the results of the test scenarios, we are able to merit the algorithms improved linearity on the two accounts: being an optimization algorithm, the cost function is at the core of the MS-SSA function and design. From the benchmark test functions and EV HESS simulation, the MS-SSA returns the best and second-best score in a 14 out of 23 applicable test problems explored. This puts the functions performance compared to the other selected algorithms at 60%.The algorithm introduces a dynamic learning rate, and the learning rate can be said to be random but fundamentally governed by the positional difference of the search agents relative to the global minima. This means that though random, that initially, the learning rate is large and immensely decreases as it approaches the minima.Unlike conventional algorithms, the MS-SSA convergence rate varies with the number of iterations enabling it to minimize error improving performance particularly where limitation on number of iterations is needed. The coupling of this algorithm with the dynamic model for real-time optimization of EV HESS has the advantages of improved performance in terms of energy consumption over fuzzy control whilst being fast enough to meet the speed requirements.


## 6. Conclusion

This paper introduces a master-slave salp swarm algorithm for real-time control of hybrid energy storage Systems in pure electric vehicles. By introducing a master-slave learning scheme, the algorithms’ exploitation is improved, as the dynamic learning rate balances exploration and exploitation for improved global performance in a variety of optimization problems. From the results, we established that theoretically, MSSSA offers the best optimized control strategy for EV HESS where few iterations are necessary for real-time optimization and control.This work provides an abstract model for incorporation of an improved metaheuristic algorithm in a real-time optimization problem. Practical implementation of the conceptualized model requires further research into different master-slave learning techniques suited to particular problems, predictive tools to further the potential for real-time optimization, and multiobjective algorithm design to encompass complex nature of real-time optimization problems.



---

*Source: 1648433-2022-09-14.xml*