A MODIFIED PARTICLE SWARM OPTIMIZATION ALGORITHM FOR THE OPTIMIZATION OF A FUZZY CLASSIFICATION SUBSYSTEM IN A SERIES HYBRID ELECTRIC VEHICLE

Original scientific paper Particle swarm optimization (PSO) based optimization algorithms are simple and easily implementable techniques with low computational complexity, which makes them good tools for solving large-scale nonlinear optimization problems. This paper presents a modified version of the original method by combining PSO with a local search technique at the end of each iteration cycle. The new algorithm is applied for the task of parameter optimization of a fuzzy classification subsystem in a series hybrid electric vehicle (SHEV) aiming at the reduction of the harmful pollutant emission. The new method ensured a better fitness value than either the original PSO algorithm or the clonal selection based artificial immune system algorithm (CLONALG) by using similar parameters.


Introduction
Nature inspired algorithms have been widely successfully applied for optimization problems in the last three centuries.Particle Swarm Optimization (PSO) is one of the most popular of them because it is a simple and easily implementable method with low computational complexity.Besides, it also maintains the "memory" of the best solutions [1].Its original version was developed by Kennedy and Ebenhart [2] in 1995.PSO was inspired by the social behaviour of bird flocking and fish schooling.
Although in the course of years PSO has been applied successfully for many problems [3], several modifications and enhancements have been proposed so far.Richards and Ventura [4] introduced a new method for the initial distribution of the particles.Campana et al. suggested a new mode for the definition of the particle's trajectories to get a better exploration of the search space.Kennedy and Mendes [5] proposed the usage of a fully informed particle swarm where the velocity vector is determined based on the performance of each neighbour of a particle.Fan and Shi [6] demonstrated that the performance of the original method can be improved by proper dynamic change of v max .Clerc and Kennedy [7] proposed a constriction coefficient to improve the convergence of the particles.Shi et al. [8] proposed the use of an extra parameter called inertia weight for the velocity calculation.Chen et al. [9] suggested the application of an adaptive inertia weight.Pehlivanoglu [10] introduced a new mutation strategy to avoid the convergence of the particles around a local optimum solution.Campana et al. [11] reformulated the standard PSO iteration into a linear dynamic system in order to provide a better positioning of the initial particles.Precup et al. [12] hybridized PSO with the Gravitational Search Algorithm for the optimal tuning of Takagi-Sugeno-Kang PI-fuzzy controllers.
In this paper, we introduce a modified (hybridized) version of PSO where we combine the original method with a simple local search technique.The modified algorithm is applied for the task of parameter optimization of a fuzzy classification subsystem in a series hybrid electric vehicle (SHEV) aiming at the reduction of the harmful pollutant emission.The SHEV system is modelled in Simulink.The rest of this paper is organized as follows.The new hybrid algorithm is presented in Section 2. The main components of the used SHEV and the fuzzy classification subsystem are overviewed briefly in Section 3. Section 4 presents the applied objective (cost) function and the simulation results.The conclusions are drawn in section 5.

The modified PSO algorithm
In this section we are going to present a modified PSO algorithm, which was used for the optimization of some parameters of the fuzzy system presented in Section 3. The novelty of the proposed method compared to the original PSO is that it applies a local search technique at the end of each iteration cycle.
PSO is a population based heuristic optimization algorithm.Its goal is to find the optimal values for the elements of a feature vector where n is the number of the parameters/properties to be optimized.The optimization problem can be defined as Technical Gazette 24, Suppl.2(2017), 295-301 ( ) where LB and UB are vectors with n elements containing the lower and upper bounds for each parameter, and F(.) is the fitness (objective) function, which will be presented in details in Section 4.1.
The particles (members of the swarm) can be characterized by their position in the search space and the corresponding fitness value.Therefore, in case of PSO based methods the feature vector P is called position vector.The initial distribution of the particles usually can be defined randomly.However, a guided initialization is also possible when some a-priory information is available.The particles change their position in each iteration cycle, by exploring new areas of the search space.The distance and the exact direction of movement is defined by a so called velocity vector, which is calculated based on the "memory" of the swarm, i.e. the previous value of the velocity vector, the so far best position of the given particle (personal best) and the so far best position taken into consideration of the whole swarm (overall best).The velocity vector of the particle j in the iteration cycle i is where PB j is the personal best position of the j th particle, OB i−1 is the overall best position in the i−1 th iteration cycle, c 1 and c 2 ∈ [0,1] are constant parameters of the method; r 1 and r 2 ∈ [0,1] are random values; and P i−1,j is the position vector of the j th particle in the previous iteration cycle.The value of c 3 is defined usually as an arbitrary function of c 1 and c 2 .For example The new position of the j th particle is calculated as In some cases, only integer values are acceptable as elements of the position vector.This demand can be fulfilled by applying a rounding operation In the new position, each particle is evaluated.Furthermore, the personal best and overall best vectors are also updated if necessary.
In order to improve the positions of the particles an iterative local search technique is employed for the first n B best particles at the end of each iteration cycle.Local search methods try to find better candidate solutions (particle position in our case) based on iterative exploration of the neighbourhood of an initial solution [13].They apply local changes in each cycle and stop when either the prescribed maximal number of iteration or a desired performance level is reached.
The key idea of the local search technique applied in our case is that the local optima is approached step by step so that in the course of each step two new candidate positions are calculated for the current particle.After evaluating their performance, the particle will be placed in the position with the best performance, which can be either the old position or any of the new position candidates.
This concept is implemented in the following way.In each iteration cycle for each selected particle one examines and modifies each element of the position vector one-by-one.For the current element two new values are calculated where s k is a predefined step value for the kth element of the position vector.From the three available values that one is kept as the new coordinate value of the particle, which ensures the best fitness value After each parameter modification the PB and OB vectors are updated if necessary.The number of iteration cycles (n l ) of the local search is a parameter of the method.Following the local search, a new iteration cycle of the whole method is started with the recalculation of the velocity vectors.
The default stopping criterion is the number of allowed iterations (n i ).The algorithm is described below.Beside the number of allowed iterations other applicable stopping criteria can be considered as well.Such conditions could be: n fe the number of fitness evaluations exceeds an upper limit -owing to the fact that the calculation of the fitness function is one of the computationally most expensive steps, n i the number of iteration cycles exceeds an upper limit, F tr the fitness of at least one particle becomes better than a threshold value, n wi the number of consecutive generations without any improvement regarding the overall best fitness value exceeds an upper limit.
The parameters of the algorithm are summarized in Tab. 1.

