this page 2015-007 N.Farrokhseresht.pdfPDF-1.6 %âãÏÓ 2223 0 obj endobj 2231 0 obj...
Post on 13-Apr-2018
224 Views
Preview:
Transcript
DEGREE PROJECT, IN , SECOND LEVELELECTRIC POWER SYSTEMS
STOCKHOLM, SWEDEN 2015
Impact of Large Amounts of WindPower on Primary Frequency Control
A TECHNICAL AND ECONOMIC STUDY
NAKISA FARROKHSERESHT
KTH ROYAL INSTITUTE OF TECHNOLOGY
SCHOOL OF ELECTRICAL ENGINEERING
Impact of Large Amounts of WindPower on Primary Frequency Control: a
Technical and Economic Study
Author:
Nakisa Farrokhseresht
Supervisor:
Prof. Mohammad Reza Hesamzadeh
Prof. Hector Chavez
Examiner:
Prof. Mohammad Reza Hesamzadeh
A thesis submitted in fulfilment of the requirements
for the degree of Master of Science
in the
Electricity Market Research Group
Electric Power Systems Department
School of Electrical Engineering
KTH Royal Institute of Technology
Abstract
Renewable energy sources help reaching the environmental, social and economic goals
of producing electrical energy in a clean and sustainable matter. Among the various
renewable resources, wind power is assumed to have the most favorable technical and
economic prospects and offers significant potential for reducing greenhouse gas (GHG)
emissions. As wind power installations are more and more common in power systems,
additional research is needed in order to guarantee the quality and the stability of the
power system operation.
Maintaining the frequency as close as possible to its rated level is one of the most im-
portant tasks for grid operators in order to maintain a stable electricity grid. However,
the significant penetration of wind generation in power grids has raised new challenges
in the operational and planning decisions of power systems. Wind turbine units almost
always include power converters decoupling the frequency dynamics of the wind power
generators from those of the grid. This decoupling causes a reduction in the total system
inertia, affecting the system’s ability to overcome frequency disturbances.
To study the impact of wind power on the system inertia, first the Nordic 32-A System,
representing a scaled version of the Swedish grid, is implemented in PSS/E. A system
identification of model parameters with actual data follows. This ad-hoc identification
method determines the dynamic parameters of the governors and prime movers in the
model. The two metrics of primary frequency control; the instantaneous minimum fre-
quency and the rate of change of frequency (ROCOF) are simulated using the identified
power system, and via an extrapolation, the maximum wind power penetration in Swe-
den is found, considering that the system has to comply with the instantaneous minimum
frequency requirements and also that the tripping of the generators’ ROCOF relays is
prevented.
The second part of the work focuses on an economic study of the cost to guarantee
an adequate frequency response, particulary the Primary Reserve (PR). The Primary
Reserves is the capacity of the generators that is reserved for the governors to use for Pri-
mary Frequency Control (PFC). Primary Reserves also include the ramping capability
requirement of power plants for regulating power imbalances caused by contingencies.
Recent studies have shown that having more renewable resources, such as wind with
no PFC capability as well as an electricity market design with no incentive for PFC,
are important drivers for a decline in the frequency response in the system. One so-
lution is the careful design of a PFC ancillary service market by introducing suitable
constraints to ensure the adequacy of Primary Frequency Control. However, applying
these constraints will increase the generation cost especially when more and more wind
power is integrated. This work proposes the use of an adequacy constraint to evaluate
i
the economic impact of wind integration with respect to its influence on guaranteeing
an adequate PFC. To analyze the cost increment for maintaining an adequate frequency
response in the presence of wind power, an optimal power flow (OPF) problem is de-
signed with an objective function of the generation cost minimization and considering a
PFC adequacy constraint. The results show that the inclusion of the new constraints in
the optimal dispatch OPF leads to a higher dispatch cost.
Keywords: Inertial response, primary frequency control, power system simulation, sys-
tem identification, wind power integration, power system optimization optimal power
flow
ii
Acknowledgements
There are several people I would like to thank for helping me not only to complete this
master thesis project but generally, in my life in Sweden and Belgium.
I would like to begin by thanking Associate Professor Mohammad Reza Hesamzadeh
for creating the thesis project, and giving me the opportunity to work on it. Professor
Hesamzadeh has been my main supervisor, and has given much appreciated and con-
tinuous support, encouragement and positive interaction. Also I would like to express
my gratitude to my other supervisor, Assistant Professor Hector Chavez, for his support
and guidance. His valuable comments, insight and encouragement were always of the
greatest assistance to me.
I would like to give a special acknowledgement to my master program coordinator Pro-
fessor Johan Driesen for his guidance and kind help. In addition, a special thanks goes
to EIT/KIC-InnoEnergy for funding my two years master program: Energy in Smart
Cities. I owe Bert Willems a lot of thanks. You were not only my financial coordinator
but more importantly you became one of my best friends. I sincerely want to thank
Hossein Shahrokni, my course instructor. Thank you for your kind help and guidance.
I would like to thank my colleagues of the Electricity Market Research Group of KTH,
especially Mahir Sarfati, the people in the Electric Power Systems department of KTH,
particulary Dr. Ebrahim Shayesteh, and my friends in the ELECTA group of the depart-
ment of Electrical Engineering of KULeuven, in particular Dr. Priyanko Guha Thakurta.
I am also grateful to my boss, Mr. Hassan Khamseh of the BIDEC company, where I
have been working for almost four years as a mechanical engineer and never forget his
support and his warm encouragement. Many thanks go to my lovely friends in Iran for
cheering me up when I needed it; Mina Safari, Zohreh Kashi, Shahrzad Mohammadpour,
Pegah Tiba and Farzad Farkhondehkalam.
I will never forget all the kindness from the Jacqmaer family; Frans, Hilde and Pieter.
Thanks for everything, for your kind wishes, your prays and for all the candles you
lighted for my success. During these years, you were with me either in times of joy or
difficulties and you help me sincerely and I thank you from the bottom of my heart.
Last, but not least, I would like to express my gratitude to my lovely family and my
uncle Ali Farrokhseresht for their financial and emotional support. Thank you Babaee
to stimulate the love for nature in me and teach me to dare to dream and hold on to
my dreams. Thanks to Giti, my tree of life, I learned that the goal is not of the greatest
importance, but that the path leading to the goal is more valuable! Finally my little
sister, my cute classmate! Thank you for sharing this fascinating journey with me!
iii
Contents
Abstract i
Acknowledgments iii
Contents iv
List of Figures vii
List of Tables ix
Abbreviations x
Symbols xi
1 Introduction 1
1.1 Background . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.1.1 Wind Power Integration . . . . . . . . . . . . . . . . . . . . . . . . 1
1.1.2 Power Systems Stability . . . . . . . . . . . . . . . . . . . . . . . . 3
1.1.3 Generation Scheduling . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2 Problem Definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.3 Thesis objectives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
1.4 Resources/Tools Used for that Purpose . . . . . . . . . . . . . . . . . . . 7
1.5 Published papers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
1.6 Outline of this work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2 Frequency Control for Power Systems 10
2.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
2.2 Frequency Control Systems . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.3 Inertial Response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.3.1 Swing Equation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.3.2 Center of Inertia . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
2.4 Primary Frequency Control (PFC) . . . . . . . . . . . . . . . . . . . . . . 16
2.5 Metrics for Primary Frequency Control (PFC) Adequacy . . . . . . . . . . 18
2.5.1 ROCOF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
2.5.2 Frequency Nadir . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.6 PFC Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.6.1 UK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.6.2 Ireland . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.6.3 Sweden . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
iv
2.7 Simulation tool PSS/E . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
2.7.1 Network Representation in PSS/E . . . . . . . . . . . . . . . . . . 22
2.7.2 Power Flow Calculation . . . . . . . . . . . . . . . . . . . . . . . . 22
2.7.3 Dynamic Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . 23
2.7.4 Program Automation . . . . . . . . . . . . . . . . . . . . . . . . . 23
3 Wind Power 24
3.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
3.2 Power Extraction From The Air Stream . . . . . . . . . . . . . . . . . . . 24
3.3 Wind Turbine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
3.3.1 Fixed-Speed Wind Turbine . . . . . . . . . . . . . . . . . . . . . . 27
3.3.2 Variable-Speed Wind Turbine . . . . . . . . . . . . . . . . . . . . . 27
3.4 Doubly Fed Induction Generator (DFIG) . . . . . . . . . . . . . . . . . . 28
3.5 Wind Turbine Model in PSS/E . . . . . . . . . . . . . . . . . . . . . . . . 29
3.5.1 Running a Static Power Flow . . . . . . . . . . . . . . . . . . . . . 29
3.5.2 Running a Dynamic Power Flow . . . . . . . . . . . . . . . . . . . 30
4 Optimal Power Flow (OPF) with PFC Adequacy Constraints 31
4.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
4.2 DC Power Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
4.3 Economic Dispatch (ED) . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
4.4 Optimal Power Flow (OPF) . . . . . . . . . . . . . . . . . . . . . . . . . . 34
4.5 Introducing PFC Constraints . . . . . . . . . . . . . . . . . . . . . . . . . 35
5 Case Study 41
5.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
5.2 Nordic 32-A Test System . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
5.3 Modification of the Nordic 32-A Test System . . . . . . . . . . . . . . . . 44
6 Method and Simulation Results 46
6.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
6.2 Impact of Wind Integration on PFC Adequacy . . . . . . . . . . . . . . . 46
6.2.1 Center-of-Inertia (COI) frequency . . . . . . . . . . . . . . . . . . 47
6.2.2 Identification of model parameters using actual data . . . . . . . . 52
6.2.3 Wind Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
6.2.4 Simulation Results . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
6.2.4.1 Impact of Wind Integration on the ROCOF . . . . . . . 57
6.2.4.2 Impact of Wind Integration on the Nadir . . . . . . . . . 59
6.2.5 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
6.3 Economic Impact of Wind Integration on Primary Frequency Control . . 60
6.3.1 Adding Governors with a Ramp Rate Capability . . . . . . . . . . 60
6.3.2 Stress Test . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
6.3.3 Wind Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
6.3.4 Optimal Power Flow formulation With PFC adequacy Constraints 63
6.3.4.1 Validation of the DC Power Flow equations . . . . . . . . 64
6.3.4.2 Calculating the Total Cost Difference . . . . . . . . . . . 65
6.3.5 Simulation Results . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
6.3.6 Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
v
7 Conclusions and Future Work 72
7.1 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
7.2 Future Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
A Implementing the Nordic 32-A Test System in PSS/E 76
A.1 Developing Nordic 32-A test System . . . . . . . . . . . . . . . . . . . . . 76
A.2 Power Flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
A.3 Dynamic Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
A.4 Wind Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
B Wind Model Parameters 85
C Matlab and Python Code for Identification of Section 6.3 89
D Matlab code and GAMS Implementation of the PFC-OPF of Section6.3 94
D.1 Matlab File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
D.2 PFC-OPF GAMS File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
Bibliography 98
vi
List of Figures
1.1 World cumulative installed capacity of wind power . . . . . . . . . . . . . 2
1.2 Regional distribution of the globally installed wind power capacity (MW)for the end of 2012 and 2013 . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.3 Electricity production by wind power in Sweden . . . . . . . . . . . . . . 3
1.4 Classification of power systems stability . . . . . . . . . . . . . . . . . . . 4
1.5 Problem when great amounts of wind power are integrated in a power grid 6
2.1 Ideal steady-state characteristics of a governor with speed droop . . . . . 17
2.2 Common dead-band configurations . . . . . . . . . . . . . . . . . . . . . . 18
3.1 Airflow over wind tunnel . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
3.2 Fixed-speed wind turbine . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
3.3 Variable-speed wind turbine with a synchronous/induction generator . . . 28
3.4 DFIG with a Power Converter connected to the rotor terminals . . . . . . 28
3.5 Control block diagram of DFIG wind turbine . . . . . . . . . . . . . . . . 29
3.6 Overall wind turbine model of DFIG . . . . . . . . . . . . . . . . . . . . . 30
4.1 Governor operation and frequency behavior after a power plant outage . . 37
4.2 Generator ramping capability . . . . . . . . . . . . . . . . . . . . . . . . . 39
5.1 The single-line diagram of Nordic 32-A test system . . . . . . . . . . . . . 42
5.2 The block diagram of GENSAL generator . . . . . . . . . . . . . . . . . . 43
5.3 Block diagram of GENROU generator . . . . . . . . . . . . . . . . . . . . 43
5.4 The control diagram for the Simplified Excitation System . . . . . . . . . 43
5.5 The dynamic control model for STAB2A . . . . . . . . . . . . . . . . . . . 44
5.6 The block diagram for the HYGOV governor . . . . . . . . . . . . . . . . 44
6.1 Measured frequency in the Nordic system (NORDEL) after a sudden trip-ping of 530, 800 and 1100 MW generation . . . . . . . . . . . . . . . . . . 47
6.2 Procedure for calculating the COI frequency . . . . . . . . . . . . . . . . . 51
6.3 Frequency response of the original Nordic 32-A grid and the measuredfrequency response after a actual contingency . . . . . . . . . . . . . . . . 52
6.4 Algorithm for the ad-hoc model identification method . . . . . . . . . . . 54
6.5 Algorithm for calculating the ROCOF and frequency Nadir after wind isintegrated . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
6.6 Frequency response after contingency of 550 MW for different amountsof integrated wind power production . . . . . . . . . . . . . . . . . . . . . 58
6.7 Linear extrapolation of the predicted ROCOF and frequency Nadir behavior 58
vii
6.8 Result of identification: comparison of real frequency data and the simu-lated center-of-inertia frequency . . . . . . . . . . . . . . . . . . . . . . . . 61
6.9 Calculating the ramp rate ci as the slope of the mechanical power over time 62
6.10 Method to determine the change in generation cost when the PFC ade-quacy constraints are imposed . . . . . . . . . . . . . . . . . . . . . . . . . 66
6.11 Inertia and cost difference when wind is integrated in the system . . . . . 70
A.1 Loadflow solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
A.2 Convert/Reconstruct Loads and Generators . . . . . . . . . . . . . . . . . 78
A.3 An example of a dyr-file for a hydro and thermal power plant . . . . . . . 79
A.4 The dynamic data spreadsheet . . . . . . . . . . . . . . . . . . . . . . . . 80
A.5 Assign Channels for Machine Quantities . . . . . . . . . . . . . . . . . . . 81
A.6 Initialization of the dynamic simulation . . . . . . . . . . . . . . . . . . . 81
A.7 Channel plot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
A.8 Speed versus time for machine 1012, after tripping machine 1014 . . . . . 83
A.9 The electrical system configuration for AC/AC wind farm . . . . . . . . . 83
A.10 Dynamic data file for GEWTG2 . . . . . . . . . . . . . . . . . . . . . . . 84
viii
List of Tables
2.1 Different frequency controls levels . . . . . . . . . . . . . . . . . . . . . . . 11
3.1 Power flow parameters of GE 1.5MW . . . . . . . . . . . . . . . . . . . . . 30
6.1 Original and identified dynamic parameters of the Nordic 32-A model . . 55
6.2 Effect of wind integration on ROCOF and frequency Nadir . . . . . . . . 59
6.3 Generator data including power generation PGen, machine base Mbase,ramp rate ci and plant type . . . . . . . . . . . . . . . . . . . . . . . . . . 62
6.4 Effect of wind integration on the system inertia and the frequency Nadir . 70
6.5 Effect of wind integration on the number of responsive units . . . . . . . . 70
6.6 Effect of wind integration on the dispatch cost . . . . . . . . . . . . . . . 71
A.1 Load conversion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78
A.2 Power flow data for GE 1.5MW and a wind farm . . . . . . . . . . . . . . 84
B.1 GE Wind Turbine Electrical Control GEWTE2 . . . . . . . . . . . . . . . 85
B.1 GE Wind Turbine Electrical Control GEWTE2 . . . . . . . . . . . . . . . 86
B.1 GE Wind Turbine Electrical Control GEWTE2 . . . . . . . . . . . . . . . 87
B.2 GE Wind Turbine Generator/Converter GEWTG2 . . . . . . . . . . . . . 87
B.3 Two Mass Shaft GEWTT1 . . . . . . . . . . . . . . . . . . . . . . . . . . 87
B.4 GE Pitch Control GEWTP2 . . . . . . . . . . . . . . . . . . . . . . . . . . 88
B.5 GE Wind Turbine Aerodynamics GEWTA2 . . . . . . . . . . . . . . . . . 88
ix
Abbreviations
COI Center Of Inertia
CIGRE Conseil International des Grands Reseaux Electriques
DAM Day-Ahead Market
DC Direct Current
DFIG Doubly Fed Induction Generator
ED Economic Dispatch
ENTSO-E European Network of Transmission System Operators for Electricity
GHG GreenHouse Gas
GWEC Global Wind Energy Council
LTC Load Tap Changer
NLP Non-Linear Programming
OPF Optimal Power Flow
PF Power Flow
PFC Primary Frequency Control
PR Primary Reserve
PSS/E Power System Simulator for Engineering
PTDF Power Transfer Distribution Factors
RES Renewable Energy Sources
ROCOF Rate Of Change Of Frequency
RTM Real Time Market
TSO Transmission System Operator
UFLS Under Frequency Load Shedding
x
Symbols
A area [m2]
δ angle [rad]
E power [W]
f frequency [Hz]
F force [N]
H per unit inertia constant [s]
I current [A]
J moment of inertia [kg −m2]
M system inertia [MWs/Hz]
P power [W (Js−1)]
ρ density [kg/m3]
Q reactive power [var]
R resistance [Ω]
S base power [MVA]
t time [s]
θ angle [rad]
T torque [Nm]
U voltage [V]
V speed [m/s]
ω angular velocity [rads−1]
W kinetic energy [J]
X reactance [Ω]
Y admittance [Ω−1]
Z impedance [Ω]
xi
Chapter 1
Introduction
1.1 Background
1.1.1 Wind Power Integration
Every society needs energy and related services to meet the social and economic devel-
opment and to improve the human welfare and health. However, greenhouse gas (GHG)
emissions resulting from the provision of energy services cause an historic increase in
atmospheric GHG concentrations [1]. Recent data shows that the consumption of fossil
fuel is the major source of GHG emissions [1]. The deployment of Renewable Energy
Sources (RES) is one of the possible options to mitigate climate change.
RES which have the potential to provide energy services with zero or almost zero emis-
sions of both air pollutants and greenhouse gases, supply almost 14 percent of the total
world energy demand [2]. The global financial crisis did not pose problems for the rapid
growth of the capacity of renewables in 2009; wind power a 32% increase, hydropower
a 3% increase, grid-connected photovoltaics a 53% increase, geothermal power a 4% in-
crease, and solar hot water/heating a 21% increase [1].
Among the various renewable resources, wind power is assumed to have the most fa-
vorable technical and economic prospects and offers significant potential for reducing
greenhouse gas emissions. Roughly 1.8 % of the worldwide electricity demand has been
met by wind power energy by the end of 2009, but it is predicted that the share of world-
wide wind power will grow up to 20 % by 2050 [1]. Wind power is a major new energy
resource in both Europe and the U.S in 2009: approximately 39 % of all the capacity
1
1.1 Background Chapter 1
installed in these two parts of the world came from wind power [1]. From 2000 till 2009,
new wind power plants accounted for almost 11% of the new electricity generating instal-
lations. The Global Wind Energy Council (GWEC) predicts that the installed capacity
of wind power will continue to increase and their forecasts are presented in Figure 1.1
[3]. Figure 1.1 shows the steadily increasing trend of the global installed wind power
capacity. By the end of 2012, there were 24 countries with an installed wind capacity
of more than 1000 MW. The cumulative installed capacities of wind power in different
regions of the world for the years 2012 and 2013 are shown in Figure 1.2 [3].
This trend is also seen in Sweden where the share of the electricity production coming
39485974
94121
159198
238283
318367
418474
536596
0 50 100 150 200 250 300 350 400 450 500 550 600 650
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
Global)cumulative)installed)wind)capacity)(GW)
Market forecasts
Historical data
Figure 1.1: World cumulative installed capacity of wind power [3]
from wind power has increased significantly from 0.5 % in 2003 to 4.4 % in 2012 [4].
Over the period 2003 - 2012, the production of electricity from wind power has been
increased more than tenfold (Figure 1.3). Sweden also has a planning framework for
wind power, projecting a production of 17 GW (6 GW onshore, 11 GW offshore) by
2030 [5].
As wind power installations are more and more common in power systems, additional
research is needed in order to guarantee the quality and the security of the power system
operation in view of the increased presence of this new energy source which has different
characteristics from traditional sources.
2
1.1 Background Chapter 1
0 20,000 40,000 60,000 80,000 100,000120,000
Europe
Asia
NorthlAmerica
LatinlAmerica
PacificlRegion
AfricalandlMiddlelEast
Series1
0 50,000 100,000 150,000 200,000 250,000
Europe
Asia
NorthlAmerica
LatinlAmerica
PacificlRegion
AfricalandlMiddlelEast
Europe AsiaNorth
AmericaLatin
AmericaPacificRegion
AfricalandMiddlelEast
Endl2012 109,817 97,715 67,748 3,530 3,219 1,165
Endl2013 121,474 115,927 70,811 4,764 3,874 1,255
Global wind power capacity (MW)
Figure 1.2: Regional distribution of the globally installed wind power capacity (MW)for the end of 2012 and 2013 [3]
0
1
2
3
4
5
6
7
8
2003 2004 2005 2006 2007 2008 2009 2010 2011 2012
Win
d p
rod
uct
ion
(TW
h)
Figure 1.3: Electricity production by wind power in Sweden [4]
1.1.2 Power Systems Stability
Power systems stability has been recognized as an important issue for a secure system
operation [6]. Power system stability is the ability of a power system to regain an equi-
librium state after being subjected to a physical disturbance [7]. The study of power
systems stability can be divided into the following topics: the study of rotor angle sta-
bility, of frequency stability and of voltage stability [7]. This classification of power
systems stability is shown in Figure 1.4. This work focuses on the frequency stability.
3
1.1 Background Chapter 1
power system stability
frequency stability
small distrubance
angle stability
rotor angle stability
voltage stability
transientstability
largedisturbance
voltage stability
smalldisturbance
voltage stability
Figure 1.4: Classification of power systems stability [7]
Maintaining the frequency as close as possible to its rated level is one of the most im-
portant tasks for grid operators in order to maintain a stable electricity grid [8]. If the
frequency deviates significantly from its scheduled value, Under Frequency Load Shed-
ding (UFLS) is more likely to occur. Also the possibility of tripping of the over-frequency
generator protection relays increases which can lead to a blackout [8].
The definition of frequency stability given by CIGRE and IEEE is the following: “Fre-
quency stability refers to the ability of a power system to maintain a steady frequency
following a severe system disturbance, resulting in a significant imbalance between gen-
eration and load” [9]. Primary Frequency Control (PFC) is the leading mechanism of
the frequency control system to ensure reliable operation [10]. The PFC is defined by
ENTSO-E as “the power delivered by the rotating masses of the synchronous machines
in response to frequency drops” and also as “the governor response that acts to arrest
frequency decays” [11].
1.1.3 Generation Scheduling
In order to have the secure and the stable power system, the socioeconomic cost should
be minimized. This can be done by scheduling the generation well. The generation
scheduling normally consists of three time frames: the day-ahead market (DAM), the
intraday market and the real-time market (RTM). The day-ahead market (DAM) usually
opens in the morning, on the day before the actual dispatch of the generation units [12].
It is also called the planning period and in this period market participants submit their
bids and offers to the market based on forecasts of the loads. Then, the market operator
sets the forecast price and the forecast dispatch level. The next phase is the intraday
4
1.2 Problem Definition Chapter 1
market which takes place one hour before the actual day (in the case of NORDEL).
Additional information such as updated forecasts and units’ availability help the market
participants to make adjustments in their trading [13]. Finally, in the real time market
which is also known as the operating period, the market operator defines the real price
and the real dispatch for all the participants. The operation of the real-time markets
varies from bidding zone to bidding zone, and can be done over a time period of 5 min-
utes, up till periods of one hour before the actual dispatch [12].
However, the load forecast in the planning period may not always be correct. There-
fore in the real-time market, generators may have to change their production instantly.
Hence, the frequency control system is required to control the generator outputs. But
this frequency control system needs “reserve capacity” in order to operate adequately.
One of the important parts of these reserves is the primary reserve (PR). The “primary
reserve” is the capacity that is required by the primary frequency control system and it
is employed to stabilize the frequency deviation in the entire interconnected grid [14].
1.2 Problem Definition
There are two main types of wind turbine generators: fixed-speed and variable-speed.
In the fixed-speed wind turbine, the generator is coupled via a transformer immediately
to the grid. But a more common turbine generator is the variable-speed wind turbine
due to its advantages; it generates an almost constant torque, it can absorb wind fluc-
tuations, and it can improve the power quality of the grid. However, this type of wind
turbine has negative effects on the PFC [15]. Since in modern variable-speed wind tur-
bines power electronic converters are employed to decouple the generator from the grid,
the moving parts of the wind turbines are not synchronized with the system frequency.
Also, a large penetration of wind power implicates a reduction of the power supplied by
conventional synchronous generators, so the contribution of wind machines to the total
system inertia is low to zero [15] [16].
In addition, recent studies have shown that having more renewable resources, such as
wind with no PFC capability as well as an electricity market design with no incentive
for providing PFC, are important drivers for a decline in the frequency response in the
system [8] [17]. Moreover, a classical optimal power flow problem without additional
5
1.3 Thesis objectives Chapter 1
system constraints including the provision of a reserve capacity can not guarantee an
adequate operation of the grid in the presence of a large amount of wind power. Fi-
gure 1.5 summarizes the problem definition. This thesis seeks to investigate the problem
and provide solutions.
Large penetration of wind
Reduce the power suppliedby conventional
generators
- Less overall inertia in the grid- Less PFC capability- Less reserve capacity
Insufficientfrequency stability
Figure 1.5: Problem when great amounts of wind power are integrated in a powergrid
1.3 Thesis objectives
This thesis aims to perform a technical and economic analysis of the effect on the primary
frequency control of the Swedish grid, when a high amount of wind power is integrated in
the system. In the technical part of the thesis, the penetration level of wind generation is
determined that leads to insufficient PFC for the case of the Swedish grid. The following
items are discussed in this part:
• Review of the NORDEL grid code requirements for primary frequency control,
• Implementing the Nordic 32-A test system as the representation of the Swedish
grid in PSS/E,
• Identification of the grid’s model parameters with actual data,
• Including wind turbines into the model,
• Evaluating the impact of wind penetration on a few important primary frequency
control metrics,
• Determining the amount of wind generation that leads to an inadequate primary
frequency control.
6
1.5 Published papers Chapter 1
The second part of the work is economic study of the influence of large amount of wind
on PFC. The economic part has the aim to carefully design an OPF for the economic
operation of the system so that an adequate primary frequency control is guaranteed.
However, introducing additional constraints will increase the generation cost, especially
if more and more wind power is integrated. The following items are considered in this
part:
• Applying governors with ramp rate capability,
• Performing “stress test” to calculate ramp rate capability of each generator in the
gird,
• Including wind turbines into the identified model,
• Formulating an optimal power flow including constraints to guarantee an adequate
PFC operation,
• Evaluating the economic impact of wind integration when the developed mini-
mal requirements to ensure primary frequency adequacy are added to the control
system.
1.4 Resources/Tools Used for that Purpose
In this work the Nordic 32-A test system representing the real Swedish grid is im-
plemented in the power system analysis software PSS/E. The procedure for running
power flows, performing dynamic simulations and integrating wind turbines in the grid
in PSS/E are explained in the Appendix A. An ad-hoc system identification method
is applied in this work which requires PSS/E to be automated. In order to automate
PSS/E, calculations are performed in Matlab, which calls Python to execute PSS/E. All
the Matlab and Python codes for the PSS/E automation are provided in Appendix C.
Moreover, the optimization problem in the second part of the thesis is solved by the
KNITRO solver in the General Algebraic Modeling System (GAMS) platform [18]. The
GAMS codes are provided in Appendix D.
7
1.6 Outline of this work Chapter 1
1.5 Published papers
• N. Farrokhseresht, H. Chavez, M. R. Hesamzadeh, Determination of Acceptable
Inertia Limit for Ensuring Adequacy Under High Levels of Wind Integration, In-
ternational Conference on European Energy Market, Krakow, Poland, 28-30 May
2014.
• N. Farrokhseresht, H. Chavez, M. R. Hesamzadeh, Economic Impact of Wind Inte-
gration on Primary Frequency Response, IEEE PowerTech Conference, Eindhoven,
the Netherlands, 29 June-2 July 2015.
1.6 Outline of this work
The report is written in 7 chapters with the following descriptions:
• Chapter 1 has been specified to describe the thesis. This includes the background
of the thesis and a description of problem definitions and different thesis steps.
• Chapter 2 focuses on frequency control for power systems and the concepts of pri-
mary, secondary and tertiary control are briefly explained. Two important metrics
for primary frequency control are introduced. In the next part, the requirements
for primary frequency control in the UK, Ireland and Sweden are presented. This
Chapter ends with a brief explanation about the power system analysis software
PSS/E.
• Chapter 3 concentrates on wind power and two main wind turbine technologies:
the fixed-speed and variable-speed wind turbine are presented. Also in this Chap-
ter, the doubly-fed induction generator (DFIG), as one kind of the variable-speed
wind turbines which is commonly used, is explained.
• Chapter 4 discuses DC Power flow, Economic Dispatch (ED) and Optimal Power
Flow (OPF). The last Section of this Chapter presents the new adequacy con-
straints in a classical OPF for ensuring PFC adequacy.
8
1.6 Outline of this work Chapter 1
• Chapter 5 illustrates first, a case study consisting of the Nordic 32-A test system,
representing a scaled version of the Swedish grid. Then the modification on the
original Nordic 32-A test system which are needed in order to have capability of
dynamic simulation will be explained.
• Chapter 6 explains the method for studying the impact of wind integration on
the adequacy of primary frequency control , and also the economic impact of the
wind integration on the generation cost, where as a test grid the CIGRE Nordic
32-A system was taken. This Chapter includes an ad-hoc identification method
which required that PSS/E was automated. It discusses wind integration and
presents an OPF with PFC adequacy constraints. In the next part of this chapter,
two different scenarios are studied; the first scenario considers the PFC adequacy
constraint in the OPF, while in the second scenario, the PFC constraint is not
included. This way, the economic cost of this constraint can be found. At the end
of each Section, the simulation results and a summary are given in detail.
• Chapter 7 summarizes the main conclusions and provides some recommendations
for future research.
9
Chapter 2
Frequency Control for Power
Systems
2.1 Introduction
Nowadays, the demands on the quality and security of supply of the voltage and fre-
quency are higher and automatic controllers and regulators were introduced in order
to meet these requirements [19]. Therefore there is a need for an ancillary service1 to
supply these control actions. The task of the control systems of a power system is to
keep the system within acceptable operating limits in such a way that the security of
supply is maintained and the quality of the power, such as the voltage magnitude and
the frequency, is within specified limits.
In this chapter, first the basics of frequency control including the concepts of primary,
secondary and tertiary control are briefly explained. After describing the inertial re-
sponse and primary frequency control in detail, some important metrics to describe the
primary frequency control adequacy are provided. The primary frequency control re-
quirement for UK, Ireland and Sweden are discussed in the next part. The chapter ends
with a brief explanation about the power system analysis software PSS/E which is used
in this work to model a power system and analyze the frequency control.
1Ancillary services are defined as all services required by the transmission or distribution systemoperator to enable them to maintain the integrity and stability of the transmission or distributionsystem as well as the power quality [20]
10
2.3 Frequency Control Systems Chapter 2
2.2 Frequency Control Systems
The response of the power system and its generators to a frequency change can be
divided into four phases (Table 2.1) [10] [21].
Table 2.1: Different frequency controls levels
No. Control Name Time frame Control objectives
1 Inertial response 0-2 s Transient frequency dip minimization
2 Primary control 2-20 s Arrest frequency decays
3 Secondary control 20 s - 2 min Steady-state frequency
4 Tertiary control 15 min Economic-dispatch
In the first phase, which takes place during the first seconds after the frequency changes,
the rotor of the generators releases or absorbs part of its kinetic energy. This action is
mathematically described by the swing equation and is called “Inertial Response”. The
inertial response is inherently provided by conventional generators in power systems and
no control is activated within this phase.
If the frequency signal deviates from the set value, a signal is produced that will influ-
ence the valves, gates, servos, etc, in order to bring the frequency back to an acceptable
value. That is the purpose of “Primary Control”. All the generators are participating
in the primary control irrespective of the location of the disturbance. A typical time
response for this primary control is in the order of a few seconds (2-20 s).
In the “Secondary Control” phase, the remaining frequency error which is still present
after the primary frequency response phase is compensated by adjusting the power set-
points of the generators. The secondary control acts in a time response period of a few
seconds to minutes, typically 20 s-2 min.
Finally the “Tertiary Control” level occurs in a time frame of minutes (typically 15
minutes) and modifies the set-points of the active power in the generators to achieve
a desired economically optimal global power system operation strategy. Not only fre-
quency and active power controls are considered, but also voltage and reactive power
are controlled in this stage.
This work focuses on first two levels which will be explained in detail in the next parts.
11
2.3 Frequency Control Systems Chapter 2
2.3 Inertial Response
When there is a large contingency in the grid, the frequency begins to decline imme-
diately and the rate of this initial decline is mainly determined by the inertia of the
system. As the inertia is connected with the motion of synchronous devices, the swing
equation describes the inertia response well, thus it will be explained below.
2.3.1 Swing Equation
The net torque causing acceleration (or deceleration) when there is an unbalance between
the torques acting on the rotor is [22]:
Ta = Tm − Te (2.1)
Where
Tm the mechanical or shaft torque supplied by the prime mover lessretarding torque due to rotational losses, in N-m;
Te the net electrical or electromagnetic torque, in N-m;Ta the net accelerating torque, in N-m.
The differential equation describing the rotor dynamics based on law’s of rotation is:
Jd2θmdt2
= Tm − Te (2.2)
Where J is the total moment of inertia of synchronous machine (kg.m2), θm is the angu-
lar displacement of the rotor with respect to the stationary reference axis on the stator
(rad). It is more convenient to chose the angular reference relative to a synchronously
rotating reference frame moving with constant angular velocity ωsm, thus:
θm = ωsmt+ δm (2.3)
Where δm is the rotor position before disturbance at time t = 0. First derivative of
equation (2.3) gives the rotor angular velocity ωm as:
ωm =dθmdt
= ωsm +dδmdt
(2.4)
12
2.3 Frequency Control Systems Chapter 2
And the second derivative of equation (2.3) gives the rotor acceleration as:
d2θmdt2
=d2δmdt2
(2.5)
Substituting equation (2.5) in (2.2):
Jd2δmdt2
= Tm − Te (2.6)
Multiplied equation (2.6) by ωm:
Jωmd2δmdt2
= ωmTm − ωmTe (2.7)
Power is equal angular velocity times torque, thus;
Jωmd2δmdt2
= Pm − Pe (2.8)
The quantity Jωm is known as the inertia constant and is denoted by the M . The M is
related to kinetic energy Wk by:
Wk =1
2Jω2
m =1
2Mωm (2.9)
or
M =2Wk
ωm(2.10)
Since ωm does not change by a large amount before stability is lost, ωm ' ωsmM . Thus,
M =2Wk
ωsm(2.11)
The swing equation (2.8) in terms of M :
Md2δmdt2
= Pm − Pe (2.12)
If p is the number of poles of a synchronous generator, the electrical power angle δ is
related to the mechanical power angle δm by:
δ =p
2δm (2.13)
13
2.3 Frequency Control Systems Chapter 2
Also,
ω =p
2ωm (2.14)
Thus, swing equation (2.12) in terms of δ:
2
pMd2δ
dt2= Pm − Pe (2.15)
Equation (2.15) is divided by the base power Sbase in order to be normalized:
2
p
2Wk
ωsmSbase
d2δ
dt2=
PmSbase
− PeSbase
(2.16)
The quantity of per unit inertia constant H can be defined as:
H =Wk
Sbase(2.17)
The unit of H is in seconds and it has value in the ranges from 1 to 10 seconds, depending
on the size and the type of machine. Substituting equation (2.17) in (2.16):
2
p
2H
ωsm
d2δ
dt2= Pm(pu) − Pe(pu) (2.18)
According to (2.14), the swing equation can be written as:
2H
ωs
d2δ
dt2= Pm(pu) − Pe(pu) (2.19)
2.3.2 Center of Inertia
If a load suddenly increases by ∆PL at time t = 0 at bus k for a grid with multiple
machines , at t = 0+, each machine i will react according to its proximity to the change.
Each generator will then increase its generation according to the synchronizing power
coefficients PSiK . Generators that are closer to bus k, will contribute more, and genera-
tors that are farther away, will contribute less. PSiK is bigger if bus i is closer to bus k,
and smaller if bus i is farther from bus k, so the contribution from generator i is [21] :
∆Pei =(−PSik) (−∆PL)
n∑j=1
PSkj
=PSikn∑j=1
PSkj
∆PL (2.20)
14
2.3 Frequency Control Systems Chapter 2
where PSik =∂Pik∂δik|δik0 (2.21)
According to equation (2.19), the linearized swing equation for machine i is:
2Hi
ω0
d2∆δidt2
= −∆Pei (2.22)
Where δi is the rotor angle of generator i and ω0 is the nominal speed. The inertia
constant Hi has the dimension of time (s) and indicates the time that the system can
provide nominal power by using only the energy stored in its rotating masses. Substi-
tution equation (2.20) in (2.22):
2Hi
ω0
d2∆δidt2
= −
PSikn∑j=1
PSkj
∆PL (2.23)
Taking Hi to the right hand side of equation (2.23), we have:
2
ω0
d2∆δidt2
= −[PSikHi
]∆PLn∑j=1
PSkj
. (2.24)
In order to eliminate the term PSiK , first we use ∆ωi instead of ∆δi for all generators
i = 1, 2, . . . , n, then sum up the equations for each i:
2
ω0
dH1∆ω1
dt= − PS1k
n∑j=1
PSkj
∆PL
.
.
.
+2
ω0
dHn∆ωndt
= − PSnkn∑j=1
PSkj
∆PL
⇒ 2
ω0
n∑i=1
dHi∆ωidt
= −
n∑i=1
PSik
n∑j=1
PSkj
∆PL = −∆PL
(2.25)
In steady state, the speed will be the synchronous speed but during transients, the
speeds of the generators and hence the bus frequencies, differ. Now the ”Center Of
15
2.4 Frequency Control Systems Chapter 2
Inertia (COI)” of the system can be defined as:
ω ≡
n∑i=1
Hiωi
n∑i=1
Hi
or ∆ω ≡
n∑i=1
Hi∆ωi
n∑i=1
Hi
. (2.26)
Differentiating ∆ω with respect to time:
d∆ω
dt≡
n∑i=1
d(Hi∆ωi)dt
n∑i=1
Hi
, (2.27)
orn∑i=1
d (Hi∆ωi)
dt=
[n∑i=1
Hi
] [d∆ω
dt
]. (2.28)
Now substitute equation (2.28) into (2.25):
2
ω0
[n∑i=1
Hi
] [d∆ω
dt
]= −∆PL, (2.29)
Thus:d∆ω
dt=−∆PLω0
2n∑i=1
Hi
, (2.30)
And finally:d∆f
dt=−∆PLf0
2n∑i=1
Hi
≡ mf , (2.31)
Where mf can be evaluated at time instant 0, immediately after the contingency and is
then called the initial rate-of-change-of-frequency (ROCOF) [15].
2.4 Primary Frequency Control (PFC)
A power system needs a closed loop control system to regulate the frequency of the
system. If the system frequency decreases (increases), the primary frequency control
system sends instructions to the generators to increase (decrease) the power output.
Primary frequency control is mainly provided by generators’ governors. A governor is
the feedback controller that senses the system frequency and acts on generator’s prime
16
2.4 Frequency Control Systems Chapter 2
Figure 2.1: Ideal steady-state characteristics of a governor with speed droop [23]
movers (such as steam or water turbines) to regulate frequency deviations. Governors
with a speed-droop characteristic have several settings:
• Droop R
The governor droop R is defined as the variation in power output in steady state
with respect to the variation in system frequency (Figure 2.1). R is calculated as
the ratio of the speed deviation ∆ω or the frequency deviation ∆f to a change
in the valve/gate position or the power output ∆P . It is normally expressed in
percent:
percent R =percent speed or frequency change
percent power output change× 100
=
(ωNL − ωFL
ω0× 100
) (2.32)
where
ωNL steady-state speed at no load;ωFL steady-state speed at full load.
For example, a 5% droop means that generator output will increase by 100% if
there is a frequency deviation of 5%. Looking at Figure 2.1, it can be seen that
governors for primary control are proportional controllers, with the droop R as
the controlling gain.
• Dead-band db
The dead-band is defined as “the total magnitude of the change in steady-state
17
2.5 Metrics for Primary Frequency Control Chapter 2
Figure 2.2: Common dead-band configurations [25]
speed within which there is no resulting change in the position of the governor-
controlled valves or gates” [24] and it is expressed in percent of the rated speed.
The most common types of the dead-band are shown in Figure 2.2 [25]. The droop
characteristic can show a discontinuous step at the borders of the dead-band, or
can be continuous. For instance, a maximum dead-band of 0.06% (0.036 Hz for
nominal frequency of 60 Hz) for a large steam turbine and 0.02% for hydraulic
turbines is specified by IEEE standard [24]. If there is a small frequency deviation
which lies entirely within the dead-band, the governor will be inactive.
2.5 Metrics for Primary Frequency Control (PFC) Ade-
quacy
There are two important metrics for PFC adequacy: ROCOF and frequency Nadir.
2.5.1 ROCOF
The initial slope of the frequency deviation versus time after a contingency is called
the rate-of-change-of-frequency (ROCOF). The frequency dynamics are governed by the
swing equation [23]:df (t)
dt=
1
MH(Pm(t)− Pe (t)) (2.33)
where
18
2.5 Metrics for Primary Frequency Control Chapter 2
f (t) system frequency (Hz);MH system inertia (MWs/Hz);Pm (t) system mechanical power (MW);Pe system electrical load (MW).
After the loss of a power plant of size Pl at time t = 0, the swing equation becomes as
follows at the moment of the contingency:
ROCOF =df
dt(0) =
1
MH(−Pl) (2.34)
The system inertia MH is calculated as:
MH =Pl
|ROCOF |(2.35)
It can be seen from equation (2.34) that the ROCOF depends mainly on the kinetic
energy stored in the rotational parts of the generators and loads. The more inertia in the
system, the smaller the ROCOF magnitude, and a slower and hence less severe frequency
drop will take place. The ROCOF magnitude should not be too large, otherwise the
islanding detection relay will be tripped and the generator will be disconnected from the
grid.
2.5.2 Frequency Nadir
The frequency Nadir is the lowest frequency reached after a contingency and it is the
main metric which determines Under Frequency Load-Shedding (UFLS). The UFLS
leads to disconnecting large groups of costumers at predetermined frequency set-points
and it is a drastic form of emergency frequency control. Loads that are disconnected
through UFLS must be reconnected via special procedures. Therefore UFLS is an emer-
gency operating measure and it should be avoided in normal situations [10].
The magnitude of the frequency Nadir is governed mainly by the size of the contingency,
the kinetic energy of the rotating machines, the number of generators participating in
the primary frequency control, the reserves and their distribution over the generators,
and the dynamic characteristics of the loads and machines such as ramp rate capability
[26]. Each of these characteristics should economically be stimulated to provide an ade-
quate Nadir and hence avoiding UFLS. The general condition for having PFC adequacy
19
2.6 PFC Requirements Chapter 2
is [27]:
fNadir ≥ fmin (2.36)
Where fmin is the minimum acceptable frequency and fNadir is the frequency Nadir.
2.6 PFC Requirements
The high penetration of wind power has an impact on the stability of the power sys-
tem. Some countries, such as UK and Ireland, have prepared specific grid codes for the
ROCOF relay to maintain continuity and security of the electric supply. This section
presents the requirements for primary frequency control in the UK and Ireland. Also
the requirements for two metrics of PFC adequacy (ROCOF and frequency Nadir) for
Sweden will be specified.
2.6.1 UK
The electric power system in the UK is operated by National Grid, and has a maximum
demand of about 60 GW and an installed capacity of 80 GW. The demand is met by
nuclear, coal fired and gas fired power plants and the annual electricity consumption
is around 360 TWh. National Grid is responsible for providing a sufficient frequency
responsive reserve by defining a “Mandatory Frequency Response”. All the generators
connected to the UK transmission grid should fulfil the requirement to have the capacity
of providing this “Mandatory Frequency Response”. Generators must have a 3-5%
governor droop characteristic and be capable to provide continuous modulation power
response through their governing systems. The National Grid ROCOF relays are set
at 0.125 Hz/s but [28] shows that the integration of wind power may lead to ROCOFs
close to 1 Hz/s.
2.6.2 Ireland
The Irish power system consists of two different TSOs: EIRGRID for southern Ireland
and SONI for northern Ireland. The maximum magnitude of the ROCOF relays settings
recommended in the Irish grid is 0.5 Hz/s. As the republic of Ireland has set an electric-
ity target of 40% from renewable resources by 2020 [29], wind capacity will continue to
20
2.7 Simulation tool PSS/E Chapter 2
grow significantly in this period. The technical and operational implications associated
with this high share of renewable energy in the power system of Ireland were studied in
[29]. The results of this study show that two issues are limiting the acceptable level of
wind integration: frequency stability after loss of generation and transient stability after
severe network faults. Some additional recommendations for system operation were de-
rived based on this study. For instance, the ROCOF relays in distribution networks are
to be replaced by alternative protection schemes or the threshold of the ROCOF relays
is to be increased.
2.6.3 Sweden
Sweden is part of the NORDEL system. NORDEL was established in 1963 and is a
body for co-operation between the transmission system operators in Denmark, Finland,
Iceland, Norway and Sweden. The aim of the NORDEL is to establish a Nordic electricity
market. The installed capacity of NORDEL is about 100.8 GW, of which about 8.9 GW
is wind power [30].
As the Nadir adequacy point of view, an automatic load shedding for Sweden is specified
at 49.4 Hz@0.15 s [31]. But in the case of ROFOC, there is no requirement on the
maximum value for the magnitude of the ROCOF in the Nordic Grid Code. However, a
report by Elforsk defines 0.5 Hz/s as the maximum acceptable ROCOF magnitude [32].
Thus, the primary frequency control is adequate for Sweden when:
• The magnitude of the ROCOF is be less than 0.5 Hz/s,
• The frequency Nadir is larger than 49.4 Hz.
2.7 Simulation tool PSS/E
All the calculations in this work are performed with the professional software pack-
age PSS/E (Power System Simulator for Engineering). The PSS/E is used by many
power system utilities for stability studies [33]. It has an extensive library of power
systems components including generators, exciters, governor, stabilizer and protection
21
2.7 Simulation tool PSS/E Chapter 2
models [34]. The PSS/E consists of a complete set of programs for the study of the
power system with both steady-state and dynamic simulations.
2.7.1 Network Representation in PSS/E
The power system network is modeled in PSS/E using a description with the bus ad-
mittance matrix:
I = Y.U (2.37)
where I is vector of positive-sequence currents flowing into the network at its buses,
U is vector of positive-sequence voltages at the network buses and Y is the network
admittance matrix [34].
2.7.2 Power Flow Calculation
The following are the basic input data for power flow calculation in the PSS/E:
• Transmission line impedance and charging admittance,
• Transformer impedance and tap ratios,
• Admittance of shunt-connected devices such as static capacitors and reactors,
• Load-power consumption at each bus of the system,
• Real power output of each generator or generating plant,
• Either voltage magnitude at each generator bus or reactive power output of each
generating plant,
• Maximum and minimum reactive power output capability of each generating plant.
And the outputs of power flow calculation are:
• The magnitude of the voltage at every bus where this is not specified in the input
data,
• The phase of the voltage at every bus,
22
2.7 Simulation tool PSS/E Chapter 2
• The reactive power output of each plant for which it is not specified,
• The real power, reactive power, and current flow in each transmission line and
transformer.
2.7.3 Dynamic Simulation
After solving the steady state power flow, a dynamic simulation can be performed in the
PSS/E. It consists of all the functionality for transient, dynamic and long term stability
analysis. System disturbances such as faults, generator tripping, motor starting and
loss of field can be incorporated in this dynamic simulation. The program consists of
an extensive library of generator, exciter, governor and stabilizer models as well as relay
model including under-frequency, distance and over-current relays.
2.7.4 Program Automation
The PSS/E provides a mechanism to control the PSS/E execution other than via direct
user interaction [35]. There is the ability to specify a set of operations for the PSS/E to
perform in a file and to tell the PSS/E to use the instructions in that file as commands.
This controlling of the execution is done by the API (Application Program Interface).
There are two automation processes in the PSS/E based on the API; the Python in-
terpreter (Python programs) and the IPLAN simulator (IPLAN programs). This work
uses Python which is an interpreter, interactive, object-oriented programming language.
This issue will be explained in Chapter 6 and Appendix A.
23
Chapter 3
Wind Power
3.1 Introduction
Among the various renewable energy resources, wind power is assumed to have the most
favorable technical and economic prospects [1]. People have utilized wind energy from
the very early recorded history. The first accepted establishment of the use of windmills
was in the tenth century in Sistan, in the eastern part of Iran. The wind drives mills
and raises water from the streams in order to irrigate gardens [36].
First, this chapter introduces the physical laws describing the conversion from wind
energy to electrical energy [37], and then discusses two main wind turbine technologies:
the fixed-speed and variable-speed wind turbine. In the next section, the Doubly-Fed
Induction Generator (DFIG) is explained in detail as it is one kind of variable-speed wind
turbine which is commonly used [15]. The chapter ends with explaining the modeling
of wind turbines in PSS/E.
3.2 Power Extraction From The Air Stream
The kinetic energy in a flow of air with a density of ρ [kg/m3] and speed of V [m/s]
through a unit area perpendicular to the wind direction is expressed as 12ρV
2 per unit
volume. The mass flow rate of an air stream flowing through an area A is ρAV , and
thus
W = (ρAV )1/2V 2 = 1/2ρAV 3 (3.1)
24
3.2 Power Extraction From The Air Stream Chapter 3
Figure 3.1: Airflow over wind tunnel [37]
The air density ρ depends on the air pressure and the air temperature:
ρ = ρ0(288B
760T) (3.2)
Where ρ0 is the density of dry air at standard temperature and pressure (1.226 kg/m3
at 288 K,760 mm HG),T is the air temperature (K) and B is the barometric pressure
in mm Hg. As the pressure and the temperature are both function of the height above
sea level, taking an air density of 1.2 kg/m3, thus:
W = 0.6V 3 per unit area (3.3)
Only a proportion of the power W can be converted to useful energy by a wind turbine.
An ideal air flow through a wind turbine is shown in Figure 3.1. The mass flow rate is
the same at position 0, 1 and 2: upstream, at the rotor and downstream:
Mass flow rate, m = ρA0V0 = ρA1V1 = ρA2V2 (3.4)
The force of F on the blade is calculated as:
F = m(V0 − V2) (3.5)
The power W is given by the rate of change of kinetic energy:
W = m(1/2V 20 − 1/2V 2
2 ) (3.6)
25
3.3 Wind Turbine Chapter 3
From equations above, it can be found that:
V1 = 1/2(V0 + V2) (3.7)
The downstream velocity factor b is defined as the ratio of the upstream and downstream
wind speeds:
b =V2
V0(3.8)
Then,F
A1= 1/2ρV 2
0 (1− b2) (3.9)
Then by using equation (3.6) and (3.9):
W
A1= 1/2ρV 3
0 × 1/2(1− b2)(1 + b) (3.10)
The fraction of energy extracted by the wind turbine is called the coefficient of perfor-
mance Cp:
Cp =W
W1(3.11)
Because,
W1 = 1/2ρA1V3
0 (3.12)
Then,
Cp = 1/2(1− b2)(1 + b) (3.13)
The maximum value of the coefficient Cp is found for b equal to 1/3:
Cp,max =16
27or about 59% (3.14)
Cp,max is called Belts’ limit and it used for all types of wind turbines. Another coefficient
is the “Capacity Factor” which is defined as effective number of operating hours (kWh)
per installed capacity (kW) and it is typical in the range of 35-40% [37].
3.3 Wind Turbine
There are two main types of wind turbines: fixed-speed and variable-speed. In this
section, these two types of wind turbines will be discussed.
26
3.4 Doubly Fed Induction Generator Chapter 3
Figure 3.2: Fixed-speed wind turbine [40]
3.3.1 Fixed-Speed Wind Turbine
A fixed-speed wind turbine is shown in Figure 3.2. The induction generator is directly
connected to the grid. In this type, a capacitor bank is necessary for providing reactive
power which is absorbed by the induction generator. The gear box is present in order
to couple the low speed of the turbine to the high speed of the generator. Fixed-speed
turbines are simple, robust and cost-efficient and they were used by many manufacturers
in the 1980s and 1990s [38]. The main problem of this type is however that the fluctuation
in the wind speeds cannot be controlled [39]. Another disadvantages of this type are the
risk of loss of synchronism because of over-speed in case of voltage dips and increasing
of reactive power consumption, especially after fault clearance.
3.3.2 Variable-Speed Wind Turbine
The variable-speed wind turbine consists of a converter connected to the stator of the
induction or synchronous generator as shown in Figure 3.3. This type of wind turbine
can generate an almost constant generator torque. The wind fluctuations are absorbed
by changes in the generator speed [41]. An increased capture of energy, an improved
power quality and a reduced mechanical stress on the turbine are advantages of variable-
speed wind turbines. However, the drawback is the use of more components and the
complicated electrical system leads to a higher cost.
Variable-speed turbines with “partial scale converters” are known as doubly-fed induc-
tion generators (DFIGs). This work uses the DFIG in the simulations as this type is
widely used in wind farms [38].
27
3.5 Wind Turbine Model in PSS/E Chapter 3
Figure 3.3: Variable-speed wind turbine with a synchronous/induction generator [42]
Figure 3.4: DFIG with a Power Converter connected to the rotor terminals [43]
3.4 Doubly Fed Induction Generator (DFIG)
The schematic of a Doubly-Fed Induction Generator (DFIG) wind turbine is shown in
Figure 3.4. The main part of the DFIG consists of an induction generator with power
supply on the rotor as it can be seen in Figure 3.4. The stator is directly connected to the
grid, while the rotor circuit is connected via a power converter to the grid. The power
converter regulates the rotor current and hence controls the electromagnetic torque,
field and the stator output voltage. Figure 3.5 illustrates the general block diagram for
controlling a DFIG. The main parts are the generator and drive train, the turbine rotor,
the grid-side converter with DC-link capacitor, the pitch controller and the rotor-side
controller. The rotor-side converter controls the active and reactive power which the
rotor consumes or produces. The grid-side converter controls the voltage of the DC-link
capacitor [44].
28
3.5 Wind Turbine Model in PSS/E Chapter 3
Figure 3.5: Control block diagram of DFIG wind turbine [44]
3.5 Wind Turbine Model in PSS/E
The PSS/E provides dynamic simulation models for DFIG units and the models were
developed by GE Energy. For instance, there exist the GE 1.5, 3.6 and 2.5 MW models
[45].
Integrating a wind turbine of the GE 1.5 MW model which is used in this work in PSS/E
consists of two steps: doing a static power flow and next a dynamic power flow. The
two steps are discussed briefly below. The procedure of wind integration in PSS/E is
provided in Appendix A.
3.5.1 Running a Static Power Flow
The first step of integrating a wind machine in power flow models, is running a static
power flow. There, a wind turbine is treated as a conventional machine. The important
parameters of a typical GE 1.5 MW machine are found in [43] and presented in Table 3.1.
29
3.5 Wind Turbine Model in PSS/E Chapter 3
Table 3.1: Power flow parameters of GE 1.5MW [43]
Data GE 1.5
Generator Rating 1.67 MVA
Pmax 1.5MW
Pmin 0.07MW
Qmax 0.726 MVAr
Qmin -0.726 MVAr
Terminal voltage 690 V
Unit Transformer Rating 1.75 MVA
Unit Transformer Z 5.75 %
Unit Transformer X/R 7.5
Figure 3.6: Overall wind turbine model of DFIG [45]
3.5.2 Running a Dynamic Power Flow
The dynamic models of a GE 1.5 MW wind turbine consist of an aerodynamics model
(GEWTA1), an electrical control model (GEWTE2), a model for the generator and
power converter (GEWTG2), a pitch control model (GEWTP1) and a 2-mass model
for the turbine shaft (GEWTT1). The connectivity between these models are shown in
Figure 3.6. The wind model parameters used in this work are given in Appendix B.
30
Chapter 4
Optimal Power Flow (OPF) with
PFC Adequacy Constraints
4.1 Introduction
One of the important tools for the planning of electrical power systems is the power flow
calculation [46]. A Power Flow (PF) is the basic tool for security analysis, by identifying
unacceptable voltage deviations or potential component overloading, generally for both
natural load evaluation and sudden structural changes.
However, in active power optimization problems where voltage and reactive power are
of no importance, it is possible to use a DC power flow model instead of an AC power
flow [19]. There, the equations are linearized by assuming that the voltage magnitudes
are constant and equal to 1 pu, by assuming that the voltage angles are small, and
by neglecting the line resistance with respect to the line reactance. Therefore, in this
chapter, DC Power flow will first be introduced. Then, the next section discusses the
problem of Economic Dispatch (ED) and thirdly, the more general problem of Optimal
Power Flow (OPF) will be explained. The last section is devoted to introducing new
constraints in the classic OPF in order to ensure the adequacy of the PFC.
31
4.2 DC Power Flow Chapter 4
4.2 DC Power Flow
The active power flow Pij through a line which connects the sending node i to the
receiving node j is [47]:
Pij = ViVj [Gij cos(θi − θj) +Bij sin(θi − θj)]− V 2i Gij (4.1)
Where
Vi magnitude of voltage at bus i;θi angle of voltage at bus i;Gij series conductance of the transmission line;Bij series susceptance of the transmission line.
The Vi and θi are the state variables of the problem. Equation (4.1) is called the AC
power flow equation. AC power flows require many calculations but represent the reality
of the power system accurately. The following assumptions are made in order to speed
up the calculation [48]:
1. The resistance of each branch is negligible compared to the reactance,
2. Vi = Vj = 1 pu,
3. Assume that (θi−θj) < 2π/9, and then cos(θi−θj) ≈ 1 and sin(θi−θj) ≈ (θi−θj).
Then, equation (4.1) reduces to:
Pij = Bij(θi − θj) (4.2)
Equation (4.2) is known as the DC power flow equation. Considering Bij = 1Xij
, equa-
tion (4.2) changes to:
Pij =1
Xij(θi − θj) (4.3a)
(θi − θj) = XijPij (4.3b)
32
4.2 DC Power Flow Chapter 4
This is a linear equation. The assumptions of DC power flow linearize the power flow
equation. Suppose a network consists of n nodes and m transmission lines, and defines
the following parameters:
A the node-branch incidence matrix ((n− 1)×m);X a diagonal matrix (m× n) containing the reactance of the lines;PF the vector (m× 1) containing the power flow through the lines;θ the vector ((n− 1)× 1) of bus voltage angles.
The network incidence matrix A does not include the row corresponding to the reference
or slack node and is defined as [12]:
Ali =
1, if i is the originating node for link l;
−1, if i is the terminating node for link l;
0, otherwise.
Equation (4.3b) can then be expressed in matrix form as:
AT θ = XPF (4.4a)
PF = (X−1AT )θ (4.4b)
Defining P as the ((n− 1)× 1) vector of the power injections at every node, then:
P = APF (4.5)
And thus,
P = (AX−1AT )θ = Bθ (4.6)
Where B = AX−1AT is known as the susceptance matrix. Considering equation (4.4b)
and (4.6), PF can be expressed as:
PF = (X−1ATB−1)P = HP (4.7)
H is an (m × (n − 1)) matrix and is referred to as the matrix of shift factors, power
transfer distribution factors (PTDFs) or simply distribution factors. Hli is the amount
by which the active power flow over the link l varies with a change in the injection at
node i [12].
33
4.4 Optimal Power Flow Chapter 4
In the DC power flow model, the flow on any network element can be represented as a
linear function of the injections at the nodes of the network [12].
4.3 Economic Dispatch (ED)
This work supposes that the electric energy system is managed by a central operator
with full information on the technical and economic data of the generators, the loads,
and the network. Then, the Economic Dispatch (ED) problem seeks to find a solution
for the problem of allocating the total demand among the generators in order to have
the minimum production cost. The ED problem has as objective function the minimiza-
tion of the production cost with respect to constraints such as energy balance and the
operational limits of the generating units. There are different methods to solve the ED
problem such as the Lambda Search Technique (for rather simple cost functions), the
Gradient Search and Newton’s method [49]. In an ED problem, the generator outputs
are the only adjustable variables.
4.4 Optimal Power Flow (OPF)
After allocation of the total demand among the generators so that the production cost
is minimized by the ED, there is a need to include the transmission losses as well as
power flow constraints in the optimization problem. When the complete transmission
system model is included in ED, the problem is called an Optimal Power Flow (OPF)
[49]. The ED covers the generation limits, while the OPF includes many more of the
power system limits such as limits on the generator reactive power (in an AC Optimal
Power Flow), limits on the voltage magnitude or flows over transmission lines.
The mathematical formulation of the OPF introduces decision variables (such as gener-
ator voltage, LTC transformer tap position, load shedding, reactive injection for static
VAR compensators), state variables (that describe the response of the system to changes
in the control variables) and parameters (including known characteristic of the system
and assumed constant parameters such as network topology, network parameters, gen-
erator cost functions).
34
4.5 Introducing PFC Constraints Chapter 4
A compact form of the OPF problem is:
Minimize f(x, u) (4.8a)
s.t. G(x, u) = 0 (4.8b)
H(x, u) ≤ 0 (4.8c)
u ≤ u ≤ u (4.8d)
where u is the set of decision variables, such as generator active power, generator bus
voltage; x is the set of state variables, e.g. load bus voltage magnitude and angle; f(x, u)
represents the objective function, e.g. power generation cost or power transmission
losses; H(x, u) is the set of operational constraints, e.g. currents and voltage limits,
branch power flow limits; G(x, u) is the set of power flow equations and u and u are the
physical limits of the decision variables [19].
There exist challenges for solving the OPF due to the big size of problem and (in case
of an AC OPF) non-linearities or non-convexity of the problem. The General algebraic
Modeling System (GAMS) is a modeling software that is designed for modeling linear,
nonlinear or mixed integer optimization problems [18].
4.5 Introducing PFC Constraints
A classic DC OPF with objective function of minimizing the cost of generating power
and the cost of providing capacity for reserves is given below:
Minimize∑
i∈Iei(Pi) +
∑i∈I,i 6=l
si(Ri) (4.9a)
s.t.∑
i∈IPi =
∑j∈J
dj (4.9b)
− Lk ≤∑
i∈I,j∈JHik(Pi − dj) ≤ Lk, k ∈ K (4.9c)
0 ≤ Ri ≤ Rmaxi , i ∈ I, i 6= l (4.9d)
Pi +Ri ≤ Pmaxi , i ∈ I (4.9e)
Pi, Ri ≥ 0, i ∈ I (4.9f)
35
4.5 Introducing PFC Constraints Chapter 4
where
i ∈ I set of generators;j ∈ J set of loads;k ∈ K set of transmission lines;i = l largest system generator;Pi dispatched power of generator i (MW);ei(Pi) generator i energy cost function ($/h);Ri reserve of generator i (MW);si(Ri) generator i reserve cost function ($/h);Pmaxi total capacity of generator i (MW);Rmaxi maximum reserve of generator i (MW);dj load j (MW);Lk line k thermal limit (MW);Hik element (i,k) of PTDF matrix H.
Constraint (4.9b) represents the DC power flow power balance equations. Constraint
(4.9c) means that the line flow cannot exceed the line capacity limits. Finally, Con-
straints (4.9d), (4.9e) and (4.9f) set the reserve and generation limits.
Ri is the “Primary Reserve (PR)” of generator i which is the capacity of the generators
that is reserved for governors to apply PFC [14]. The PFC adequacy, depends as ex-
plained before on the inertia and the ramping capability of the governors. The outage
of the largest generator in the grid is considered for determining the PR requirement.
Therefore adding a governor response constraint guaranteing PFC adequacy in equation
(4.9a) is needed. The proof of these new expressions comes from [27] and are explained
as follow. Referring to Chapter 2, the swing equation (2.33) is given here again as:
df (t)
dt=
1
MH(Pm(t)− Pe (t)) (4.10)
Assume that at the time t = 0, a power plant with size Pl stops working and becomes
out of order. Next, the mechanical power Pm decreases with Pl, while the electrical load
power Pe stays constant (Figure 4.1), because the load does not change.
It can be seen from Figure 4.1 that the frequency first decreases as Pm−Pe = −Pl < 0.
When the frequency drop exceeds the dead-band value fdb, the governor starts working
and starts increasing the mechanical power from the prime movers. The frequency
decreases till tNadir, and then the frequency stabilizes when Pm −Pe = 0. After that, it
will increase because Pm − Pe > 0. Finally the frequency reaches the steady state value
36
4.5 Introducing PFC Constraints Chapter 4
C
fdb
tss
fss
Figure 4.1: Governor operation and frequency behavior after a power plant outage [27]
of fss at tss.
Equation (4.10) can be integrated over time between t = 0 and t = tNadir:∫ tNadir
0
df(t)
dtdt = fNadir − f0,
=1
MH
∫ tNadir
0(Pm(t)− Pe(t))dt
(4.11)
The first instants after a contingency are only governed by the inertial response:
td =MH
Plfdb (4.12)
In Figure 4.1, td is the time at which the frequency drop exceeds the dead-band fdb.
If the dead-band frequency fdb is reached, the governor starts to work. The governor
increases the mechanical power Pm with a ramp rate C:
C =∆Pm∆t
(4.13)
37
4.5 Introducing PFC Constraints Chapter 4
The integral on the right hand side of equation (4.11) can be developed as:
fNadir − f0 =1
MH(
∫ td
0(−Pl)dt)
+1
MH(
∫ tNadir−td
0(−Pl + C(t− td))dt)
=−1
MHPltd
+1
MH(
∫ tNadir−td
0(−Pl + Ct)dt)
=−1
MHPltd
+1
MH
(−Pl(tNadir − td) +
C(tNadir − td)2
2
)=−1
MHPltd +
1
MH(−Pl
2(tNadir − td))
=−1
MH(Pltd +
P 2l
2C)
(4.14)
Equation (4.14) expresses the relation between fNadir, inertia MH , the power loss Pl,
the governor dead-time td and the ramp rate C.
According to equation (2.36), for having PFC adequacy fNadir must be larger than fmin,
and thus:
fNadir = f0 −1
MH(Pltd +
P 2L
2C) ≥ fmin
−1
MH(Pltd +
P 2l
2C) ≥ fmin − f0
Pltd +P 2l
2C≤MH(f0 − fmin)
P 2l
2C≤MH(f0 − fmin)− Pltd
2C
P 2l
≥ 1
MH(f0 − fmin)− Pltd
C ≥12P
2l
MH(f0 − fmin)− Pltd= Cmin
(4.15)
Now substitute equation (4.12) into (4.15), Cmin can be written as:
Cmin =12P
2l
MH(f0 − fmin − fdb)(4.16)
Equation (4.16) defines the overall system governor ramp rate. Likewise, the PFC
constraint on individual units depends on the ramp rate ci of the individual plant. The
ci is described as the fastest possible mechanical power output change of the machine i.
38
4.5 Introducing PFC Constraints Chapter 4
The value of ci is calculated from so called stress test : observations of a large contingency
during low governor capability conditions (Figure 4.2).
td tNadir
PiNadir
Figure 4.2: Generator ramping capability ci [27]
[27] defines two necessary and sufficient conditions for satisfying equation (2.36): First,
the sum of the reserves (except i = l, the unit which experiences the outage) should be
larger than the largest possible loss Pl:
∑i∈,i 6=l
Ri ≥ Pl (4.17)
The second condition is that Ri should be delivered before tNadir [27]; therefore, Ri must
be smaller than PNadiri . PNadiri is the power delivered by unit i at tNadir:
Ri ≤ PNadiri (4.18)
From Figure 4.2, PNadiri = ci(tNadir − tdb), thus:
Ri ≤ ci(tNadir − tdb) (4.19)
According to Figure 4.1, tNadir − tdb is equal to PlCNadir
. However the CNadir should
be replaced by Cmin due to the fact that with Cmin the worst condition is examined,
as the frequency Nadir is deeper when the system ramp rate C is smaller. Therefore,
equation 4.19 becomes:
Ri ≤ ciPlCmin
(4.20)
Now substitute equation (4.16) into (4.20):
Ri ≤ ciPl12P 2l
MH(f0−fmin−fdb)
(4.21)
39
4.5 Introducing PFC Constraints Chapter 4
Yielding,
Ri ≤ ci2MH(f0 − fmin − fdb)
Pl(4.22)
Equation (4.22) and (4.17) can be added to the set of equations (4.9a). Then, the OPF
also includes a PFC adequacy constraint:
Minimize∑
i∈Iei(Pi) +
∑i∈I,i 6=l
si(Ri) (4.23a)
s.t.∑
i∈IPi =
∑j∈J
dj (4.23b)∑i∈,i 6=l
Ri ≥ Pl (4.23c)
Ri ≤ 2ciMH(f0 − fmin − fdb)
Pl, i ∈ I, i 6= l (4.23d)
− Lk ≤∑
i∈I,j∈JHik(Pi − dj) ≤ Lk, k ∈ K (4.23e)
0 ≤ Ri ≤ Ri, i ∈ I, i 6= l (4.23f)
Pi +Ri ≤ Pi, i ∈ I (4.23g)
Pi, Ri ≥ 0, i ∈ I (4.23h)
where
ci generator i governor ramp rate (MW/s);fmin minimum acceptable frequency (Hz);fdb system governor’s dead-band (Hz);f0 rated frequency (Hz).
Constraint (4.23b) is the power balance equation. Constraint (4.23c) and (4.23d) belong
to the constraints to ensure PFC adequacy in the grid. Constraint (4.23e) states that
the line flow capacity limits should be respected. Hik is an (m × (n − 1)) matrix of a
network with n nodes and m transmission lines and is referred to as the Power Transfer
Distribution Factor matrix. Hik is the amount by which the flows over the link k varies
with a change in the injection at node i [12]. Finally, constraints (4.23f), (4.23g) and
(4.23h) set the reserve and generation capacity limits, respectively.
40
Chapter 5
Case Study
5.1 Introduction
This Chapter presents a case study which aims to examine how different levels of wind
integration have an influence on frequency stability. First in Section 5.2, the Nordic 32-A
test system, a model of the Swedish grid, will be presented. Then, in Section 5.3, the
modification to the original Nordic 32-A test system which are necessary to have ability
of performing dynamic simulation in PSS/E will be explained.
5.2 Nordic 32-A Test System
The CIGRE Nordic 32-A test system is used as a model of the Swedish transmission
grid in this work [50]. As the single line diagram of the grid shows in Figure 5.1, the
Nordic 32-A test system includes four main areas. The northern area is characterized
by the presence of a lot of hydro generation and by a low load. The central area,
on the contrary, has a high demand for electrical energy and contains mostly thermal
power plants. The south-western area contains multiple thermal units and has a low
load. Finally, the external area is connected to the northern area and has a mixture of
different types of generation and load [40].
The total installed capacity of Nordic 32-A is 17.5 GW. However, the real Swedish grid
has the total installed capacity of 33.5 GW [51]. Thus, the Nordic 32-A test system
is considered a one half scaled-down version of the real Swedish grid in this work [52].
41
5.2 Nordic 32-A Test System Chapter 5
Central
North
External
SouthWest
Figure 5.1: The single-line diagram of Nordic 32-A test system
The model consists of 32 main buses, 51 transmission lines, 13 transformers and 22
generators, 13 of which are hydro units, whereas the rest are thermal generators. The
following dynamic models are used in the original Nordic 32-A test system [50]:
• GENSAL: represents a salient pole generator and is used for all hydro power units.
Figure 5.2 shows the block diagram of GENSAL generator.
• GENROU: is a model of a synchronous generator with a cylindrical round rotor
and represents the generators of the thermal power units. Figure 5.3 shows the
42
5.3 Modification of the Nordic 32-A Test System Chapter 5
Figure 5.2: The block diagram of GENSAL generator [53]
block diagram of GENROU generator.
Figure 5.3: Block diagram of GENROU generator [53]
• SEXS: represents the excitation system’s dynamic model and is used for all types
of synchronous generators. Figure 5.4 describes the control diagram of SEXS.
Figure 5.4: The control diagram for the Simplified Excitation System [53]
• SATB2A: is the stabilizer model, dampening the oscillations in the electrical output
power, Figure 5.5 shows the dynamic control model for STAB2A.
• HYGOV: represents the governor for hydro plants (no governor for thermal units).
The block diagram for the HYGOV governor is illustrated in Figure 5.6.
43
5.3 Modification of the Nordic 32-A Test System Chapter 5
Figure 5.5: The dynamic control model for STAB2A [53]
Figure 5.6: The block diagram for the HYGOV governor [53]
5.3 Modification of the Nordic 32-A Test System
The simulations carried out in this work were performed using the power system si-
mulation tool PSS/E 33.4. All the procedure for developing Nordic 32-A Test System
in PSS/E are provided in Appendix A. The Nordic 32-A grid is modeled based on the
parameters given in [50], but some modifications are made in order to be able to perform
a dynamic simulation using the model. The changes are kindly provided by Prof. Tuan
A. Le from Chalmers University. They are as the following (there are no changes in the
bus data):
With respect to the generator data:
• The active generation PG of the generator attached to bus 1012 is 600 MW in [50],
but is 400 MW in the modified test grid.
• The minimum allowed reactive power of the generator attached to bus 1012 is
-80 MVAr in [50], but is -200 MVA in the modified test grid.
44
5.3 Modification of the Nordic 32-A Test System Chapter 5
• The minimum allowed reactive power of the generator attached to bus 1013 is
-50 MVAr in [50], but is -200 MVAr in the modified test grid.
• The minimum allowed reactive power of the generator attached to bus 1014 is
-100 MVAr in [50], but is -200 MVAr in the modified test grid.
• The active generation of the generator attached to bus 4012 is 600 MW in [50],
but is 500 MW in the modified test grid.
• In [50], there is only one machine attached to bus 4051 with PG = 600 MW, but
in the modified test grid, there are 2, with PG = 600 and 400 MW.
• In [50], there is only one machine attached to bus 4051 with Qmax = 350 MVAr,
but in the modified test grid, there are 2, with Qmax = 350 and 350 MVAr.
• In [50], there is only one machine connected to bus 4051 with a scheduled voltage
of 1.02 pu, but in the modified test grid, there are 2, scheduled voltages 1.0 and
1.0 pu.
• In [50], there is only one machine attached to bus 4051 with a machine power base
of 700 MVA, but in the modified test grid, there are 2, each having a power base
of 700 MVA.
• All scheduled voltages are set to 1 pu in the modified test grid.
With respect to the branch data:
• The long-term line flow rating of line 41-4041 is 770 MVA but is 750 MVA in [50].
• The long-term line flow rating of line 43-4043 is 1430 MVA but is 1500 MVA in
[50].
• The long-term line flow rating of line 51-4051 is 1430 MVA but is 1500 MVA in
[50].
• The long-term line flow rating of line 61-4061 is 770 MVA but is 750 MVA in [50].
• There is an extra branch, between buses 4061 and 4062, not present in [50].
• The line charging parameter B is completely different from in [50].
45
Chapter 6
Method and Simulation Results
6.1 Introduction
This Chapter explains the method for studying the impact of wind integration on the
adequate operation of PFC, considering two metrics of PFC adequacy: the ROCOF and
the frequency Nadir. The following part of this Chapter discusses the second objective
of this work which is the cost analysis of the impact of wind integration on the adequacy
of operation of the Primary Frequency Control. A case study using the Nordic 32-A
test system, introduced in Chapter 5, is presented in this Chapter. In Section 6.2,
the parameters of the grid will be identified with an ad-hoc method. This requires
the automation of PSS/E. Next in that Section, wind turbines are integrated in the
identified Nordic 32-A test system and the effect of the wind integration on the ROCOF
and frequency Nadir, is investigated. Section 6.3 contains the second objective of the
work; investigating the economic impact of wind integration on the PFC, considering
the ramp rate capabilities for all the governors in the grid. Finally, an OPF is presented
which includes constraints ensuring the adequacy of PFC operation. At the end of each
Section, an overview of the simulation results and a summary are provided.
6.2 Impact of Wind Integration on PFC Adequacy
This Section explains the method for studying the technical impact of wind integration
on the adequacy of PFC operation. The Nordic 32-A system is taken as an example
46
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
to illustrate the method. The Center-Of-Inertia (COI) frequency should be calculated.
In order to acquire the COI frequency, PSS/E needs to be automated. This is done by
Python and the psspy module. Next, an ad-hoc method to identify the grid parameters
using actual data of a contingency occurring in the NORDEL system, will be presented.
Wind turbines of type GE 1.5 MW are subsequently integrated in the model. In the
next step, the effect of different levels of wind power generation on the ROCOF and
frequency Nadir of the COI frequency of the grid are investigated. Finally, the amount
of wind capacity that leads to an inadequate primary frequency control is calculated.
6.2.1 Center-of-Inertia (COI) frequency
A starting point for analyzing the frequency stability in the Swedish grid is to study the
primary frequency control when there is a sudden load-generation imbalance. Figure 6.1
shows the frequency during three generation outage events in the Nordic system [54].
We will model the Nordic system with the Nordic 32-A grid, which is a model for
0 50 100 150 200 250 30049.5
49.6
49.7
49.8
49.9
50
50.1
50.2
Freq
uenc
y(H
z)
Time(seconds)
10-04-1609-08-1009-07-02
16/04/2010 (550 MW)
10/08/2009 (1100 MW)
02/07/2009 (800 MW)
Figure 6.1: Measured frequency in the Nordic system (NORDEL) after a suddentripping of 530, 800 and 1100 MW generation
mainly the Swedish grid. Since the installed capacity of the Nordic 32-A model is half
of that of the real Swedish grid, the machine on bus 1014 with a generation of 1100/2
=550 MW is considered for the contingency on 10/08/2009 (1100 MW). The question
that arises here is which frequency of the Nordic 32-A test system should be compared
with the real data? Bus frequencies can indeed be different from each other. The
answer is the center-of-inertia (COI) frequency of the grid. First of all, the definition of
47
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
the Center-Of-Inertia frequency, which was discussed in Chapter 2, is given here. The
“Center-Of-Inertia frequency” of the system is defined as:
∆f ≡
n∑i=1
Hi∆fi
n∑i=1
Hi
. (6.1)
According to equation (6.1), the speed/frequency of each machine after applying a con-
tingency, is needed for calculating the COI frequency. Analyzing and simulating the
speeds of all the machines in the system requires that we automatically perform the si-
mulation in PSS/E. For this purpose, PSS/E contains an embedded Python interpreter.
The PSS/E package includes the following Python extension modules, documented in
the PSS/E Application Program Interface (API) document [55]:
• psspy - provides access to the PSS/E API,
• dyntools - tools for processing channel output files,
• redirect - some tools to connect I/O streams between PSS/E and Python.
First, the Python interpreter should be initialized:
import os,sys
sys.path.append(PSSE_LOCATION)
os.environ[’PATH’] = os.environ[’PATH’] + ’;’ + PSSE_LOCATION
import psspy
import redirect
redirect.psse2py();
Then, the power flow analysis, the dynamic simulation and the wind integration will be
performed by following commands (see also Appendix A):
1- Open the raw data file (by .raw extension) containing the description of the grid (this
file is Nordic32.raw). For instance:
psspy.read(0,r"""C:\Documents and Settings\nfarrokh\Desktop\Nordic32.RAW""")
48
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
2- Set the base frequency to 50 Hz:
psspy.base_frequency(50.0)
3- Perform a static power flow (using the full Newton-Raphson method) in order to
provide a start state for the dynamic simulation:
psspy.fnsl([0,0,0,1,1,0,99,0])
4- Apply activity CONG to convert the generators to Norton equivalents. These are
models used in the dynamic simulation:
psspy.cong(0)
5- Apply activity CONL to convert the loads to Norton equivalents. The percentages
of the loads that are considered as constant impedances, constant current sources and
constant powers, and which are used in this work, are specified in Table A.1:
psspy.conl(0,1,1,[0,0],[ 50.0, 25.0, 50.0, 25.0])
6- Apply activity FACT to factorize the admittance matrix Y in its triangular compo-
nents:
psspy.fact()
7- Apply activity TYSL to allow switching studies in the dynamic simulation:
psspy.tysl(0)
8- Load the dynamic data file (dyr-file), containing the dynamic models for governors,
exciters, stabilizers and wind turbines. For instance:
psspy.dyre_new([1,1,1,1],r"""C:\Documents and Settings\nfarrokh\
Desktop\dynamic_data.dyr""",r"""cc""",r"""ct""","")
49
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
9- Define the output Channels. These are the quantities for which we want to store the
time-waveform in the memory. In the example below, the 7th channel of the machine of
bus 1012 is stored. The 7th channel is the machine speed deviation in per unit.
psspy.machine_array_channel([1,7,1012],r"""1""","")
10- Start the dynamic simulation and send the simulation results to the file gop.out:
psspy.strt(0,r"""gop.out""")
11- Run the simulation from the moment of initialization (at a negative time instant)
till zero seconds:
psspy.run(0,0.0,1,1,0)
12- Apply a contingency at t = 0. In the example below, the contingency is the discon-
nection of machine 1014:
psspy.dist_machine_trip(1014,r"""1""")
13- Run the simulation till t = 80 seconds:
psspy.run(0, 80,1,1,0)
Now, using another python file, all of the channels (here: recorded machine speeds)
which are stored in the file gop.out should be written to a text file in order to process
it in Matlab:
chnfobj = dyntools.CHNF(r"""C:\Documents and Settings\nfarrokh\
Desktop\gop.out""")
chnfobj.txtout(channels=[1,2,...,22],
txtfile=’outfile.txt’)
Here, the three dots in the channels list should be replaced with the numbers of the
actual channels. The next step is processing the obtained text-file in Matlab. First,
50
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
the text files are read and the data is stored in a matrix variable SPEED. Then each
column of SPEED, containing the machine speed as a function of time for each unit,
is multiplied with the allocated inertia H of the unit. The resulting matrix is called
HiTimesSPEED. Then the COI frequency is calculated as∑
iHi·SPEEDi∑iHi
.
The above described steps are performed by a Matlab file called main-COI.m. It has the
following tasks:
• Run a Python file (dynamic-simulation.py) to run a dynamic simulation ac-
cording to the above described steps 1-13, applying a 550 MW contingency and
obtaining the speed of all the generation units,
• Run a Python file (exporttotxtfile.py) to export the simulation channel data
(.out file) to a text file (.txt file),
• Run a Matlab file (processtextfiles.m) to process the text file, calculating the
COI frequency.
The procedure for calculating the COI frequency is shown in Figure 6.2.
In2MATLAB2run2a2python2file2linked2to2PSSYE.Ox2Perform2power2flow.2
Nx2Load2dyrxfile.2Cx2Define2channel2output2as2speed2versus
2time2of2each2machine.2qx2Run2dynxsim.2apply2a2contingency2of2((HMW.2
(x2Save2output2in2Fout2file
Run2another2python2file22to2convert2Fout2file
2to2Ftxt2file
Finish
PYTHON
PSSYE
PYTHON
MATLAB
MATLAB
MATLAB
OxRead2the2Ftxt2file2and2save2each2channel2in2column2of2amatrix2SPEED
NxMultiply2each2column2i2of2SPEED2with2the2inertia2Hi.save2as2HiTimesSPEED.CxSum2all2the2inertia2Hi.
qxCalculate2COI2frequency2as2sumgHiTimesSPEED.N5YsumgHi5
Figure 6.2: Procedure for calculating the COI frequency
51
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
6.2.2 Identification of model parameters using actual data
After obtaining the simulated COI frequency by automating PSS/E, it is plotted together
with the frequency data of the real contingency on August 9 2010 [54]. It can be seen in
Figure 6.3 that there is a significant difference between the measured frequency response
and the simulated Center-of-Inertia frequency response of the original Nordic 32-A test
system after the contingency occurs. The Nordic 32-A model was developed in 1993 and
is reported to model the dynamic behavior of the Swedish grid well. However, the grid
changed since then and the Nordic 32-A model needs to be updated.
The whole idea of an ad-hoc identification is to find the dynamic parameters of the
0 10 20 30 40 50 60 70 80−0.018
−0.016
−0.014
−0.012
−0.01
−0.008
−0.006
−0.004
−0.002
0
TimeT[s]
Per
Tuni
tTfre
quen
cyTd
evia
tionT
[pu]
OriginalTNordic32TModel
MeasuredTFrequencyTResponse
MeasuredTFrequencyTResponse
OriginalTNordicT32TModel
Figure 6.3: Frequency response of the original Nordic 32-A grid and the measuredfrequency response after a actual contingency
components of Nordic 32-A in such a way that after applying the 550 MW contingency,
the COI frequency response corresponds with the measured frequency response after the
real contingency of 1100 MW. In order to do an ad-hoc identification process, a Matlab
file (main-identification.m) was written which performs the following tasks:
• Make a for-loop to change dynamic parameters such as inertia H, droop R and
the time constants of all the governors,
52
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
• Run a Matlab file (changeHsAndRAndTInDyrFile.m) to make a dyr-file containing
the changed values of the dynamic parameters (H, R and the time-constants),
• Run a Python file (dynamic-simulation.py) to perform a dynamic simulation in
PSS/E,
• Run a Python file (exporttotxtfile.py) to export the simulation channel data
to a text file,
• Run a Matlab file (processtxtfile.m) to process the text file, obtaining the COI
frequency and comparing the COI frequency with the real data by calculating a
goodness-of-fit number. This goodness-of-fit is used in order to decide whether the
dynamic parameters are acceptable or not.
The inertia constants H of the generators are adjusted in the range [0.3, 10] s until the
simulated COI frequency matches with the measurement data of the frequency inside
the time range [0, 2] s. The governors are namely typically not yet active in this time
interval and the dynamic behavior is fully governed by the inertia [14]. To calculate the
goodness-of-fit, a least-square criterion is used. Then, the droop constants of the gover-
nors are sought by adjusting them until the simulated frequency matches the measured
data in steady-state. The droop determines in fact the steady-state behavior. Finally,
various dynamic parameters of the HYGOV governor belonging to the machines in hy-
draulic plants are sought by matching the transient in the simulated frequency with the
measured data. The identification method is presented in Figure 6.4.
The dynamic parameters in the Nordic 32-A model before and after identification are
shown in Table 6.1. It should be noted that the model identification is time dependent,
because different load conditions lead to different frequency control dynamics.
6.2.3 Wind Integration
This work focuses mainly on the variable-speed type of wind turbines which is more
commonly used than the fixed-speed turbines [15]. There are several studies that show
how the inertia of the blades can be utilized through an implementation of an additional
control loop [56], but standard DFIG-wind turbines typically do not have frequency
control capabilities.
53
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
Change dynamic parameters such as inertia H, droop R and
time constants
run another python file to convert the PSS/E .out file
to a .txt file
Is goodness-of-fit ok?
make a dynamic file (.dyr ) containing the dynamic data
of every machine
No
Yes
Final Identified Model
MATLAB
MATLAB
PYTHON
PSS/E
PYTHON
MATLAB
In MATLAB run a python file linked to PSS/Ewhich does following steps:
1- Perform power flow, 2- Load dyr-file,
3- Define channel output as speed versus time of each machine,
4- Run dyn-sim, apply a contingency of 550MW, 5- Save output as .out file
MATLAB
1- Read the .txt file and save each channel as column of a matrix SPEED,
2- Multiply each column i of SPEED with the inertia Hi, save as HiTimesSPEED, 3- Sum all the inertia Hi,
4- Calculate COI-frequency as sum (HiTimesSPEED,2) / sum (Hi)5- Compare COI with real data of contingency in NORDEL
6- Calculate goodness-of-fit as a least-square criterion
Figure 6.4: Algorithm for the ad-hoc model identification method
54
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
Table 6.1: Original and identified dynamic parameters of the Nordic 32-A model
Dynamic para-meters
Originalparame-
ters
Identifiedparame-
tersR, PermanentDroop
0.04 pu 0.05 pu
Tg , Servo TimeConstant
0.2 s 0.2 s
Tr, Governor TimeConstant
5 s 0.6 s
Tf , Filter TimeConstant
0.05 s 0.1 s
Velm, Gate Veloc-ity Limit
0.1 pu/s 0.1 pu/s
Gmax, MaximumGate Limit
0.95 pu 0.9 pu
Gmin, MinimumGate Limit
0 pu 0 pu
Tw, Water TimeConstant
1 s 0.5 s
Dturb, TurbineDamping
0 0.4
At, Turbine Gain 1 0.95H1, Inertia ofThermal Genera-tors
6 s 9 s
H2, Inertia of Hy-dro Units
3 s 7.7 s
The wind turbine model for all wind farms in this study is assumed to be a DFIG of type
GE 1.5 MW [43]. All simulations are performed in PSS/E. The rated quantities needed
for a static and dynamic simulation of a typical GE 1.5 MW wind turbine are taken from
[43]. In each wind park, 300 identical wind turbines are lumped together. The rated
wind turbine quantities for a static power flow are presented in Table A.2 in Appendix A.
The dynamic models of a GE 1.5 MW wind turbine consist of an aerodynamic model
(GEWTA1), an electrical control model (GEWTE2), a model for the generator and
power converter (GEWTG2), a pitch control model (GEWTP1) and a 2-mass model for
the turbine shaft (GEWTT1). All the required data for the dynamic model is described
in Appendix B [43].
The assumptions in the study when wind farms are added to the identified Nordic 32-A
model are:
• The load will not change in different scenarios,
• The wind speed remains constant during the simulations,
• One aggregated wind turbine is used to represent all the wind turbines inside a
wind farm,
55
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
• The wind power output is 70% of the installed capacity [14]. This captures the
fact that the correlation between different wind farms within a large geographical
area is not perfect, so it is very unlikely that all wind farms generate a maximum
output at the same time,
• The integration of wind is assumed to replace existing thermal units and the output
of the replaced generator is equal to the output of the integrated wind generation.
This work concerns the tripping of one unit at bus 1014 with a rated output of 550 MW
which causes a generation loss of 4.8 % (the total production is 11400 MW). A number
of simulations have been performed to further understand the impact of wind power on
frequency stability. In order to calculate the ROCOF and frequency Nadir after wind
integration, a Matlab file (main-windintegration.m) is run which performs following
steps:
• Run a Python file (dynamic-simulation.py) to perform a dynamic simulation in
PSS/E. This file is the same as the python file before with the difference that after
reading the Nordic32.raw file, an extra command is inserted:
psspy.addmodellibrary($r"""C:\Program Files\PTI\PSSEWind
\GEWT\V33\gewt.dll"""$)
Notice that the dynamic data of a wind turbine of GE 1.5 MW according to
Appendix B should be added to the dyr-file.
• Run a Python file (exporttotxtfile.py) to export the simulation channel data
to a text file,
• Run a Matlab file (processtxtfile.m) to process the text file, obtaining the COI
frequency and calculating the ROCOF as the initial slope of the COI frequency
and the frequency Nadir as the minimum value of the COI frequency.
The algorithm for calculating the ROCOF and frequency Nadir after wind is integrated
and a contingency is performed, is presented in Figure 6.5. Because the load is assumed
to be constant for all the different values of wind power in this work, it was necessary
to switch off the more expensive thermal units to keep the power balance; this process
was done according to the order of economic merit which is determined by executing a
56
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
runLanotherLpythonLfileLLtoLconvertLtheLPSSDEL3outLfile
LtoLaL3txtLfile
Finish
PYTHON
PSSDE
PYTHON
MATLAB
InLMATLABLrunLaLpythonLfileLlinkedLtoLPSSDEwhichLdoesLfollowingLsteps:
RbLPerformLpowerLflow25bLAddLmodelLlibraryLofLgewt3dllL
5bLLoadLdyrbfileLincludingLwindLmodels2L0bLDefineLchannelLoutputLasLspeedLversus
LtimeLofLeachLmachine2LWbLRunLdynbsim2LapplyLaLcontingencyLofLCC4MW2L
CbLSaveLoutputLasL3outLfile
MATLAB
RbLReadLtheL3txtLfileLandLsaveLeachLchannelLasLcolumnLofLaLmatrixLSPEED2L
5bLMultiplyLeachLcolumnLiLofLSPEEDLwithLtheLinertiaLHi2LsaveLasLHiTimesSPEED2L0bLSumLallLtheLinertiaLHi2L
WbLCalculateLCOILfrequencyLasLsumL1HiTimesSPEED25-LDLsumL1Hi-CbLCalculateLROCOFLasLinitialLslopeLofLtheLCOILfrequency
qbLCalculateLNadirLasLtheLminimumLfrequencyLofLtheLCOILfrequency
Figure 6.5: Algorithm for calculating the ROCOF and frequency Nadir after wind isintegrated
classical Economic Dispatch OPF in GAMS.
6.2.4 Simulation Results
6.2.4.1 Impact of Wind Integration on the ROCOF
Figure 6.6 shows the frequency response of the system after a contingency of 550 MW
(machine 1014) for the base case (without wind) and with wind power integration.
Also the impact of wind integration on the ROCOF and frequency Nadir is shown in
Table 6.2.
According to Table 6.2, the magnitude of the ROCOF increases when more wind power
is added to the system. As described in Chapter 2, this study will consider 0.5 Hz/s as
a maximum limit for the ROCOF. Using the ROCOF data of Table 6.2, and performing
57
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
0 10 20 30 40 50 60 70 8049.5
49.6
49.7
49.8
49.9
50
50.1
50.2
Timeb[s]
Cen
terb
ofb
Iner
tiab
ofb
theb
bu
sbfr
equ
enci
esb[
Hz] BasebCasebNobWind
600bMWbWindbFarm1200bMWbWindbFarm1800bMWbWindbFarm2400bMWbWindbFarm3000bMWbWindbFarm
3000MW
1800MW
1200MW
600MW
2400MW
BasebCase
Figure 6.6: Frequency response after contingency of 550 MW for different amountsof integrated wind power production
Wind [GW]0 5 10 15 20 25
RO
CO
F [H
z/s]
0.1
0.15
0.2
0.25
0.3
0.35
0.4
0.45
0.5
0.55
0.6
20.08GW
(a) Acceptable level of wind integration for ensuring theadequacy of the ROCOF
Wind [GW]0 2 4 6 8 10 12
Fre
quen
cy N
adir
[Hz]
49.2
49.25
49.3
49.35
49.4
49.45
49.5
49.55
49.6
49.65
6.2 GW
(b) Acceptable level of wind integration for ensuring theadequacy of the frequency Nadir
Figure 6.7: Linear extrapolation of the predicted ROCOF and frequency Nadir be-havior
58
6.2 Impact of Wind Integration on PFC Adequacy Chapter 6
Table 6.2: Effect of wind integration on ROCOF and frequency Nadir
Wind Integration ROCOF Magnitude Frequency Nadir(MW) (Hz/s) (Hz)
0 0.11488 49.6113
600 0.12149 49.6052
1200 0.13818 49.5902
1800 0.14868 49.5797
2400 0.16236 49.5686
3000 0.16678 49.5184
a linear extrapolation in Matlab, a ROCOF magnitude of 0.5 Hz/s is predicted when
the wind capacity is 20.08 GW (Figure 6.7(a)). This means that for the Swedish grid,
40.16 GW is the maximum wind power that can be integrated into the system. More
wind power will cause the ROCOF to become inadequate. However, the expectation for
wind power in Sweden is 17 GW by 2030 [5], and hence, there is no problem for the
immediate future.
6.2.4.2 Impact of Wind Integration on the Nadir
Table 6.2 shows a decreasing trend for the Nadir. The frequency Nadir requirement is to
maintain the system frequency above 49.4 Hz at all times as specified in Chapter 2. Based
on the data from Table 6.2, the wind generation value that causes the system frequency to
fail complying with this requirement is 6.2 GW as indicated in Figure 6.7(b). Therefore
a critical wind generation for Sweden would be 12.4 GW. In the other words, when the
wind power, integrated into the Swedish grid, is larger than 12.4 GW, there would be
frequency Nadir inadequacy. This is, in principle, of concern as the wind capacity is
expected to increase up to 17 GW by 2030 [5].
6.2.5 Summary
After implementing the Nordic 32-A model in PSS/E, the Center-Of-Inertia frequency
of the grid is calculated by automating PSS/E with the psspy python module. The
comparison of the COI frequency with the real NORDEL data shows that the dynamic
parameters of the Nordic 32-A system need to be determined as the original model
predicts a frequency response which is very much different from the measured behav-
ior. Therefore, the parameters are determined with an ad-hoc system identification
59
6.3 Economic Impact of Wind Integration on PFC Chapter 6
approach. After the identification, wind turbines of type GE 1.5 MW are integrated
into the model and for various wind integration levels, the ROCOF (the initial slope
of the COI frequency after a contingency) and the frequency Nadir (the minimum COI
frequency) are determined. By considering the allowable values of each of the metrics
of PFC, the amount of wind capacity that leads to an inadequate primary frequency
control is determined as well.
6.3 Economic Impact of Wind Integration on Primary Fre-
quency Control
In the previous Section, the technical impact of wind integration on the frequency in the
grid is investigated; however the cost analysis of this impact has not yet been investi-
gated. Therefore, this Section discusses the cost analysis of the wind integration on the
requirements for primary frequency control adequacy. First, the ramp rate capabilities
for all the governors in the grid are included in the model. Then a stress test is applied to
find the ramp rates of each unit. Wind turbines of type GE 1.5 MW are next integrated
in the model. The outcome of the previous Section was that the Nadir adequacy can
not be maintained in the system when a large amount of wind is integrated. Since one
of the requirements to have an adequate operation of the Primary Frequency Control is
that the frequency Nadir is larger than the minimum allowed frequency value, PFC ad-
equacy constraints need to be considered in the OPF determining the optimal operation
of the grid. In the last part of this Section, this OPF, containing the PFC adequacy
constraints, is presented. Finally, the simulation results are presented in detail and a
summary is given.
6.3.1 Adding Governors with a Ramp Rate Capability
The ramp rate capability of governor are one of the dynamic properties of units that can
play an important role in primary frequency control [14] [27]. Since in the Nordic 32-A
test system, the HYGOV model is used as the governor for hydro plants and has no
ramping rates, it is replaced by the HYGOV2-model, having ramping rates. Also, the
governor model IEEEG1 is used for the thermal plants (governors for thermal power
plants are not considered in [50]). Then, the measured frequency response after the
60
6.3 Economic Impact of Wind Integration on PFC Chapter 6
actual contingency of 1100 MW on September 8, 2010 in NORDEL [54], is considered
in order to identify the dynamic parameters of the Nordic 32-A test system. All the
Matlab code and Python code for the identification are provided in Appendix C. The
procedure explained in Section 6.2 is repeated here and the results of the identification
are shown in Figure 6.8.
0 10 20 30 40 50 60 70 80−8
−7
−6
−5
−4
−3
−2
−1
0
1x 10
−3
Time.[s ]
Pe
r.u
nit.
fre
qu
en
cy.d
evi
atio
n.[
pu
]
Real.frequency.data.Icontingency.of.1100.MW.on.Sep..8,.2010.in.Nordel3
COI.frequency.of.identified.Nordic.32-A
COI.frequency.Identified.Nordic.32-A
Real frequency data
Figure 6.8: Result of identification: comparison of real frequency data and the simu-lated center-of-inertia frequency [54]
6.3.2 Stress Test
After identifying the dynamic parameters of the Nordic 32-A model, the ramp rates
of each generator, being the fastest possible change of mechanical power output of the
machine, are obtained by applying a “stress test”.
In this test, the value of the mechanical power of each generator is computed in PSS/E
as a function of time after a contingency of the largest machine on bus 2032 (850 MW
installed capacity) and all of these data are transferred to Excel format in order to easily
process it further in Matlab. First the ramp rates are computed in pu per second and
then these are multiplied with the machine base Mbase of the corresponding machine in
order to obtain the ramp rates in MW/s. The ramp rate ci is calculated in Matlab as the
slope of the rising flank (Table 6.3). For instance, the ramp rate ci for the machine 1012
is shown in Figure 6.9.
61
6.3 Economic Impact of Wind Integration on PFC Chapter 6
Table 6.3: Generator data including power generation PGen, machine base Mbase,ramp rate ci and plant type
BusNo.
PGen[MW]
Mbase[MVA]
ci[MW/s]
Planttype
1012 400 800 5.3 Hydro
1013 300 600 4 Hydro
1014 550 700 4.7 Hydro
1021 400 600 4 Hydro
1022 200 250 1.7 Hydro
1042 360 400 1.6 Thermal
1043 180 200 0.8 Thermal
2032 750 850 13 Hydro
4011 451 1000 6.7 Hydro
4012 500 800 5.3 Hydro
4021 250 300 2.2 Hydro
4031 310 350 2.8 Hydro
4041 0 300 2.8 Hydro
4042 630 700 2.4 Nuclear
4047 540 600 2.8 Nuclear
4051 400 700 2.4 Nuclear
4062 530 600 2.8 Coal
4063 530 600 2.4 Coal
4071 300 500 3.3 Hydro
4072 2000 4500 30 Hydro
18-8PMEC8 1012[BUS10128 130.00]18:8gop
Time8(seconds)1009080706050403020100
0.58
0.57
0.56
0.55
0.54
0.53
0.52
0.51
0.5
0.49
ci
Pm
ech8[p
u]
Figure 6.9: Calculating the ramp rate ci as the slope of the mechanical power overtime
62
6.3 Economic Impact of Wind Integration on PFC Chapter 6
6.3.3 Wind Integration
The wind turbines which are modeled as DFIGs of type GE 1.5 MW have the same dy-
namic model as in the previous Section. They are integrated in the identified Nordic 32-A
system where HYGOV2 and IEEEG1 governors are employed, having ramp rate capa-
bilities. In each wind park, 300 identical wind turbines are lumped together. The outage
of one of the large machines on bus 1014 is applied and a number of simulations have
been performed. The system inertia MH is calculated for every wind generation level
making use of equation (2.35), and also the frequency Nadir is determined.
6.3.4 Optimal Power Flow formulation With PFC adequacy Constraints
The cost increase for maintaining adequacy of the PFC operation in the presence of
wind can be calculated by solving following Optimal Power Flow problem as explained
in Chapter (4):
Minimize∑
i∈Iei(Pi) +
∑i∈I,i 6=l
si(Ri) (6.2)
Subject to: ∑i∈I
Pi =∑
j∈Jdj (6.3)
∑i∈,i 6=l
Ri ≥ Pl (6.4)
Ri ≤ 2ciMH(f0 − fmin − fdb)
Pl, i ∈ I, i 6= l (6.5)
− Lk ≤∑i∈I
Hik(Pi − di) ≤ Lk, k ∈ K (6.6)
0 ≤ Ri ≤ Rmaxi , i ∈ I, i 6= l (6.7)
Pi +Ri ≤ Pmaxi , i ∈ I (6.8)
Pi, Ri ≥ 0, i ∈ I (6.9)
ei(Pi) is the energy cost function of generator i, si(Ri) is the reserve cost function of
generator i, Pi is the active power generated by generator i, dj is the active power,
attached as a load to bus j, Ri is the reserve capacity of generator i for the PFC, Lk
is the thermal limit of line k and Hik is element (i, k) of PTDF -matrix H. Pl is the
amount of the contingency and occurs at bus l, MH is the system inertia, f0 the rated
63
6.3 Economic Impact of Wind Integration on PFC Chapter 6
frequency, fmin is the minimum acceptable frequency and fdb is system governor’s dead-
band. The superscripts max and min indicate the maximal and minimal values of the
considered quantities.
The objective is to minimize the generation and the reserve cost. Equation (6.4) and
(6.5) are sufficient and necessary conditions for adequate PFC operation in the grid;
Equation (6.4) states that the total reserve should be larger than the largest possible
power loss and equation (6.5) ensures to deploy these reserves before the time instant
that the frequency Nadir occurs. Equation (6.3), (6.6)-(6.9) are the usual DC power
flow equations.
6.3.4.1 Validation of the DC Power Flow equations
A DC power flow based on equations (6.2), (6.6), (6.8), (6.3) and (6.9) with quadratic
fuel cost functions was set up to test the correctness of the implementation. The power
flow was tested on the 14-bus test system case14 of which the data can be found in the
files accompanying any Matpower distribution [57].
The following Matpower commands realize this:
define_constants;
mpc = loadcase(’case14’);
opt = mpoption;
opt.model = ’DC’;
opt.pf.alg = ’NR’;
opt.pf.tol = 1e-6;
opt.pf.max_it = 50;
opt.pf.enforce_q_lims = 1;
[result,success] = rundcopf(mpc, opt);
64
6.3 Economic Impact of Wind Integration on PFC Chapter 6
The total cost is 7642.59 $/h. Then, implementing a standard Economic Dispatch OPF
in GAMS, using equations (6.2), (6.6), (6.3), (6.8) and (6.9), with the KNITRO NLP
solver, a total cost of 7642.594 $/h was found, which is the same as in Matpower.
Inspecting the dispatched generation powers returned by GAMS and the power flows
over all the lines, exactly the same values in the Matpower results is found. Therefore
the implementation of the DC power flow in GAMS is validated.
6.3.4.2 Calculating the Total Cost Difference
The OPF with equations (6.2)-(6.9) including the PFC adequacy constraint was pro-
grammed in GAMS and executed on the identified Nordic 32-A test system. For ana-
lyzing the cost increase for maintaining adequacy in the presence of wind power, two
scenarios will be investigated. For the first scenario, constraints (6.4) and (6.5) are in-
cluded in the OPF. In contrast, in the second scenario, the constraint on the governor
ramping rate is not included in (6.2). The difference in generation cost between these
two scenarios will be the cost for enforcing the adequacy of the PFC operation. The
assumptions made, are:
• The load will not change in different scenarios, also the role of the loads, also
providing inertia, in the PFC is not investigated,
• The system governor’s dead-band is 50 mHz [31],
• fmin is considered to be 49.4 Hz [31],
• The coefficients of the quadratic generator cost functions and the thermal limits
of the transmission lines are taken from [58],
• The maximum primary reserve Rmaxi is 30 % of the installed capacity of the gen-
erators Pmaxi [59],
• The wind speed remains constant during the simulations,
• The reserve costs and the wind generation marginal costs are assumed to be zero.
The methodology is illustrated with the flowchart of Figure 6.10. First the PSS/E data
of Nordic32-A should be converted into Matlab Matpower format as follows:
65
6.3 Economic Impact of Wind Integration on PFC Chapter 6
SimulationVofVmodifiedNordicV32VtestVsystemVin
PSS/ETVusingVIEEEG1VandHYGOV2VforVgovernorVofthermalVandVhydroVunits
PreparingVPFCDOPFinVGAMS
IntegratingVwindVparksVintoVtheNordicV32VtestVsystemVinVPSS/EVandVcalculatingV
frequencyVNadirVandVMHforVdifferentVwindVlevels
OPFVwithout PFCVadequacy
EconomicVdispatchTdeterminingVgenerationT
reservesVandVtotalVgenerationcost
TotalVGenerationVCostVDifference
IdentificationVofVdynamicVparametersofVmodifiedVNordicV32VtestVsystem
utilizingVrealVcontingencyVdata
ScenarioV1 ScenarioV2
cost cost
CalculatingVrampVratesVasrisingVslopeVofVmechanical
powerVofVeachVmachineVasVafunctionVofVtimeVafterVapplying
aVlargeVcontingency
OPFVwith PFCVadequacy
EconomicVdispatchTdeterminingVgenerationT
reservesVandVtotalVgenerationcost
Figure 6.10: Method to determine the change in generation cost when the PFCadequacy constraints are imposed
66
6.3 Economic Impact of Wind Integration on PFC Chapter 6
filename = ’Nordic32.raw’;
mpc = psse2mpc(filename);
savecase(’nordic32.m’, mpc);
The power base is 100 MVA. nordic32.m contains the bus, generator and branch
data (Section 5.3). The generator cost data is taken from [58] and also included in
nordic32.m. Also the ramp rates of each generator, calculated in Section 6.3.2, are
added to the generator data section. Finally the line flow rates are added to the branch
data part of nordic32.m and also the table of with the wind integration data is added
to this file.
Another Matlab file is made. It is called main_file.m and is used to load the data of
nordic32.m and running the OPF in GAMS. The following elements are first calculated
in the main_file.m, and expressed in per unit if they are voltages, powers or impedances
or admittances. They are to be imported in GAMS:
• i, the set of the bus indices.
• l, the set of the line indices.
• r_l, the vector containing the active load.
• lin_li, the vector containing the line limits (active power limit).
• H, the PTDF matrix.
• Pmax, the vector containing the maximum active power of the generator.
• ramp_rate, the vector containing the ramp rates of generators.
• gen_cost, a matrix containing the three cost coefficients for a quadratic fuel cost
function in its columns. The first column contains the constant coefficient, the
second column the coefficient of the linear term and the third column the coefficient
of the quadratic term.
• M_H, the scalar containing the inertia.
• f_db, the scalar containing the frequency dead-band.
67
6.3 Economic Impact of Wind Integration on PFC Chapter 6
• P_L, the scalar containing the contingency.
• wind, the scalar containing the amount of wind.
The form in which these vectors are specified is the following: they have nb rows where
nb is the number of buses and each row corresponds with a particular bus.
Previous matrices and vectors are encapsulated in a struct in Matlab as follows (for
instance for lin_li):
lin_li=struct(’name’,’lin_li’,’type’,’parameter’,’val’,line_lim,’form’,’full’);
In Matlab, the data element was called line_lim, and this will be sent to GAMS as
line_li. For sets, such as the set i, the struct should be constructed differently. The
type-field should have the value set:
N=struct(’name’,’i’,’type’,’set’,’val’,[linspace(1,nb,nb)]’);
Next, these structs are stored in a GDX-file opt_mod_wgdxcall_data.gdx with
wgdx(’opt_mod_wgdxcall_data’,N,M,r_l,lin_li,H,Pmax,ramp_rate,
gen_cost,M_H,f_db,P_L,wind);
The content of the GDX-file is imported into GAMS with the commands
$gdxin opt_mod_wgdxcall_data
$load i l r_l lin_li H Pmax ramp_rate gen_cost M_H f_db P_L wind
$gdxin
The parameter Rmax, the scalar of the rated frequency f0 and the minimum frequency
fmin are declared in GAMS as:
parameter
Rmax(i) maximum GR of generator i;
Rmax(i) = 0.3*Pmax(i,’1’);
68
6.3 Economic Impact of Wind Integration on PFC Chapter 6
scalar f0 normal frequency
/50/;
scalar fmin nadir frequency
/49.4/;
The GAMS file is called PFC-OPF.gms. The KNITRO-solver for NLP-problems was
used due to the quadratic cost function. The GAMS code for the OPF to calculate the
cost difference can be found in Appendix D.
In order to calculate the frequency Nadir when PFC adequacy constraints are imposed,
the overall ramping capability is needed. The overall ramping capability of the system
is the sum of the ramping rates of the individual units with the governor in service [14].
Then, the frequency Nadir is calculated for every level of wind integration as (see 4.14):
fNadir = f0 − fdb −1
MH(P 2l
2C) (6.10)
Where f0 is the rated frequency and fdb is the dead-band frequency.
6.3.5 Simulation Results
After performing the simulation, the economic dispatch of the generation Pi and the
reserves Ri are found as well as the cost of the generation and the number of responsive
units providing reserves. The values of the frequency Nadir for both scenarios and the
inertia MH are shown for different levels of wind power production in Table 6.4. It can
be seen that with increasing wind power, the amount of system inertia MH and the
frequency Nadir are declining (Figure 6.11).
Additionally, the number of responsive units providing reserve is shown for both scenarios
in Table 6.5. It is clear that the number of responsive units is increasing for both
scenarios. However in scenario 1, the numbers rise more significantly from 12 to 18
units while in scenario 2 the increase is from 9 to 11 units. However, the value of the
reserve of each unit diminishes, because with more wind, there is less inertia, and thus
less primary reserve will be needed for an adequate PFC according to equation 6.5.
Note that (6.5) is a constraint on each unit i, so this constraint restricts how large the
contribution of unit i to the total reserve is. For the first scenario, we can say that due
to the fixed value of the contingency for every wind level, the sum of the reserves is also
69
6.3 Economic Impact of Wind Integration on PFC Chapter 6
fixed and is equal to Pl.
The impact of wind integration on the total generation cost is shown for both
0
1000
2000
3000
4000
5000
6000
7000
0
1000
2000
3000
4000
5000
6000
0 500 1000 1500 2000 2500 3000
Co
st D
iffe
ren
ce (
$/h
)
MH
(MW
s/H
z)
Wind (MW)
Cost difference
Inertia MH
Figure 6.11: Inertia and cost difference when wind is integrated in the system
Table 6.4: Effect of wind integration on the system inertia and the frequency Nadir
Wind Inertia Freq. Nadir Freq. NadirLevel MH Without PFC With PFC(MW) (MWs/Hz) Const. (Hz) Const. (Hz)
0 4887 49.4295 49.5979
600 4409 49.3988 49.5597
1200 3804 49.3603 49.4976
1800 3419 49.2113 49.4467
2400 3301 49.1752 49.4287
3000 3007 49.1360 49.4097
Table 6.5: Effect of wind integration on the number of responsive units
Wind Resp. Units Resp. UnitsLevel Without PFC With PFC(MW) Const. Const.
0 9 12
600 9 14
1200 9 15
1800 11 17
2400 11 17
3000 11 18
scenarios in Table 6.6. Figure 6.11 shows how the cost difference rises with an increasing
integration of wind turbines. As it can be seen from Table 6.6, with no wind power, the
OPFs with PFC constraints and without PFC constraints yield different dispatch costs.
The cost difference between these two cases is the cost of the PFC adequacy constraints.
70
6.3 Economic Impact of Wind Integration on PFC Chapter 6
In other words, the PFC adequacy constraints limit the feasible set of solutions and this
in turn leads to higher dispatch costs.
Table 6.6: Effect of wind integration on the dispatch cost
Wind Total Cost Total Cost CostLevel Without PFC With PFC Difference(MW) Const. ($/h) Const. ($/h) ($/h)
0 295261 295897 636
600 277143 278096 953
1200 261235 262362 1127
1800 247346 248711 1365
2400 234324 235925 1601
3000 221900 224340 2440
6.3.6 Summary
The primary frequency reserve of a power plant is related to the ramp rate of this plant.
Therefore, for each generator in the Nordic 32-A system a governor with ramp rate
capability has been chosen. HYGOV2 governors were chosen for the hydro plants, and
IEEEG1 governors for the thermal plants. Because we changed the grid, we again need
to determine the dynamic parameters of the system. Next, the ramp rates of the gov-
ernors are calculated by performing a stress test. An increasing amount of wind power
was integrated in the identified model and its effect on the frequency Nadir and on the
system inertia was investigated. The simulation results show a reduction in inertia and
also a deterioration of the frequency Nadir when more and more wind is integrated into
the grid. Therefore, there is a need for considering extra constraints to ensure adequacy
of the PFC operation. To analyze the cost of considering these new constraints, two
scenarios are investigated: the first scenario considers the PFC adequacy constraints
and the second scenario does not. The PFC-OPF is modeled in GAMS and the cost of
wind integration is investigated. The simulation results show that the consideration of
these new constraints leads to a higher dispatch cost (Table 6.6).
71
Chapter 7
Conclusions and Future Work
7.1 Conclusions
This thesis has studied the technical and economic impacts of the integration of large
amounts of wind on the power system’s frequency stability, and particularly on primary
frequency control when there is a mismatch between load and generation. This work
proposed a method and algorithm for studying the effect of wind integration on the
primary frequency control for the Nordic 32-A grid, representing the Swedish grid. The
method can however be used for other power systems as well.
First, in this work the concepts of primary frequency control (PFC) as well as the two
metrics ROCOF and frequency Nadir were discussed. The requirements for primary
frequency response in some interconnections such as NORDEL and Sweden were stud-
ied. Based on the Nordic grid code, the requirements of an adequate PFC operation for
Sweden as part of NORDEL were specified as follows: the ROCOF magnitude should
not be larger than 0.5 Hz/s and the frequency Nadir must be above 49.4 Hz.
In order to study the technical impact of increasing levels of wind capacity, the Nordic
32-A System, representing a scaled version of the Swedish grid, is implemented in PSS/E.
Before wind is integrated into the grid, the center-of-inertia-frequency of the Nordic 32-
A grid is calculated with this model in PSS/E. There was a significant difference with
the measured frequency response after a contingency occurred in NORDEL. Therefore,
an ad-hoc identification of model parameters with actual data has been set up. In order
to do the identification, the power system analysis software PSS/E has been automated
with the Python psspy module.
72
7.1 Conclusions Chapter 7
Calculations are performed in Matlab, which calls Python to execute PSS/E. The in-
ertia constants H of the generators, the droop constants and time constants of the
governors are sought by adjusting them until the simulated center-of-inertia-frequency
of the Nordic 32 -A system matches the real data. After identification, wind turbines
of type GE 1.5 MW were integrated in the identified model and their effect on the two
metrics of primary frequency control, the ROCOF and frequency Nadir, were investi-
gated. The simulation results show an increase in the ROCOF magnitude and also a
deterioration of the frequency Nadir when more and more wind is integrated into the
grid. There were no major concerns associated with the ROCOF, but in the case of
the Nadir, the system was unable to maintain the frequency above 49.4 Hz for a wind
generation of about 12.8 GW or higher.
Some assumptions and simplifications in this first part are the following: The load will
not change in the different scenarios while in reality, the load changes constantly. Also,
it was assumed that the wind speed remains constant during the simulations. Another
assumption is that the integration of wind is assumed to replace existing thermal units
and the generation of the replaced generators is equal to the value of the wind genera-
tion. Finally, this work uses the built-in wind turbine models of PSS/E which can not
be changed or modified extensively.
Although wind turbines can provide a frequency response to maintain adequacy, such a
frequency response requires that the turbine does not operate at the maximum power
point. The reason for this is that if the frequency drops, the turbine cannot increase its
power output unless the turbine is operating below the maximum power point. If not
transformed immediately into electricity, wind energy is lost, so any operating condition
below the maximum power point represents a lost opportunity cost.
For the second part of the thesis, an optimal power flow (OPF) is designed with objec-
tive function of minimizing the generation cost. The frequency control system needs to
have capacity over primary reserves (PR) to regulate the load-generation balance after a
contingency occurs. Primary reserves are defined as the capacity of generators that are
reserved for governors to be used by the PFC. The PFC adequacy is explained before
and depends on the inertia and the ramping capability of the governors. Therefore, it
was necessary to add a constraint to the OPF about the governor response so that it can
guarantee PFC adequacy. There are two conditions: first the sum of the reserves should
be larger than the largest possible loss and the second condition is that the primary
reserves should be delivered before the time instant the Nadir frequency occurs.
73
7.2 Future Work Chapter 7
First, governors with ramp rates capability are considered for all the generators in the
Nordic-32 system. The governors HYGOV2 (for hydro plants) and IEEEG1 (for thermal
power plants) were taken and system identification is performed a second time to match
the real data with the simulations. The ramp rates of each governor were calculated by
performing a ’stress test’ in such a way that the mechanical power is recorded versus
time, after the biggest contingency in the grid occurs. The rising flank of this curve is
the ramp rate. For analyzing the cost increment of maintaining adequacy in the presence
of elevated levels of wind power, two scenarios were studied; the first scenario considers
the PFC constraints, while the second scenario does not include any PFC adequacy
constraints. The generation cost difference between these two scenarios is the cost of
the PFC adequacy constraint. The simulation shows that with an increasing capacity of
the installed wind turbines, the consideration of the PFC adequacy constraints increases
the generation cost.
The economic dispatch of the generators, the reserves and the cost of the generation
as well as the number of responsive units providing reserves are found when the PFC-
constrained OPF was solved. The values of the frequency Nadir and inertia were found,
in function of the level of wind penetration. It can be seen that with an increasing
amount of wind in the system, the inertia is declining. The frequency Nadir is also de-
clining. Also the number of responsive units, providing reserve in both scenarios (with
and without PFC adequacy constraints) were shown. It is shown that with increasing
levels of wind in the system, the reserves are distributed among more generators. On
the other hand, the amount of reserve of each unit diminishes because with more wind,
there is less inertia, and less reserve will be needed for PFC adequacy.
The simulation results show a reduction in the system inertia and also a deterioration
of the frequency Nadir after integrating more and more wind into the grid. Therefore,
there is a need for considering the extra constraints to ensure adequacy of the PFC.
However, the consideration of these new constraints leads to a higher dispatch cost.
This work proposes a method and algorithm for studying the effect of wind integra-
tion on primary frequency control. It uses Nordic 32-A as a test grid, representing the
Swedish grid, but can be used for other grids as well.
74
7.2 Future Work
Some ideas for doing future research, are:
• Improving the ad-hoc identification process by including more actual data of the
frequency response after sudden losses of generation. Also system identification
techniques with optimization methods can be considered.
• Considering other control strategies for the frequency response of wind turbines
such as synthetic inertia,
• Including a model for a responsive load in the PFC-OPF formulation,
• Design of an ancillary service market including an adequacy assessment to repre-
sent the opportunity cost of wind turbines providing frequency response,
• Calculating the grid inertia endogenously in the OPF. In the proposed work, the
inertia of the grid needs to be exogenously calculated using the PSS/E software.
• Study the market signals or regulated frameworks to provide the PFC service when
it is needed. The current work only proposes an algorithm to predict the wind
integration level which causes PFC inadequacy.
75
Appendix A
Implementing the Nordic 32-A
Test System in PSS/E
In this part the procedure of running a power flow analysis, a dynamic simulation and
how to integrate wind in the grid in PSS/E, will be presented.
A.1 Developing Nordic 32-A test System
• Start PSS/E from the Windows Start menu ⇒ Select Programs > Siemens PTI
> PSSE33 > PSSE,
• Create a new network ⇒ Menu Bar > File > New > Network case and Diagram
> click OK,
• The window “Build New Case” appears ⇒ Set Base MVA to 100 MVA and Base
Frequency to 50 Hz > click OK,
• There are tabs to choose from at the bottom of the Network data, each tab can be
accessed by clicking on it. Enter all the data of the buses, branches, transformers,
generators, loads and fixed shunts according to [50] and modification explained in
Section 5.3. Make sure to have at least one slack bus in the grid. In this work,
bus 4011 is the slack bus, having a bus code of 3,
• Save the file as a Power Flow Raw Data File (by .raw extension) or as a Saved
Case File (by .sav extension) ((Nordic32.raw)).
76
A.2 Power Flow
• Go to the Menu Bar > Power Flow > Solution > Solve,
• The window “Loadflow solutions” will appear ⇒ Go to the tab “Newton” > Con-
figure the window to match the one shown in Figure A.1,
Figure A.1: Loadflow solutions
• Then click on button “Solve” and then “Close”.
A.3 Dynamic Simulation
The dynamic simulation consists of following steps:
1. Basic setup:
• Go to the Menu Bar > Power Flow > Convert Loads and Generators,
77
• The window “Convert/Reconstruct Loads and Generators” will appear ⇒
Configure the window to match the one shown in Figure A.2 and click on the
button “Convert”. Activities CONL and CONG convert loads and generators
from pure constant to Norton equivalents [35]. The parameters in the Table
A.1 are used for converting the load in this work for all the simulations.
They signify the percentages of modeling the loads as a constant admittance,
current source and power flow,
Figure A.2: Convert/Reconstruct Loads and Generators
Table A.1: Load conversion
Convert constant MVA Active power Reactive power
Constant current 50 50
Constant admittance 25 25
Constant power 25 25
• Go back to the Menu Bar⇒ Power Flow > Solution > Solution for switching
studies (TYSL). The window “solution for Switching Studies” will be dis-
played. Select the solution options “Use voltage vector as start point” and
“Factorize before performing solution (FACT)”. Then click on OK. Activ-
ity TYSL is used to solve the load flow for switching and dynamic studies
78
and activity FACT factorizes the network admittance matrix for dynamic
simulations [35].
2. Preparing dynamic data file (dyr-file)
The Dynamic Data File contains general data, generator data, exciter data, and
governor data, and all the other data necessary to perform a dynamic simulation.
The following steps are needed to make an dynamic data file (dyr-file):
• Open the Notepad program ⇒ File > New > Save As > Name it and save
it as type .dyr: (dynamicdata.dyr). Each equipment record in a dyr-file has
the following general format [35]:
′BUSID′ ′model name′ ′data list′
Here, BUSID indicates the bus number at which this equipment model is to
be placed, model name is the name of the model and data list consists of the
constant parameters associated with the model. The dynamic parameters of
the generator models can be found in Chapter 1 of [53]. Also, the parameters
for the stabilizer and the excitation system models are provided in Chapter 3
and Chapter 6 of [53]. Chapter 7 of [53] provides a description of the dynamic
parameters for the Turbine governor models. Figure A.3 is an example of a
dyr-file.
Bus Number Generator type for hydro plant
Governor for hydro plants
Stabilizer model
Excitation model
Generator type for thermal power
plants
Figure A.3: An example of a dyr-file for a hydro and thermal power plant
79
• Go to the menu bar > File > Open and then choose the dyr-file dynamic-
data.dyr. The window “Read Raw Format Dynamics Data” will appear. Click
on OK. The dynamic data spreadsheet will be opened (Figure A.4).
Figure A.4: The dynamic data spreadsheet
3. Performing a dynamic simulation
• Go to the Menu Bar > Dynamics > Define simulation output (CHAN) >
Machine quantities,
• The window “Assign Channels for Machine Quantities” will appear. Click
on the button “Select” and select the machine currently under consideration
and click on OK,
• Select “Speed” in the cell for the “Machine quantity” and click on the button
“Go” as shown in Figure A.5,
• Go back to the Menu Bar > Dynamics > Simulation > Perform simulation
(STRT/RUN),
• The window “Perform Dynamic Simulation” will appear. Type “gop.out” in
the “Channel output file” part. Click on the button “Initialize” as shown in
Figure A.6. This is called the activity ”STRT” which calculates the initial
values of all variables and states for each equipment model as a function of the
model’s constant data and the boundary condition at the bus in the working
case at which it is referenced [35]. The message “INITIAL CONDITIONS
CHECK O.K.” should be displayed in the Output Bar.
80
Figure A.5: Assign Channels for Machine Quantities
Figure A.6: Initialization of the dynamic simulation
• Change the simulation time to zero and click once on the button “Run”. Then
click on the button “Close”. It is suggested in [35] that after one performs
the activity STRT, one must execute the activity RUN for some period of
simulation time without applying any disturbance.
4. Applying a contingency
• Go to the Menu Bar > Disturbance > Disconnect machines,
• The window “Disconnect a Machine” will be displayed. Select the machine
that should be disconnected, then click on OK.
• Go back to the Menu Bar > Dynamics > Simulation > Perform simulation
(STRT/RUN). Change the simulation time, click on the button “Run”, and
then close the window.
81
Figure A.7: Channel plot
5. Plot the output of the simulation
Go to the Menu Bar > File > Open > select the gop.out file that is created before.
An empty channel plot will appear as can be seen in Figure A.7. Click on the
“Channel Files” in the “Plot Tree View” and then click on “gop”. Next, click on
the figure of the quantity one wishes to display and drag it into the channel plot
area. Figure A.8 shows an example where the speed is shown versus the time for
machine 1012, after machine 1014 is tripped at a simulation time of 20 seconds.
A.4 Wind Integration
The type of wind turbine used in all the wind farms in this work is GE 1.5 MW. This
type is explained in Chapter 3. Typical wind farms may include tens to hundreds of
identical wind turbines and for the modeling of wind farms consisting of a large number
of wind turbines, an aggregated model is therefore necessary [33]. In this work, 300
identical wind turbines in each wind farm are clustered together and connected to a
common point. The result is a single equivalent machine.
Also in this work, an AC/AC electrical system configuration is selected and all the wind
turbines are connected radially as shown in Figure A.9 [60]. The rated values of the
parameters for a wind farm consisting of 300 lumped turbines of type GE 1.5 MW is
presented in Table A.2.
82
Figure A.8: Speed versus time for machine 1012, after tripping machine 1014
Figure A.9: The electrical system configuration for AC/AC wind farm [60]
The procedure for integrating the GE 1.5 MW wind turbine in PSS/E is presented below:
• It should be noted that a wind turbine is treated as a conventional machine[45].
The new bus for the wind turbine should be added in the tab “Bus” of the “Network
Data” spreadsheet. All the data of Table A.2 are entered into the cells in the
machine tab in “Network data”. Also in the transformer tab, there should be
included a new transformer connecting the wind turbine to one of the buses in the
grid. Next, follow the steps of Section A.3 till the second step,
• Go to the Menu Bar > Tools > Load Model library ⇒ Navigate to the folder
Program Files > PTI > PSSEWind > GEWT > v33 > gewt.dll,
83
Table A.2: Power flow data for GE 1.5 MW and a wind farm [43]
DFIG GE1.5 MW [43]
WindFarm(300lumped
turbines)
Generator ra-ting, MVA
1.67 500
Pmax, MW 1.5 450
Pmin, MW 0.07 21
Pgen, MW - 300
Xsorce, pu 0.8 0.8
Unit trans-former rating,MVA
1.5 525
Number of WTs Bus Number 0 for 1.5 MW
Figure A.10: Dynamic data file for GEWTG2
• Add in the dyr-file (dynamicdata.dyr) the information about the dynamic model
of the wind machines as shown in Figure A.10 for a GEWTG2 model (generator
model), and for a GEWTE2 model (turbine model) and a GEWTT1 model (two
mass shaft model), a GEWTA2 model (aerodynamics model) and a GEWTP2
model (pitch control model). All of the dynamic parameters are provided in Ap-
pendix B [45].
• Open the modified dyr-file including the wind machine dynamic data and follow
the second step of Section A.3. The rest of the procedure to perform a dynamic
simulation is the same as for a conventional machine.
84
Appendix B
Wind Model Parameters
Table B.1: GE Wind Turbine Electrical Control GEWTE2 [45]
Symbol Description Value
Tfv Filter time constant in voltage regulator (sec) 0.15
Kpv Proportional gain in Voltage regulator(pu) 18
Kiv Integrator gain in Voltage regulator (pu) 5
Rc Line drop compensation resistance (pu) 0
Xc Line drop compensation reactance (pu) 0
Tfp Filter time constant in Torque regulator (sec) 0.05
Kpp Proportional gain in Torque regulator(pu) 3
Kip Integrator gain in Torque regulator (pu) 0.6
Pmax Max limit in Torque regulator )pu) 1.12
Pmin Min limit in Torque regulator (pu) 0.04
Qmx Max limit in Voltage regulator (pu) 0.436
Qmn Min limit in Voltage regulator (pu) -0.436
IPmax Max active current limit (pu) 1.12
Trv voltage sensor time constant (sec.) 0.02
RPMX, maximum power order derivative (pu) 0.45
RPMN, minimum power order derivative (pu) -0.45
Tpower Power reference filter time constant, sec. 60
KQi Volt/MVAR gain 0.1
Vmincl min. voltage limit 0.9
Vmaxcl max. voltage limit 1.1
KV i Int. Volt/Term. voltage gain 40
XIQmin min. limit 0.5
XIQmax max. limit 1.45
Tv Lag in WindVar controller 0.05
85
Table B.1: GE Wind Turbine Electrical Control GEWTE2 [45]
Symbol Description Value
Tp Pelec filter in fast PF controller 0.05
Fn A portion of on-line wind turbines 1
Tpav Pavail filter time constant, sec. 0.15
FRa Frequency response curve 0.96
FRb Frequency response curve 0.996
FRc Frequency response curve 1.004
FRd Frequency response curve 1.04
PFRa Frequency response curve 1
PFRb Frequency response curve 0.95
PFRc Frequency response curve 0.95
PFRd Frequency response curve 0.4
PFRmax Max Pavail 1
PFRmin Min Pavail 0.2
Tw Power command rate limit time constant, sec. 1
T LVPL LVPL sensor, sec. 0.25
V LVPL LVPL breakpoint -1
SPDW1 Initial arbitrary wind speed, m/sec 14
SPDWMX max. wind speed, m/sec. 25
SPDWMN min. wind speed, m/sec. 3
SPD LOW Low rotor speed to trip WTG -0.9
WTTHRES High wind trip threshold 8
EBST Braking resistor energy threshold 0.2
KDBR Braking resistor controller gain 10
Pdbr MAX Breaking resistor power error max limit 1
ImaxTD converter current limit 1.7
Iphl Hard active current limit 1.12
Iqhl Hard reactive current limit 1.25
TIpqd Reactive droop time constant 5
Kqd Reactive droop gain 0
Xqd Reactive droop Synthesizing Impedance 0
Kwi WindInertia Gain 0
dbwi WindInertiadeadband 0.0025
TIpwi WindInertia filter time constant 1
Twowi WindInertia washout time constant 5.5
urIwi WindInertia up ramp rate limit 0.1
drIwi WindInertia down ramp rate limit -1
Pmxwi WindInertia maximum additional power 0.1
Pmnwi WindInertia minimum additional power 0
86
Table B.1: GE Wind Turbine Electrical Control GEWTE2 [45]
Symbol Description Value
Vermx Reactive power control maximum error signal 0.1
Vermn Reactive power control minimum error signal -0.1
Vfrz Reactive power control freeze voltage 0.7
QmxZP Qmax limit in Zero Power Mode 0.12
QmnZP Qmin limit in Zero Power Mode -0.12
Table B.2: GE Wind Turbine Generator/Converter GEWTG2 [45]
Symbol Description Value
Prate Rated power of the original unit, MW 1.5
Xeq Equivalent reactance for current injection, pu on MBASE 0.8
JVLVPL1 LVPL voltage 1 0.5
VLVPL2 LVPL voltage 2 0.9
GLVPL LVPL gain 1.22
VHVRCR2 HVRCR voltage2 1.2
CURHVRCR2 max reactive current at VHVRCR2 2
VLVACR1 Low voltage active current regulation logic, voltage 1 0.4
VLVACR2 LVACR logic, voltage 2 0.8
Rip LVPL Rate of LVACR active current change 10
T LVPL voltage sensor for LVACR time constants 0.02
LVPL 1st voltage point 0.0
LVPL 1st power point 0.0
LVPL 2nd voltage point 0.5
LVPL 2nd power point 0.167
LVPL 3rd voltage point 0.9
LVPL 3rd power point 0.925
IQCMD Impedance for Changing IQCMD to Voltage Signal 0.0
Table B.3: Two Mass Shaft GEWTT1 [45]
Symbol Description Value
H total inertia of the drive train, MW*sec/MVA 4.94
DAMP machine damping factor, p.u. P/p.u. Speed 0
Htfrac turbine inertia fraction (Hturb/H) 0
87
Freq1 first shaft torsional resonant frequency, Hz 1.88
DSHAFT shaft damping factor 2.3
Table B.4: GE Pitch Control GEWTP2 [45]
Symbol Description Value
Tp Time constant of the output lag (sec) 0.3
Kppt Proportional gain of PI regulator (pu) 150
Kipt Integrator gain of PI regulator (pu) 25
Kpc Proportional gain of the compensator (pu) 3
Kic Integrator gain of the compensator (pu) 30
θmin Lower pitch angle limit (degrees) -4
θmax Upper pitch angle limit (degrees) 27
dθ/dt min Lower pitch angle rate limit (degrees/sec.) -10
dθ/dt max Upper pitch angle rate limit ( degrees/sec.) 10
Pref power reference 1
Table B.5: GE Wind Turbine Aerodynamics GEWTA2 [45]
Symbol Description Value
λmax Max. Lambda from Cp curves 20.0
λmin Min. Lambda from Cp curves 0.0
PITCHMAX Upper limit of pitch angle 27.0
PITCHMIN Lower Limit of pitch angle -4.0
Ta time constant of the conversion smoothing 0.0
ρ Air density, kg/m3 1.225
Radius Blade radius, m 35.25
GBratio Gear box ratio 72.0
Synchr Synchronous rpm 1200.0
88
Appendix C
Matlab and Python Code for
Identification of Section 6.3
In this Appendix, all the Matlab and Python codes related to the identification method
explained in Section 6.3 are provided. First a Matlab file of main-identification.m
was written which run: 1- a Matlab file changeHsAndRAndTInDyrFile.m, 2- a Python
file dynamic-simulation.py, 3- a Python file exporttotxtfile.py and finally 4- a
Matlab file (processtxtfile.m).
1. main-identification.m
clear;
clc;
H1_vec = [0.5:2:10];
H2_vec = [0.5:2:10];
H3_vec = [0.5:2:10];
% HYGOV2 and IEEEG1 parameters
R1_vec = 0.083;
R2_vec = 0.1540;
Kp_vec = 1;
Ki_vec = 0;
KA_vec = 0.03;
T1_vec = 0.01;
T2_vec = 15.5;
T3_vec = 0.1;
T4_vec = 0.07;
T5_vec = 2;
T6_vec = 0.8;
Tr_vec = 0.95;
89
r_vec = 0.36;
VGmax_vec= 0.172;
Gmax_vec = 1;
Gmin_vec = 0;
T3i_vec = 0.1;
T4i_vec = 0.1;
U0_vec =0.0066;
Uc_vec = -0.008;
M = [];
count = 0;
for a = 1:length(H1_vec)
H1 = H1_vec(a);
.
.
.
count = count + 1;
% Make a new dyr file with the new H, R and T-values
changeHsAndRAndTInDyrFile(H1, H2, H3, R1, R2, Kp, Ki, KA, T1, T2, T3,
T4, T5, T6, Tr, r, VGmax, Gmax, Gmin, T3i, T4i, U0, Uc);
% run the dynamic simulation
! C:\Python27\python.exe dynamic_simulation.py
% export the simulation channel data to a text file
! C:\Python27\python.exe exporttotxtfile.py
% process the text file and calculate a goodness-of-fit number
processtxtfile
% save this goodness-of-fit number
M = [M; H1, H2, H3, R1, R2, Kp, Ki, KA, T1, T2, T3, T4, T5, T6, Tr, r,
VGmax, Gmax, Gmin, T3i, T4i, U0, Uc, int_of_squared_error];
end
[y,ind]=min(abs(M(:,end)));
M(ind, :)
2. changeHsAndRAndTInDyrFile.m
function changeHsAndRAndTInDyrFile(H1, H2, H3, R1, R2, Kp, Ki, KA, T1,
T2, T3, T4, T5, T6, Tr, r, VGmax, Gmax, Gmin, T3i, T4i, U0, Uc)
[fid, message] = fopen(’dynamic_data.dyr’, ’w’);
line = [’1012 ’’GENSAL’’ 1 5.0000 0.50000E-01 0.10000’, ’\t’, num2str(H2),
’\t’, ’0.0000 1.1000 0.70000 0.25000 0.20000 0.15000
90
0.10000 0.30000 /\r\n’];
count = fprintf(fid,line);
line = [’1012 ’’STAB2A’’ 1 1.0000 4.0000 1.0000 2.0000
0.30000 1.0000 0.50000E-01 0.50000E-01/\r\n’];
count = fprintf(fid,line);
line = [’1012 ’’SEXS’’ 1 0.20000 20.000 50.000 0.10000
0.0000 4.0000 /\r\n’];
count = fprintf(fid,line);
line = [’1012 ’’HYGOV2’’ 1’, ’\t’, num2str(Kp), ’\t’, num2str(Ki),’\t’,
num2str(KA), ’\t’, num2str(T1), ’\t’, num2str(T2), ’\t’, num2str(T3),’\t’,
num2str(T4), ’\t’, num2str(T5), ’\t’, num2str(T6), ’\t’, num2str(Tr),’\t’,
num2str(r), ’\t’, num2str(R1), ’\t’, num2str(VGmax), ’\t’, num2str(Gmax),’\t’,
num2str(Gmin), ’\t’, ’0.85’, ’/\r\n’];
count = fprintf(fid,line);
.
.
.
line = [’0 ’’LDFRAL’’ * 0.75000 0.0000 0.75000 0.0000 /\r\n’];
count = fprintf(fid,line);
fclose(fid);
3. dynamic-simulation.py
import os,sys
PSSE_LOCATION = r’C:\Program Files\PTI\PSSE33\PSSBIN’
sys.path.append(PSSE_LOCATION)
os.environ[’PATH’] = os.environ[’PATH’] + ’;’ + PSSE_LOCATION
import psspy
import redirect
redirect.psse2py();
psspy.psseinit(800);
psspy.read(0,r"""C:\Documents and Settings\nfarrokh\Nordic32.RAW""")
psspy.base_frequency( 50.0)
psspy.fnsl([0,0,0,1,1,0,99,0])
psspy.cong(0)
psspy.conl(0,1,1,[0,0],[ 50.0, 25.0, 50.0, 25.0])
psspy.conl(0,1,2,[0,0],[ 50.0, 25.0, 50.0, 25.0])
psspy.conl(0,1,3,[0,0],[ 50.0, 25.0, 50.0, 25.0])
psspy.fact()
psspy.tysl(0)
psspy.rawd_2(0,1,[1,1,1,0,0,0,0],0,r"""C:\Documents and Settings\nfarrokh\
Nordic32.raw""")
psspy.dyre_new([1,1,1,1],r"""C:\Documents and Settings\nfarrokh\dynamic_data.dyr
""",r"""cc""",r"""ct""","")
91
psspy.machine_array_channel([1,7,1012],r"""1""","")
.
.
.
psspy.machine_array_channel([22,7,4072],r"""1""","")
psspy.strt(0,r"""gop.out""")
psspy.change_channel_out_file(r"""gop.out""")
psspy.run(0,0.0,1,1,0)
psspy.dist_machine_trip(1014,r"""1""")
psspy.change_channel_out_file(r"""gop.out""")
psspy.run(0, 80,1,1,0)
4. exporttotxtfile.py
import os,sys
PSSE_LOCATION = r’C:\Program Files\PTI\PSSE33\PSSBIN’
sys.path.append(PSSE_LOCATION)
os.environ[’PATH’] = os.environ[’PATH’] + ’;’ + PSSE_LOCATION
import psspy
import redirect
import dyntools
redirect.psse2py();
chnfobj = dyntools.CHNF(r"""C:\Documents and Settings\nfarrokh\gop.out""")
chnfobj.txtout(channels=[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22],
txtfile=’outfile.txt’)
5. processtxtfile.m
close all
% read the text file
[t, ch1012, ch1013, ch1014, ch1022, ch1042, ch1043, ch2032, ch4011, ch4012,
ch4021, ch4031, ch4041, ch4042, ch40471, ch40472, ch40511, ch40512, ch4062,
ch40631, ch40632, ch4071, ch4072] = ...
textread(’outfile.txt’, ’%f %f %f %f %f %f %f %f %f %f %f %f %f %f %f %f %f %f %f
%f %f %f %f’,’headerlines’, 8);
SPEED_matrix = [ch1012, ch1013, ch1014, ch1022, ch1042, ch1043, ch2032,
ch4011, ch4012, ch4021, ch4031, ch4041, ch4042, ch40471, ch40472, ch40511,
ch40512, ch4062, ch40631, ch40632, ch4071, ch4072];
% store the SPEED data, multiplied with the inertia H in a big matrix
HiTimesSPEED_matrix
HiTimesSPEED_matrix = [];
for k =1:22,
SPEED = SPEED_matrix(:,k);
% 1012,1013,1014,1021,1022,2032,4011,4012,4021,4031,4071 and 4072 have H=3,
%Machine number 1042,1043,4042,4047,4051,4062,4063 have H=6,Machine number
%4041 has H=2
switch k
case 1,2,3,4,7,8,9,10,11,21,22
92
H = H2;
case 5,6,13,14,15,16,17,18,19,20
H = H3;
case 12
H = H1;
otherwise
disp(’Filename not found’);
H = 0;
end
HiTimesSPEED_matrix = [HiTimesSPEED_matrix, H*SPEED]; % the columns
%of this matrix contain the SPEED for each machine (each machine in a different column),
%multiplied with the corresponding inertia
end
% WE ASSUME THAT STEADY STATE OCCURS AFTER 80 SECONDS
% find the index in the t-vector where 80 seconds occurs: this is ind
[y,ind] = min(abs(t - 80));
% sum(Hi):
sumH = 11*H2 + 10*H3 + H1;
data_vector = sum(HiTimesSPEED_matrix/sumH, 2); % divide Hi*SPEED_i by
%sumH and sum all the columns i
% compare real data with data_vector and return a number that indicates
%the goodness-of-fit
%-----------------------------------------------------------------------
Real_steadystate = -0.0027823;
[data_Real, txt] = xlsread(’dataReal.xlsx’);
t_Real = data_Real(:,1);
d_Real = data_Real(:, 2);
d_Real_i = interp1(t_Real, d_real, t(1:ind));
% a measure for the goodness of fit is for example the integral of the
% squared error from t=0 till t=80 s:
int_of_squared_error = trapz(t(1:ind), (data_vector(1:ind) - d_Real_i(1:ind)).^2)
figure;
plot(t, Real_steadystate*ones(size(data_vector)), ’b-’, t, data_vector, ’r--’,
t_Real, d_Real, ’g-.’); xlim([0, 80]);
legend(’Real Data Steady State’, ’Center of Inertia PSSE’, ’Real Data’);
xlabel(’Time [s]’); ylabel(’Per unit frequency deviation [pu]’);
93
Appendix D
Matlab code and GAMS
Implementation of the PFC-OPF
of Section 6.3
D.1 Matlab File
close all,
clear all,
addpath ’C:\GAMS\win64\23.9’
clc,
tic,
gamso.output = ’Std’;
define_constants;
mpopt = mpoption(’VERBOSE’,0,’OUT_ALL’, 0);
%%% loading case to be considered and changing parameters as required
mpc = loadcase(nordic32);
line_lim=mpc.branch(:,RATE_A)/mpc.baseMVA;
%%% calculating system size
nb = size(mpc.bus, 1); % number of buses
ng = size(mpc.gen, 1); % number of generators
nl = size(mpc.branch, 1); % number of lines
n_wind = size(mpc.wind, 1); % number of wind farms
slack=find(mpc.bus(:,BUS_TYPE)==3); % define slack bus
94
HH = makePTDF(mpc.baseMVA, mpc.bus, mpc.branch, slack); % make PTDF
Pmaxx=zeros(nb,1);
ramp=zeros(nb,1);
cost_a = zeros(nb,1);
cost_b = zeros(nb,1);
cost_c = zeros(nb,1);
windd = zeros(nb,1);
for i=1:ng
Pmaxx(mpc.gen(i,GEN_BUS))=mpc.gen(i,PMAX);
ramp(mpc.gen(i,GEN_BUS))=mpc.gen(i,PC1);
cost_a(mpc.gen(i,GEN_BUS))=mpc.gencost(i,7);
cost_b(mpc.gen(i,GEN_BUS))=mpc.gencost(i,6);
cost_c(mpc.gen(i,GEN_BUS))=mpc.gencost(i,5);
end
for j=1:n_wind
windd(mpc.wind(j,1))=mpc.wind(j,2);
end
Pmaxx=Pmaxx/mpc.baseMVA; % convert Pmax to per unit
windd=windd/mpc.baseMVA; % convert winds to per unit
ramp=ramp/mpc.baseMVA; % convert ramp rate capability to per unit
cost_c=cost_c*mpc.baseMVA*mpc.baseMVA; % convert cost coefficient c to per unit
cost_b=cost_b*mpc.baseMVA; % convert cost coefficient b to per unit
real_load = mpc.bus(:,PD)/mpc.baseMVA; % define loads and convert it to per unit
gen_costs = [cost_a cost_b cost_c]; % generation costs
M_HH = 4887/mpc.baseMVA; % define system inertia
f_dbb = 0.05; % define dead band frequency
P_LL = 550/mpc.baseMVA; % define power loss
N=struct(’name’,’i’,’type’,’set’,’val’,[linspace(1,nb,nb)]’);
M=struct(’name’,’l’,’type’,’set’,’val’,[linspace(1,nl,nl)]’);
r_l=struct(’name’,’r_l’,’type’,’parameter’,’val’,real_load,’form’,’full’);
lin_li=struct(’name’,’lin_li’,’type’,’parameter’,’val’,line_lim,’form’,’full’);
H=struct(’name’,’H’,’type’,’parameter’,’val’,HH,’form’,’full’);
Pmax=struct(’name’,’Pmax’,’type’,’parameter’,’val’,Pmaxx,’form’,’full’);
ramp_rate=struct(’name’,’ramp_rate’,’type’,’parameter’,’val’,ramp,’form’,’full’);
gen_cost=struct(’name’,’gen_cost’,’type’,’parameter’,’val’,gen_costs,’form’,’full’);
M_H=struct(’name’,’M_H’,’type’,’parameter’,’val’,M_HH,’form’,’full’);
f_db=struct(’name’,’f_db’,’type’,’parameter’,’val’,f_dbb,’form’,’full’);
P_L=struct(’name’,’P_L’,’type’,’parameter’,’val’,P_LL,’form’,’full’);
wind=struct(’name’,’wind’,’type’,’parameter’,’val’,windd,’form’,’full’);
wgdx(’opt_mod_wgdxcall_data’,N,M,r_l,lin_li,H,Pmax,ramp_rate,gen_cost,
M_H,f_db,P_L,wind);
95
D.2 PFC-OPF GAMS File
sets
i
l Total number of lines in the system
;
parameters
r_l Load at each bus
lin_li Line limits
H PTDF matrix
Pmax Generator limits
ramp_rate Ramp rates
gen_cost Generation costs
M_H System inertia
f_db
P_L
wind
;
$gdxin opt_mod_wgdxcall_data
$load i l r_l lin_li H Pmax ramp_rate gen_cost M_H f_db P_L wind
$gdxin
parameter
Rmax(i) maximum GR of generator i;
Rmax(i) = 0.3*Pmax(i,’1’);
scalar f0 normal frequency
/50/;
scalar fmin nadir frequency
/49.6/;
positive variable
P(i) generator i dispatch
v(i) wind generator
R(i) generator i governor reserve;
variable
z total generation cost
flow(l)
;
flow.lo(l)=-lin_li(l,’1’);
flow.up(l)=lin_li(l,’1’);
R.fx(’13’)=0;
Equation
gencost
energbalance
96
totalcap(i)
reserveadequecy
nadiradequecy(i)
transmission(l)
maxreserve(i)
windlimit(i)
;
gencost..z=e=sum(i,gen_cost(i,’1’)+gen_cost(i,’2’)*P(i)+gen_cost(i,’3’)*P(i)*P(i));
energbalance..sum(i,P(i))+sum(i,v(i)) =e= sum(i,r_l(i,’1’));
transmission(l)..flow(l) =e= sum(i,H(l,i)*(P(i)-r_l(i,’1’)));
totalcap(i)..P(i)+R(i) =l= Pmax(i,’1’);
reserveadequecy..sum(i,R(i)) =g= P_L(’1’,’1’);
nadiradequecy(i)..R(i) =l= (2*ramp_rate(i,’1’)*M_H(’1’,’1’)*(f0-fmin-f_db(’1’,’1’)))
/P_L(’1’,’1’);
windlimit(i)..v(i)=l=wind(i,’1’);
maxreserve(i)..R(i)=l= Rmax(i);
Model PrimaryReserveOPF /all/;
option NLP=KNITRO;
Solve PrimaryReserveOPF using NLP minimizing z;
Display P.l,R.l,v.l,z.l;
97
Bibliography
[1] O. Edenhofer. Renewable energy sources and climate change mitigation. Cambridge
University Press, New York, 2009. ISBN 978-1-107-02340-6.
[2] M. M. Brown, N. Desai, and G. Doucet. World energy assessment: energy and the
challenge of sustainability. United Nations Development Programme, New York,
USA, 2000. ISBN 92-1-126126-0.
[3] Global wind report - annual market update 2013. Technical report, Global Wind
Energy Council, April 2014.
[4] Vindkraftsstatistik. Technical report, Energimyndigheten, 2012.
[5] G. Torn and G. Hassan. EU tradewind work package 2: wind power scenarios
WP2.1: wind power capacity data collection. Technical report, TradeWind, April
2007.
[6] P. Kundur. Definition and classification of power system stability. IEEE Transac-
tions on Power Systems, 19(2):1387–1401, MAY 2004.
[7] J. Machowski, J. W. Bialek, and J. R. Bumby. Power system dynamics: stability
and control. Wiley, West Sussex, United Kingdom, 2008. ISBN 978-0-470-72558-0.
[8] E. Elar, V. Gevorgian, A. Touhy, B. Kirby, M. Milligan, and M. O’Malley. Market
designs for the primary frequency response ancillary service- part I: motivation and
design. IEEE Transactions on Power Systems, 29(1):421–431, January 2014.
[9] Definition and classification of power system stability. Technical report, IEEE/CI-
GRE, May 2004.
98
Bibliography
[10] Use of frequency response metrics to assess the planning and operating requirements
for reliable integration of variable renewable generation. Technical report, Ernest
Orlando Lawrence Berkeley National Laboratory, December 2010.
[11] Supporting document for the network code on operational security. Technical re-
port, ENTSO-E, February 2013.
[12] B. Darryl and M. R. Hesamzadeh. The economics of electricity markets. Wiley-
IEEE Press, West Sussex, United Kingdom, 2014. ISBN 1-118775-75-9.
[13] C. Hamon. On frequency control schemes in power systems with large amounts of
wind power. PhD thesis, KTH Royal Institute of Technology, 2012.
[14] Hector Chavez. Frequency control adequacy for increasing levels of variable gener-
ation. PhD thesis, University of Texas at Austin, May 2013.
[15] G. Lalor, A. Mullane, and M. OMalley. Frequency control and wind turbine tech-
nologies. IEEE Transactions on Power Systems, 20(4):1905–1913, November 2005.
[16] A. Mullane and M. O’Malley. The inertial response of induction-machine-based
wind turbines. IEEE Transactions on Power System, 20(3):1496–1503.
[17] M. Li and J. D. McCalley. Influence of renewable integration on frequency dynamics.
In Proc. 2012 IEEE Power and Energy Society General Meeting, pages 1–7, July
2012.
[18] GAMS development corporation. http://www.gams.com/, 2007.
[19] A. G. Exposito, A. J. Conejolo, and C. Canizares. Electric energy systems, analysis
and operation. Taylor and Francis Group LLC, New York, 2009. ISBN 978-0-8493-
7365-7.
[20] Ancillary services unbundling electricity products an emerging market. Technical
report, The Union of the Electricity Industry EURELECTRIC, February 2004.
[21] V. Vittal. Impact of increased DFIG wind penetration on power systems and mar-
kets. Technical report, Power Systems Engineering Research Center, October 2009.
[22] H. Saadat. Power system analysis. McGraw Hill, New York, USA, 1999. ISBN
0-07-56134-3.
99
Bibliography
[23] P. Kundur. Power system stability and control. McGraw-Hill, Palo Alto, California,
1994.
[24] Recommended practice for functional and performance units, characteristics of con-
trol systems for steam turbine generator. Technical report, IEEE Standard 122-
1991, February 1992.
[25] H. Chavez and M. R. Hesamzadeh. The need for a market-based provision of
inertia and frequency response to integrate wind power in NORDEL. Technical
report, KTH Royal Institute of Technology, November 2013.
[26] J. Morren. Grid support by power electronic converters of distributed Generation
units. Gildeprint B.V., Enschede, The Netherlands, 2006. ISBN 90-811085-1-4.
[27] H. Chavez, R. Baldick, and S. Sharma. Governor rate-constrainted OPF for primary
frequency control adequacy. IEEE Transactions on Power Systems, 29(3):1473–
1480, May 2014.
[28] W. Hung, G. Ray, and G. Stein. Frequency changes during large disturbances WG.
Technical report, NationalGrid, 2010.
[29] DS3: System services consultation finance arrangements. Technical report, EIR-
GRID, June 2012.
[30] Nordic market report 2013, development in the Nordic electricity market. Technical
report, NordREG, September 2013.
[31] Nordic grid code (Nordic collection of rules). Technical report, NORDEL, January
2007.
[32] J. Vikesj, L. Messing, and G. Power. Wind power and fault clearance. Technical
report, Elforsk, April 2011.
[33] A. Perdana. Wind turbine models for power system stability studies. PhD thesis,
Chalmers University of Technology, 2006.
[34] PSSE-33.4 program application guide: volume I. Technical report, Siemens PTI
Ltd, March 2013.
[35] PSSE 33.4 program operation manual. Technical report, Siemens PTI Ltd, March
2013.
100
Bibliography
[36] D. G. Shepherd. Historical development of windmill. Technical report, NASA Lewis
reasearch Center, 1990.
[37] J. F. Walker and N. Jenkins. Wind energy technology. John Wiley, New York, 1997.
ISBN 0-471-96044-6.
[38] L. H. Hansen, L. Helle, and F. Blaabjerg. Conceptual survey of generators and
power electronics for wind turbines. Technical report, Riso National Laboratory,
Roskilde, Denmark, December 2001.
[39] M. P. Papadopoulos, S. A. Papathanassiou, and N. G. Boulaxis. Voltage quality
change by grid-connected wind turbines. In Proceedings of European Wind Energy
Conference, pages 783–785, Nice, France, 1999.
[40] K. Elkington. The dynamic impact of large wind farms on power system stability.
PhD thesis, KTH Royal Institute of Technology, April 2012.
[41] T. Petru and T. Thiringer. Active flicker reduction from a sea-based 2.5 MW wind
park connected to a weak grid. In Proceedings of Nordic Workshop on Power and
Industrial Electronics, pages 783–785, Aalborg, Denmark, June 2002.
[42] A. Petersson. Analysis, modeling and control of doubly-fed induction generators for
wind turbines. PhD thesis, Chalmers University of Technology, 2005.
[43] Modelling of GE wind turbine-generators for grid studies. Technical report, GE
Energy, April 2009.
[44] M. Seyedi. Evaluation of the DFIG wind turbine built-in model in PSS/E. Master’s
thesis, Chalmers University of Technology, 2009.
[45] Y. Kazachkov, R. Altman, J. Senthil, and K. Patil. PSSE wind modeling package for
GE 1.5/1.6/2.5/2.75/4.0 MW wind turbines user giude. Technical report, Siemens
PTI Ltd, August 2011.
[46] J. Schlabbach and K. H. Rofalski. Power system engineering: planning, design,
and operation of power systems and equipment. Wiley, Wienheim, Germany, 2008.
ISBN 978-3-527-40759-0.
[47] S. A. Gabriel, A. J. Conejolo, J. D. Fuller, B.F. Hobbs, and C. Riuz. Comple-
mentarity modeling in energy markets. Springer, New York Heidelberg Dordrecht
London, USA, 2013. ISBN 0884 8289.
101
Bibliography
[48] D. Kirschen and G. Strbac. Fundamentals of power system economics. John Wiley
and Sons, Ltd, West Sussex, United Kingdom, 2004. ISBN 0-470-84572-4.
[49] A.J. Wood and B. F. Wollenberg. Power generation, operation and control. John
Wiley and Sons, Ltd, New York, USA, 1984. ISBN 0-471-58699-4.
[50] K. Walve. Nordic32-A CIGRE test system for simulation of transient stability and
long term dynamics. Technical report, Svenska Kraftnat, March 1996.
[51] Energy in Sweden 2012. Technical report, Swedish Energy Agency, October 2012.
[52] N.R. Ullah and T. Thiringer. Effect of operational modes of a wind farm on the
transient stability of nearby generators and on power oscillations: a Nordic grid
study. Wind Energy, 11(1):63–73, January 2008.
[53] PSSE 33.4 Model Library. Technical report, Siemens PTI Ltd, March 2013.
[54] Z.W. Li, O. Samuelsson, and R. Garcia-Valle. Frequency deviations and generation
scheduling in the Nordic system. In IEEE Trondheim PowerTech, the Power of
Technology for a Sustainable Society, Trondheim, Norway, June 2011.
[55] PSSE application program interface (API). Technical report, Siemens PTI Ltd,
March 2013.
[56] J. Morren, J. Pierik, and H. de Haan. Inertial response of variable speed wind
turbines. Electric Power Systems Research, 77(11):980–987, July 2006.
[57] R. D. Zimmerman and C. E. Murillo-Sanchez. Matpower 5.0 user’s manual. Tech-
nical report, Cornell University, December 2014.
[58] W. Feng, L. A. Tuan, L. Tjernberg, A. Mannikoff, and A. Bergman. A new approach
for benefit evaluation of multiterinal VSC-HVDC using a proposed mixed AC/DC
optimal power flow. IEEE Transactions on Power Delivery, 29(1):432–443.
[59] H. Chavez and R. Baldick. Inertia and governor ramp rate constrained economic dis-
patch to assess primary frequency response adequacy. In International Conference
on Renewable Energies and Power Quality (ICREPQ12), Santiago de Compostela,
Spain, March 2012.
[60] S. Lundberg. Configuration study of large wind parks. Master’s thesis, Chalmers
University of Technology, 2003.
102
XR-EE-EPS 2015:007
www.kth.se
top related