You are on page 1of 6

Articial neural networks for solving the power ow problem in

electric power systems


V. Leonardo Paucar *, Marcos J. Rider
Department of Electrical Engineering, Federal University of Maranhao, Campus do Bacanga, 65085-580 Sao Luis, MA, Brazil
Received 20 June 2001; accepted 23 January 2002
Abstract
In this paper, the use of artificial neural networks (ANN) is proposed for solving the well known power flow (PF) problem of
electric power systems (EPS). PF evaluates the steady state of EPS and is a fundamental tool for planning, operation and control of
modern power systems. The mathematical model of the PF comprises a set of non-linear algebraic equations conventionally solved
with the Newton-Raphson method or its decoupled versions. In order to take advantage of the superior speed of ANN over
conventional PF methods, multilayer perceptrons neural networks trained with the second order Levenberg/Marquardt method
have been used for computing voltages magnitudes and angles of the PF problem. The proposed ANN methodology has been
successfully tested using the IEEE-30 bus system. # 2002 Published by Elsevier Science B.V.
Keywords: Power ow problem; Articial neural networks; Electric power systems
1. Introduction
The operation of electric power systems (EPS) is
managed, remote and automatically, from control
centers and energy management systems (EMS). Ad-
vanced on-line and off-line functions such as automatic
generation control, state estimation, topological analy-
sis, static security analysis, and others, are performed
routinely in modern EMS. Almost all of those functions
have to perform a large number of power flow (PF)
studies as a fundamental part of the operation meth-
odologies of their systems [1,2].
Steady state of power systems may be determined by
solving the PF equations that mathematically are
represented by a set of non-linear algebraic equations.
That problem is known as the load-flow or PF problem
and its main objective is the calculation of all bus
voltages magnitudes and angles, and consequently the
PFs over the transmission lines [1].
Continuous growth and complexity of power systems
have originated the adoption of sophisticated computer
tools for efficient planning, operation and control of
their systems. PF computer programs are used basically
to calculate the steady state of practical power systems
composed of hundreds or thousands of bus bars and
transmission lines [3,4].
For example, to perform the contingency screening,
which is one of the most CPU time consuming tasks for
on-line static security assessment, the computation in a
few minutes of many PF scenarios is very important
simulating the occurrence of several contingencies and
different loading conditions [3]. As a consequence of
that and other applications, many efforts have been
devoted to further speed up the solution of the PF
problem including sparse matrix and vector methods,
parallel processing and the adoption of powerful and
modern computers [1,2,4].
Most AC PF problems are solved with the well known
iterative Newton-Raphson (NR) method and with its
XB and BX fast-decoupled versions [2,4]. A common
practice for the initialization of the PF problem is to
adopt a flat start with 1.0 pu for voltage magnitudes and
zero degrees for angles [1]. Typically 3 or 4 of NR, XB
or BX iterations are needed to solve a PF problem
corresponding to practical size power systems and
without using accelerating factors. In other cases related
to stressed, longitudinal or ill-conditioned EPS, more
iterations may be necessary. An interesting and useful
alternative to the flat start is to use a previous solution * Corresponding author.
Electric Power Systems Research 62 (2002) 139/144
www.elsevier.com/locate/epsr
0378-7796/02/$ - see front matter # 2002 Published by Elsevier Science B.V.
PII: S 0 3 7 8 - 7 7 9 6 ( 0 2 ) 0 0 0 3 0 - 5
of a similar or generic operation condition case of the
EPS under analysis [1,5].
Artificial neural networks (ANN) is considered as an
important technique of artificial intelligence and it is
being used successfully in many areas of power systems.
Since the first paper dealing with neural networks
application in power systems was issued [6], increasing
literature demonstrates the potential of ANN in power
systems analysis, especially in applications that take
advantage of the speed of neural networks for on-line
calculations and their inherent capacity to overcome the
modeling complexity [7/9]. In Ref. [10] are discussed
interesting applications of ANN to power systems in, for
example, load forecasting, dynamic security assessment,
fault diagnosis, etc.
The proposal in this paper is to use ANN to compute
the bus voltages magnitudes and angles of the PF
problem of power systems. The proposed ANN-based
PF solver is intended to be faster than the conventional
PF problem solvers which use the NR method, particu-
larly in those cases involving advanced on-line applica-
tions of the PF problem in the EMS. The proposed
ANN architectures and the selected input/output vari-
ables used in the training and testing of the nets will be
presented in the remaining parts of this paper. Applica-
tion results to the IEEE-30 bus test system (IEEE-30)
are also discussed.
2. The proposed neural network methodology
Applications of back-propagation neural networks
(BP) to static security analysis of small test power
systems is reported in the literature [11]. Besides that
and other BP applications to PF problems, some non-
traditional neural networks have been proposed in the
literature for solving PF problems such as the counter-
propagation neural network [8], Hopfield model [12],
radial basis functions [9] and a neural network PF based
in an ANN-based minimization model [13]. In spite of
the prospective success of those non-conventional mod-
els, the proposal in this work considers the adoption of
the popular and well-known neural network feed-
forward multilayer perceptron (MLP) architecture with
some additional considerations to be detailed in the
following paragraphs. Those considerations will en-
hance the results of the proposed ANN compared with
other nets proposed in the literature.
It is assumed that a simple MLP neural network
composed of a single hidden layer and the output layer
is capable of solving difficult and complex problems like
the non-linear PF problem. Non-linear hyperbolic
tangent activation functions may be used for the hidden
units while linear activation functions may be used in
the output units. It must be noted that feed-forward
MLP is the most extended ANN architecture in
engineering and EPS applications [10,14,15].
In Fig. 1 a schematic diagram of the proposed MLP
neural networks architecture is shown. The vector x
includes the input variables and y is the output vector
containing the voltage magnitude and angle for each
bus. NN
V
represents the net for voltage computation
and NN
u
for angle calculation. Consequently the
number of NN
V
nets will be equal to the number of
PQ buses and the number of NN
u
nets will be equal to
the sum of PQ and PV buses.
The composition of the input variables for the
proposed neural networks has been carefully selected,
attempting to emulate the solution process of a conven-
tional PF computer program. The following data has
been considered in the input: the electric network
parameters represented by the diagonal elements of the
bus conductance and susceptance matrix, voltage mag-
nitudes of generation buses including the slack bus, the
active power generations of PV buses, and those
parameters values related to contingency simulation.
In order to accelerate the neural networks training, the
conductance and susceptance elements must be normal-
ized. For this ANN-based PF model the system loads,
active and reactive power components, are represented
like constant admittance and they are included into the
diagonal of the bus admittance matrix [Y] /[G]/j [B],
where [G] and [B] are the bus conductance and
susceptance matrices, respectively.
Supervised training of ANN is a usual training
paradigm for MLP architectures. Since the PF problem
demands a solution with high precision, the neural
networks have to be trained considering a very small
stopping criterion. In this case the first order training
methods are not recommended due to its convergence
difficulties in the vicinity of global optimum [15,16]. For
this reason the second order Levenberg/Marquardt
training method will be adopted [17]. A computer
Fig. 1. Proposed MLP ANN architecture.
V.L. Paucar, M.J. Rider / Electric Power Systems Research 62 (2002) 139/144 140
program written in C// language has been implemented
to perform the simulations reported here.
Output values of the trained neural networks must be
capable of computing the voltages with very good
arithmetic precision. An advantage of the ANN calcula-
tion is that there is no possibility of non-convergence as
it might occur with iterative methodologies like NR [18].
The proposed methodology suggests the use of ANN
as a PF solver of a specific power system. Input and
output data of the neural networks are the same used in
a PF program. Only a previous processing of some
values is necessary, such as the elements of bus
admittance matrix, which will be supplied to the trained
neural networks.
In order to obtain a very good generalization
capability of the neural networks, the composition of
the training data will take into account several loading
scenarios, simple contingency occurrence cases simulat-
ing power generation variations, outages of transmission
lines, different generation voltage values, switching of
shunt reactors and capacitors, and simulation of differ-
ent on load transformer tap values. Depending on the
analysis to be conducted, it is possible to increase or
reduce the quantity of training cases.
In the literature, application results of simple con-
tingencies like transmission lines outages and several
loading levels have been reported. Contingencies that
originate islands or subsystems will not be considered
for training data. Contingencies that cause system
division may be overcome by solving each subsystem
separately [8/10].
An adequately trained neural network is expected to
compute the bus voltages and angles with adequate
precision when loading levels are not very different from
the maximum and minimum loading limits imposed by
the training data. Stopping criteria and performance
assessment of the ANN need useful quantities like those
shown in Eq. (1) /Eq. (6):
e
V
ij
jV
NR
ij
V
NN
ij
j 100%; (1)
e
u
ij
ju
NR
ij
u
NN
ij
j; (2)
e
maxV
maxfe
V
ij
g; i 1; . . . ; nb; j 1; . . . ; n (3)
e
maxu
maxfe
u
ij
g; i 1; . . . ; nb; j 1; . . . ; n (4)
e
avV

