Particle Swarm Optimization Based Optimal Reactive Power Dispatch for Power Distribution Network with Distributed Generation

Reactive power dispatch plays a main role in order to provide good facility secure and economic operation in the power system. Optimal reactive power dispatch (ORPD) is a nonlinear optimization problem and has both equality and inequality constraints. ORPD is defined as the minimization of active power loss by controlling a number of variables. Due to complex characteristics of ORPD, heuristic optimization has become an efficient solver. In this paper, particle swarm optimization (PSO) algorithm and MATPOWER toolbox are applied to solve the ORPD problem for distribution system with distributed generating (DG) plant. The proposed method minimizes the active power loss in a practical power system as well as determines the optimal placement of a new installed DG. The practical 41-bus, 6-machine power distribution network of Myingyan area is used to evaluate the performance. The result shows that the adjustment of control variables of distribution power network with a new DG gives a better approach than adjustment only the control variables without DG.


Introduction
The optimal reactive power dispatch (ORPD) is a sub problem of the optimal power flow calculation and has a significant influence on secure and economic operation of power systems. The controllable system quantities are the capacity of a new distributed generator, controlled voltage magnitude, reactive power injection from reactive power sources and transformer tapping [1]. The main objective of this paper is to minimize the active power loss by optimizing the control variables within their limits and to find the optimal placement of a new DG in distribution system.
Integrating of DG into distribution network already reduces power loss because some portion of the required current form upstream is substantially reduce which result lower loss through line resistance. Further reduction of loss can be achieved by intelligently managing reactive power from the installed DG [2].
Several conventional optimization algorithms [3] have been proposed to solve the ORPD problem such as linear programming, quadratic programming, and interior point method. Main problem associated with these conventional techniques is easily falling in local optimum solution. As the ORPD is nonlinear, evolutionary computation methods such as genetic algorithm (GA) [4], evolutionary programming (EP) and particle swarm optimization (PSO) [5] algorithm are best suitable to solve it.
In the present work, an application of particle swarm optimization (PSO) and MATPOWER toolbox [6] is used to solve optimal reactive power dispatch problem integrating a new DG. The PSO algorithm is a global search method which explores search space to get the global optimum. The PSO is a stochastic, population-based computer algorithm modeled on swarm intelligence. PSO finds the global minimum of a multidimensional function with best optimum. MATPOWER is an open source MATLAB toolbox focused on solving the power flow problems.

The Mathematical Model of Optimal Reactive Power Dispatch
The goal of optimal reactive power dispatch [7][8][9] is to determine the optimum values of independent variables by optimizing a predefined objective function with respect to the operating bounds of the system. The ORPD problem can be mathematically expressed as a nonlinear constrained optimization problem as follows: where, a is vector of state variables, b is vector of control variables, f(a, b) is objective function, g(a, b) is different equality constraints set, h(a, b) is different inequality constraints set.

Variables
The control variables should be adjusted to satisfy the power flow equations. For the ORPD problem, the set for control variables can be formulated as [1,2]: where, P G is real power output at the generator buses excluding at the slack bus, V G is voltage magnitude of generator buses, Q C is shunt VAR compensation, T is tap settings of transformer, Ng is no. of generator units, Nt is no. of tap changing transformers and Nc is no. of shunt VAR compensation devices, respectively. There is a need of variables for all ORPD formulations for the characterization of the system. The state variables can be formulated as: where, P G1 is real power generation at the slack bus, V L is magnitude of voltage at load buses, Q G is reactive power generation of all generators, S L is transmission line loading, Npq is no. of PQ buses and NL is no. of transmission lines, respectively.

Objective Function
The objective of the reactive power dispatch is to minimize the active power loss through controlling the capacity of reactive power control devices and the reactive power of DG. The expression can be described as follows: where, NL is the number of transmission lines, G k is the conductance of the k th line, V i and V j are the voltage magnitudes at the end buses i and j of the k th line and ij θ is the voltage angle difference between buses i and j.

System Constraints
There are two ORPD constraints named inequality and equality constraints. These constraints are explained in the sections given below.
Equality Constraints: Minimization of objective function is subject to follow equality constraints. These constraints represent power flow active and reactive power balance equations.
where, P G is the active power generated, Q G is the reactive power generated, P D is the active power demand, Q D is the reactive power demand, NB is total no. of buses, G ij and B ij are the transfer conductance and susceptance between bus i and j. Inequality Constraints: The inequality constraints are typically technical limitations of the power system devices in the network. Inequality constraints represent the system operating limits as: [3][4].
(a) Generator Constraints: Generator voltages and generated reactive power outputs are limited to as follows: where, i=1, 2, 3,…., Ng. Ng is no. of generator buses.
The control variables are self-constrained variables. In this reactive power dispatch problem, the inequality constraints are incorporated as penalty terms into the objective function in (6). The fitness function for above reactive power dispatch problem is generalized as follows: (13) where, Vi λ is the penalty multiplier for voltage limit, Ti λ is the penalty multiplier for transformer tap setting limit and Gi λ is the penalty multiplier for generated reactive power limit respectively. Penalty multipliers are large positive constants for minimum deviation in these inequality constraints.
Limiting values of V , T and Q are defined as follows:

Reactive Power Supply Capability of Distributed Generation
DG connected to electrical grid through power electronic converter can be set to inject reactive power by changing its operating power factor or increasing its reactive current output. How much reactive power can be supplied by DG unit depends on its active power set point. The diagram illustrating reactive power capability is shown in Figure 1. If DG active power is set close to its rated apparent power rating, capacitive or inductive reactive power range that can be supplied is small. Reactive supply capability of DG can be increased by reducing its active power generation. If active power set point is reduced, more reactive supply is guaranteed [10]. Even though the amount of reactive power that can be supplied by DG is limited and is not enough to supply the entire reactive power requirement, this corrective action in consequence can minimize the power losses inside the distribution network. As DG unit will be integrated into distribution network depending on the location, reactive power amount required from DG unit will be varied in different operating conditions. In finding optimal reactive power, optimization algorithm such as particle swarm optimization is required [11].
Not all DG technology is suitable to control reactive power continuously. For an example, DG from intermittent resources such as Photovoltaic is not reliable because the required services probably cannot be delivered when it is needed. The technologies of synchronous generator based DG, micro turbine generation system and fuel cell can fit this requirement. These technologies are available commercially and capable to provide active power and other services such as reactive current injection when required.

A Technique of Particle Swarm Optimization Combined with MATPOWER Toolbox
Power system optimization problems are more complication and diversity when additional constraints are considered. The heuristic algorithm optimization is required in finding the optimal settings of control variables including voltage magnitude of a new DG. In this paper, the technique of applied MATPOWER into a particle swarm optimization (PSO) algorithm is contributed to solve ORPD problem integrating a DG.

MATPOWER
MATPOWER [12] is a powerful MATLAB programming package for power flow and optimal power flow solving. The biggest advantage of MATPOWER is its easiness to use and modify the original code. MATPOWER process can be applied into particle swarm optimization in terms of loss reduction in power system. The process of MATPOWER comprises of three steps as follows: Step 1: Input file, the power system data such as bus data, branch data and generator data will be read for next steps.
Step 2: Calculate the power flow by Newton-Raphson method.
Step 3: Display all results.

Particle Swarm Optimization
The particle swarm optimization algorithm (PSO) was discovered by James Kennedy and Russell C. Eberhart in 1995 [13,14]. This algorithm is inspired by simulation of social psychological expression of birds and fish. PSO includes two terms p best and g best . The concept of modification of a searching point by PSO is illustrated in Figure 2. The velocity Distribution Network with Distributed Generation of each particle is updated over the course of iteration from these mathematical equations: where, c 1 , c 2 are acceleration constants, k is the current iteration number.
The first part of (17) provides momentum to the particles. It provides diversification to the particles in search procedure. The inertia weight constant of the particles which controls the exploration of the search space, given by: The second and third parts of (17) are known as cognitive component and social component respectively. These components provide attraction towards best ever position and attraction towards best previous performance of neighborhood respectively. 'iter' is the number of iterations to be performed. Each particle's position is updated as (19).

Step by Step Procedures of PSO Algorithm Combined with MATPOWER Toolbox for ORPD
In the ORPD problem, the elements of the solution consist of all control variables, namely, generator bus voltages, the transformer tap setting and the reactive power generation. These variables are representing continuous variables in the PSO population. The fitness function of ORPD problem presented in this paper is to minimize the total power loss. For each individual, the equality constraints given by (7) and (8) are satisfied by using MATPOWER toolbox.
Step by step procedures to implement the optimal reactive power dispatch problem using PSO combined with MATPOWER toolbox are as follows: Step 1: Initialization of PSO parameters. Load case information: the system data; generator data, bus data and branch data are saved in MATPOWER case file.
Step 3: Find fitness value of fitness function and save p best and g best values.
Step 4: Update the velocity and position of each particle using (17) and (19).
Step 5: Call MATPOWER simulation function 'runpf' to run power flow updated particles' positions and velocities.
Step 6: Display simulation results and loss of each particle after power flow calculation using MATPOWER.
Step 7: Check whether the inequality constraints violates the limit or not at the end of power flow. If the solution exceeds the limits, penalize the violations.
Step 8: Find new fitness value of fitness function using updated particle position and velocity.
Step 9: Compare new fitness value with previous value. If the new fitness value obtained is better than the previous value, update new p best and g best .
Step 10: Repeat above procedure from step 4 for max no. of iterations.
The flow chart of the PSO algorithm combined with MATPOWER toolbox for ORPD is illustrated in Figure 3.