SHEV and fuzzy classification subsystem
The concept of hybrid electric vehicles (HEVs) emerged from the need for finding solution for the task of reducing the fuel consumption of the traditional internal combustion engine (ICE) based vehicles and to extend the drive range of the electric cars.In general, there are four main HEV types [14] depending on the links between the different components and the applied propulsion type.They are the series [15,16], parallel [17,18], seriesparallel [19] and complex [20] HEVs.
The configuration and components of SHEVs are presented in Fig. 1, where FT is the fuel tank, G is the generator, B is the battery, M is the electric motor, P is the power converter, and T is the transmission system.
The thin line represents the hydraulic link, the double line indicates the mechanical link, and the thick line is used for the electrical link.In a SHEV there is no mechanical link between the ICE and the transmission system.
SHEVs' advantageous features are their simplicity; the freedom they give to the vehicle designer as well as the bigger efficiency compared to other configuration types, which is a result of the lower number of mechanical links [21,22].Practically the vehicle functions as an electric car, the ICE is used only for battery charge.

Figure 1 Configuration and components of SHEVs
An important purpose of this research was to create a control structure that ensures low level harmful pollutant emission and low fuel consumption.To fulfil this task, a SHEV model [23] was created in Simulink.
Fuzzy concept based solutions are widely recognised as suitable tools for control, classification, and other purposes (e.g.[24÷30]).Therefore, the subsystem of the SHEV that aims at the control of the generator and the electric motor was developed with a fuzzy classification system in it.The task of the fuzzy subsystem is the determination of the desired charging state of the battery in function of the acceleration/deceleration needs, the energy stored in the battery, and the altitude change in the next section of the route.
The block diagram of the fuzzy subsystem is given in Fig. 2. The fuzzy subsystem works with the following three input signals.The output of the fuzzy subsystem is the desired charging state.It has three possible values, which are used later by another subsystem.These values are 0 -no charge, 1 -slow charge, 2 -fast charge.
The fuzzy system works as a classifier with three inputs.Supposing that the driver does not press at the same time the gas and the brake pedals the two signals could be aggregated taking the brake signal with negative sign.The second input is the normalized (relative) value of the energy stored in the battery E brel .The third input of the fuzzy controller is the relative value of the altitude change in the next 500 m of the route.We supposed that the altitude difference between the current point of the route and the point to which one can "see ahead" (500 m route distance) is not bigger than the mentioned route distance itself.Therefore, we used this distance for the normalization of the altitude difference.This input value indicates whether one can expect a positive (battery charging) or negative (battery depletion) effect of the altitude change.In order to keep low the complexity of the rule base we defined the input partitions with a relative low number of fuzzy sets.Thus the first input variable (acc_brk) has a partition with four sets (NL, NS, PS, PL) owing to the fact that it aggregates two signals (acceleration and braking).All membership functions are triangle shaped (see Fig. 3).
In case of the second input (E brel ) bell shaped membership functions were chosen.The corresponding partition is shown in Fig. 4. It contains three fuzzy sets (S, M, L).In case of the third input (s j ) also bell shaped membership functions were used.The corresponding partition is shown in Fig. 5.
In case of the output we need only three distinct values (0, 1, and 2) referring to the three possible charge states.The corresponding partition is created using singleton type membership functions.Its graphical representation is shown in Fig. 6.Mamdani-type inference technique was chosen owing to the following two aspects: (1) it applies easily interpretable IF-THEN rules that contain both the antecedent and consequent sides fuzzy sets, and (2) it is implemented in Matlab's Fuzzy Logic Toolbox.
Mamdani type fuzzy reasoning activates and uses all the rules whose antecedent sets overlap the observation with a membership value greater than zero and generates the conclusion fuzzy set applying an s-norm to the results obtained firing the individual rules.
In our case there are only three acceptable output values, which situation demands the use of a special defuzzification method that yields the abscissa value where the conclusion set takes its maximum.The application of singleton consequent fuzzy sets ensure that this maximum can be only one of the desired output values.
Having the antecedent and consequent partitions defined an initial rule base was created with 36 rules based on assumptions of human experts.

