Sie sind auf Seite 1von 79

Martin Geidl

Implementation of FACTS and Economic


Generation Dispatch in an Interactive Power
Flow Simulation Platform
Diploma Thesis PSL0201
Department:
EEH Power Systems Laboratory, ETH Z urich
Experts:
Prof. Dr. G oran Andersson, ETH Z urich
Univ.-Prof. Dr. Lothar Fickert, TU Graz
Supervisors:
Dipl. El. Ing. ETH Christian Schaner, ETH Z urich
Ass.-Prof. Dr. Herwig Renner, TU Graz
Z urich, March 2003
Vorwort
Diese Diplomarbeit habe ich im Rahmen meines Erasmus-Studienaufenthaltes an
der ETH Z urich von August 2002 bis M arz 2003 verfasst. In dieser Zeit hatte ich
Gelegenheit mich intensiv mit meinen personlichen Interessensgebieten zu befassen,
die Arbeit hat mir sehr viel Freude bereitet.
Bedanken mochte ich mich bei all jenen, die mich in dieser Zeit begleitet haben:
Meinen Eltern f ur die groz ugige Unterst utzung und das Vertrauen, meinem Bruder
Stefan f ur den privaten IT-Support, Michi f urs Coaching, Wol und Georg f ur die
Zeit in Z urich, den Maxen f ur die Wochenenden daheim, Sandra und Thomas f ur
die netten Abende.
Bei allen Mitarbeitern des PSL bedanke ich mich f ur die freundliche Aufnahme in
der Gruppe und das angenehme Arbeitsklima. Rusejla, Tina und Thilo danke ich
f ur die zahlreichen Tipps und die spannenden fachlichen Diskussionen.
Besonderer Dank gilt Prof. Goran Andersson und Prof. Lothar Fickert sowie meinen
Betreuern Dr. Herwig Renner und Christian Schaner. Sie haben mir die M oglichkeit
gegeben diese Arbeit durchzuf uhren und mich dabei bestens betreut.
Vielen Dank!
Z urich, am 7. M arz 2003
i
Abstract
Title: Implementation of FACTS and Economic Generation Dispatch in an Inter-
active Power Flow Simulation Platform
Keywords: SVC, TCSC, Injection Model, KKT, Unlimited Point, Economic Dis-
patch
This diploma thesis reports the implementation of new features in a power ow
simulation platform. The FACTS elements SVC and TCSC are mathematically
described and implemented in the Newton-Raphson power ow computation as well
as in the GUI. The SVC element is equipped with regulation on reactive power,
voltage and ring angle, the TCSC is implemented with regulation on active power
and ring angle. Furthermore an Economic Generation Dispatch which targets
minimisation of the total generation costs in a network is implemented, whereas the
cost functions of the generators are assumed to be quadratic functions of the active
power output. The inequality constrained optimisation problem is solved with the
so-called Unlimited Point algorithm.
ii
Kurzfassung
Titel: Implementierung von FACTS und Economic Generation Dispatch in einer
interaktiven Lastuss-Simulationsumgebung
Stichw orter: SVC, TCSC, Injection Model, KKT, Unlimited Point, Economic
Dispatch
In der vorliegenden Arbeit wird eine bestehende Lastuss-Simulationsumgebung er-
weitert. Die FACTS-Elemente SVC und TCSC werden mathematisch modelliert
und sowohl in der Newton-Raphson Lastussrechnung als auch im GUI implemen-
tiert. Der SVC wird mit Regelung auf Blindleistung, Spannung und Steuerwinkel
ausgestattet, der TCSC wird mit Regelung auf Wirkleistung und Steuerwinkel imple-
mentiert. Weiters wird ein Modul Optimaler Kraftwerkseinsatz zur Minimierung
der gesamten Erzeugungskosten in einem Netzwerk implementiert, wobei die Kosten
der Generatoren als quadratische Funktionen der Wirkleistung angenommen werden.
Das ungleichheitsbeschrankte Optimierungsproblem wird mit dem Unlimited Point
Algorithmus gel ost.
iii
Contents
List of Acronyms viii
List of Symbols ix
1 Introduction 1
1.1 Assignment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.2 Simulation Platform FlowDemo.net . . . . . . . . . . . . . . . . . . . 1
1.3 Flexible AC Transmission Systems . . . . . . . . . . . . . . . . . . . 3
1.3.1 Thyristor Controlled Reactor . . . . . . . . . . . . . . . . . . 3
1.3.2 Static Var Compensator . . . . . . . . . . . . . . . . . . . . . 4
1.3.3 Thyristor Controlled Series Capacitor . . . . . . . . . . . . . . 5
1.4 Power Flow Computation . . . . . . . . . . . . . . . . . . . . . . . . 5
1.4.1 Newton-Raphson . . . . . . . . . . . . . . . . . . . . . . . . . 6
1.5 Economic Generation Dispatch . . . . . . . . . . . . . . . . . . . . . 7
2 FACTS Modelling 8
2.1 FACTS Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.1.1 Injection Model . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.1.2 Total Susceptance Model . . . . . . . . . . . . . . . . . . . . . 9
2.1.3 Firing Angle Model . . . . . . . . . . . . . . . . . . . . . . . . 10
2.2 Implemented Models . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
2.2.1 TCR Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
iv
CONTENTS
2.2.2 Circuit for SVC and TCSC . . . . . . . . . . . . . . . . . . . . 12
2.2.3 SVC Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.2.4 TCSC Model . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
3 Implementation of FACTS in the Power Flow Computation 17
3.1 SVC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.1.1 Reactive Power Regulation . . . . . . . . . . . . . . . . . . . . 18
3.1.2 Voltage Regulation . . . . . . . . . . . . . . . . . . . . . . . . 18
3.1.3 Firing Angle Regulation . . . . . . . . . . . . . . . . . . . . . 18
3.2 TCSC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
3.2.1 Active Power Regulation . . . . . . . . . . . . . . . . . . . . . 19
3.2.2 Firing Angle Regulation . . . . . . . . . . . . . . . . . . . . . 20
3.2.3 Resonance Protection and Angle Limits . . . . . . . . . . . . . 20
3.3 Additional Implementations . . . . . . . . . . . . . . . . . . . . . . . 21
3.3.1 Determination of the Fire Delay Angle . . . . . . . . . . . . . 21
3.3.2 Incremental Changes of SVC and TCSC . . . . . . . . . . . . 22
3.3.3 Switching of SVC and TCSC . . . . . . . . . . . . . . . . . . 22
3.3.4 Power Limits . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
3.3.5 Formatting of the Results . . . . . . . . . . . . . . . . . . . . 24
4 Implementation of FACTS in the Client 25
4.1 SVC in the Client . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
4.1.1 Class Svc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
4.1.2 Class SvcDialog . . . . . . . . . . . . . . . . . . . . . . . . . 26
4.2 TCSC in the Client . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
4.2.1 Class Tcsc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
4.2.2 Class TcscDialog . . . . . . . . . . . . . . . . . . . . . . . . . 28
5 Economic Generation Dispatch 31
v
CONTENTS
5.1 Mathematical Approach . . . . . . . . . . . . . . . . . . . . . . . . . 31
5.1.1 Problem Formulation and Optimality Conditions . . . . . . . 31
5.1.2 Unlimited Point Algorithm . . . . . . . . . . . . . . . . . . . . 32
5.1.3 Optimisation of Total Generation Costs . . . . . . . . . . . . . 33
5.2 Implementation of the Economic Generation Dispatch . . . . . . . . . 37
6 Program Tests 39
6.1 Tests with Single SVC and TCSC Element . . . . . . . . . . . . . . . 40
6.1.1 3-bus Test Network . . . . . . . . . . . . . . . . . . . . . . . . 40
6.1.2 Single SVC Test . . . . . . . . . . . . . . . . . . . . . . . . . . 40
6.1.3 Single SVC Test Results . . . . . . . . . . . . . . . . . . . . . 42
6.1.4 Single TCSC Test . . . . . . . . . . . . . . . . . . . . . . . . . 42
6.1.5 Single TCSC Test Results . . . . . . . . . . . . . . . . . . . . 43
6.2 Combined SVC and TCSC Test . . . . . . . . . . . . . . . . . . . . . 43
6.2.1 6-bus Test Network . . . . . . . . . . . . . . . . . . . . . . . . 44
6.2.2 Test Arrangement . . . . . . . . . . . . . . . . . . . . . . . . . 44
6.2.3 Combined SVC and TCSC Test Results . . . . . . . . . . . . 44
6.3 Test of Economic Generation Dispatch . . . . . . . . . . . . . . . . . 47
6.3.1 Test Arrangement . . . . . . . . . . . . . . . . . . . . . . . . . 47
6.3.2 EGD Test Results . . . . . . . . . . . . . . . . . . . . . . . . . 47
6.4 Known Issue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
7 Conclusion 50
7.1 Project Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
7.2 Discussion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
7.3 Outlook . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
A Flowcharts 53
vi
CONTENTS
B Test Data 57
C Variables, Scripts and Functions 64
Bibliography 68
vii
List of Acronyms
Shortcut Full Name
AC Alternating Current
FACTS Flexible Alternating Current Transmission Systems
TCR Thyristor Controlled Reactor
SVC Static Var Compensator
TCSC Thyristor Controlled Series Capacitor
GUI Graphical User Interface
GTO Gate Turn O
IGBT Isolated Gate Bipolar Transistor
MOV Metal Oxide Varistor
EGD Economic Generation Dispatch
viii
List of Symbols
Symbol Description
i
TCR
TCR current
t time
re delay angle
rated angular frequency
u voltage
U voltage, rms-value
L inductance
C capacitance
X
L
, X
C
reactance of a reactor, capacitor
B susceptance
B
L
, B
C
susceptance of a reactor, capacitor
B
TCR
apparent susceptance of a TCR
U
i
, U
j
node voltage
P
ij
, P
ji
active power ow
Q
ij
, Q
ji
reactive power ow

ij
,
ji
transmission angle

i
,
j
phase angle
F objective function
g equality constraint
h inequality constraint
L Lagrangian-function
, Lagrangian-multipliers
z slack variable for inequality constraints
C
P
cost function of generator
P
i
active power output of generator
a
0,i
, a
1,i
, a
2,i
cost function factors
A
P
matrix of cost function factors
P
gen
vector of generator power values
P
gen,max
vector of max. generator power values
J Jacobian matrix
n number of generators, dimension of objective function
m number of equality constraints
p number of inequality constraints
ix
Chapter 1
Introduction
1.1 Assignment
The intention of this work is to implement FACTS (Flexible Alternating Current
Transmission Systems) and Economic Generation Dispatch in the power ow demon-
stration platform FlowDemo.net see [1].
Dealing with the implementation of FACTS, two dierent tasks have to be per-
formed: At rst appropriate mathematical models have to be found, secondly the
devices have to be implemented in the power ow computation as well as in the
Graphical User Interface (GUI).
For the Economic Generation Dispatch an algorithm to solve the inequality con-
strained optimization problem due to Karush-Kuhn-Tucker has to be implemented
in Matlab.
1.2 Simulation Platform FlowDemo.net
FlowDemo.net is an interactive, internet based software to compute and visualise
power ow in an electric transmission system [1]. The program is freely accessible
on the internet on www.FlowDemo.net. The intention of this software is not only
to compute but also to demonstrate and visualise the power ow in an electric
transmission system.
Predened networks could be loaded and demonstrated in version 1.0, it went online
in 2001. The new version 2.0 provides a GUI with a network editor where the user
1
1.2 Simulation Platform FlowDemo.net
can dene individual networks and hold them in a data base. FlowDemo.net 2.0
contains the FACTS elements SVC and TCSC and the new feature Economic Gen-
eration Dispatch.
FlowDemo.net 2.0 consists of several software modules which are implemented in
various programming languages (see Figure 1.1). The modular software design tar-
gets independence of the functional units and extensibility. The four major parts
are the client, the server, the computation engine and the data base.
Figure 1.1: Software assembly of FlowDemo.net 2.0
Client: The client, which includes the Graphical User Interface (GUI) with the
network editor, is implemented in Java. It works either in edit-mode or in run-
mode. In the edit-mode a network editor is available which allows the user to
design, edit, save or load individual networks. As long as the network is edited no
computation and visualisation is done. In the run-mode the power ow is computed
and illustrated.
Server: The server is the central functional unit that manages all software modules
and connections between them. It is also implemented in Java.
Computation Engine: The power ow computation, which is not visible for the
user of FlowDemo.net, is started in the client by clicking on the run-button. At
rst network errors, islands or disconnected elements are detected, then the network
data are prepared and nally the power ow computation starts. The matrix-based
procedure uses a Newton-Raphson algorithm which is implemented in Matlab [2],
[3]. When the computation is nished the results are sent back to the client and
the power ow is visualised in the GUI. Matlab is a suitable instrument for this
task, its major advantage over other programming languages is the easily handling
of matrices, especially if they are sparse.
2
1.3 Flexible AC Transmission Systems
Data Base: The user can create individual networks and save them either locally
or in the FlowDemo.net data base. It is also possible to load predened networks in
read only mode. The network data are kept in tables for busses, generators, loads,
shunts, lines, transformers, capacitors, SVC and TCSC. They contain all input-
data of the network elements but no results of the power ow computation. The
implementation in PostgreSQL is based on the IEEE Power System Applications
Data Dictionary [12].
1.3 Flexible AC Transmission Systems
Flexible Alternating Current Transmission Systems (FACTS) are controllable power-
electronic based devices in electric transmission systems which allow to aect power
ow and/or node voltages dynamically [5], [6], [7].
As mentioned in [5] the rst FACTS, based on mechanically switched reactors and
capacitors, were developed in the 1960s. Later, in the 1970s, semiconductor-switches
were applied which oered new opportunities and initialized a rapid development.
Today FACTS are equipped with converter-based technology using high-capacity
thyristors (also GTO-thyristors) or IGB-transistor switches.
FACTS generally work as
parallel compensation,
series compensation or
both, parallel and series compensation.
Typical elds of application are dynamic reactive power compensation, dynamic
power ow control and power ow dispatching, increase of transmission capacity,
improve of steady-state stability (voltage regulation) and enhancing dynamic sta-
bility (oscillation damping).
Some basic FACTS circuits will be shortly described in this chapter, mathematical
descriptions of the devices are given in section 2.
1.3.1 Thyristor Controlled Reactor
A Thyristor Controlled Reactor (TCR) is one of the simplest FACTS elements (see
Figure 1.2). It consists of a linear reactor in series with two bipolar thyristors [7].
3
1.3 Flexible AC Transmission Systems
Changing the current by triggering the thyristors aects on the apparent suscep-
tance, i.e. the apparent susceptance of the TCR is a function of the thyristor ring
angle. Usually a TCR is used in combination with other reactive elements, for
example with a capacitor in parallel.
Figure 1.2: Thyristor Controlled Reactor
1.3.2 Static Var Compensator
The Static Var Compensator (SVC) is a device for dynamic shunt compensation, the
most common type comprises a TCR in parallel with a xed capacitor
1
pictured in
Figure 1.3. The equivalent impedance of this circuit can be aected by triggering the
thyristors, with a certain dimensions of the capacitor and the reactor it is possible to
get an operating area from inductive to capacitive susceptance. In AC transmission
systems usually three of these circuits are connected in delta, with ratings up to
many hundred MVA [7].
Figure 1.3: SVC circuit
1
There are several other possible arrangements mentioned in [5].
4
1.4 Power Flow Computation
1.3.3 Thyristor Controlled Series Capacitor
A TCR with a capacitor in parallel can also be used as a series element for series
compensation, the circuit is the same as the mentioned SVC circuit. This arrange-
ment is called Thyristor Controlled Series Capacitor, one of its typical applications
is the compensation of inductive transmission lines: If the TCSC is operated in
capacitive mode, i.e. the apparent susceptance of the circuit is capacitive, it can be
used to compensate a part of the lines inductivity.
Figure 1.4: TCSC circuit
1.4 Power Flow Computation
As described in [3] the power ow computation
2
is the task to determine any normal
state of an electric network. This normal state is:
The network is in a static state, the waveforms of network quantities like
voltages, currents and powers are sinusoidal in time.
All network elements have linear characteristics.
The system works under symmetric conditions.
3
Given are the values of xed loads, the impedance of shunt elements, line and trans-
former parameters, FACTS power values, voltage targets or ring angles, generator
voltages and/or power values
4
and the topology of the network. The result of the
2
also called load ow computation
3
Otherwise the system has to be transformed in three decoupled systems (M-G-0) and re-
transformed after the computation of each single decoupled system.
4
That depends on the regulation type of the generator. For the slack generator only the node
voltage is given, for PV-generators the active power and the node voltage is specied and for
PQ-generators active and reactive power is xed.
5
1.4 Power Flow Computation
power ow computation includes node voltages and voltage angles, current and
power values.
In [3] the fundamental power ow equation system which is based on linear models
is stated as:
Nr. Equation
1
2
3
A
1 c
=
_

