# An Anfis Based Optimal Capacitor Placement Model Computer Science Essay

Published:

This paper deals with the design of distributed power systems and optimal capacitor placements based on the ANFIS (Adaptive Network Fuzzy Inference Systems) using Mamdani-type fuzzy inference model. Traditionally, this problem of optimal capacitor placement has been solved through various optimization techniques, but it is more time consuming than various non-traditional techniques. These non-traditional techniques can provide a better solution with lesser computational time but still there is scope for improvement of such solution. In this paper, we introduce ANFIS architecture for the first time to obtain an optimal capacitor placement in power-distributed systems. The results are compared with 34-bus distribution test system with other models, with respect to the capacitor placement on the networks, savings and the computational time.

Keywords: Optimal Capacitor Placement, Fuzzy Logic, Artificial Neural Networks (ANN), ANFIS, Optimal power flow.

## 1. Introduction

The installation of shunt capacitors on radial distribution feeders is essential for many reasons, a few of which are power flow control, improving system stability, power factor correction, voltage profile management, and loss minimization. Capacitor planning must determine the optimal site and size of capacitors to be installed on the buses of a radial distribution system.

### Professional

#### Essay Writers

Get your grade

or your money back

using our Essay Writing Service!

Many researchers have developed algorithms to solve a problem by installing shunt capacitors on redial distribution feeders, analytical approaches [1-4], numerical programming methods [5-8], heuristic programming [9-12], approaches based on genetic algorithms [13-18], ANN and fuzzy based approaches discussed in [19-22], and hybrid algorithms [23-24]. The algorithms / procedures described above to obtain the optimal capacitor placements have their own merits and demerits. The input and output variables discussed in ANN and genetic algorithms are deterministic in nature, whereas practical considerations in reality are uncertain in nature. Hence defining fuzzy type input / output variables are necessary and that will lead to more accurate results. The fuzzy expert system [22-24] approaches to determine the suitable locations for capacitor placement have disadvantages, because the actual fuzzy linguistic classifications of input and output variables are considered as such. But in this paper, we combine fuzzy and neural, which has advantages that even some smaller deviations defined in the linguistic classification can be adjusted during the neural network training and it determines the actual placement of the capacitors.

Another advantage of this paper is the ANFIS - Mamdani model finds the optimal capacitor placement accurately rather than other methods discussed so far in the literature, because of the fuzzy-natured output. No researchers in this field have concentrated on ANFIS-Mamdani model because of its operational complexity and no readymade software supported this idea including Matlab. In this paper, we applied both the manual and computational calculations to achieve the result.

The arrangement of rest of this paper is as follows: The reactive compensation problem and its mathematical background are formulated in section 2. Section 3 presents the proposed solution method with a brief explanation of layer-wise ANFIS architecture and its solution procedure. In Section 4, the proposed method is evaluated using some standard distribution networks and finally the result is compared with other techniques.

## 2. Mathematical Formulation:

In this paper, we combine the learning capability of neural network and fuzzy reasoning. The scheme is called the fuzzy neural network (FNN). The FNN can be realized as a neural network structure, and the parameters of fuzzy rules can be expressed as the connection weights of the neural network. It is easy to translate the "expert-priori-knowledge" into the fuzzy if-then rules. The FNN architecture employed in this work is the ANFIS in which Mamdani type fuzzy inference system is employed. The ANFIS architecture can construct an input-output mapping based on both human knowledge, in the form of if-then rules, and stipulated input-output data pairs. The ANFIS will be employed in two fuzzy inputs called the Power Loss Index (PLI) and the Voltages(V) and one fuzzy output called Capacitor Placement Suitability (CPS).

The block diagram of the ANFIS based capacitor placement evaluation is given below:

## Capacitor Placement

## ANFIS

## Load Flow Diagram

## System Data

## cement ïƒž ïƒž ïƒž

## Capacitor Sizing Algorithm ïƒ ïƒŸ

## ïƒœ ïƒœ

The objective function for capacitor placements is to reduce the total energy losses and to maintain the bus voltage within the prescribed limits with minimum cost. The defined objective function has two parts, namely the cost of capacitor placement and the cost of total energy losses. The cost of capacitor placement includes the cost of capacitor, installation and the operational cost.

### Comprehensive

#### Writing Services

Plagiarism-free

Always on Time

Marked to Standard

The objective function of the optimal capacitor placement is given below:

## Objective function:

Minimize (1)

## subject to the constraints

(2)

where F = the total annual cost function defined in $'s, KPL = annual cost per unit of power losses ( $/kW ) , PL = total active power losses (kW), KC(m) = cost of capacitor placement (cost / kVAR), B(m) = shunt capacitor size placed at bus m (kVAR), N = total number of buses, Vmin(i) = minimum permissible rms voltage at bus i, and Vmax(i) = maximum permissible rms voltage at bus i.