Case Study System Network
To demonstrate the effectiveness of the proposed PSO based algorithm for reactive power dispatch, a practical 41-bus distribution test system is used as shown in Figure 4. The distribution system is extracted from 132/66/33 kV Myingyan substation in Myingyan area of Myanmar. The voltage levels of the test system are 230 kV, 132 kV, 66 kV and 33 kV. This system has 6 generating stations, 36 load buses, 41 branches, 5 transformers, and 1 shunt reactive power compensator at bus 11. The incoming line of Myingyan substation is 132 kV line. There are 19 outgoing lines (66 kV and 33 kV lines). Yeywa (bus 1) is taken as the slack bus and other five generators are located at bus 2, 3, 4, 5 and 6 respectively. The evident features of the simulation results are also discussed in this section. The initial operating conditions for the proposed method are given as follows for 100 MVA base. The total load of the test system is 252.92 MW and 130.58 MVAr. MATPOWER toolbox is used to calculate the power flow of practical 41-bus distribution system. Before optimization, the total real and reactive power loss of the entire system is 15.969 MW and 32.87 MVAr, respectively.

Parameters of PSO Based ORPD
To successfully implement the proposed method for ORPD problem, the setting limits of reactive power control variables are shown in Table 1. The bus voltage magnitudes are maintained within 0.9 to 1.1 p.u. Table 2 shows the penalty factors of the fitness function used in (13). The basic parameters of PSO algorithm are shown in Table 3.

Testing Scenarios
Two scenarios were considered to show the effectiveness of the proposed method to control reactive power on practical 41-bus distribution system. The conventional PSO algorithm has been implemented in MATLAB programming language incorporated with MATPOWER package, and numerical tests are carried out on a core i5, 2.20 GHz, 4 GB RAM computer.
Scenario 1: Optimal reactive power dispatch without new DG and Scenario 2: Optimal reactive power dispatch with new DG and finding optimal placement of a new DG.
Scenario 1: Optimal reactive power dispatch without new DG. Figure 5 shows the optimization process of the proposed method without installing a new DG. At the beginning of the process, optimal active power loss is about 15 MW. As the particles continually update their positions towards the best solution, the real power loss keeps decreasing. After 160 iterations, no obvious improvement can be observed. Finally, the total power loss of the system converges to 13.4251 MW. The total CPU time is about 622.114 sec. The voltage profile of case study network after optimization using particle swarm optimization is shown in Figure 6. It can be observed that the voltages at each bus are maintained within their acceptable limits.   The second scenario is about adding a new DG to the practical 41-bus system and then optimizes the reactive power of the system by using the proposed approach. A direct-derive synchronous generator and gas turbine is selected as the new DG. Its rated power is 2050 kW which can deliver 1.2 MVAr and -1.0 MVAr reactive powers. The optimal placement of a new DG in 33 kV Myingyan distribution network is determined in this scenario.
If a new DG is installed on different buses, it will be required to modify the capacity of the real and reactive power to new parameters. The voltage magnitude of the new installed DG bus is added as a new control variable before executing the MATLAB code. A comparison of the real power loss of base case, optimization without new DG and optimization when DG is installed on various buses of 33 kV Myingyan distribution network is illustrated in Figure 7. It can be seen that optimization with a new DG can further reduce the active power loss than optimization using PSO without DG. After integrating a new DG on bus 39, the total active power loss can be reduced to minimum 12.0994 MW. The optimal placement of a new DG is on bus 39. Figure 8 shows the optimal loss reduction process of the proposed method when a small gas turbine is installed on bus 39. The initial real power loss of the system is at about 16.5 MW. The particles start to converge after conducting 130 iterations. Finally, the total power loss of the system is 12.0994 MW. The total CPU time is 651.403 sec.   The results from Table 5 show that the optimal settings of control variables to get minimum active power loss when a new DG is installed on bus 39. There are 13 control variables which optimize reactive power and the proposed method succeeds in keeping all control variables within their limits. The total active power loss after optimization with a new DG is 12.0994 MW. The optimal reactive power dispatch of generators is given in Table 6. The obtained results concerning with new DG installation show that all existing generators' reactive power ranges are within their acceptable limits.

Conclusion
In this paper, combined technique of particle swarm optimization algorithm with MATPOWER toolbox is applied to solve reactive power dispatch problem and to determine the optimal placement of new installed DG in existing system. The performance of the proposed technique has been tested on the 41-bus distribution system and compared the simulation results without and with DG. It can be observed that reactive power dispatch approach for distribution system with a distributed generation can further reduce the active power loss than without DG. The benefit of lower active power loss obtained will provide better economic dispatch and secure operation in power system.