_
[diag(M
Net
Ii
) 0 ] [diag(M
Net
Ui
) 0 ] 0
C
T
0 0
0 E C
_

_
_

_
I
Nport
U
Nport
U
Kirch
_

_
=
_

_
0
0
0
_

_
4 P
Nport
+ jQ
Nport
diag(U
Nport
)I

Nport
= 0
5 P
0
gen

/load
P
gen

/load
Nport
= 0
6 Q
0
load
Q
load
Nport
= 0
7 U
0
gen
|U
gen
Nport
| = 0
8 angle
0


(U
Kirch
Slack
) = 0
Equation 1, 2 and 3 include the topological description of the network as well as the
linear models of the network elements. Equation 4 describes the power relationship
of all n-ports. Equation 5 and 6 specify the balance between generated and con-
sumed active and reactive power values. The magnitudes of the node voltages are
added in equation 7, equation 8 denes the slack angle. A more detailed description
is given in [3].
The procedure of power ow computation can be divided in two main parts: Firstly,
the equations based on the linear models have to be formulated, and secondly the
system of linear and nonlinear equations has to be solved.
1.4.1 Newton-Raphson
With the iterative method of Newton-Raphson it is possible to obtain the zeros
of a nonlinear function f(x) = 0 using the Taylor-Series approach. Because it is
an iterative method, the result always contains a so-called mismatch value that
6
1.5 Economic Generation Dispatch
decreases with the number of executed iterations if the computation converges.
5
A
detailed description with numeric examples of the Newton-Raphson algorithm is
given in [3].
1.5 Economic Generation Dispatch
The task of Economic Generation Dispatch is to dispatch the total generation power
in a network to the generators due to their economic behavior whereas the total costs
of generation should be minimised. For this purpose every generator is modelled with
a cost function that denes the dependence of the generator costs and the generated
power.
6
The inequality constrained optimisation problem is generally formulated as
[15]:
Minimise F(x) Objective function
subject to g(x) = 0 Equality constraints
and h(x) 0 Inequality constraints
The objective function describes the total generation costs as a function of the gener-
ated active power values, for FlowDemo.net these functions are assumed as quadratic
polynomials. The equality constraint results from the condition that the total gen-
eration power must be the same before and after the dispatch.
7
The inequality
constraints represent the power limits of the generators. A detailed discussion of
this problem formulation is done in Chapter 5.
FlowDemo.net solves the inequality constrained optimization problem with the so
called Unlimited Point method.
5
Newton-Raphson does not converge in every case resp. for every function.
6
In this work only active power is considered.
7
This equation is not fullled after a generation dispatch and re-computation of the power ow:
Due to the new generation pattern the power ow situation in the whole network changes. For this
reason the network losses and therefore the slack power and the total generated power change.
7
Chapter 2
FACTS Modelling
In this Chapter mathematical models of FACTS are discussed. Firstly an overview
of common modelling instruments is given and secondly the applied models are
explained. The priorities for the models implemented in FlowDemo.net are applica-
bility for the computation engine and clearness for the user.
2.1 FACTS Models
There are several ways of modelling FACTS, whereas the suitability of a model
depends on the specic problem. Some basic modelling techniques are mentioned in
the following.
2.1.1 Injection Model
The Injection Model describes the FACTS as a device that injects a certain amount
of active and reactive power to a node, so the FACTS device is represented as a
PQ-element [5], [8], [11]. Figure 2.1 shows the idea of interpreting a FACTS device
as PQ-elements. If the FACTS model does not contain losses, the injected powers
can be written as [8]:
P
ij
= U
i
U
j
B
ij
sin
ij
(2.1)
P
ji
= P
ij
(2.2)
Q
ij
= U
2
i
B
ij
U
i
U
j
B
ij
cos
ij
(2.3)
Q
ji
= U
2
j
B
ij
U
i
U
j
B
ij
cos
ji
(2.4)
8
2.1 FACTS Models
Figure 2.1: Injection Model
whereas only the FACTS (no other elements) is connected between bus i and bus j.
P
ij
and P
ji
represent active power ow, Q
ij
and Q
ji
are reactive power values. The
transmission angles are

ij
=
i

j
=

U
i


U
j
(2.5)

ji
=
ij
(2.6)
Since this model uses PQ-elements to describe the FACTS, it can be implemented
in a Newton-Raphson computation like PQ-loads. The Injection Model does not
contain internal information about the device, i.e. it is independent from the internal
design of the FACTS.
2.1.2 Total Susceptance Model
This model interprets the FACTS as a shunt (for shunt compensation) or series el-
ement (for series compensation) with varying susceptance B [9]. Due to (2.1)-(2.6)
the power ow through the FACTS depends on B, P
ij
and Q
ij
= f(B). Figure 2.3
Figure 2.2: Total Susceptance Model
shows a 1-port and a 2-port black box. In network analysis every n-port is repre-
sented by the impedance matrix which can be stated from the T or circuit model
of the network element. Inserting the variable B in the 1- and 2-port models for
shunt and series elements leads to the 1-port matrix model for the shunt connected
element:
_
I
i
_

_
jB
ij
_ _
U
i
_
=
_
0
_
(2.7)
9
2.2 Implemented Models
Figure 2.3: 1-port (a) and 2-port (b) element
The 2-port model for the series element can be stated as:
_
_
I
i
I
j
_
_

_
_
jB
ij
jB
ij
jB
ij
jB
ij
_
_
_
_
U
i
U
j
_
_
=
_
_
0
0
_
_
(2.8)
Since it is well known how to implement the 1-port and 2-port models in a power
ow computation, this model is proper for a power ow computation with Newton-
Raphson. Like the Injection Model, the Total Susceptance Model does not describe
the internal design of the FACTS. It does not contain the dependence of B from
any internal value, for example ring angle.
2.1.3 Firing Angle Model
As described in [9] the Firing Angle Model includes the dependence of the FACTS
impedance or power values from the variable ring angles of semiconductor switches.
The ring angle is now considered as a state variable, so that B
1
ij
= X
ij
=
f(, X
L
, X
C
) and P
ij
, Q
ij
= f(, X
L
, X
C
). Such a function f(, X
L
, X
C
) can be
inserted in the Injection Model as well as in the Total Susceptance Model. With
this extended model the user can inuence powers by changing ring angles of the
valves.
With the Firing Angle Model we consider the internal circuit as well as values which
aect the power ow through the device, like capacitance, reactance and especially
the ring angle. A major dierence between this model and the models mentioned
above is that the Firing Angle Model describes the FACTS internal design.
2.2 Implemented Models
After having a look on dierent modelling techniques in Section 2.1 we will now dis-
cuss which and how models are implemented in the computation engine. FlowDemo.net
10
2.2 Implemented Models
uses more or less all models mentioned in Section 2.1. For each type of regulation
the models are nested in dierent ways with respect to the ring angle.
Power-Regulation: The injected powers are set by the user, so the injected load(s)
is (are) given. After the Newton-Raphson power ow computation the apparent
susceptance of the FACTS can be determined from the node voltage and the power
value. In the last step the re delay angle is computed from the apparent susceptance
by adopting the Firing Angle Model (see Section 2.1.3).
Voltage-Regulation: The desired node voltage is given, the injected powers are
results of the power ow computation. After determining the total susceptance of
the device from the voltage and the power value, the re delay angle is calculated.
Angle-Regulation: The total susceptance can be determined from the user-dened
re delay angle and the reactance of the capacitor and the reactor. Afterwards the
device is implemented in the power ow computation like a shunt or series element
(SVC or TCSC). The injected loads are result from the computation.
The active power losses of a SVC or a TCSC are neglected in the models because
usually they are below one percent of the reactive power rating of the device [5].
2.2.1 TCR Model
In [6] the current of an elementary single-phase TCR with re delay angle
1
control
is stated as:
i
TCR
(t) =
1
L
_
t

v(t)dt (2.9)
With a sinusoidal voltage u(t) = U cos t we get for the current:
i
TCR
(t) =
U
L
(sin t sin ) (2.10)
Assuming not only the voltage sinusoidal but also the current, the RMS-value results
in
I
TCR
() =
U
L
_
1
2

sin 2
_
(2.11)
Using I
TCR
= UB
TCR
and B
L
= X
1
L
=
1
L
the apparent susceptance
2
of the circuit
can be written as
B
TCR
() = B
L
2 sin 2

(2.12)
1
The re delay angle , also called trigger angle, is equivalent to the prevailing conduction
angle = 2, therefore a TCR can be characterized by either of them. and are dened
in [6].
2
This is the fundamental frequency equivalent without considering harmonics of the current.
11
2.2 Implemented Models
Therefore the susceptance of a TCR can be varied continuously from maximum
( = 0, B
TCR
= B
L
) to minimum ( =

2
, B
TCR
= 0).
2.2.2 Circuit for SVC and TCSC
A TCR in parallel with a capacitance is a basic circuit for SVC and TCSC. The
arrangement shown in Figure 2.4 allows to vary the equivalent susceptance continu-
ously. If L <
1
C
the control range covers capacitive and reactive operation mode.
Figure 2.4: Basic circuit for SVC and TCSC
The equations for this circuit can be stated as follows. With a capacitance
B
C
= X
1
C
= C (2.13)
connected in parallel to a TCR, the apparent susceptance of the whole circuit results
in
B = B
TCR
+ B
C
(2.14)
and with (2.12) it can be expressed as
B() = B
L
2 sin 2

+ B
C
(2.15)
Figure 2.5 and Figure 2.6 picture the trajectories of B and X = B
1
for a basic
circuit with B
L
= 1.0 p.u. and B
C
= 0.2 p.u. Concerning the ring angle three
dierent operation modes can be dened for this circuit [7]:
Bypassed-Thyristor Mode ( = 0

): In this mode the thyristors are triggered


to full conductance, the module behaves approximately like a parallel arrangement
of the capacitor and the inductor. If the susceptance of the inductor is higher than
the susceptance of the capacitor, the current through the device is inductive.
Blocked-Thyristor Mode ( = 90

): The thyristors are blocked, the current