Generally, the losses in the distribution line happen due to the following two factors, which are (i) Current flowing through the conductor, and (ii) The resistance in the line. The annual power losses can be estimated through the formula

PL = I2 . R . L . DF . LF .TPY (3)

Where I = total current flowing through the line for single phase, R = resistance of the line, L = length of the line, DF = discounting factor, LF = load factor and TPY = total number of hours working per year.

Several researchers have developed the optimum sizes of the capacitor following many different approaches, namely, analytical methods [4, 7, 28-30], numerical programming methods [5], heuristic methods [11], and AI based methods which includes genetic algorithms, expert systems, simulated annealing, artificial neural networks, fuzzy set theory and combination of the above AI based techniques called hybrid techniques [13, 22-25 ].

In this paper, we have used the following optimization model for finding the size of the capacitor, and it is given below:

Maximize: (4)

## subject to the constraint

(5)

where ï„LP = the loss reduction in peak demand, ï„LE = energy due to capacitor installation, KP = cost of peak demand per kVAR, KE = cost of energy per kVAR, Kc = cost of capacitor per kVAR, C is the size of the capacitor in kVAR, ï„V = the change in voltage due to capacitor installation, and ï„Vmax = Maximum Voltage which cannot be exceeded.

## 3. Adaptive Neuro-Fuzzy Inference Systems (ANFIS):

Neuro-fuzzy techniques have emerged from the fusion of artificial neural networks and fuzzy inference systems. Fuzzy inference is the process of formulating the mapping from a given input to an output using fuzzy logic. Then, the mapping provides a basis from which decisions can be made, or patterns discerned. The process of fuzzy inference systems (FIS) involves fuzzification, design of fuzzy-based systems using fuzzy if-then rules, Mamdani-aggregator, and the defuzzification.

In this section, we design ANFIS architecture with Mamdani-type to determine the optimum capacitor placment in the distributed power systems. ANFIS is used a hybrid-learning algorithm to identify the membership function parameters of single-output, Mamdani-type fuzzy inference systems. Mamdani-type inference, expects the output membership functions to be fuzzy sets. A combination of least-squares and back propagation gradient descent methods are used for training FIS membership function parameters to model a set of input / output data.

The designed ANFIS architecture can have two fuzzy inputs and one fuzzy output. The two fuzzy inputs are Power Loss Index and Voltage, and the fuzzy output variable is Capacitor Placement Suitability. All the fuzzy input and output variables are linguistically divided into five linguistic classifications, namely Low (L), Low Medium (LM), Medium (M), High Medium (HM) and High (H). The theoretical background, expert knowledge and Turing test can be used to evaluate the fuzzy membership functions. The membership diagram for the above said input and output fuzzy variables are given in figs. 1-3. The advantages of the ANFIS procedure to obtain the optimum capacitor placements are (i) even if a small variation occurs in the membership function evaluation, that can be adjusted during ANN training, (ii) anomalies, if any, are self corrected, and (iii) the decision is taken afterwards using either back propagation or hybrid learning algorithm and not merely the fuzzy design rule.

Fuzzy decision matrix, given in table-1, is used for input variables PLI and V to identify the optimum node for finding the suitability of the capacitor placement.

## 3.1 Design of ANFIS architecture for finding the optimum capacitor placement

The ANFIS can simulate and analyze the mapping relation between the input and output data through an artificial neural network learning algorithm to optimize the parameters of a given fuzzy inference systems, namely the power loss index, the voltage and the capacitor placement suitability. It combines the powerful features of fuzzy inference systems with those of artificial neural networks. The computational procedure for finding the capacitor placement suitability through Mamdani fuzzy inference system is based on the following rule [25], "Under sum-product composition, the output of a Mamdani FIS with centroid defuzzification is equal to the weighted average of the centroids of consequent membership functions, where each of the weighting factors is equal to the product of a firing strength and the consequent membership functions area".

### This Essay is

#### a Student's Work

This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.

Examples of our workA typical architecture of ANFIS is shown in Fig. 4, where a circle indicates a fixed node, and a square indicates an adaptive node. The designed ANFIS has five layers and the layer-wise explanation is given below:

## Layer 1 :

Two input nodes are used in this layer, called PLI and V. The normalized input data should be fed into this layer. The output of this layer is the corresponding membership value of PLI and the voltage. The triangular and trapezoidal membership functions are used for designing fuzzy membership function. Symbolically, it can be defined as

The diagrammatic representation of the membership function for PLI and V are given in figs. 1-2, and its mathematical representations are given in equations (6) and (7). The output of node-1 and node-2 in layer-1 are computed through equations (6) and (7) respectively.

(6)

(7)

## Layer -2:

There are 25 nodes used in this layer and every node is a fixed node labeled ï, whose output is the product of all the incoming signals; we have manually defined 25 rules and the output of these 25 rules will be the output of layer-2. Based on the fuzzy decision matrix is given in table-1, the following rules will be framed.