Fitness function
In the course of the optimization process one is looking for that solution candidate, which proves to be better than all the others by means of an objective (fitness) function.In most of the cases the type of this function is "the smaller the better".It means that the lower the values of the objective function are the better the given parameter set will be considered.In our case the goal of the optimization was to reduce the harmful pollutant emission by taking into consideration the battery energy level and fuel consumption as well.The available SHEV model [23] made possible the measurement of five characteristics that were the fuel consumption of the ICE (B), the CO emission of the ICE (e CO ), the HC emission of the ICE (e HC ), the NOx emission of the ICE (e NOx ), and the battery energy level (E br ).Therefore, the cost function (F) used in [23] and [31] was applied as objective function.
where T is the simulation time.
All components of the objective function were taken into consideration with equal weights.Thus lower cost function values represent lower fuel consumption and harmful pollutant emission and therefore correspond to better solutions.All components are relative values compared to predefined constant maximum values, which were taken from [31] (see Tab. 1).

Parameter optimization
In case of this research the parameter optimization aimed at the improvement of the rule base by means of changing (if necessary) the categories (output values) associated to the individual rules.In the course of the optimization process the SHEV had to track the HTDC (Heavy Traffic Driving Cycle) [21] speed profile.
In case of all parameters of the fuzzy inference except the defuzzification the default values were used, i.e. the min operator as t-norm (and method), and the max operator as s-norm (or method).These are the most commonly used parameter values in case of Mamdanitype systems.
The algorithm has been implemented in Matlab.The position vector of a particle contained the consequents of the rules using a numerical encoding, i.e. 1 for no charge, 2 for slow charge, and 3 for fast charge.Due to their meaning the elements of the position vector can be only integer values.Thus the rounding operation (6) was also included.Its initial version was The simulations were run in Simulink with T s =1500 s simulation time.The parameters of the algorithm were The resulting initial value of the fitness function was F=0.0342.At the end of the optimization the fitness value became F=0.0141.
The same optimization task was also carried out using the original PSO algorithm with similar parameters and a clonal selection based artificial immune system algorithm (CLONALG) [32] with the same population size and allowed system evaluation number.The final fitness values are presented in Tab. 2. Thus the proposed algorithm proved to provide the best results.The rule base corresponding to the best particle of the final swarm is presented in Tab. 3.

Conclusions
In this paper, a modified version of the particle swarm optimization was proposed, which was applied for the optimization of a fuzzy classification subsystem used in the model of a series hybrid electric vehicle.Here the goal was to ensure a low level of harmful pollutant emission and low fuel consumption.The fuzzy classifier controls the internal combustion engine by switching between three possible charging states.It applies Mamdani type fuzzy reasoning and a special defuzzification technique.The proposed optimization algorithm was used for the determination of the consequent sets of the rules.
The new technique combines the original PSO with a local search technique at the end of each iteration cycle.The local optimum of the objective function is approached so that in the course of each step two new candidate positions are calculated in the neighbourhood of the current particle and the particle will be moved in that position, which provides the best objective function value.
The results obtained by the proposed method were compared to the ones achieved with the original PSO and the artificial immune system algorithm CLONALG.The new method outperformed both of them.Further research will consider the application of a fuzzy rule interpolation based interpolation technique (e.g.[33÷36]) in order to reduce the complexity of the rule base and the time necessary for fitness evaluation.
acc a value belonging to the interval [0, 1] indicating the position of the gas pedal.brk a value belonging to the interval [0, 1] indicating the position of the brake pedal.X a vector with multiple components from which we use the indicator of the energy stored in the battery (E b ) and the altitude values for the next 500 m of the route (s j ).

G
Figure 2Structure of the fuzzy subsystem

Figure 3 Figure 4 Figure 5
Figure 3 First input -composed signal of the acceleration and brake signals

Figure 6
Figure 6 Output -charge levels

Table 2
Final fitness values

Table 3
Final rule base