through the reactor gets zero and the arrangement acts just like a xed capacitor.
12
2.2 Implemented Models
Partially Conducting Thyristor (0

< < 90

): In this operation area it


is possible to control the apparent susceptance of the circuit continuously from
inductive to capacitive character.
As generally known, a capacitance in parallel with an inductance has always a
resonance point where B
L
= B
C
. Due to (2.14), the antiresonance-condition for
the basic circuit is
B(
res
) = B
L
2
res
sin 2
res

+ B
C
= 0 (2.16)
This condition can be fullled by variation of , i.e. there is a ring angle
res
, where
the circuit oscillates in resonance. In order to prevent the circuit from resonance
state, this ring delay angle
res
has to be forbidden, therefore the user should not
be allowed to set =
res
. The determination of the re delay angle
res
where
B(
res
) = 0 is explained in 3.3.1. For keeping a safety margin to resonance, a
protected area for the ring angle is dened as

res
> >
res
+ (2.17)
Antiresonance is not a problem for shunt-connected circuits because the bus voltage
is xed, so in case of resonance the current gets close to zero what does not endanger
the internal elements of the device. For series connected circuits we can assume the
current or the transmission power as xed, what leads to a high series voltage drop
if the circuit is in resonance state. This could cause a serious stress for the FACTS
components.
2.2.3 SVC Model
As mentioned in Section 1.3.2, a SVC is a shunt-connected circuit. The equations
of the basic circuit are used here.
Due to the equations of the Injection Model (2.1) and (2.3) and the fact that there
is no bus j for a shunt connected element, what means
U
j
= 0 (2.18)
the active and reactive power values of an SVC element result in
P
i
= 0 (2.19)
Q
i
= U
2
i
B (2.20)
13
2.2 Implemented Models
0 10 20 30 40 50 60 70 80 90
0.2
0.1
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
Fire delay angle [deg]
E
q
u
i
v
a
l
e
n
t

s
u
s
c
e
p
t
a
n
c
e

B
(

)

[
p
.
u
.
]
Figure 2.5: Variable susceptance (B
L
= 1.0 p.u., B
C
= 0.2 p.u.)
0 10 20 30 40 50 60 70 80 90
15
10
5
0
5
10
15
Fire delay angle [deg]
E
q
u
i
v
a
l
e
n
t

r
e
a
c
t
a
n
c
e

X
(

)

[
p
.
u
.
]
Inductive operation
Capacitive operation
Figure 2.6: Variable reactance (B
L
= 1.0 p.u., B
C
= 0.2 p.u.)
14
2.2 Implemented Models
Figure 2.7: SVC Model
With (2.15) we get a function for the reactive power that includes the re delay
angle:
Q
i
= U
2
i
_
B
L
2 sin 2

+ B
C
_
(2.21)
Considering this equation in matters of resonance where B = 0 we can see that
resonance state would cause a reactive power consumption of Q
i
= 0.
2.2.4 TCSC Model
The TCSC is a series connected TCR in parallel with a capacitor. For the injected
Figure 2.8: TCSC Model
power values of the TCSC at bus i and bus j the equations (2.1)-(2.6) are used.
Applying (2.15) leads to the transmitted active power
P
ij
= U
i
U
j
_
B
L
2 sin 2

+ B
C
_
sin
ij
(2.22)
Since the model does not consider any active power losses in the TCSC we get the
same absolute value (but due to the reference system with a dierent sign) on the
other bus of the TCSC:
P
ji
= P
ij
(2.23)
15
2.2 Implemented Models
Since losses in lines are usually not neglected, this equation is just valid for the
TCSC element but not for a combination of a TCSC with lines. Because the TCSC
is a reactive element the reactive power values are not equal on both nodes, they
can be stated as
Q
ij
= U
i
_
B
L
2 sin 2

+ B
C
_
(U
i
U
j
cos
ij
) (2.24)
Q
ji
= U
j
_
B
L
2 sin 2

+ B
C
_
(U
j
U
i
cos
ji
) (2.25)
If the circuit is in resonance state, the expression in the big brackets of (2.24) and
(2.25) gets close to zero. Assuming a certain (desired) power ow P
ij
+ jQ
ij
one
can recognise that this would cause very high bus voltages that could endanger the
TCSC.
16
Chapter 3
Implementation of FACTS in the
Power Flow Computation
The FACTS devices have to be implemented in the Matlab computation engine
by integrating SVC and TCSC models. FlowDemo.net 1.0 provides a power ow
computation for networks consisting of the 1-port elements generator, load, shunt,
capacitor and the 2-port elements line and transformer. Version 2.0 includes also
the FACTS devices SVC (1-port) and TCSC (2-port).
The implementation of the FACTS elements is based on the linear models
of the existing elements. There are no new element types in the network
matrices and the Jacobian matrix. Depending on the regulation the
FACTS are included in the element matrices of loads, generators, shunts
and lines.
3.1 SVC
Depending on the regulation type, the SVC can be described like a PV-generator, a
PQ-load or a shunt element with dened susceptance B. The original SVC matrix is
fractionised and each SVC element is embedded in the element matrix of generators,
loads or shunts before the Newton-Raphson computation is started. When the
computation is nished the results relating to the SVC elements are taken out from
the generator, load and shunt result vectors and the power values are saved in the
SVC result vectors. This procedure is shown in Appendix A.
17
3.1 SVC
3.1.1 Reactive Power Regulation
For a Q-regulated SVC the user denes the reactive power Q
i
the device should
inject. In this case the Injection Model is used, and the SVC is implemented like a
reactive load that consumes a dened amount of reactive power from the connected
bus.
Since Q
i
is known and U
j
is a result of the power ow computation, we can obtain
the equivalent susceptance by converting (2.20) to
B =
Q
i
U
2
i
(3.1)
With B, U
i
, X
C
, X
L
and (2.15) it is possible to determine the re delay angle
(explained in Section 3.3.1).
3.1.2 Voltage Regulation
If the user wants to control the bus voltage U
i
, the SVC has to act like a PV-regulated
generator (with P = 0) according to the Injection Model. A result of the power ow
computation is the power value Q
i
but not the equivalent susceptance and the ring
angle of the thyristors, they are determined in the same way as described in Section
3.1.1.
3.1.3 Firing Angle Regulation
Other than the mentioned regulations on reactive power and node voltage it is
possible to set the re delay angle of the TCR. If this is done, the Total Susceptance
Model is applied after the apparent susceptance B of the SVC is computed from ,
X
L
and X
C
. The device is then implemented like a shunt, the computation results
include the power values.
In this regulation mode the reactive power limits are not taken into consideration.
The user can get every reactive power value that results from the specied re delay
angle. A way to nd the ring angles where reactive power values are on the limit
is to run the SVC in reactive power regulation mode, set the desired value on the
limit and take a look at the re delay angle. To get sure that the minimum reactive
power limit is not violated with ring angle regulation the angle must not be less
than the displayed angle when the SVC worked in reactive power regulation mode
on its lower limit. The maximum reactive power limit is exceed if the angle is greater
18
3.2 TCSC
than the angle which is displayed if the SVC operates in reactive power regulation
on its upper reactive power limit.
3.2 TCSC
For the Thyristor Controlled Series Capacitor two types of regulation are imple-
mented. The rst one is the control of the active transmitted power P, the second
is to set the re delay angle . Depending on the control mode, the TCSC is imple-
mented as loads on the connected busses or as a line between them. For this reason
the TCSC matrix which includes all TCSC information is split and the TCSC ele-
ments are embedded in the element matrices of loads and lines. The computation
starts with this additional rows in the load and line matrices. After it is nished
the results are assigned to TCSC, lines and loads.
3.2.1 Active Power Regulation
P-regulated TCSC means that the user denes the active power that should be trans-
mitted from bus i to bus j, whereas the reactive powers, the equivalent susceptance
and the ring angle are unknown.
Eliminating B from (2.1)-(2.4) gives the injected reactive power values as functions
of the specied value P and the complex node voltages:
Q
ij
=
P
ij
sin
ij
_
U
i
U
j
cos
ij
_
(3.2)
Q
ji
=
P
ij
sin
ij
_
U
j
U
i
cos
ij
_
(3.3)
With this equations the TCSC can be handled like two loads P
ij
+ jQ
ij
at bus i and
P
ij
+ jQ
ji
at bus j.
Using (3.2) and (3.3) to obtain the reactive power values, we have to consider that
the node voltages are not known before the power ow computation and that they
will vary with every iteration of the Newton-Raphson algorithm. Therefore Q
ij
and Q
ji
have to be recalculated after every iteration step.
When the Newton-Raphson computation is nished, the apparent susceptance of
19
3.2 TCSC
the TCSC is found by transforming (2.22):
1
B =
P
ij
U
i
U
j
sin
ij
(3.4)
The re delay angle can be determined from the equivalent susceptance B = f(),
X
L
and X
C
as explained in 3.3.1.
3.2.2 Firing Angle Regulation
The angle-regulated TCSC is treated like a line with variable reactance X. After
the apparent susceptance B of the TCSC circuit is computed from (2.15), the line
impedance can be set to X = B
1
. This TCSC, which is now handled like a line
with Z = jB
1
is added in the line matrix and the computation is started. The
result contains the active and reactive power values.
3.2.3 Resonance Protection and Angle Limits
As discussed in Section 2.2.2, every TCSC circuit has a resonance point where
the total impedance gets innite high and, assuming a certain current, the voltage
between the TCSC busses gets innite high too. To protect the TCSC elements from
overvoltage, real circuits include a Metal Oxide Varistor (MOV) in parallel to the
capacitor and the TCR. Another more preventative kind of overvoltage protection
is to avoid a certain band of the ring angle where resonance would put the circuit
at the risk of overvoltage.
For this reason the user is not allowed to set the re delay angle in an area which
is close to the resonance angle
res
, the safety margin must be kept. Since the
user usually does not know the resonance angle of the circuit the re delay angle
res
that would cause resonance is computed with (2.16). Afterwards (2.17) is checked
and, if necessary, the angle is corrected automatically:
If
res
<
res
it is set to =
res

If
res
< <
res
+ it is set to =
res
+
1
B can also be determined from Q
ij
or Q
ji
. Since the dened value does not include any
numeric miscalculation, we decided for P
ij
.
20
3.3 Additional Implementations
These are the resonance limits for the re delay angle. Additional limits result from
the maximum and minimum ring delay, this is
0

90

and corrected, if the user denes the ring angle outside this range. In order to
inform the user about any automatically modication of input data, a message is
sent to the GUI if corrections have been done.
3.3 Additional Implementations
3.3.1 Determination of the Fire Delay Angle
For P-, Q- and V-regulated devices, the equivalent susceptance is determined after
the power ow computation.
Due to (2.15) the re delay angle is a function of the TCRs apparent susceptance
B, the susceptance of the reactor B
L
and the capacitance B
C
. If these three values
are known it is possible to determine from a nonlinear implicit equation in the
form of
g() = 0 (3.5)
Transforming (2.15) leads to
g() = B
_
B
L
2 sin 2

+ B
C
_
= 0 (3.6)
This equation can be solved with the method of Newton-Raphson. It uses a Taylor
series approach, therefore it is necessary to nd the derivation
g()

_
B
_
B
L
2 sin 2

+ B
C
__
(3.7)
that results in
g()

=
2B
L

(1 + cos 2) (3.8)
The determination of the re delay angle is implemented with a Newton-Raphson
algorithm in Matlab. The function is used to determine the resonance ring angle