Rule 1: if x ï¥ PLI-LOW and if y ï¥ V-LOW then output = CPS-LM

Rule 2 : if x ï¥ PLI-LOW and if y ï¥ V-LM then output = CPS-LM

Rule 3 : if x ï¥ PLI-LOW ad if y ï¥ V-M then output = CPS-LOW

## .

Rule 25: if x ï¥ PLI-HIGH and if y ï¥ V-HIGH then output = CPS-LM

Symbolically, it is defined as. Each node output represents the firing strength of a rule. The membership function for CPS is given in equation (8).

(8)

The output of this layer can be designed to find the weight value of wi, it can either by using max-min procedure or max-product procedure which are clearly defined in [25]. But, in this paper we followed by max-product procedure to find the wi value for i = 1 to 25.

## Layer -3 :

There are 25 nodes assigned in this layer and every node is a fixed node labeled N. Each node in this layer computes two constant values, namely ai and zi, where ai = area of the compounded membership function obtained at node i, and zi = centroid of the compounded membership function obtained at node i. The formula for obtaining ai and zi are

Symbolically, the output of this layer is defined as,

O3i = wi ai zi for i = 1, 2, 3, â€¦, 25

## Layer -4 :

Two nodes are used in this layer which is fixed nodes labeled Î£. The first node computes Î£ wi ai zi and the second node computes Î£ wi .

## Layer - 5 :

The single node in the fifth layer is a fixed node labeled '/ ' that computes the overall output of the given ANFIS structure. Symbolically, the output of this layer is defined by

O51 = Î£ wi ai zi / Î£ wi.

It is seen from the ANFIS architecture that when the values of the premise parameters are fixed, the overall output can be expressed as z = Î£ wi ai zi / Î£ wi.. The optimal values of the consequent parameters can be found by using the least-square method (LSM). When the premise parameters are not fixed, the search space becomes larger and the convergence of training becomes slower. The hybrid learning algorithm combining the LSM and the back propagation (BP) algorithm can be used to solve this problem. This algorithm converges much faster since it reduces the dimension of the search space of the BP algorithm. During the learning process, the premise parameters in the layer1 and the consequent parameters in the layer 4 are tuned until the desired response of the FIS is achieved. The surface diagram of the given rule matrix given in table-1 is given in fig. 5.

The solution procedure includes manual calculation as well as programming techniques that are used to obtain the result. We manually derived the fuzzy compounded membership function for all the 25 rule combinations separately and the resultant values are used to obtain the area and centroid of the compounded membership function at every node of the ANFIS architecture given in layer-3. The output membership function satisfies the normality, convexity, symmetricity and equal bandwidth property, so that it is easy to find the compounded membership function, but the exact computational time cannot be predicted because of the nature of the problem.

## 4. Results Analysis and Discussion:

The proposed ANFIS has been applied to test the capacitor placement problem on 34-bus radial distribution system [26] with one main feeder and four laterals, and the rated line voltage is 11 kV. The line and the load data can be found in [26], and a single line diagram of the given distribution system is shown in fig.7.

After computation of the node voltage and power loss indices, we find the high suitability position for installing the capacitors. There are five combinations that will provide high suitability indices; namely, rules 11, 16, 17, 21 and 22. Out of these five combinations, we rank the optimal rule that satisfies our constraints and assumptions and they are 17, 22, 16, 21, and 11. Based on the above assumptions, PLI and voltage calculations, the ANFIS determined that the node 26 has the first and foremost suitable place for installing a capacitor with a capacity of 1350 kVAR. The same procedure is to be applied repeatedly to find the suitable positions to place the capacitors. The subsequent computations of the ANFIS obtain the suitability positions as 18, 17 and 6 with capacitor sizes 650, 430 and 325 kVAR respectively. The minimum and the maximum voltages before the capacitor placement are 0.93785 p.u and 0.989321 p.u respectively. After the capacitor placement it varies between 0.967324 p.u and 1.028711 p.u.

Using the programming techniques, we have generated considerably large amount of raw data points through simulation and tested with ANFIS architecture using back-propagation and hybrid methods of two hidden layers of 120 and 96 neurons apart from input and output layers, the error level 1e-04 is reached in 2648 epochs. The simulation results of 34-bus system are compared with other methods is given in table -2:

## 5. Conclusions

A new and novel approach is presented in this paper to determine suitable candidate nodes in the power distribution systems for capacitor placement problem. The exactness of the candidate nodes installation is based on the non-linear network optimization obtained through deepest descent method and least square estimations used for both back-propagation and hybrid learning techniques with error accuracy 1e-04. The advantages of the proposed method are: i). the deterministic and probabilistic approaches are used together to determine the suitable capacitor placement and its size of the capacitors. ii). it guarantees to achieve a local optimum and closely to the global optimization, and iii). it achieves better savings when compared with other methods discussed in the literature.

In future work, the extreme learning machine concepts will be used to determine the optimum capacitor placement with less computational time.