1
n nb
X
n
j1
X
nb
i1
e
V
ij
(5)
e
avu

1
n nb
X
n
j1
X
nb
i1
e
u
ij
(6)
where i , j /bus number, PF case number; n, nb/
number of PF cases, number of buses; V
ij
NN
, V
ij
NR
/
voltage magnitudes computed by NN
V
, NR; u
ij
NN
,
u
ij
NR
/voltage angles computed by NN
u
, NR;
e
maxV
/maximum simple voltage error, in %; e
maxu
/
maximum simple bus angle error; e
avV
/average voltage
error for n cases, in %; e
avu
/average angle error for n
cases.
In Eq. (1), e
V
ij
is the simple error in voltage magnitude
and it is defined as the difference between the voltage
magnitude computed with a NR program and that
voltage computed with the trained ANN. The simple
angle error e
u
ij
is given by Eq. (2). In Eq. (5), e
avV
is the
average voltage error for all buses and simulated cases.
3. Application results
The IEEE-30 system, which is composed of 30 buses
and 41 branches, has been used to test the proposed
methodology; its one line diagram is given in Fig. 2. This
system has been simulated with 10 load scenarios from
which 6 have been used for training and 4 for testing of
the neural networks. Minimum and maximum active
power load levels have been considered 212.55 and
354.25 MW, respectively. The base case considered
283.40 MW, consequently a variation of 9/25% has
been assumed in the load level with respect to the base
case. The total number of generated PF cases has been
583 from which 351 cases have been chosen randomly
for training and the remaining 232 cases for testing of
the proposed ANN. Those quantities correspond to a
large amount of cases, normally encountered in practical
power system security applications [3,7,10].
Enhanced generalization capability in the application
of the proposed ANN-based PF is attained when the
training and testing data is generated considering almost
all possible simple contingency occurrences and a great
interval of load levels. Contingencies that originate
subsystems have been avoided in order to prevent non-
convergence situations or difficult training of the neural
networks. Those subsystems problems may be solved by
analyzing those islands separately. The slack bus gen-
erator was not considered in the list of contingencies of
generator trippings. The variation level of transformer
taps has been considered from 0.9 to 1.1 pu by using
small steps. Switching of shunt compensations has been
simulated only for buses that have this option with small
discrete steps being the extreme values 15 and 25 MVAr.
Generation tensions have been modified from 1.0 to
1.15 pu, including the slack bus.
It is expected that the neural networks will be able to
learn the voltages pattern corresponding to training
cases and besides they will acquire the generalization
capability to solve new PF cases. In Fig. 3 the tension
profiles corresponding to the voltages of PQ buses vs.
contingencies for all training cases is shown. The ANN
must learn those voltage profiles during the training as
will be shown later.
V.L. Paucar, M.J. Rider / Electric Power Systems Research 62 (2002) 139/144 141
The proposed neural networks have been trained until
the absolute value of the mean square error (MSE) was
below 1e/9. After a successful training NN
V
and NN
u
networks are ready to compute the bus voltages
magnitudes and angles of any new simple contingency
and load level operation condition of the corresponding
power system. Benchmark results for voltage magni-
tudes and angles have been assumed from output values
of a conventional NR PF computer program for which a
maximum power mismatch d/1.0e/4 pu as stopping
criterion of NR iterations has been considered.
The most adequate architectures of the NN
V
and
NN
u
neural networks have been selected using cross
validation [14]. NN
V
is composed of 67 input units, 10
neurons in the hidden layer and 1 unit in the output
layer. NN
u
also has the same architecture.
For a typical training of the neural networks NN
V
and NN
u
, the maximum training errors have been
e
maxV
/0.016% and e
maxu
/0.0128. On the other
hand, the maximum errors in the testing stage of the
proposed neural networks have been e
maxV
/0.124%
and e
maxu
/0.0588. The average error of voltages
magnitudes for all 232 test cases has been found as
e
avV
/0.004%. The maximum error in voltage magni-
tudes for all test cases has been identified as occurring in
bus No. 3 when the total load was 354.25 MW. In Ref.
[9] a maximum voltage error e
maxV
/2.5% for a 10-bus
power system has been reported while in other refer-
ences maximum errors greater than 2.5% have been
reported [10].
Fig. 2. One line diagram of the IEEE-30 test system.
Fig. 3. Voltages of PQ buses of IEEE-30 system for 351 training PF
cases.
V.L. Paucar, M.J. Rider / Electric Power Systems Research 62 (2002) 139/144 142
Results corresponding to the worst test case during
the training have been included in Table 1. The two last
columns contain the comparison between the voltages
computed with a conventional NR program and with
the proposed ANN. From those results it has been
observed that the proposed nets have solved the PF with
very good precision.
In Figs. 4 and 5, profiles have been detailed of the bus
voltages and angles at bus No. 3 vs. contingencies, and
for the load level of 354.25 MW, which has originated
the maximum voltage error during the test stage. As can
be noted from all results, the MLP nets may solve a
large number of PF problems with excellent processing
times and adequate precision.
In spite of the successful results reported here, the
application of ANN to solve the PF problem as part of a
contingency analysis of large scale power systems it is
not very practical and novel developments will be
welcome. Two problems are associated with that
difficulty, the computer memory requirements and the
CPU time. The first one, which is related to the neural
network dimension, may be overcome by reducing the
number of inputs and neurons. As a consequence of that
reduction the CPU time will be enhanced.
Table 1
Comparison of NR and ANN (NN
V
, NN
u
) outputs corresponding to the case of maximum test error, IEEE-30 system
Bus No. NR ANN (NN
V
, NN
u
) Error
V (pu) u (8) V (pu) u (8) e
Vij
(%) e
uij
(8)
1 1.0600 0.00 1.0600 0.00 / /
2 1.0450 6.69 1.0450 6.70 / 0.0106
3 1.0135 9.99 1.0123 9.99 0.1238 0.0054
4 1.0041 12.08 1.0036 12.09 0.0480 0.0118
5 1.0100 18.05 1.0100 18.05 / 0.0032
6 1.0051 14.23 1.0046 14.23 0.0525 0.0080
7 0.9970 16.46 0.9967 16.46 0.0348 0.0093
8 1.0100 15.26 1.0100 15.25 / 0.0033
9 1.0442 17.90 1.0440 17.91 0.0212 0.0032
10 1.0347 19.84 1.0345 19.84 0.0235 0.0073
11 1.0820 17.90 1.0820 17.91 / 0.0016
12 1.0443 19.70 1.0442 19.71 0.0120 0.0105
13 1.0710 19.70 1.0710 19.72 / 0.0192
14 1.0220 20.99 1.0216 21.00 0.0414 0.0156
15 1.0120 21.18 1.0115 21.18 0.0475 0.0074
16 1.0313 20.11 1.0311 20.13 0.0239 0.0145
17 1.0270 20.19 1.0267 20.20 0.0347 0.0177
18 0.9816 22.84 0.9814 22.85 0.0195 0.0013
19 0.9680 23.61 0.9679 23.60 0.0084 0.0041
20 1.0304 20.11 1.0305 20.11 0.0091 0.0029
21 1.0180 20.47 1.0176 20.48 0.0397 0.0104
22 1.0184 20.47 1.0182 20.47 0.0222 0.0003
23 1.0019 21.37 1.0016 21.37 0.0344 0.0013
24 0.9992 21.17 0.9991 21.17 0.0132 0.0035
25 0.9972 20.67 0.9970 20.67 0.0194 0.0022
26 0.9745 21.22 0.9743 21.22 0.0168 0.0013
27 1.0069 20.02 1.0069 20.02 0.0038 0.0011
28 1.0008 15.02 1.0006 15.02 0.0223 0.0010
29 0.9813 21.62 0.9811 21.63 0.0186 0.0023
30 0.9665 22.78 0.9663 22.79 0.0199 0.0061
Fig. 4. Voltage at bus No. 3 under simple contingencies when the
IEEE-30 system load is 354.25 MW, corresponding to the case of
maximum test error.
V.L. Paucar, M.J. Rider / Electric Power Systems Research 62 (2002) 139/144 143
4. Conclusions
The use of neural networks to compute the bus
voltages, magnitudes and angles, in order to solve the
PF problem has been proposed. The Levenberg/Mar-
quardt second order training method has been adopted
for obtaining small MSEs without losing generalization
capability of the ANN.
A careful selection of input variables has been
important for defining the most adequate MLP archi-
tectures. To minimize the input data dimension only the
diagonal elements of bus conductance and susceptance
matrices instead of the full bus admittance matrix has
been included.
IEEE-30 test system has been used to test the
proposed ANN-based PF methodology. Of 583 PF
generated cases, 351 cases have been chosen randomly
for training and 232 for testing. These cases have
simulated the occurrence of simple contingencies and
several load and generation conditions.
The maximum voltage error of all training and testing
cases of the tested power system has been 0.124% while
the average error was below of 0.004%. Those values are
better than other results reported in the literature on
neural networks-based PF; this fact confirms the power
of simple MLP neural networks to power systems
applications.
Acknowledgements
The authors would like to thank the Brazilian
institutions: CAPES (Coordenacao de Aperfeicoamento
Superior) and CNPq (Conselho Nacional de Desenvol-
vimento Cient co e Tecnologico), for their support to
this research.
References
[1] J. Arrillaga, C.P. Arnold, B.J. Harker, Computer Analysis of
Power Systems, Wiley, 1991.
[2] B. Stott, Review of load-ow calculation methods, IEEE Proc. 62
(1974) 916/929.
[3] S. Weersooriya, M. El-Sharkawi, M. Damborg, R.J. Marks, II,
Towards static security assessment of a large scale power system
using neural networks, IEE Proc. */C 139 (1992) 64/70.
[4] R. Van Amerongen, A general-purpose version of the fast
decoupled load ow, IEEE Tran. Power Syst. 4 (2) (1990) 760/
770.
[5] J.B. Ward, H.W. Hale, Digital computer solution of power-ow
problems, Tran. AIEE PAS-75 (1956) 398/404.
[6] D.J. Sobajic, Y.H. Pao, Articial neural-net based dynamic
security assessment for electric power systems, IEEE Tran. Power
Syst. 4 (1) (1989) 220/226.
[7] Y. Mansour, A. Chang, J. Tamby, E. Vaahedi, B. Corns, M. El-
Sharkawi, Large scale dynamic security screening and ranking
using neural networks, IEEE Tran. Power Syst. 12 (2) (1997) 954/
960.
[8] K.L. Lo, L.J. Peng, J.F. Macqueen, A.O. Ekwue, D.T.Y. Cheng,
Fast real power contingency ranking using a counterpropagation
network, IEEE Tran. Power Syst. 13 (4) (1998) 1259/1264.
[9] J.A. Refaee, M. Mohandes, H. Maghrabi, Radial basis function
networks for contingency analysis of bulk power systems, IEEE
Tran. Power Syst. 14 (2) (1999) 772/778.
[10] M. El-Sharkawi, D. Niebur, Articial neural networks with
applications to power systems, IEEE PES special publication 96
TP 112-0 (1996).
[11] R. Fischl, M. Kam, J.-C. Chow, S. Ricciardi, Screening power
system contingencies using a back-propagation trained multi-
perceptron, Proceedings of the IEEE International Symposium on
Circuits and Systems, (1989) 486/489.
[12] H. Mori, Quadratic load ow calculation in electric power
systems using a Hopeld model, Proceedings of ICANN92,
Brighton, UK, (September) (1992) 1667/1670.
[13] T.T. Nguyen, Neural network load-ow, IEE Proc. */Generation
Transmission Distribution 142 (1) (1995) 51/58.
[14] S. Haykin, Neural Networks: a Comprehensive Foundation,
second ed., Prentice Hall, 1998.
[15] V.L. Paucar, A.L. Morelato, E. Vuono, Training an ANN with
the BFGS method for real-time identication of sinusoidal
waveforms, Proceedings of ISAP99, Brazil (April) (1999) 193/
196.
[16] R. Battiti, First and second-order methods for learning: between
steepest descent and Newtons method, Neural Comput. 4 (2)
(1992) 141/166.
[17] M.T. Hagan, M.B. Menhaj, Training feedforward networks with
the Marquardt algorithm, IEEE Tran. Neural Networks 5 (6)
(1994) 989/993.
[18] V.L. Paucar, M.J. Rider, Efcient power ow problem initializa-
tion using articial neural networks, Proceedings of LESCOPE
2000, Nova Scotia, Canada (July) (2000) 119/123.
Fig. 5. Angle at bus No. 3 under simple contingencies when the IEEE-
30 system load is 354.25 MW, corresponding to the case of maximum
test error.
V.L. Paucar, M.J. Rider / Electric Power Systems Research 62 (2002) 139/144 144

You might also like