res
before the power ow computation gets started and to determine the ring angle
after the power ow computation of P-, Q- or V-regulated devices has nished.
21
3.3 Additional Implementations
3.3.2 Incremental Changes of SVC and TCSC
Whenever the user changes only one value of the network, for example a load value,
the program does not start a completely new computation of the whole network.
Only the changed value is sent from the client to the computation engine and the
Newton-Raphson algorithm starts taking the former results as initial values. The
intention behind this procedure is to increase the computation speed, especially
when the client works in run-mode and the user changes a value by clicking on a
puls/minus-button of an element. For SVC and TCSC this incremental changes are
implemented for changes of the target values P, Q, U and . If the control mode
of a FACTS element is changed, the power ow computation is started from the
beginning.
The implementation allows to do incremental changes in two steps:
1. Several declarations of variables which identify the changing element and the
setting of the new target value have to be done.
2. A script which searches for the changing element and replaces the old value
with the new value before it runs the load ow computation has to be called.
Appendix C Table C.1 gives detailed information about the declarations and the
changing commands for all implemented SVC and TCSC incremental changes. The
content of the declaration variables is listed in Table C.2.
3.3.3 Switching of SVC and TCSC
If an element is switched on or o in the client, the power ow has to be calcu-
lated new. The switching is implemented quite similar to the incremental changes
described in section 3.3.2.
If an element is switched not the whole new network is sent to the computation
engine. Just the information about the switched element is given to the load ow
program. If an element is switched o the current value of the element is dened
with zero and the computation starts with the old results as initial values for the
Newton-Raphson algorithm. The program does not read the new topology of the
network and the incidence matrix is the same as before. Only the given and the
wanted value change.
Since FlowDemo.net 1.0 was designed for only one element of each kind per bus and
22
3.3 Additional Implementations
the FACTS elements are treated like loads, shunts, lines or generators this switching
is not trivial to implement for the FACTS elements. The design does not allow to
switch perhaps the relating load of a SVC element if there is another real load on
the same bus.
Another way to implement switching is to delete the elements line in the element
matrix, rebuild the computation matrices and start Newton-Raphson using a part of
the old results as initial values. After the matrices are prepared for Newton-Raphson,
it is always possible to distinguish between the element matrix rows which come from
a SVC or TCSC and the rows which represent original elements. But it is a problem
that after switching o a FACTS element and clearing the depending element row
in the element matrix, saving this information and recomputing the load ow, it
could happen that other elements are switched before the rst element is switched
on again. This could cause a change of the matrix dimension.
It is generally feasible to solve the problem in question, it could be a task for the
future work.
Switching o FACTS elements is implemented in the Matlab code, but in another
way than the switching of the non-FACTS elements. Whenever a SVC or TCSC
element is switched o its relating row in the element matrix is deleted, the matrices
are prepared for the computation and Newton-Raphson starts taking the old voltage
values as start values for the new run. In Table C.3 the commands for FACTS
switching are printed, whereas the declaration variables are dened in Table C.2.
This procedure takes less iterations than a completely new computation would need
to converge. But of course a procedure which sets the current to zero instead of
changing the element matrices would be faster. Whenever a FACTS element is
switched on, the computation starts from the beginning.
3.3.4 Power Limits
Real generators are not able to deliver unlimited power. The mechanical and electri-
cal design of a machine leads to limits for active and reactive power. If a generator
reaches such a power limit, the control unit keeps the value on a constant level (limit)
independent from the power demand in the system. This fact has to be considered
and implemented in the computation software.
In the version 1.0 of FlowDemo.net these borders were checked after the Newton-
Raphson algorithm converged. If limits were violated, the element values were set
to these boundary values and the computation was started again.
23
3.3 Additional Implementations
This procedure is now integrated in the Newton-Raphson algorithm. Whenever the
absolute values of the disturbance vector are below the tolerance value the limits
are checked. If there are any violations the exceeded values are set to their limits
and the computation continues. If no limits were violated the loop ends and the
computation itself is nished.
3.3.5 Formatting of the Results
The results of the Matlab computation program are formatted and packed in a result
vector which includes all voltages, voltage angles and power values in a well dened
order. This vector is sent to the client where the results are displayed.
24
Chapter 4
Implementation of FACTS in the
Client
This Section describes the implementation of the FACTS elements in the Client
of FlowDemo.net. The new elements are represented by Java classes which are
explained in the following.
SVC and TCSC are added in the GUI as new elements. Basically, the implementa-
tion is done by adding classes for both elements to the object oriented Java code.
The new classes are Svc and Tcsc. For conguring SVC and TCSC elements the
user can open a dialog window by double-clicking on an element symbol in the edi-
tor. These dialog boxes are implemented in the classes TcscDialog and SvcDialog.
A toolbar is placed in the upper left corner of the client window and includes but-
tons for all network elements (see Figure 4.1). After clicking a button, the user can
create an element in the edit area.
1
Buttons for SVC and TCSC are added in the
class Toolbar.
Figure 4.1: Toolbar with buttons for SVC and TCSC
1
In this case an instance of the relating class is generated.
25
4.1 SVC in the Client
4.1 SVC in the Client
Since a Static Var Compensator is a 1-port element, the class for this element
is implemented as a subclass of the class OnePortEl which includes all common
variables and methods for 1-ports.
2
The dialog window for the SVC is implemented
in the class SvcDialog.
4.1.1 Class Svc
The class Svc contains new variables which are characteristic for the SVC element,
like the re delay angle , the reactance of the capacitor X
C
and the inductor X
L
and the control mode. The inheritance tree starts with the superclass element:
Element OnePortEl Svc
The class includes also the graphical design of the SVC element which is shown in
Figure 4.2. The black rectangle between the SVC and the bus is a switch. It can be
operated by clicking on it.
Figure 4.2: SVC symbol in dierent positions
4.1.2 Class SvcDialog
The class SvcDialog contains the implementation of the SVC dialog window. It is
an inheritance of the superclass Dialog.
Dialog SvcDialog
Whenever the user clicks on a SVC symbol in the editor, a dialog window opens
where the user can specify the parameters of the device. This window, which is
divided in ve major parts, is shown in Figure 4.3.
2
That means Svc is a so called inheritance or extension of OnePortEl.
26
4.1 SVC in the Client
Figure 4.3: SVC dialog window
Current Values: The current values for reactive power and the re delay angle are
printed in this eld whereas a positive sign for the reactive power means inductive
consumption.
Power Limits: Positive and negative reactive power limits can be specied in this
text boxes. If the power limit is exceeded, it may happen that the desired operating
state cannot be reached. Perhaps the desired voltage cant be obtained because the
SVCs power limit is reached. As mentioned in Section 3.1.3, there are no power
limits for the -regulated SVC.
Regulation: In this part the user can choose the control mode and set the target
value. Of course only the value of the selected control mode is used in the computa-
tion, the other two values cant be set because they are results of the computation.
Elements: The values of the internal elements X
C
and X
L
can be specied in these
boxes. In the V (voltage) and Q (reactive power) control mode it might happen
that the desired operating state can not be gained with these elements. In this case
27
4.2 TCSC in the Client
the user is informed by an according warning message.
Step Value +/: Whenever a + or button is clicked while the client is working
in run-mode, the magnitude of the concerning value changes with this user-dened
step value.
4.2 TCSC in the Client
The Thyristor Controlled Series Capacitor is a 2-port element, therefore the class
Tcsc is an extension of the superclass TwoPortEl.
4.2.1 Class Tcsc
This class is implemented with all special features of a TCSC compared with other
2-port elements like re delay angle , the reactance of the capacitor X
C
and the
inductor X
L
and the control mode. The inheritance tree is:
Element TwoPortEl Tcsc
In Figure 4.4 the graphical design of the TCSC element which is also implemented
in this class is shown.
Figure 4.4: TCSC symbol in dierent positions
4.2.2 Class TcscDialog
The dialog window for the TCSC was implemented in the class TcscDialog which
is an inheritance of the superclass Dialog.
Dialog TcscDialog
28
4.2 TCSC in the Client
This Dialog window consists of two layers which are pictured in Figure 4.5 and
Figure 4.6. The layer can be selected by clicking on a button at the top of the
window.
Figure 4.5: Tcsc dialog window: Current Values
Figure 4.6: Tcsc dialog window: Control & Elements
Current Values: Active, reactive and apparent power ow values are printed in
the upper part followed from the load value in % which is related to the maximal
apparent transmission power (specied in the text box Max Apparent Transmission
29
4.2 TCSC in the Client
Power). The voltage drop and the ring angle of the TCSC are printed at the
bottom of the window.
Control & Elements: In the rst part of this layer the user can choose a regulation
mode and set the relating target value. Beneath text boxes for X
C
and X
L
follow.
Finally the step value for changes with the +/ buttons can be specied (see Section
4.1.2).
30
Chapter 5
Economic Generation Dispatch
The task of Economic Generation Dispatch (EGD) is to minimise the total cost of
active power generation in a network assuming that every generator has quadratic
cost curves related to its own active power generation. The loads are assumed to be
completely inexible, i.e. of constant value and independent of the market situation.
This kind of Economic Dispatch is also called Lambda-Dispatch, which is done in
electric spot markets. Inputs for the EGD are the total inexible load and the power
limits of the generators, results are the powers of the generators and the so-called
Market Clearing Price (MCP) or System Marginal Price (SMP).
The problem of EGD is based on the theory of non-linear inequality constrained
optimisation which is described in Section 5.1.1.
5.1 Mathematical Approach
In this Section the inequality constrained optimisation problem for the EGD is
formulated and an algorithm which is used to solve the problem is described.
5.1.1 Problem Formulation and Optimality Conditions
The inequality constrained optimisation problem is a special case of the equality
constrained optimisation problem. In addition to the equality constraints we get
31
5.1 Mathematical Approach
new constraints expressed from inequalities [15]:
Minimise F(x) Objective function
subject to g(x) = 0 m Equality constraints
and h(x) 0 p Inequality constraints
(5.1)
From optimisation theory we know that this conditions can be fullled by minimis-
ing an articial objective function, the so-called Lagrangian function L. This
function includes the objective function, the equality constraints and the inequality
constraints:
L(x) = F(x) +
T
g(x) +
T
h(x) (5.2)
The vectors and include the so called Lagrange multipliers which get additional
unknown variables in this formulation. Every equality constraint g
i
(x) is multiplied
with an element
i
, every inequality constraint h
i
(x) is multiplied with an element

i
. The objective function and the Lagrangian function have the same argument
vector x, its dimension n is the number of variables which have to be optimised.
dim{x} = n 1
dim{g(x)} = dim{} = m 1
dim{h(x)} = dim{} = p 1
(5.3)
In the optimum of the Lagrangian function (5.2) the necessary optimality conditions
of the rst order, the Karush-Kuhn-Tucker (KKT) optimality conditions, are
fullled [15]:
F(x)
x
+
_
g(x)
x
_
T
+
_
h(x)
x
_
T
= 0 (5.4)
g(x) = 0 (5.5)
diag {} h(x) = 0 (5.6)
h(x) 0 (5.7)
0 (5.8)
This system of equality and inequality constraints can be solved with the so-called
Unlimited Point algorithm [16] by transforming it to a set of equality constraints
and solving the new equation system with the Newton-Raphson method.
5.1.2 Unlimited Point Algorithm
The Unlimited Point algorithm is an integrated method to solve the KKT-system by
the use of Newton-Raphson. It is not based on a common optimisation method like
QP, LP, Simplex or Interior Point, it uses just a Newton-Raphson algorithm.
32
5.1 Mathematical Approach
To get an equation system which can be solved with Newton-Raphson, the original
KKT-system has to be modied. This transformation is shortly explained in the
following paragraph.
As described in [16] the rst inequality constraint (5.7) is transformed into an equal-
ity constraint by adding a positive slack variable which is equal to or greater than
zero. Together with the second inequality constraint (5.8) we can replace both
inequality constraints with one new equality constraint and reformulate the trans-
formed KKT-system:

x
_
F( x) +

T
g( x) +
2s
T
h( x)
_
= 0 (5.9)
g( x) = 0 (5.10)
h( x) +z
2r
= 0 (5.11)
diag{
2s
}z
2r
= 0 (5.12)
This equation system can be solved with a Newton-Raphson algorithm. As men-
tioned in [16] the convergence of this method depends on the variables s and r, a
good convergence can be achieved with r = 2 and s = 1. The notations
2s
and
z
2r
denotes that every single element of and z has an exponent of 2s or 2r. This
exponent is not the exponent of the whole vector!
5.1.3 Optimisation of Total Generation Costs
The theory of KKT and the Unlimited Point algorithm can be used to nd an optimal
dispatch of the generated power in a network where the total costs of the active power
generation are at a minimum. In this work the cost functions of the generators are
assumed to be polynomials of second order. Every generator is characterised by the
parameters a
0,i
, a
1,i
and a
2,i
:
C
P
(P
i
) = a
0,i
+ a
1,i
P
i
+ a
2,i
P
i
2
(5.13)
The rst parameter a
0,i
of this polynomial can be interpreted as the xed costs of a
power generation. The second parameter a
1,i
represents the costs for primary energy
which are almost linear to the power output. The third parameter a
2,i
includes the
losses which occur in power stations and other costs which arise quadratically with
the power output. We can write the parameters of the cost functions a
0,i
, a
1,i
and
33
5.1 Mathematical Approach
a
2,i
of all generators in a matrix:
A
P
=
_

_
a
0,1
a
1,1
a
2,1
a
0,2
a
1,2
a
2,2
.
.
.
.
.
.
.
.
.
a
0,n
a
1,n
a
2,n
_

_
(5.14)
This matrix keeps all information about the cost characteristics of the generators in
the network. Furthermore we can arrange the active power values of all n generators
in a vector:
P
gen
=
_
P
1
P
2
. . . P
i
. . . P
n
_
T
(5.15)
Now we can state the objective function as the total generation costs in the whole
network by summing up the generation costs of the generators.
F(P
gen
) =
n

i=1
A
P
(1,i)
+A
P
(2,i)
P
gen
(i)
+A
P
(3,i)
P
gen
(i)
2
(5.16)
Since the total inexible load keeps constant, the total generation before and after
the dispatch must be equal
1
, therefore we can sum up the generated powers and
state the equality constraint
P
1
+ P
2
+ . . . + P
i
+ . . . + P
n
P

tot
= 0
n

i=1
P
gen
(i)
P

tot
= 0 (5.17)
whereas P

