{'fraction_non_alphanumeric': 0.028734893288763177, 'fraction_numerical': 0.015106711236821805, 'mean_word_length': 4.835333833458365, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 5, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Hybrid Differential Evolution and Harmony Search for Optimal Power Flow

In this paper, we presents a novel approach for solving optimal power flow (OPF) problems using a hybrid differential evolution and harmony search (DEHS). The DEHS method is an improved differential evolution method based on the harmony search scheme. Harmony Search has strong and easy to combine with other methods in optimization and the Differential Evolution algorithm has a very great ability to search solutions with a fast speed to converge, contrary to the most meta-heuristic algorithms. The DEHS method has the flexible adjustment of the parameters to get a better optimal solution. Moreover, an effective constraint handling framework in the method is employed for properly handling equality and inequality constraints of the problem. The proposed DEHS has been tested on three systems including IEEE-30 bus system with quadratic fuel cost function, IEEE-30 bus system with valve point effects fuel cost function and IEEE-57 bus system with quadratic fuel cost function. The obtained results from DEHS algorithm have been compared to those from other methods in the literature. The result comparison has indicated that the proposed DEHS method is more effective than many other methods for obtaining the optimal solution for the test systems. Therefore, the proposed DEHS is a very favorable method for solving the optimal power flow problems.


Introduction
Optimal power flow (OPF) problem is the important fundamental issues in power system operation. In essence, it is the optimization problem and its main objective is to reduce the total generation cost of units while satisfying unit and system constraints. Although the OPF problem developed long time ago but so far it has been extensively studied due to its importance in power system operation. There have been many methods developed to solve OPF problem from classical methods such as Newton's method, gradient search, linear programming (LP), nonlinear programming, quadratic programming (QP), etc to methods based on artificial intelligence and evolutionary based methods such as ant colony optimization (ACO), genetic algorithm (GA), improved evolutionary programming (IEP), tabu search (TS), simulated annealing (SA), etc. These methods have been effectively for solving the problem.
In recent years, many methods have been applied to solve the OPF problem such as the proposed approach employs differential evolution algorithm for optimal settings of OPF problem control variables is presented in [1], a improved differential evolution approach to solve the stochastic optimal power flow problem [2], a differential evolution approach to solve optimal power flow problem with multiple and competing objectives [3], the harmony search method for solving optimal power flow problems is presented in [4], A Genetic Algorithm for Solving the Optimal Power Flow Problem [5]. However, these methods have large number of iterations to achieve solution and easily affected by the relevant control parameters. This paper proposes a hybrid differential evolution and harmony search (DEHS) algorithm by combining the mechanisms of both HS and DE. We had some experiments of the classical HS meta-heuristics with slow convergence and the growth of search space dimensionality. In the present work, we replace the pitch adjustment operation in original HS with a mutation strategy borrowed from the real of the DE algorithms. After that, the memory consideration and the enhanced pitch adjustment operation are both employed to strengthen the exploration ability. Compared with the classical HS meta-heuristics, the use of differential mutation and crossover can enhance the exploitation in the DEHS. DEHS algorithm may inherit elements from as many individuals as its number of dimensions when generating a new individual to enhance the exploration ability. The proposed DEHS has been tested on three different power systems including IEEE-30 bus system with quadratic fuel cost function, IEEE-30 bus system with valve point effects fuel cost function and IEEE-57 bus system with quadratic fuel cost function. The numerical results from the proposed method are compared to those from many other methods in the literature ( Figure 1).

Optimal Power Flow Problem
The OPF problem can be described as an optimization (minimization) process with nonlinear objective function and nonlinear constraints [6]. The general OPF problem can be expressed as center operator (generated active and reactive powers, generation bus voltage magnitudes, transformers taps, etc.).
The essence of the optimal power flow problem resides in reducing the objective function and simultaneously satisfying the load flow equations (equality constraints) without violating the inequality constraints.
The fuel cost function is given by where, N G is the number of generation including the slack bus. P G is the generated active power at bus i. a i , b i and c i are the unit costs curve for i th generator.
The smooth quadratic fuel cost function without valve point loadings of the generating units are given by (4), where the valvepoint effects are ignored. The generating units with multi-valve steam turbines exhibit a greater variation in the fuel-cost functions. Since the valve point results in the ripples, a cost function contains higher order nonlinearity. Therefore, the equation (4) should be replaced by (5) for considering the valve-point effects [6].
The sinusoidal functions are thus added to the quadratic cost functions as follows [6]. 2 ,min where a i , b i , c i are the fuel cost coefficients of the i th unit and e i and f i are the fuel cost coefficients of the i th unit with valve point effects.
While minimizing the cost function, it is necessary to make sure that the generation still supplies the load demands plus losses in transmission lines. Usually the power flow equations are used as equality constraints [5].
where active and reactive power injection at bus i are defined in the following equation The inequality constraints of the OPF reflect the limits on physical devices in power systems as well as the limits created to ensure system security. The most usual types of inequality constraints are upper bus voltage limits at generations and load buses, lower bus voltage limits at load buses, reactive power limits at generation buses, maximum active power limits corresponding to lower limits at some generators, maximum line loading limits and limits on tap setting. The inequality constraints on the problem variables considered include Generation constraint: Generator voltages, real power outputs and reactive power outputs are restricted by their upper and lower bounds as follows where N C is the number of shunt compensator.
Transformer constraint: Transformer tap settings are restricted by their upper and lower bounds as follows where N T is the number of transformer tap.
where N L is the number of load bus.

Differential evolution
In 1995, Price and Storn proposed a new evolutionary algorithm for global optimization and named it as differential evolution (DE) [7]. This method has few parameters for tuning make the algorithm quite popular in the literature. DE obtains solutions to optimization problems using three basic operations including mutation, crossover, and selection. The steps of DE including the operations are described as follows: Step 1: Mutation Choose the target vector x i,g (= x 0,g ) and basic vector x r0,g (= x 2,g ).
Calculate the value for a mutant vector: Step 2: Crossover Select new vector from the target vector and mutant vector according to the following rules: Step 3: Selection Calculate the value of the objective function with the new vector is created, compare this value to the objective function value of the first selected target vector to decide whether to select a new vector or not.
The proceudre of the DE method for solving an optimization problem is given in Figure 2.

Harmony search
Harmony search (HS) algorithm was recently developed in an analogy of music improvisation process where music players improvise the pitches of their instruments to obtain better harmony [8]. First of all, HS initializes harmony memory (HM) which stores the feasible vectors that are all in the feasible space. The harmony memory size (HMS) determines the number of vectors to be stored. Then, through the harmony memory considering rate (HMCR), HS choose any one value from the HM, utilize the pitch adjusting rate (PAR), choose an adjacent value of one value from the HM, and choose totally random value from the possible value range [9]. The steps in the procedure of HS are as follows: Step 1: Initialize the algorithm parameters and optimization operators such as HMS, HMCR, and PAR.
Step 3: Improvise a new harmony from HM. A new harmony vector is generated from HM based on based on three rules: memory considerations, pitch adjustments, and randomization. The HMCR, which varies between 0 and 1, is the probability of choosing one value from the historic values stored in the HM, and (1-HMCR) is the probability of randomly choosing one feasible value not limited to those stored in the HM.
The pitch adjusting process is performed only after a value is chosen from the HM. The value PAR sets the rate of doing pitch adjusting and the value (1-PAR) sets the rate of doing nothing.
where bw is an arbitrary distance bandwidth (a scalar number) and rand() is a uniformly distributed random number between 0 and 1.
Step 4: Update HM. If the new harmony vector is better than the worst harmony in HM, judged in terms of the objective function value, the new harmony is included in HM and the existing worst harmony is excluded from HM.
Step 5: Repeat Steps 3 and 4 until the terminating criterion is satisfied.

Hybrid differential evolution and harmony search
The overall procedure of the proposed algorithm can be summarized as in Figure 3.

Numerical Results
The proposed DEHS algorithm has been applied to OPF problems in three different power systems including IEEE-30 bus system with quadratic fuel cost function, IEEE-30 bus system with valve point effects fuel cost function and IEEE-57 bus system with quadratic fuel cost function. For each system, the proposed DEHS method is run 100 independent trials and the obtained optimal results are compared to those from other methods.

Case 1:
The IEEE 30-bus system with quadratic fuel cost function.
In this example, the standard IEEE 30-bus system has been used to test the OPF problems. This system has six generators located at  buses 1,2,5,8,11,13 and four transformers with off-nominal tap ratio in lines 6-9, 6-10, 4-12 and 28-27. Table 1 shows the optimal dispatches of the generators. Also note that all outputs of generator are within its permissible limits. The proposed method is run 100 independent trials and the obtained optimal results are compared to those from other methods such as Genetic algorithm (GA) [10], tabu search/simulated annealing (TS/SA) [11], Evolutionary Programming (EP) [12] and Differential Evolution (DE). It is observed that DEHS algorithm gives better total cost than other methods in a clearly manner. The computation time of the DEHS method is also faster than other methods. These results have shown that the proposed method is feasible and indeed capable of acquiring better solution. Figure 4 shows the convergence characteristic of DE and DEHS. The security constraints are also checked for voltage magnitudes in Figure 5. The voltage magnitudes are between their minimum and maximum values. No load bus was at the lower limit of the voltage magnitudes.

Case 2: The IEEE 30 bus system with valve point effects fuel cost function
In this case, the generating units of buses 1 and 2 are considered to have the valve-point effects on their fuel cost characteristics. The fuel cost coefficients of these generators are taken from [13]. The fuel cost coefficients of the remaining generators have the same values as of the test Case 1. The total cost obtained by the proposed DEHS is less than that from Improved Evolutionary Programming (IEP) [14], Self-Adaptive Differential Evolution with Augmented Lagrange Multiplier method (SADE_ALM) [15], Self Organizing Hierarchical Particle Swarm Optimizer with Time Varying Acceleration Coefficients (SOH-PSO TVAC) [16] and Differential Evolution (DE). Table 2 has indicated that the DEHS algorithm gives better results than other methods with the percentage as follow IEP 2.49%, SADE-ALM 1.47%, SOH -PSO TVAC 0.05% and DE 0.04%. Therefore, the proposed DEHS is very effective for solving the OPF problem with valve point loading effects. Table 2 also show DEHS required the least solution time ( Figure 6).

Case 3:
The IEEE 57 bus system with quadratic fuel cost function (Figure 7).
To evaluate the effectiveness and efficiency of the proposed DEHS approach in solving larger power system, a standard IEEE 57-bus test system is considered. The IEEE 57-bus system consists of 7 generation buses, 50 load buses, and 80 branches. The generators are located at buses 1, 2, 3, 6, 8, 9, and 12 and 15 transformers are located at branches 19, 20, 31, 37, 41, 46, 54, 58, 59, 65, 66, 71, 73, 76, and 80. The system has also 3 switchable capacitor banks installed at buses 18, 25, and 53. For dealing with this system, there 31 control variables to be handled including real power output of 6 generators except the generator at the slack bus, voltage at 7 generation buses, tap changer of 15 transformers, and reactive power output of 3 switchable capacitor banks (Figure 8). The total load demand of system is 1250.8 MW and 336.4 MVAR. The bus data, line data, cost coefficients, minimum and maximum limits of real power generations are taken from [17,18]. The maximum and minimum values for voltages of all generator buses and transformer   tap settings are considered to be 1.1 and 0.9 in p.u. The maximum and minimum values for voltages of all load buses are 1.06 and 0.94 in p.u [19]. Table 3 shows the minimum, average, maximum cost achieved by the DEHS algorithm in 100 runs. Obviously, the minimum costs acquired by the proposed methods are all lower than that obtained by stochastic weight trade-off particle swarm optimization (SWT-PSO) [20], particle swarm optimization (PSO) [17], MATPOWER [21] and Differential Evolution (DE). The standard deviation of proposed methods is also lower than other methods. The security constraints are also checked for voltage magnitudes in Figure 9. The voltage magnitudes are between their minimum and maximum values. No load bus was at the lower limit of the voltage magnitudes.

Conclusion
In this paper, the hybrid differential evolution and harmony search algorithm has been presented to solve the optimal power flow problems. In the new improved method, the conventional DEHS algorithm is used with the variance coefficients to speed up the convergence to the global solution in a fast manner regardless of the shape of the cost function. Numerical results have indicated that the DEHS algorithm has dominates many other methods in the literature in solving the optimal power flow problems for all the test cases in terms of total costs, total loss and computational times. Moreover, the proposed method is very effective for solving large-scale systems. Therefore, the proposed DEHS method is favorable for solving optimal power flow problems with non-convex objective function.    Table 3: Result comparison of the ieee 57-bus system with quadratic fuel cost function.