tot
is the total generation power before the dispatch. After re-dispatching
the generation and recomputing the power ow the slack power will change due to
the changed load ow situation. For this reason the total generation power has to
be recalculated after every dispatch.
The inequality constraints come from the power limits of the generators. The max-
imum active generation power values are written in a vector
P
gen,max
=
_
P
1,max
P
2,max
. . . P
i,max
. . . P
n,max
_
T
(5.18)
The power value of each generator must be lower than or equal to the maximum
value. This leads to the rst kind of inequality constraints for the power output of
the generators:
P
i
P
i,max
0 i = 1 . . . n
P
gen
(i)
P
gen,max
(i)
0 i = 1 . . . n (5.19)
1
Taking network losses into account, the total generation changes with the slack power.
34
5.1 Mathematical Approach
With this inequality constraint we limit the generators power values with its maxi-
mum power. Another inequality constraint comes from the minimum power output
of the generators which is assumed to be zero.
P
i
0 i = 1 . . . n
P
gen
(i)
0 i = 1 . . . n (5.20)
As described in Section 5.1.2 the inequality constraints are transformed in equality
constraints by adding a positive slack variable:
P
i
P
i,max
+ z
2r
i
= 0 i = 1 . . . n
P
i
+ z
2r
(n+i)
0 i = 1 . . . n
P
gen
(i)
P
gen,max
(i)
+z
2r(i)
= 0 i = 1 . . . n (5.21)
P
gen
(i)
+z
2r(n+i)
0 i = 1 . . . n (5.22)
The Lagrangian-function (5.2) for the optimisation of the total costs of n generators
due to the polynomial cost functions (5.13) is
L(x) = a
0,1
+ a
0,2
+ . . . + a
0,i
+ . . . + a
0,n
+a
1,1
P
1
+ a
1,2
P
2
+ . . . + a
1,i
P
i
+ . . . + a
1,n
P
n
+a
2,1
P
2
1
+ a
2,2
P
2
2
+ . . . + a
2,i
P
2
i
+ . . . + a
2,n
P
2
n
+
1
_
P
1
+ P
2
+ . . . + P
i
+ . . . P
n
P

tot
_
+
1
(P
1
P
1,max
) +
2
(P
2
P
2,max
) + . . .
+
i
(P
i
P
i,max
) . . . +
n
(P
n
P
n,max
)
+
n+1
(P
1
) +
n+2
(P
2
) + . . .
+
n+i
(P
i
) + . . . +
2n
(P
n
)
(5.23)
With (5.16), (5.17) and (5.21) the transformed KKT-system (5.9) can be set up.
The number of equations in this system of n generators is 5n +1. As recommended
in [16] we use s = 1 and r = 2 for the exponent of the slack variables. Equation
(5.24) represents the transformed KKT-system for n generators.
Preparing the system (5.24) for a matrix-based Newton-Raphson algorithm we have
to arrange the unknown variables of the equation system in a vector x (5.25). After
the iterative computation converged, this vector contains the results.
x =
_
P
1
. . . P
i
. . . P
n

1

1
. . .
i
. . .
2n
z
1
. . . z
i
. . . z
2n
_
T
(5.25)
For the implementation of Newton-Raphson we need the Jacobian matrix of the
equation system. It is built by partially dierentiating each row of the transformed
35
5.1 Mathematical Approach
a
1,1
+ 2a
2,1
P
1
+
1
+
2
1
+
2
n+1
= 0
a
1,2
+ 2a
2,2
P
2
+
1
+
2
2
+
2
n+2
= 0
.
.
.
.
.
.
a
1,i
+ 2a
2,i
P
i
+
1
+
2
i
+
2
n+i
= 0
.
.
.
.
.
.
a
1,n
+ 2a
2,n
P
n
+
n
+
2
n
+
2
2n
= 0
P
1
+ P
2
+ . . . + P
i
+ . . . + P
n
P

tot
= 0
P
1
P
1,max
+ z
4
1
= 0
P
2
P
2,max
+ z
4
2
= 0
.
.
.
.
.
.
P
i
P
i,max
+ z
4
i
= 0
.
.
.
.
.
.
P
n
P
n,max
+ z
4
n
= 0
P
1
+ z
4
n+1
= 0
P
2
+ z
4
n+2
= 0
.
.
.
.
.
.
P
i
+ z
4
n+i
= 0
.
.
.
.
.
.
P
n
+ z
4
2n
= 0

2
1
z
4
1
= 0

2
2
z
4
2
= 0
.
.
.
.
.
.

2
i
z
4
i
= 0
.
.
.
.
.
.

2
2n
z
4
2n
= 0
(5.24)
36
5.2 Implementation of the Economic Generation Dispatch
KKT-system (5.24). In (5.26) the Jacobian matrix is stated for a system with n = 2
generators.
J
(n=2)
=
_

_
2a
2,1
0 1 2
1
0 2
3
0 0 0 0 0
0 2a
2,2
1 0 2
2
0 2
4
0 0 0 0
1 1 0 0 0 0 0 0 0 0 0
1 0 0 0 0 0 0 4 z
3
1
0 0 0
0 1 0 0 0 0 0 0 4 z
3
2
0 0
1 0 0 0 0 0 0 0 0 4 z
3
3
0
0 1 0 0 0 0 0 0 0 0 4 z
3
4
0 0 0 2
1
z
4
1
0 0 0 4
2
1
z
3
1
0 0 0
0 0 0 0 2
2
z
4
2
0 0 0 4
2
2
z
3
2
0 0
0 0 0 0 0 2
3
z
4
3
0 0 0 4
2
3
z
3
3
0
0 0 0 0 0 0 2
4
z
4
4
0 0 0 4
2
4
z
3
4
_

_
(5.26)
Since (5.24) includes 5n+1 equations with 5n+1 unknown variables the dimension
of the Jacobian matrix J and the vector x is:
dim{J} = (5n + 1) (5n + 1) (5.27)
dim{ x} = (5n + 1) 1 (5.28)
The Jacobian matrix and the right hand side of the equation system (5.24) have to
be computed in each iteration of the Newton-Raphson algorithm.
5.2 Implementation of the Economic Generation
Dispatch
The Economic Generation Dispatch (EGD) is implemented by using the mathemat-
ical approach described in the last Section. The optimisation problem is solved with
the Unlimited Point algorithm as described in Section 5.1.2. It is implemented in
Matlab.
Re-dispatching the generation aects the power ow in the network. The slack
power and the total active generated power change too, therefore re-dispatching and
recomputing have to be repeated several times until the power ow in the network
does not signicantly change anymore. The procedure is repeated in a loop that
terminates if the change of the generator power values is below a dened tolerance
value (see owchart in Appendix A). The iteration steps are:
1. The user species the parameters of the polynomial cost function for each
generator in the network.
2. The power ow in the network is computed.
3. The total active power generation is given by the sum of all generator power
values.
37
5.2 Implementation of the Economic Generation Dispatch
4. The total generation power is re-dispatched to the generators in the network
with respect to the power limits and the total generation costs.
5. The power ow in the network is computed again, therefore the slack power
and the total generation change.
6. If the generator power values did not change signicantly after the power ow
computation the loop ends, otherwise the algorithm continues with step 3.
Usually Newton-Raphson algorithms use a well dened tolerance value as a criteria
for convergence. If all elements of the right hand side of the equation system, the so-
called disturbance vector, are below the tolerance value, the loop terminates. When
solving (5.24) with Newton-Raphson the disturbance vector is computed in every
iteration from the unknown variables in (5.25). If we consider realistic dimensions
for these variables we can see that they are placed in a wide numerical range. The
generator power values, their power limits and the total generation may vary in
dimensions of many hundred MW. The slack variables
i
and z
i
can be very close
to zero if generators are close to their limits. Therefore the results of the last 2n
equations in (5.24) can be in a very dierent dimension than the values of all other
equations. If we assume P
i
= 100 MW and z
i
= 10
8
(this is realistic if a generator
is close to a limit) we get a numerical range of 10
10
. Taking into account that there
is an element z
4
i
in the Jacobian matrix, it is obvious that these circumstances are
likely to cause critical situations in the numeric calculation.
For this reason it is dicult to nd a proper tolerance value. If the tolerance value
is too small, the algorithm needs many iterations to converge. If it is to large, the
algorithm converges with inaccurate results.
The solution of this problem is to scale the power values in a lower dimensions
before starting Newton-Raphson and re-scale them after the algorithm converged.
In FlowDemo.net the power values are transformed in the p.u. system.
38
Chapter 6
Program Tests
The features of FlowDemo.net 2.0 which were added in this project are tested by
comparing the power ow results with those of the software package NEPLAN [14].
Firstly, a small 3-bus network with a single SVC and TCSC element is used to test
the dierent regulation modes. Then a combined arrangement of SVC and TCSC is
tested in a 6-bus network which is a part of the standardised IEEE 14-bus network.
The Economic Generation Dispatch is tested with three generators in the 6-bus
network which is dened in Section 6.2.1. Dierent cost structures and generator
limits are specied.
With insight to the internal procedure of the computation it is also possible to com-
pare some characteristic quantities like the number of iterations until the Newton-
Raphson algorithm converges or the maximal mismatch value in addition to the
load ow result. Of course for this comparison both programs have to work with the
same parameters for the Newton-Raphson procedure, i.e. the same tolerance value,
maximal number of iterations, step size etc. Therefore in NEPLAN the Convergence
mismatch has to be set to the same value as in FlowDemo.net and Newton Raph-
son has to be specied as Calculation method. With these settings NEPLAN does
not completely support the computation of networks including SVC and TCSC. If
the network contains these elements, the Calculation method should be set to Ex-
tended Newton Raphson. Otherwise the user is informed in the Analysis-Window,
for example TCSC not supported in NR and current iteration method. Choose ex-
tended NR.
Such internal program analysis are not reported in this work, but in general we can
state that:
39
6.1 Tests with Single SVC and TCSC Element
NEPLAN and FlowDemo.net need about the same number of iterations for simple
networks including SVC and -regulated TCSC elements.
NEPLAN needs signicantly less iterations to converge if there are P-regulated
TCSC in the network.
The reason for the second point is the dierent implementation of the TCSC in
NEPLAN and FlowDemo.net. In NEPLAN the classic n-port model is included whereas
in FlowDemo.net an Injection Model is implemented. This model needs an extra
treatment in the Newton-Raphson algorithm, a so-called step size control which
leads to an increase of the iterations until the computation converges (see Section
6.4).
All test results of FlowDemo.net and NEPLAN are printed in Appendix B.
6.1 Tests with Single SVC and TCSC Element
For the single SVC and TCSC tests, where only one SVC or TCSC is part of the net-
work, the 3-bus network described in the following paragraph is used. It is designed
with respect to a typical application of FACTS, the Congestion Management.
6.1.1 3-bus Test Network
The 3-bus network shown in Figure 6.1 represents a situation where FACTS can be
used to manage congestion. The line from bus 1 to bus 2 is overloaded whereas the
path from bus 1 to bus 3 and bus 2 has free transmission capacity. It is possible
to change the power ow situation by using an SVC or a TCSC on bus 3. The
parameters of this network are given in Appendix C Table C.4.
6.1.2 Single SVC Test
The SVC element is tested with all three types of regulations. Since there is only
voltage regulation and no ring angle available in NEPLAN, PQ-loads with P = 0
are used to test reactive power regulated SVC, the re delay angle is checked by
recalculating the results.
The SVC elements are specied with X
C
= 1.0 p.u. and X
L
= 0.1 p.u. for all tests.
The test procedure starts with voltage regulation, all SVC data and some network
40
6.1 Tests with Single SVC and TCSC Element
Figure 6.1: 3-bus network with congestion on line 1-2
Figure 6.2: 3-bus network with single SVC
41
6.1 Tests with Single SVC and TCSC Element
values (bus voltages and angles, generated power) are recorded for dierent target
values V . Then the results of the SVCs reactive power are used as desired values
for Q-regulation and the results for the re delay angle are taken as target values
for the -regulation. After comparing all results of V -, Q- and -regulation we can
see if the program works correctly and estimate its numerical accuracy.
6.1.3 Single SVC Test Results
The SVC test results are printed in Appendix B Table B.1. In this Table we can
see the results of the three SVC regulation types in FlowDemo.net and the results
of the voltage regulated SVC in NEPLAN.
V-Regulation: In this regulation mode FlowDemo.net and NEPLAN give the same
results. Concerning two decimals there are no deviations. As we can see in Table
B.1 nr. 1 and nr. 8 the reactive power limits are not exceed.
Q-Regulation: Comparing the results of the reactive power regulation in Table
B.1 nr. 918 with the results of the voltage regulation we can see that there are
small deviations of the re delay angle in the second decimal (nr. 11 and 15). Test
nr. 9 and nr. 19 show that the reactive power limits are not violated.
Angle-Regulation: The results of the angle-regulated SVC dier from those of
NEPLAN only in nr. 24, rst decimal of the reactive power. The reason for this is
that the function which describes the FACTSs susceptance is highly sensible to the
ring angle. A very small deviation of the ring angle can cause a big deviation of
the reactive power value.
6.1.4 Single TCSC Test
The TCSC is tested with regulation of the ring angle and of the active trans-
mission power P. Since in NEPLAN the so called prevailing conduction angle and
a dierent approach for the apparent susceptance is implemented, the ring angle
results cannot be compared with those of FlowDemo.net. Sometimes a certain P is
revised by NEPLAN if it is not allowed due to certain borders and limits. These limits
can be deactivated by triggering the TCSC on the total apparent impedance X
tot
.
Because one of the applications of a TCSC is reactive line compensation, the TCSC
is tested in this eld of operation. Therefore another bus is inserted in the 3-bus
test network (which becomes a 4-bus network then) and the TCSC is tested with all
42
6.2 Combined SVC and TCSC Test
Figure 6.3: 3-/4-bus network with single TCSC
types of regulation. The network elements are exactly the same as used in Section
6.1.2, the values of the TCSC are X
C
= 0.3 p.u. and X
L
= 0.1 p.u.
6.1.5 Single TCSC Test Results
The TCSC test results are printed in Appendix B Table B.2, the results of FlowDemo.net
are compared with those of NEPLAN.
Angle-Regulation: The results dier only for U
2
in test nr. 4 and U
3
in test nr. 7.
A reason for this inaccuracy could be that the TCSC in NEPLAN is operating with
specied total impedance X
tot
. This target value X
tot
is calculated from the re
delay angle, X
L
and X
C
.
Power-Regulation: Deviations of the voltage drop du are visible in test nr. 8, 9
and nr. 12, third decimal. All other results are equal with those of NEPLAN.
6.2 Combined SVC and TCSC Test
Beside the tests where only one FACTS element was part of the network, we need
to check the functionality of the program if more than one SVC or TCSC element is
in the network. These tests are done in a more complex 6-bus network that includes
all kinds of network elements in dierent regulation modes.
The 6-bus network is also used to test the incremental changes and the switching of
FACTS elements. Incremental changes are done for all SVC and TCSC elements by
clicking on the +/ buttons which cause a change of the target value. The compu-
43
6.2 Combined SVC and TCSC Test
tation results are veried by repeatedly setting and re-setting the target value and
checking if the result values are the same as before the change/rechange operation.
This procedure is also used to check the switching of FACTS elements.
6.2.1 6-bus Test Network
For the combined SVC and TCSC tests a 6-bus network was extracted from the
standardised IEEE 14-bus network which is dened in [13]. The 6-bus network in
Figure 6.4 includes bus 1, 2, 5, 6, 12, 13 and all elements which are connected to
them from the original 14-bus network. The network data are printed in Appendix
C Table C.5.
6.2.2 Test Arrangement
Several arrangements of SVC and TCSC are tested and compared with the results of
the same network in NEPLAN. For the network shown in Figure 6.5 the result values
are documented and printed in Appendix B. The new busses 7 and 8 are inserted
to connect the TCSC elements in series with the lines.
In this example three SVC and two TCSC elements are used in dierent regulation
modes. The rst SVC regulates the voltage of bus 3. The second SVC on bus 4
is -regulated, the third SVC is Q-regulated and connected to bus 6. The TCSC
between bus 7 and bus 2 is regulated on active transmission power P, the TCSC
between bus 8 and bus 5 is regulated on the ring angle (see Table C.6).
6.2.3 Combined SVC and TCSC Test Results
The results of the combined SVC and TCSC tests are printed in Appendix B Table
B.3 and Table B.4, the target values of the FACTS are colored grey.
In Table B.3 nr. 1 and nr. 2 the power ow results of NEPLAN and FlowDemo.net for
the 6-bus network without any FACTS are compared. Then the network is computed
with the three SVC (nr. 3 and nr. 4) and later with the two TCSC elements (nr. 5
and nr. 6). Finally all FACTS are inserted in the 6-bus network (nr. 7 and nr. 8).
In Table B.4 the target value of each single SVC and TCSC element is changed and
the results of FlowDemo.net are compared with those of NEPLAN.
Since NEPLAN works with values in S.I. units one has to transform the p.u. values used
44
6.2 Combined SVC and TCSC Test
Figure 6.4: 6-bus test network
45
6.2 Combined SVC and TCSC Test
Figure 6.5: 6-/8-bus test network with SVC and TCSC elements
46
6.3 Test of Economic Generation Dispatch
in FlowDemo.net. Although the values are transformed exactly some dierences in
the power ow result occur (Table B.3 nr. 1 and nr. 2).
Another possible reason for small deviations of the results is multi-rounding, i.e. some
values may be rounded more than one time and on dierent digits during the pro-
ceedings in the client, the server and the computation engine.
6.3 Test of Economic Generation Dispatch
The Economic Generation Dispatch is tested in the Matlab environment. The test
results are printed in Appendix B.
6.3.1 Test Arrangement
The Economic Generation Dispatch is tested with three generators in the 6-bus
network pictured in Figure 6.4. An additional generator is connected to bus 4,
it operates in PQ-mode with P = 10 MW and Q = 5 MVar. The program is
tested with dierent generation limits P
gen,max
and dierent cost function factors
A
P
resp. C
P,i
. The numerical performance of the Unlimited Point algorithm is tested
by using cost function factors of very dierent numerical dimension (see Appendix
B Table B.5 nr. 1012 and nr. 1820).
6.3.2 EGD Test Results
The results of the Economic Generation Dispatch tests are printed in Appendix B
Table B.5 and B.6. The result of the ordinary power ow is P
gen
= [28.2 22.0 10.0]
T
MW, the dispatch starts with the total load of 60.2 MW.
The Unlimited Point algorithm does not converge in the second run of test nr. 9
and nr. 11, it does not converge at all in test nr. 7. The reason for this is the
big dierence in the numerical dimension of the cost function factors (see Section
5.2). Nevertheless the dispatch leads to useful results in test nr. 9 and nr. 11. In
test nr. 23 there is no possible solution due to the specied power limits, the total
generation before the dispatch is higher than the sum of the generator power limits.
The column

C
P,i
in Table B.5 and B.6 gives the total generation costs in the
network before and after the dispatch. When calculating this value it is important to
use the same dimension of P
gen,disp
as the dispatch program uses. Since the dispatch
47
6.4 Known Issue
in FlowDemo.net works with power values in p.u. these values have also to be taken
in p.u. for calculating the total costs. This means that the cost factors in the matrix
C
P,i
are related to power values in p.u. For the tests in Table B.5 and B.6 the base
power value is 1.0 p.u. = 100 MVA.
The column total save gives the total save of generation costs in the network. They
are computed as the relative dierence of the costs before and after the dispatch in
percent:
total save =

C
P,i
before

C
P,i
after

C
P,i
before
100% (6.1)
The total save is always positive except test nr. 21 and nr. 31. The reason for
this is that in these tests the generators are limited lower than they are limited for
the normal power ow computation, so that the more expensive generators have to
deliver more power as they do without any Economic Dispatch.
Of course the total save increases with the dierence in the cost factors of the
generators. The more the generators dier in their cost structures the more saving
can be made using an Economic Generation Dispatch.
6.4 Known Issue
One handicap of the TCSC Injection Model implementation is the regulation of the
active transmission power P. In a certain range of the target value P the Newton-
Raphson algorithm converges to a solution which is mathematically correct but
not useful in practice. This solution represents a point on the lower branch of the
TCSCs nose curve. As a corrective measure a step size control can be used in the
calculation of the new reactive power value after every iteration. This expands the
area where the computation leads to the desired result, but the problem still exists
for high values of P. Several measures are tried to solve the problem in question,
but unfortunately no general solution can be found with the following methods:
1. Initialising the reactive power value of the TCSC with zero and slowly increas-
ing it from iteration to iteration in order to avoid a fast decrease of the end
bus voltage.
2. Initialising and keeping the reactive power value of the TCSC zero for the rst
three iterations in order to get stabile voltages and angles before the reactive
power of the TCSC inuences them.
48
6.4 Known Issue
3. Re-setting the end bus voltage on a high and the reactive power on a low value
in order to constrain the result in the right area.
4. Changing the initial values of the Newton-Raphson procedure:
- for voltages and phase angles
- for currents and powers
5. Avoiding a change of the sign of the reactive power value, i.e. restrict the
reactive power value whether to be inductive or capacitive.
6. Calculating the new reactive power value only after every second iteration in
order to stabilise the voltage and phase angle values.
7. Including a step size control for the reactive power value, whereas the step size
depends on the change of the TCSCs end-node voltage from one iteration to
the next. Three dierent step sizes and step values are used.
8. Using a step size control which does a backward step for all unknown values
(i.e. for the whole vector of unknowns in the Newton-Raphson loop) if the
change of the voltage from one iteration to the next is over a certain limit.
Then the iteration step is repeated with a damping factor c < 1 for the reactive
power value of the TCSC.
When implementing a step size control a lot of questions come up. A criteria which
indicates the need for a change of the step size and a step size value have to be
found. It is also possible to implement more than one step size values whereas
the step size depends on the value of a certain criteria. Another possibility is to
directly determine the step size from an empirical formula which is a function of
state variables, e.g. voltage drop, active and reactive power values.
The success of such a method depends very much on the chosen criteria and step
size value. Only a small change of the step size value can completely change the
result of the computation. Therefore it is not sure that all mentioned methods fail
in every case, it is still possible that a certain criteria in combination with a certain
step size leads to the desired computation result.
49
Chapter 7
Conclusion
This report documents the implementation of two types of FACTS devices and an
Economic Generation Dispatch in the power ow simulation platform FlowDemo.net.
The conclusion will give a brief summary of the work undertaken and then discuss
possible improvements and future work.
7.1 Project Summary
In the rst step of this work the existing version of FlowDemo.net has been analysed
and the possibilities of implementing FACTS have been evaluated.
After deciding for the Static Var Compensator (SVC) and the Thyristor Controlled
Series Capacitor (TCSC), these elements were modelled mathematically and a con-
cept for the embedding in the power ow computation was worked out. Firstly, the
SVC was implemented with regulation on reactive power, node voltage and re delay
angle. Secondly, the TCSC was implemented with regulation on active transmission
power and re delay angle.
The implementations in Matlab were completed with some additional features like
incremental changes and switching procedures. Problems occurred with the switch-
ing of SVC and TCSC elements and with the computation of P-regulated TCSC.
After the implementations in the power ow computation were nished, the SVC and
TCSC elements were added to the GUI. New classes and dialog boxes for SVC and
TCSC elements were included in the object-orientated Java code and an interface
to the Matlab computation engine was dened.
50
7.2 Discussion
The rst part of this work was completed by doing several tests and comparing the
results with those of software package NEPLAN.
The second part of the project was the implementation of an Economic Generation
Dispatch. The target of this procedure is to minimise the total generation costs in the
network. This task is stated as an inequality constrained optimisation problem due
to Karush-Kuhn-Tucker, the problem was solved using an Unlimited Point algorithm
which was implemented in Matlab. The Economic Generation Dispatch was tested
out and its numerical performance was evaluated.
7.2 Discussion
Implemented FACTS Models
As mentioned in Chapter 2 an Injection Model of the SVC and the TCSC is im-
plemented for regulation of reactive and active power. The major advantage of this
model is that the implementation can be easily based on PQ-elements which are
usually available in power ow software. The new FACTS elements do not need to
be included in the Jacobian matrix which therefore stays simple.
The Injection Model seems not to be very convenient for the implementation of a
P-regulated TCSC (see Section 6.4). An implementation of the classic n-port model
(as described in [10]) would probably not cause such diculties. A step size con-
trol for the Injection Model implementation opens almost endless opportunities of
possible criteria and step size values. Since an implementation of a step size control
improved already the performance of the computation we assume that it is feasible
to solve the problem in this way. The point is to nd an ecient combination of a
signicant criteria that indicates the need for a change of the step size and a proper
step size value.
Economic Generation Dispatch
The Economic Generation Dispatch, also called Lambda Dispatch, is working cor-
rectly when using realistic values for the cost function factors. If they are placed in
very dierent numerical ranges it could happen that the Unlimited Point algorithm
does not converge.
51
7.3 Outlook
7.3 Outlook
An element which is missing in FlowDemo.net but available in common power ow
software is the innite bus (feeder). A simple implementation for power ow studies
could be based on a PV- or slack-generator without reactive power limits. Further-
more one-sided switching of 2-ports is not implemented yet. This feature could be
implemented like the two-sided switching, but only the current values of the opened
end have to be set to zero.
As mentioned in Section 3.3.3 the switching on procedures of SVC and TCSC ele-
ments are not implemented satisfactorily yet. Also the current version of the switch-
ing o procedures, which is not very fast yet, could be improved.
The implementation of the TCSC could be extended with regulation on the TCSC
current. One possibility to realise this is the use of the Injection Model quite similar
to the P-regulation.
FACTS for series and parallel compensation are now implemented, the Unied Power
Flow Controller (UPFC), which represents combined series and parallel compensa-
tion, could be a further development. Since the UPFC is a more complex element
than SVC and TCSC and due to the computation problems that occurred using
the Injection Model for the P-regulated TCSC, we would advice to implement the
classic n-port model of the UPFC.
In terms of optimisation Optimal Power Flow (OPF) would be an interesting new
feature of FlowDemo.net. Therefore elementary and extensive considerations whether
it is possible to implement this with the current software design or not have to be
done.
The Economic Generation Dispatch is now implemented as a so-called Lambda
Dispatch with total inexible load. The implementation could be enhanced with
exible loads, i.e. loads which change their values depending on the market situation.
This would introduce aspects of an electricity market in FlowDemo.net.
52
Appendix A
Flowcharts
53
Flowcharts
Q
i
set by user
Add SVC in load matrix
Start
End
Regulation ?

i
set by user
Compute X
i
= f(X
L
, X
C
,
i
)
Add SVC in line matrix
Newton-Raphson
Extract SVCs from
lines-matrix
V
i
set by user
Add SVC in gen matrix
Compute susceptance
B = f(Q, U
i
)
Extract SVCs from
gen-matrix
Compute firing angle
= f(B, X
L
, X
C
)
Extract SVCs from
load-matrix
Compute susceptance
B = f(Q, U
i
)
Compute firing angle
= f(B, X
L
, X
C
)
Figure A.1: SVC ow chart
54
Flowcharts
P
i j
set by user
Add TCSC-loads in load
matrix
P
ij
+ Q
ij
on bus i
-P
ij
+Q
ji
on bus j
Start
End
Extract TCSC-loads
from load-matrix
Regulation ?

i
set by user
Compute X
i
= f(
i
)
Add TCSC-line in line matrix
with Z
line,i
= jX
i
Newton-Raphson
Extract TCSC-lines
from lines-matrix
Compute firing angle
= f(B, X
L
, X
C
)
Iteration step
Newton-Raphson
(new U
i
, U
j
, )
Compute new reactive power
values
Q
ij
= f(P
ij
, U
i
, U
j
, )
Q
ji
= f(P
ij
, U
i
, U
j
, )
NR converged
OR
max. iterations
Compute susceptance
B = f(Pij, Ui, Uj, d)
Figure A.2: TCSC ow chart
55
Flowcharts
Start
a
0
, a
1
, a
2
and
P
gen,max
set by
user
Unlimited Point
Solution?
Power flow
computation
P
gen,old
Power flow
computation
P
gen
| P
gen
- P
gen,old
| <
d
OR
max. repeats
End
P
gen,old
= P
gen
no
yes
no
yes
P
gen
= P
gen,old
Figure A.3: Economic Generation Dispatch ow chart
56
Appendix B
Test Data
57
Test Data
FlowDemo.net
V-Regulation
V Q
SVC
U
2

2
U
3

3
P
G
Q
G
p.u. MVar deg p.u. deg p.u. deg MW MVar
1 0.90 50.0 62.62 0.96 -5.42 0.95 -2.39 125.6 112.5 *
2 0.95 48.1 62.10 0.96 -5.43 0.95 -2.43 125.5 110.1
3 0.97 34.4 58.99 0.97 -5.46 0.97 -2.67 124.8 93.6
4 0.99 20.1 56.46 0.98 -5.50 0.99 -2.92 124.3 77.1
5 1.01 5.1 54.30 0.99 -5.54 1.01 -3.16 123.9 60.6
6 1.03 -10.4 52.42 1.00 -5.59 1.03 -3.40 123.6 44.1
7 1.05 -26.7 50.75 1.00 -5.64 1.05 -3.65 123.6 27.6
8 1.10 -50.0 48.72 1.02 -5.71 1.08 -3.99 123.7 4.9 *
Q-Regulation
Q Q
SVC
U
2

2
U
3

3
P
G
Q
G
p.u. MVar deg p.u. deg p.u. deg MW MVar
9 60.0 50.0 62.62 0.96 -5.42 0.95 -2.39 125.6 112.5 *
10 50.0 50.0 62.62 0.96 -5.42 0.95 -2.39 125.6 112.5
11 48.1 48.1 62.11 0.96 -5.43 0.95 -2.43 125.5 110.1
12 34.4 34.4 58.99 0.97 -5.46 0.97 -2.67 124.8 93.6
13 20.1 20.1 56.46 0.98 -5.50 0.99 -2.92 124.3 77.1
14 5.1 5.1 54.30 0.99 -5.54 1.01 -3.16 123.9 60.6
15 -10.4 -10.4 52.43 1.00 -5.59 1.03 -3.40 123.6 44.1
16 -26.7 -26.7 50.75 1.00 -5.64 1.05 -3.65 123.6 27.6
17 -50.0 -50.0 48.72 1.02 -5.71 1.08 -3.99 123.7 4.9
18 -60.0 -50.0 48.72 1.02 -5.71 1.08 -3.99 123.7 4.9 *

Q
SVC
U
2

2
U
3

3
P
G
Q
G
deg MVar p.u. deg p.u. deg MW MVar
19 62.62 50.0 0.96 -5.42 0.95 -2.39 125.6 112.5
20 62.62 48.1 0.96 -5.43 0.95 -2.43 125.5 110.1
21 62.11 34.4 0.97 -5.46 0.97 -2.67 124.8 93.6
22 58.99 20.1 0.98 -5.50 0.99 -2.92 124.3 77.1
23 56.46 5.1 0.99 -5.54 1.01 -3.16 123.9 60.6
24 54.30 -10.5 1.00 -5.59 1.03 -3.40 123.6 44.1
25 52.43 -26.7 1.00 -5.64 1.05 -3.65 123.6 27.6
26 50.75 -50.0 1.02 -5.71 1.08 -3.99 123.7 4.9
* power limit exceed
NEPLAN
V-Regulation
V Q
SVC
U
2

2
U
3

3
P
G
Q
G
p.u. MVar deg p.u. deg p.u. deg MW MVar
27 0.90 50.0 62.62 0.96 -5.42 0.95 -2.39 125.6 112.5
28 0.95 48.1 62.10 0.96 -5.43 0.95 -2.43 125.5 110.2
29 0.97 34.4 58.99 0.97 -5.46 0.97 -2.67 124.8 93.6
30 0.99 20.1 56.46 0.98 -5.50 0.99 -2.92 124.3 77.1
31 1.01 5.1 54.30 0.99 -5.54 1.01 -3.16 123.9 60.6
32 1.03 -10.4 52.42 1.00 -5.59 1.03 -3.40 123.6 44.1
33 1.05 -26.7 50.75 1.00 -5.64 1.05 -3.65 123.6 27.6
34 1.10 -50.0 48.72 1.02 -5.71 1.08 -3.99 123.7 4.9
Nr.
Nr.
Nr.
Nr.
a-Regulation
Table B.1: SVC test data
58
Test Data
FlowDemo.net
-Regulation
U
2

2
U
3

3
U
4

4
P
34
Q
34
Q
43
du P
G
Q
G
deg p.u. deg p.u. deg p.u. deg MW MVar MVar p.u. MW MVar
1 0.00 0.99 -5.98 1.02 -2.41 1.01 -4.21 21.5 10.1 -9.3 0.0349 123.9 56.2
2 15.00 0.98 -6.25 1.03 -1.93 1.00 -4.80 17.6 9.2 -8.1 0.0567 124.0 57.0
3 30.00 0.97 -7.01 1.05 -0.62 0.98 -6.51 6.1 4.3 -3.5 0.1237 124.6 59.3
4 45.00 0.82 -8.77 1.31 -1.56 0.66 -8.90 -16.6 -129.2 63.5 0.6585 145.1 744.6
5 60.00 0.99 -2.08 1.05 -10.46 1.01 5.18 78.5 -21.8 -0.2 0.2822 127.4 47.7
6 75.00 0.99 -3.11 1.02 -8.33 1.03 2.50 64.3 -4.7 -7.5 0.1935 125.4 49.5
7 90.00 1.00 -3.22 1.02 -8.10 1.03 2.24 62.7 -3.3 -8.0 0.1846 125.3 49.7
P-Regulation
P U
2

2
U
3

3
U
4

4
Q
34
Q
43
du P
G
Q
G
MW p.u. deg p.u. deg p.u. deg deg MVar MVar p.u. MW MVar
8 -10.0 0.95 -8.11 1.09 0.86 0.93 -8.95 37.53 -10.9 7.7 0.2350 126.6 63.3
9 -5.0 0.96 -7.76 1.07 0.46 0.95 -8.18 35.77 -4.8 3.5 0.1968 125.8 61.9
10 -1.0 0.96 -7.49 1.06 0.10 0.96 -7.57 34.07 -0.9 0.6 0.1690 125.3 60.9
11 0.0 0.96 -7.42 1.06 0.00 0.96 -7.42 33.59 0.0 0.0 0.1623 125.2 60.7
12 1.0 0.97 -7.35 1.06 -0.10 0.97 -7.27 33.09 0.8 -0.6 0.1557 125.1 60.4
13 5.0 0.97 -7.08 1.05 -0.50 0.98 -6.67 30.67 3.7 -2.9 0.1303 124.7 59.5
14 10.0 0.98 -6.75 1.04 -1.05 0.99 -5.93 26.70 6.5 -5.3 0.1001 124.3 58.5
NEPLAN
X-Regulation
X U
2

2
U
3

3
U
4

4
P
34
Q
34
Q
43
du P
G
Q
G
Ohm p.u. deg p.u. deg p.u. deg MW MVar MVar p.u. MW MVar
15 1210.0 0.99 -5.98 1.02 -2.41 1.01 -4.21 21.5 10.1 -9.3 0.0349 123.9 56.2
16 1317.3 0.98 -6.25 1.03 -1.93 1.00 -4.80 17.6 9.2 -8.1 0.0567 124.0 57.0
17 1427.3 0.97 -7.01 1.05 -0.62 0.98 -6.51 6.1 4.3 -3.5 0.1237 124.6 59.3
18 1521.2 0.82 -8.77 1.30 -1.56 0.66 -8.90 -16.6 -129.2 63.5 0.6585 145.1 744.6
19 1582.9 0.99 -2.08 1.05 -10.46 1.01 5.18 78.5 -21.8 -0.2 0.2822 127.4 47.7
20 1609.3 0.99 -3.11 1.02 -8.33 1.03 2.50 64.3 -4.7 -7.5 0.1935 125.4 49.5
21 1613.3 0.99 -3.22 1.02 -8.10 1.03 2.24 62.7 -3.3 -8.0 0.1846 125.3 49.7
P-Regulation
P U
2

2
U
3

3
U
4

4
Q
34
Q
43
du P
G
Q
G
MW p.u. deg p.u. deg p.u. deg deg MVar MVar p.u. MW MVar
22 -10.0 0.95 -8.11 1.09 0.86 0.93 -8.95 -- -10.9 7.7 0.2349 126.6 63.3 *
23 -5.0 0.96 -7.76 1.07 0.46 0.95 -8.18 -- -4.8 3.5 0.1969 125.8 61.9 *
24 -1.0 0.96 -7.49 1.06 0.10 0.96 -7.57 -- -0.9 0.6 0.1690 125.3 60.9 *
25 0.0 0.96 -7.42 1.06 0.00 0.96 -7.42 -- 0.0 0.0 0.1623 125.2 60.7 *
26 1.0 0.97 -7.35 1.06 -0.10 0.97 -7.27 -- 0.8 -0.6 0.1558 125.1 60.4 *
27 5.0 0.97 -7.08 1.05 -0.50 0.98 -6.67 -- 3.7 -2.9 0.1303 124.7 59.5 *
28 10.0 0.98 -6.75 1.04 -1.05 0.99 -5.93 -- 6.5 -5.3 0.1001 124.3 58.5
* not allowed in Neplan
Nr.
Nr.
Nr.
Nr.
Table B.2: TCSC test data
59
Test Data
U
1

1
U
2

2
U
3

3
U
4

4
U
5

5
U
6

6
P
G
1
Q
G
1
P
G
2
Q
G
2
p
.
u
.
d
e
g
p
.
u
.
d
e
g
p
.
u
.
d
e
g
p
.
u
.
d
e
g
p
.
u
.
d
e
g
p
.
u
.
d
e
g
M
W
M
V
a
r
M
W
M
V
a
r
1
N
E
P
L
A
N
1
.
0
4
0
0
.
0
0
0
1
.
0
4
5
-
0
.
5
7
0
1
.
0
4
7
-
1
.
4
4
0
1
.
0
7
0
-
2
.
5
8
0
1
.
0
6
9
-
3
.
0
0
0
1
.
0
6
0
-
1
.
6
3
0
3
8
.
7
0
-
4
0
.
3
5
2
2
.
0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0
.
0
0
5
8
.
5
1
-
1
0
.
0
0
3
.
9
0
-
3
.
8
0
0
.
0
0
8
5
2
6
.
3
0
-
6
.
6
0
3
.
7
0
-
3
.
8
0
0
.
0
0
7
6
7
0
.
0
0
1
6
N
E
P
L
A
N
3
3
.
9
8
-
-
-
6
.
6
0
-
-
3
0
.
0
0
-
-
-
1
0
.
0
0
3
.
8
6
-
3
.
9
5
0
.
0
0
8
4
1
0
8
.
7
5
-
6
.
7
0
6
.
9
3
-
7
.
0
8
0
.
0
1
6
1
1
4
3
.
0
7
1
7
F
l
o
w
D
e
m
o
.
n
e
t
3
4
.
0
0
6
9
.
4
3
-
6
.
6
0
3
0
.
0
0
3
0
.
0
0
5
8
.
5
1
-
1
0
.
0
0
3
.
9
0
-
3
.
8
0
0
.
0
0
8
5
2
6
.
2
8
-
6
.
7
0
6
.
9
0
-
7
.
1
0
0
.
0
1
6
1
5
0
.
0
0
*

f
i
r
e

d
e
l
a
y

a
n
g
l
e

o
u
t

o
f

r
a
n
g
e
T
C
S
C

b
u
s

8

-

b
u
s

5
N
e
t
w
o
r
k

v
a
l
u
e
s
N
r
.
N
r
.
F
A
C
T
S

v
a
l
u
e
s
S
V
C

b
u
s

3
S
V
C

b
u
s

4
S
V
C

b
u
s

6
T
C
S
C

b
u
s

7

-

b
u
s

2
Table B.4: Combined SVC and TCSC test data
61
Test Data
C
P,i
P
gen,max
P
gen,disp
P
total total save
a
0,i
a
1,i
a
2,i MW MW MW before after %
1 1 1 100 20.05
1 1 1 100 20.05 2 10 / 10 60.15 3.74 3.72 0.48
1 1 1 100 20.05
1 0 1 100 53.46
1 1 1 100 3.46 2 12 / 12 60.38 3.46 3.36 2.91
1 1 1 100 3.46
1 1 1 100 3.75
1 0 1 100 53.73 2 12 / 12 61.21 3.52 3.37 4.36
1 1 1 100 3.73
1 1 1 100 3.36
1 1 1 100 3.36 2 12 / 12 60.08 3.64 3.35 7.85
1 0 1 100 53.36
1 1 1 100 55.21
1 2 1 100 5.21 2 11 / 11 60.42 4.16 3.96 4.71
1 3 1 100 0.00
1 3 1 100 0.00
1 2 1 100 5.06 2 11 / 11 60.12 4.52 3.96 12.52
1 1 1 100 55.06
1 1 1 100 28.20
1 10 1 100 22.00 1 not conv. 60.20 15.62 15.62 0.00
1 100 1 100 10.00
1 1 1 100 60.56
1 10 1 100 0.00 2 26 / 27 60.56 7.62 3.97 47.87
1 20 1 100 0.00
1 20 1 100 -0.08
1 10 1 100 0.00 2 26 / not conv. 60.12 11.08 3.95 64.36
1 1 1 100 60.20
1 10 1 100 0.00
1 1 1 100 30.21 2 9 / 9 60.42 6.28 3.79 39.68
1 1 1 100 30.21
1 100 1 100 0.22
1 1 1 100 30.10 2 29 / not conv. 60.42 31.66 4.00 87.35
1 1 1 100 30.10
1 1000 1 100 0.00
1 1 1 100 30.21 2 31 / 31 60.42 285.46 3.79 98.67
1 1 1 100 30.21
1 1 0 100 60.51
1 1 1 100 0.03 2 15 / 15 60.57 3.66 3.61 1.49
1 1 1 100 0.03
1 1 1 100 0.03
1 1 0 100 61.58 3 15 / 15 / 15 61.64 3.69 3.62 2.04
1 1 1 100 0.03
1 1 1 100 0.03
1 1 1 100 0.03 2 15 / 15 60.13 3.73 3.60 3.45
1 1 0 100 60.07
1 1 1 100 32.79
1 1 2 100 16.42 1 10 60.16 3.81 3.80 0.24
1 1 3 100 10.95
1 1 3 100 10.93
1 1 2 100 16.39 2 10 / 10 60.10 3.95 3.80 3.78
1 1 1 100 32.78
1 1 1 100 54.42
1 1 10 100 5.44 2 13 /13 60.40 5.17 3.93 23.87
1 1 100 100 0.54
1 1 100 100 0.54
1 1 10 100 5.42 2 13 / 13 60.11 12.05 3.93 67.41
1 1 1 100 54.15
1 1 1000 100 0.06
1 1 100 100 0.59 2 15 / 15 60.12 87.98 3.96 95.50
1 1 1 100 59.47
19
20
1
15
16
17
18
11
12
13
14
7
8
9
10
3
4
5
6
C
P,i
2
Nr. repeats
Unlim. Point
iterations
Table B.5: Economic Generation Dispatch test data
62
Test Data
C
P,i
P
gen,max
P
gen,disp
P
total total save
a
0,i
a
1,i
a
2,i MW MW MW before after %
1 1 1 100 20.05
1 1 1 100 20.05 2 10 / 10 60.15 3.74 3.72 0.48
1 1 1 100 20.05
1 1 1 100 30.18
1 1 1 20 20.00 1 11 60.18 3.74 3.74 -0.08
1 1 1 10 10.00
1 1 1 10 9.95
1 1 1 20 20.00 1 11 59.95 3.74 3.74 0.01
1 1 1 100 30.00
1 1 1 10 28.20
1 1 1 10 22.00 1 no solution 60.20 3.74 3.74 0.00
1 1 1 10 10.00
1 1 1 100 56.98
1 2 2 100 3.49 2 12 / 12 60.47 4.23 3.97 6.19
1 3 3 100 0.00
1 1 3 100 33.69
1 2 2 100 25.54 2 13 / 13 60.31 4.37 4.35 0.37
1 3 1 100 1.08
1 1 2 100 46.18
1 2 3 100 14.12 2 11 / 11 60.30 4.34 4.23 2.44
1 3 1 100 0.00
1 9 2 100 33.78
1 10 1 100 17.60 1 11 60.18 8.97 8.95 0.12
1 10 2 100 8.80
1 9 2 100 35.06
1 10 1 15 15.00 1 12 60.16 8.97 8.95 0.13
1 10 2 15 10.10
1 9 0.2 100 60.56
1 10 0.1 15 0.00 2 10 / 10 60.56 8.76 8.52 2.71
1 10 0.2 15 0.00
1 9 0.2 40 40.00
1 10 0.1 15 13.47 1 12 60.20 8.76 8.65 1.21
1 10 0.2 15 6.73
1 9 0.2 10 10.01
1 10 0.1 40 35.48 2 13 / 13 60.49 8.76 8.97 -2.37
1 10 0.2 15 15.00
1 0.700 0.035 1 0.01
1 0.040 0.002 100 61.63 3 12 / 12 / 12 61.64 3.22 3.03 6.18
1 0.150 0.070 5 0.00
1 0.032 0.001 20 20.00
1 0.029 0.001 30 30.00 2 14 / 14 60.33 3.02 3.02 0.01
1 0.034 2E-04 40 10.33
1 3.200 0.100 20 20.00
1 2.900 0.100 30 30.00 2 11 / 11 60.33 4.89 4.87 0.39
1 3.400 0.020 40 10.33
1 3.200 0.100 40 30.38
1 2.900 0.100 30 30.00 2 11 / 11 60.38 4.89 4.86 0.67
1 3.400 0.020 20 0.00
1 3.14 0.12 100 0.01
1 2.98 0.18 100 36.87 2 13 / 13 60.61 4.87 4.86 0.21
1 3.07 0.09 100 23.73
1 3.14 0.12 50 10.34
1 2.98 0.18 30 30.00 2 12 / 12 60.34 4.87 4.85 0.28
1 3.07 0.09 20 20.00
32
37
33
34
35
36
28
29
30
31
24
25
26
27
1
21
22
23
C
P,i
Nr. repeats
Unlim. Point
iterations
Table B.6: Economic Generation Dispatch test data
63
Appendix C
Variables, Scripts and Functions
Element Changing value Declarations Command/Script
TCSC P
ij
= P
ji
first{user} changeTcscP.m
second{user}
num{user}
newP{user}
TCSC first{user} changeTcscAngle.m
second{user}
num{user}
newAngle{user}
SVC Q
i
bus{user} changeSvcQ.m
newQ{user}
num{user}
SVC V
i
bus{user} changeSvcV.m
newV{user}
num{user}
SVC bus{user} changeSvcAngle.m
newAngle{user}
num{user}
Table C.1: Declarations and commands for incremental changes
64
Variables, Scripts and Functions
Variable Content
first{user} start bus nr. of TCSC
second{user} end bus nr. of TCSC
num{user} linear row index in element matrix
bus{user} connected bus nr. of SVC
newP{user} new desired active power transmission
newQ{user} new desired reactive power value
newV{user} new desired bus voltage
newAngle{user} new desired re delay angle
Table C.2: Content of declaration variables
Element Switching Declarations Command/Script
TCSC o first{user} tcscOff.m
second{user}
num{user}
TCSC on (all) start.m
SVC o bus{user} svcOff.m
num{user}
SVC on (all) start.m
Table C.3: Declarations and commands for switching
Element Bus Values
Generator 1 slack, U
target
= 1.06 p.u.
Load 3 P = 120 MW, Q = 40 MVar
Line 1-2 X = 0.12 p.u., R = 0.03 p.u., G = 0.00 p.u.
1-3 X = 0.24 p.u., R = 0.06 p.u., G = 0.00 p.u.
2-3 X = 0.16 p.u., R = 0.04 p.u., G = 0.00 p.u.
Table C.4: 3-bus test network data
65
Variables, Scripts and Functions
Element Bus Values
SVC (all) X
C
= 1.0 p.u., X
L
= 0.1 p.u.
TCSC (all) X
C
= 0.3 p.u., X
L
= 0.1 p.u.
Generator 1 slack, U
target
= 1.040 p.u.
2 PV, P = 22.0 MW, U
target
= 1.06 p.u.
Load 2 P = 21.7 MW, Q = 12.7 MVar
3 P = 7.6 MW, Q = 1.6 MVar
4 P = 11.2 MW, Q = 7.5 MVar
5 P = 13.5 MW, Q = 5.8 MVar
Shunt 3 G = 0.00 p.u., B = 0.19 p.u.
5 G = 0.05 p.u., B = 0.19 p.u.
Capacitor 2 PV, U
target
= 1.045 p.u., Q
max/min
= 500/-400 MVar
4 PV, U
target
= 1.070 p.u., Q
max/min
= 240/-100 MVar
Line 1-2 R = 0.01938 p.u., X = 0.05917 p.u., B = 0.05280 p.u.
1-3 R = 0.05403 p.u., X = 0.22304 p.u., B = 0.04920 p.u.
2-3 R = 0.05695 p.u., X = 0.17388 p.u., B = 0.03460 p.u.
4-5 R = 0.06615 p.u., X = 0.13027 p.u., B = 0.00000 p.u.
4-6 R = 0.06615 p.u., X = 0.13027 p.u., B = 0.00000 p.u.
5-6 R = 0.06615 p.u., X = 0.13027 p.u., B = 0.00000 p.u.
Trafo 3-4 R = 0.00000 p.u., X = 0.25202 p.u., B = 0.00000 p.u.,
turns ratio = 1.00 p.u.
Table C.5: 6-bus test network data
Element Bus Regulation Values
SVC 6 Q X
C
= 3.00 p.u., X
L
= 1.00 p.u.
3 V X
C
= 3.00 p.u., X
L
= 1.00 p.u.
4 X
C
= 3.00 p.u., X
L
= 1.00 p.u.
TCSC 7-2 P X
C
= 0.03 p.u., X
L
= 0.01 p.u.
8-5 X
C
= 0.10 p.u., X
L
= 0.03 p.u.
Table C.6: Values of FACTS in the 6-bus test network
66
Variables, Scripts and Functions
Filename Type Call
dispatch.m Script dispatch
kktDispatch.m Function [P nport gen disp,price,kkt msg] =
kktDispatch(Ap,P nport gen,Pmax)
kktRHS.m Function RHS = kktRHS(x,Ap,P nport gen,Pmax)
kktJacobian.m Function J = kktJacobian(x,Ap,P nport gen,Pmax)
Table C.7: Scripts and functions for Economic Generation Dispatch
Variable Content
P nport gen disp vector of dispatched generator power values in p.u.
price Lagrangian-multiplier
1
of equality constraint g
1
( x)
kkt msg string message, information about computation
x vector of unknown values (dened in 5.25)
Ap matrix of cost function factors (dened in 5.14)
P nport gen vector of generator power values before dispatch in p.u.
P max vector of maximal generator power values in p.u.
Table C.8: Variables for Economic Generation Dispatch
67
Bibliography
[1] FlowDemo.net: Interactive, internet based application to visualize power ow
in an electric transmission system, EEH Power Systems Laboratory, ETH
Z urich, 2000.
Available from www.flowdemo.net
[2] S. Baud: FlowDemo.NET: Interaktive Webanwendung f ur die Demonstration
der Lastussrechnung und -steuerung, Diplomarbeit EUS0002, EEH Power
Systems Laboratory, ETH Z urich, 2001.
[3] R. Bacher: Modellierung und Analyse Elektrischer Netze (Power Systems Anal-
ysis), Autography, EEH Power Systems Laboratory, ETH Z urich, 2000.
[4] B. T. Ooi, G. Joos, F. D. Galiana, D. McGills, R. Marceau: FACTS Con-
trollers and the Deregulated Electric Utility Environment, IEEE Electrical and
Computer Engineering, 1998.
[5] Y. H. Song, A. T. Johns: Flexible ac transmission systems (FACTS), IEEE
Press, U.K., 1999, ISBN 0-85296-771-3.
[6] N. G. Hingorani, L. Gyugyi: Understanding FACTS: Concepts and Technology
of AC Transmission Systems, IEEE Press, N.Y., 2000, ISBN 0-7803-3455-8.
[7] R. M. Mathur, R. K. Varma: Thyristor-Based FACTS Controllers for Electrical
Transmission Systems, IEEE Press, N.Y., 2002, ISBN 0-471-20643-1.
[8] X. P. Zhang, E. J. Handschin: Optimal Power Flow Control by Converter
Based FACTS Controllers, IEEE AC-DC Power Transmission, 2001.
[9] H. Ambriz-Perez, E. Acha, C. R. Fuerte-Esquivel: Advanced SVC Models for
Newton-Raphson Load Flow and Newton Optimal Power Flow Studies, IEEE
Transactions on Power Systems, 2000.
68
BIBLIOGRAPHY
[10] T. Orfanogianni: A exible software environment for steady-state power ow
optimization with series FACTS devices, Diss. ETH Nr. 13689, EEH Power
Systems Laboratory, ETH Z urich, 2000.
[11] N. Li, Y. Xu, H. Cheng: FACTS-Based Power Flow Control in Interconnected
Power Systems, IEEE Transactions on Power Systems, 2000.
[12] F. L. Alvarado: Solving Power Flow Problems with a Matlab Implementation
of the Power System Applications Data Dictionary, IEEE Proceedings of the
32
nd
International Conference on System Sciences, 1999.
[13] Power Systems Test Case Archive: IEEE 14 Bus Power Flow Test Case,
University of Washington, 2003.
Available from www.ee.washington.edu/research/pstca/
[14] BCP Busarello + Cott + Partner Inc.: NEPLAN Version 5.1.0, 2002.
Available from www.neplan.ch
[15] R. Bacher: Optimierung liberalisierter elektrischer Energiesysteme, Autogra-
phy, EEH Power Systems Laboratory, ETH Z urich, 2002.
[16] G. Tognola: Unlimited Point - Ansatz zur Losung des optimalen Lastussprob-
lems, Diss. ETH Nr. 12437, EEH Power Systems Laboratory, ETH Z urich,
1998.
69

Das könnte Ihnen auch gefallen