SlideShare a Scribd company logo
Prof.Dr.-Ing. Luigi Vanfretti
Seminar – Linköping University
June 8, 2015
Associate Professor, Docent
E-mail: luigiv@kth.se
Web: http://www.vanfretti.com
KTH Royal Institute of Technology
Stockholm, Sweden
Power System Simulation
History, State of the Art and Challenges
Outline
• Background:
– Modeling and simulation in power systems
– History
– An opportunity for evolution in power system simulation
• The iTesla Project
• Power system modeling and simulation using Modelica
– Limitations of current modeling approaches used in power systems
– iTesla Power Systems Modelica Library
– Where is Modelica used in the iTesla toolbox?
• Mock-up SW prototype for model validation/estimation at the component and cluster
level:
– Model validation software architecture based using Modelica tools and FMI Technologies
– Prototype proof-of-concept implementation: the Rapid Parameter Identification Toolbox
(RaPId)
• The cyber-physical future?
• Conclussions
MODELING AND SIMULATION
How to anticipate problems during operation?
How to study a system?
• What is a system?
– An object or collection of objects whose properties we want to study.
• Why study a system?
– To understand it in order to [buil it/operate it/maintain it/expand it]
• How can we study a system?
– Experiments:
• We learn if its possible to excite the system by controlling it’s inputs.
• We apply a set of external conditions to the accessible inputs and observe the
reaction of the system by measuring the outputs.
• Difficulties:
– Many inputs are not accessible, controllable or measurable (internal states)
– Cost: possible to damage the system / human safety.
– Danger: as in training of nuclear plant operators.
– The system may not yet exist (we are building it)
– The difficulties in experimentation lead us to the development of models.
• A model of the system allows investigation and to answer many questions
regarding the real system iif the model is realistic enough.
Models and Simulation (1/2)
• What is a model?
– A model of a system is anything an “experiment” can be applied to in order to
answer questions about that system.
• Without doing experiments on the real system.
– Instead simplified experiments are performed on the model
– We thus have a “simplified system” that reflects properties of the real system.
• There are many types of models, in engineering we mainly deal with two
types:
– Physical Model: a physical object that mimics some properties of a real system to help
us answer questions about the system.
– Mathematical model: A description of the system where the relationships between
variables of the system are expressed in mathematical form – the form: equations!
“The change of motion is proportional to the motive
force impressed “
– Newton
Models and Simulation (2/2)
• Model knowledge is stored in books and human minds which computers
cannot access – this means that equations need to be translated into
computer readable form – the form: computer programs.
• The artifacts represented by mathematical models in a computer are
called virtual prototypes (in most industries at least).
• What is simulation?
– Simulare from latin, means to pretend. A simulation is an experiment performed on a
model.
– We focus on models that can be written in computer-representable forms.
– Hence, we perform numerical experiments by performing computations in a computer.
• The value of simulation is completely dependent on how well the model
represents the real system regarding the questions to be answered.
Why do we develop models and
perform simulations?
• To reduce the lifetime cost of a
system
– In requirements: trade-off
studies
– In test and design: fewer
proto-types
– In training: avoid accidents
– In operation: anticipate
problems
The prospective pilot sat in the top section
of this device and was required to line up
a reference bar with the horizon. 1910.
More than half the pilots who died in
WW1 were killed in training.
• European “blackout” ocurred on 4/11/2006
• The frequency drops to 49 Hz, which causes automatic load shedding.
• Real power surplus of 6000 MW
Costly Operation and Failure (1/2):
Need of Modern Tools for Power System Modeling and Simulation
8
• Others: WECC 1996 Break-up, European Blackout (4-Nov.-2006), London (28-
Aug-2003), Italy (28-Sep.-2003), Denmark/Sweden (23-Sep.-2003)
• Current modeling and simulation tools were unable to predict these events.
Costly Operation and Failure (2/2):
Need of Modern Tools for Power System Modeling and Simulation
General Approach for Studying
Physical Systems
10
Physical
System
Model
Hypotheses
(assumptions)
Simplifications
(approximations)
Equations
Analytical
methods
Numerical
methods
Closed-form
solution
Numerical
(iterative) solution
Analyses
Modeler/Analyst
Duality
Modeler
Analyst
How Computers Are Used In
Modeling of Power Systems (a.k.a. The
caveman approach)!
11
Physical
System
Model
Equations
Available
Algorithms
Analyses
Numerical/Iterative
Solutions
Hypotheses and
Simplifications
Modeler with understanding of the
physical system
Limitations:
- Software used
Modeler/analyst able
to interpret results
Analyst able
to interpret solution
Note!
The model and
algorithms aplied are
not separated!
General Mathematical Model
• The most general form of representing power systems is:
– is a vector of first order derivatives of the state variables.
– is a vector of state variables.
– is a vector of discrete variables. These variables model discrete changes in the system,
e.g. breakers, tap changers.
– is the vector of first-order differential equations, governing the dynamics (depending
on time) of the system.
– The various differential equations can have different time scales ranging from fast
dynamics in μs (e.g line switching) to hours in a quasi–steady state (e.g. slow load
variations).
( ), ,tj=ξ ξ u
&% %%%
ξ
&%
u%
ξ%
j%
Power system dynamics challenges
for simulation
10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104
Lightning
Line switching
SubSynchronous Resonances,
transformer energizations…
Transient stability
Long term dynamics
Daily load
following
seconds
The presence of large time
constants and small time
constants and large amount of
discrete switches.
Difficult to simulate very
large networks.
This is usually deal with by
discretizing the model and to
solve it using discrete solvers.
Models are simplified (averaged) to allow for simulation
of very large networks.
Ad-hoc solvers have been developed to reduce simulation
time, but usually the “model” is “interlaced” with the
solver (inline integration)
Generally there are no
discrete events.
(Ad-hoc DAE solvers)
The models are simplified further by
neglecting most dynamics (replacing most
differential equations by algebraic equations).
(Ad-hoc DAE solvers)
Time-Scale Modeling
• Solving/simulating can be difficult.
• Typically we simplify the equation above by separating the
differential equations by their time constants:
( ), ,tj=ξ ξ u
&% %%%
( )
( )
( )
, , ,
, , ,
, , ,
i i fi
f f i f
s s s i
s
s
f
t
t
t
j
j
j
é ù é ù
ê ú ê ú=
ê ú ê ú
ê ú ê ú= =ê ú ê ú
ê ú ê ú=ê ú ê ú
ê ú ë ûë û
ξ ξ ξ uξ
ξ ξ ξ ξ ξ u
ξ ξ ξ ξ u
& % % %% %%
& &% % % % %%%
&% % % %%% Slow dynamics, large time constants.
Dynamics of interest.
Fast dynamics, small time constants.
: Slow, variations can be neglected: use as parameters and discard .
sξ%
: Of interest, keep the differential equations .iξ%
: Fast, consider variations instantaneous: replace differential
equations with algebraic equations.
fξ%
ij%
sj%
Simplified General DAE Form
• We can now rewrite , using the assumptions in the
previous slide, to a simplified general form:
– is the vector of state variables, .
– is the vector of algebraic variables, .
– is the vector of parameters, from discarding and letting
– is the vector of discrete variables.
– are the differential equations, .
– are the algebraic equations, .
( ), ,tj=ξ ξ u
&% %%%
( )
( )
, , , , ,
, , , , .
f t
g t
=
=
x x y η u
0 x y η u
& %
%
x
y
η
( )f ×
u%
s =ξ η%
( ) ( )if j× º ×%
sj%
f=y ξ%
( )g × ( ) ( )fg j× º ×%
i=x ξ%
• The power system needs to be in balance, i.e. after a disturbance it must converge to an
equilibrium (operation point).
- Q: How can we find this equilibrium?
- A: Set derivatives to zero and solve for all unknown variables!
• Some observations that can be made:
- The algebraic equations in corresponded to having the fast differential equations at equilibrium all
the time (in the model and in the timescale considered).
- Finding the equilibrium when most of the variables are unknown will become very difficult if we try
to solve this equation system simultaneously.
- NB: power system tools do not generally do this!
- Hence, we attempt to sequentially solve the equation system for each t.
- First, we need to solve the algebraic equations that only depend on the
algebraic variables… this is were power systems deviates from other fields.
Finding the ”Power Flow” Equilibria
( )
( )
, , , , ,
, , , , .
f t
g t
=
=
0 x y η u
0 x y η u
%
%
( )g ×
•We will separate the algebraic
equations into two sets:
1. Is the part which governs how dynamic models will evolve, since
they depend on both and , e.g. generators and their control
systems.
2. Is the network model, consisting of transmission lines and other
passive components which only depends on algebraic variables,
Power System Simulation Approach
Separation into Network and Dynamic Component Models.
( )
( )
( )
( )} ( )
1
2
, , , ,
, , ,
1
,
, , 2.
.
f
g
g
ü= ïï
ý
ï= ïþ
=
x x y η u
0 x y η u
0 y η u
& %
%
%
x y
y
Power system dynamics
10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104
Lightning
Line switching
SubSynchronous Resonances,
transformer energizations…
Transient stability
Long term dynamics
Daily load
following
seconds
Electromechanical
Transients
Electromagnetic Transients
Quasi-Steady
State Dynamics
Phasor Time-
Domain Simulation
Power System Dynamics in Europe
February 19th 2011
49.85
49.9
49.95
50
50.05
50.1
50.15
08:08:00 08:08:10 08:08:20 08:08:30 08:08:40 08:08:50 08:09:00 08:09:10 08:09:20 08:09:30 08:09:40 08:09:50 08:10:00
f[Hz]
20110219_0755-0825
Freq. Mettlen Freq. Brindisi Freq. Wien Freq. Kassoe
Synchornized Phasor Measurement Data
Power System
Dynamic Simulation Approach
Practically
unchanged since the
1970s
Power System
Power Flow Solution Approach
Practically
unchanged since the
1970sPractically
unchanged since the
1970s
10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102
103 104
Lightning
Line switching
SubSynchronous
Resonances, transformer
energizations…
Transient stability
Long term dynamics
Daily load
following
seconds
Power system phenomena and
domain specific simulation tools
Broad range of time constants results in specific domain tools for simulation.
Non-exhaustive list. There exists other proprietary and few OSS tools.
Algebraic
“Steady
State”
(Power
Flow)
Ad-hoc
Initialization
of Dynamic
States
~
Dynamic
equilibrium
Simulation
PSS/E
Power System Phasor-Time Domain
Modeling and Simulation Status Quo
10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104
Lightning
Line switching
SubSynchronous Resonances,
transformer energizations…
Transient stability
Long term dynamics
Daily load
following
seconds
Phasor Time-
Domain Simulation
PSS/E
Status Quo:
Multiple simulation tools, with their own
interpretation of different model features and data
“format”.
Implications of the Status Quo:
- Dynamic models can rarely be shared in a
straightforward manner without loss of
information on power system dynamics.
- Simulations are inconsistent without drastic
and specialized human intervention.
Beyond general descriptions and parameter
values, a common and unified modeling language
would require a formal mathematical description
of the models – but this is not the practice to date.
These are key drawbacks of today’s tools for
tackling pan-European problems.
A Short History of
power system analysis software (1/2)
• Back in the 60s & 70s, all scientific communities were in the
same condition: most software was open source de facto
and was shared among experts in the area.
– Software for power flow and transient stability became available around mid
60s.
– Programs ran in mainframes, GE and Westinghouse were the main service
providers.
– Large companies that had mainframes (for billing) started looking into using
them for power system studies.
– By the late 60s many utilities in the USA had developed their own power flow
and stability programs: Philadelphia Electric Co. (PECO) and BPA’s became
widely used programs for planning.
– These programs and their source code were freely given away (the term “open
source” did not exist yet), and the BPA SW was in the public domain because it
was developed by a US gov. entity.
A Short History of
power system analysis software (2/2)
• Back in the 60s & 70s, all scientific communities were in the
same condition: most software was open source de facto
and was shared among experts in the area.
– BPA and PECO had well-known groups of power engineers who developed,
maintained and improved the SW throughout the 70s and into the 80s.
– Other power companies that used these software, did not had their own
groups to support it and BPA and PECO could not provide support.
– Thus, vendors of planning SW who could provide such user support also thrived
in parallel.
– By the late 80s even PECO and BPA decided to disband their in-house expertise
in SW development and the use of these packages dwindled.
– There are few traces of these programs left, except for their mention in the
technical literature from those days.
A word of caution:
Lessons from the history of power system analysis software
• In the early stages of power system software development, there was no concept
of “open source software” and so, there was no understanding of the importance
and consequences of sharing with the community the code implemented.
• After the paradigm of proprietary software appeared, companies locked out code
and imposed their products by different lock-in methods (e.g. model data
format)
• The main reason that relatively few OSS SW are available today for power system
analysis (mainly academic research projects or government funded efforts) is
that:
– The potential market in power system analysis was/is relatively small and
composed of a few powerful companies (at least until the world-wide
deregulation began in the 21st century)
– A lot of the early software was heavily hardware dependent (specially code
developed in Europe by ENEL in Italy, Alstom and Areva in France)
– Expertise was/is concentrated in relatively few groups of people, most of
which developed the proprietary tools now commonly in use
Effects of the Status Quo:
Evolution of Computing vs Power System Simulation Solutions
Power System
Simulation Experts (*)
Majority of Tools
Very few tools
An opportunity for evolution:
The European Drive for Information Exchange in Power Systems
• The Third Energy Package of the EC resulted in Regulation 714/2009 which established the
European Network of Transmission Operators (ENTSO-E)
• ENTSO-E bears the responsibility of ensuring secure and reliable operation of the European
electricity system.
• The regulation underlined the need of coordination between transmission system operators
(TSOs), which
• “should use a common transmission model dealing efficiently with interdependent physical loop-flows and having
regard to discrepancies between physical and commercial flows”
• This model should be used by ENTSO-E to support “common network operation tools to ensure coordination of
network operation I normal and emergency conditions”
An opportunity for evolution:
The European Drive for Information Exchange in Power Systems
– Mandate M/490 to the EU standarization bodies CEN/CENELEC and ETSI
resulted in a report that recommends integration of technology to
facilitate:
• The “establishment of a common information model that is to be used throughout many
applications and systems”
– The report also highlighted the importance of the Common Information
Model (CIM) – IEC 61968, 61970, and 62325.
– ENTSO-E has made large efforts to comply with the mandates – and as a
result the Common Grid Model Exchange Standard was approved
– Conformity of the tools to CGMES has been carried out to Inter-
Operability (IOP) tests, however, it is a challenge to develop CIM to fulfill
all the functions to comply with the regulation – specially for
unambiguous modeling and simulation of power system dynamics
– Regulation, however, brings an opportunity to make new tools that will
comply with CGMES and use modern computing approaches:
• That who conform first might set the new status quo in power systems.
THE ITESLA PROJECT
How to anticipate problems during operation?
In a “coordinated” way, and across the whole EU?
Why are new simulation-based tools
needed for power system operations?
To operate large power networks, planners and operators need
to analyze variety of operating conditions – both off-line and in
near real-time (power system security assessment).
Different SW systems have been designed for this purpose.
But, the dimension and complexity of the problems are
increasing due to growth in electricity demand, lack of
investments in transmission, and penetration of intermittent
resources.
New tools are needed!
Current/new tools will need to perform simulations:
• Of complex hybrid model components and networks with
very large number of continuous and discrete states.
• Models need to be shared, and simulation results need
to be consistent across different tools and simulation
platforms…
• If models could be “systematically shared at the equation
level”, and simulations are “consistent across different SW
platforms” – we would still need to validate each new
model (new components) and calibrate the model to
match reality.
Common Architecture of « most »
Available Power System Security Assessment Tools
Online
Data acquisition
and storage
Merging module
Contingency screening
(static power flow)
Synthesis of
recommendations
for the operator
External data
(forecasts and
snapshots)
“Static power flow model”
That means no (dynamic)
time-domain simulation is
performed.
The idea is to predict the
future behavior under a
given ‘contingency’ or set
of contingencies.
BUT, the model has no
dynamics – only
nonlinear algebraic
equations.
Computations made
on the power system
model are based on a
“power flow”
formulation.
Result : difficult to predict
the impact of a
contingency without
considering system
dynamics!
iTesla Toolbox Architecture
How to Validate
Dynamic Models?
Focus of this
presentation
Online Offline
Sampling of
stochastic variables
Elaboration of
starting network
states
Impact Analysis
(time domain
simulations)
Data mining on the
results of
simulation
Data acquisition
and storage
Merging module
Contingency screening
(several stages)
Time domain
simulations
Computation of
security rules
Synthesis of
recommendations
for the operator
External data
(forecasts and
snapshots)
Improvements of
defence and
restoration plans
Offline validation
of dynamic models
Where are Dynamic
Models used in
iTesla?
POWER SYSTEM MODELING AND
SIMULATION USING MODELICA
Modeling and Simulation
Power System Modeling
limitations, inconsistency and consequences
• Causal Modeling:
– Most components are defined using causal block diagram definitions.
– User defined modeling by scripting or GUIs is sometimes available (casual)
• Model sharing:
– Parameters for black-box definitions are shared in a specific “data format”
– For large systems, this requires “filters” for translation into the internal data format of each program
• Modeling inconsistency:
– For (standardized casual) models there is no guarantee that the model definition is implemented “exactly” in the
same way in different SW
– This is even the case with CIM (Common Information Model) dynamics, where no formal equations are defined,
instead a block diagram definition is provided.
– User defined models and proprietary models can’t be represented without complete re-implementation in each
platform
• Modeling limitations:
– Most SWs make no difference between “model” and “solver”, and in many cases the model is somehow
implanted within the solver (inline integration, eg. Euler or trapezoidal solution in transient stability simulation)
• Consequence:
– It is almost impossible to have the same model in different simulation platforms.
– This requires usually to re-implement the whole model from scratch (or parts of it) or to spend a lot of time “re-
tuning” parameters.
This is very costly!
An equation based
modeling language can
help in avoiding all of
these issues!
• Modeling and simulation should not be ambiguous: it should be
consistent across different simulation platforms.
• For unambiguous modeling, model sharing and simulation,
Modelica and Modelica Tools can be used due to their
standarized equation-based modeling language.
• We have utilized Modelica in iTesla to provide:
– Building blocks for power system simulation: iTelsa PS Modelica Library
– The possibility to use FMUs for model sharing in general purpose tools
and exploiting generic solvers
Unambiguous
Power System Modeling and Simulation
iTesla Power Systems
Modelica Library
• Power Systems Library:
– The Power Systems library developed using
as reference domain specific software tools
(e.g. PSS/E, Eurostag, PSAT and others)
– The library is being tested in several
Modelica supporting software:
OpenModelica, Dymola, SystemModeler
– Components and systems are validated
against proprietary tools and one OSS tool
used in power systems (domain specific)
• New components and time-driven
events are being added to this library
in order to simulate new systems.
– PSS/E (proprietary tool) equivalents of
different components are now available and
being validated.
– Automatic translator from domain specific
tools to Modelica will use this library’s
classes to build specific power system
network models is being developed.
Model Editing in
OpenModelica
Model Editing in
Dymola
SW-to-SW Validation of Models in
Domain Specific Tools used by TSOs
• Includes dynamic equations for
– Eletrocmagnetic dynamics
– Motion dynamics
– Saturation
• Boundary equations
– Change of coordinates from the abc
to dq0 frame
– Stator voltage equations
• Initial condition (guess) values for
the initialization problem are
extracted from a steady-state
solution
Validation of a PSS/E Model: Genrou
Typical SW-to-SW Validation Tests
Modelica vs. PSS/E
• Basic Test Network
• Perturbation scenarios
• Set-up a model in each tool with the
simulation scenario configured
• In the case of Modelica, the
simulation configuration can be
done within the model
• In the case of PSS/E, a Python script
is created to perform the same test.
• Sample Test:
1. Running under steady state for 2s.
2. Vary the system load with constant
P/Q ratio.
3. After 0.1s later, the load was
restored to its original value .
4. Run simulation to 10s.
5. Apply three phase to ground fault.
6. 0.15s later clear fault by tripping
the line.
7. Run simulation until 20s.
Experiment Set-Up of SW-to-SW
Validation Tests and Results
Modelica
PSS/E
Python
SW-to-SW Validation of
Larger Grid Models
Original “Nordic 44”
Model in PSS/E
Line opening
Bus voltages
Implemented “Nordic 44”
Model in Modelica
SW-to-SW Validation - Nordic 44 Grid
Sample Simulation Experiment
PSS/E Dymola
DELT (simulation time step):
0.01
Number of intervals: 1500 (number chosen in order
to have almost the same simulation points as PSSE)
Network solution tolerance:
0.0001
Algorithm: Rkfix2
Tolerance: 0.0001
Fixed Integrator Step: 0.01
Simulation time 0-10 sec
Type and location of fault Line opening between buses
5304-5305
Fault time t=2 sec
Simulation Configuration in PSS/E and Dymola
Simulation Configuration in PSS/E and Dymola
SW-to-SW Validation - Nordic 44 Grid
Experiment Results
Reminder: models are used as a
key enabler of the iTesla Toolbox!
Sampling of
stochastic variables
Elaboration of
starting network
states
Impact Analysis
(time domain
simulations)
Data mining on the
results of
simulation
Data acquisition
and storage
Merging module
Contingency screening
(several stages)
Time domain
simulations
Computation of
security rules
Synthesis of
recommendations
for the operator
External data
(forecasts and
snapshots)
Improvements of
defence and
restoration plans
Offline validation of
dynamic models
Data
management
Data mining
services
Dynamic
simulation
Optimizers
Graphical
interfaces
Modelica use for
time-domain simulation
THE RAPID TOOLBOX
Mock-Up Software Prototype for
Component and Aggregate Level Model Validation
What is required from a
SW architecture for model validation?
Models
Static Model
Standard Models
Custom Models
Manufacturer Models
System Level
Model Validation
Measurements
Static
Measurements
Dynamic
Measurements
PMU Measurements
DFR Measurements
Other
Measurement,
Model and Scenario
Harmonization
Dynamic Model
SCADA Measurements
Other EMSMeasurements
Static Values:
- Time Stamp
- Average Measurement Values of P, Q and V
- Sampled every 5-10 sec
Time Series:
- GPSTime Stamped Measurements
- Time-stamped voltage and current phasor meas.
Time Serieswith single time stamp:
- Time-stamp in the initial sample, use of samplingfrequency to
determine the time-stamp of other points
- Three phase (ABC), voltage and current measurements
- Other measurements available: frequency, harmonics, THD, etc.
Time Seriesfrom other devices(FNET FDRsor
Similar):
- GPSTime Stamped Measurements
- Single phase voltage phasor measurement, frequency, etc.
Scenario
Initialization
State Estimator
Snap-shop
Dynamic
Simulation
Limited visibility of custom or manufacturer
models will by itself put alimitation on the
methodologies used for model validation
• Support “harmonized”
dynamic models
• Process
measurements using
different DSP
techniques
• Perform simulation of
the model
• Provide optimization
facilities for
estimating and
calibrating model
parameters
• Provide user
interaction
FMI and FMUs
• FMI stands for flexible mock-up interface:
– FMI is a tool independent standard to support both model exchange and co-simulation
of dynamic models using a combination of xml-files and C-code, originating from the
automotive industry
• FMU stands for flexible mock-up unit
– An FMU is a model which has been compiled using the FMI standard definition
• What are FMUs used for?
– Model Exchange
• Generate C-Code of a model as an input/output block that can be utilized by other
modeling and simulation environments
– FMUs of a complete model can be generated in one environment and then shared to
another environment.
• The key idea to understand here is that the model is not locked into a specific
simulation environment!
• We use FMI technologies to build a mock up software for model validation.
The FMI Standard is now supported by 40
different simulation tools.
User Target
(server/pc)
Model Validation Software
iTesla WP2 Inputs to WP3: Measurements & Models
Mockup SW Architecture
Proof of concept of using MATLAB+FMI
EMTP-RV and/or other HB model simulation traces and
simulation configuration
PMU and other available
HB measurements
SCADA/EMS Snapshots +
Operator Actions
MATLAB
MATLAB/Simulink
(used for simulation of the Modelica Model
in FMU format)
FMI Toolbox for MATLAB
(with Modelica model)
Model Validation Tasks:
Parameter tuning, model
optimization, etc.
User
Interaction
.mat and .xml
files
HARMONIZED MODELICA MODEL:
Modelica Dynamic Model Definition for
Phasor Time Domain Simulation
Data Conditioning
iTesla
Data Manager
Internet or LAN
.mo files
.mat and .xml
files
FMU compiled
by another tool
FMU
Proof-of-Concept Implementation
The RaPId Mock-Up Software Implementation
• RaPId is our proof of concept
implementation (prototype) of a software
tool for model estimation and validation.
The tool provides a framework for model
identification/validation, mainly
parameter identification.
• RaPId is based on Modelica and FMI –
applicable to other systems, not only
power systems!
• A Modelica model is fed through an
Flexible Mock-Unit (i.e. FMU) to Simulink.
• The model is simulated and its outputs are
compared against measurements.
• RaPId tunes the parameters of the model
while minimizing a fitness criterion
between the outputs of the simulation
and the experimental measurements of
the same outputs provided by the user.
• RaPId was developed in MATLAB.
– The MATLAB code acts as wrapper to
provide interaction with several other
programs (which may not need to be
coded in MATLAB).
• Advanced users can simply use MATLAB
scripts instead of the graphical interface.
• Plug-in Architecture:
– Completely extensible and open
architecture allows advanced users to add:
• Identification methods
• Optimization methods
• Specific objective functions
• Solvers (numerical integration
routines)
Options
and
Settings
Algorithm Choice
Results and Plots
Simulink Container
Output measurement data
Input measurement data
What does RaPId do?
Output (and optionally input) measurements are provided to RaPId by the user.
At initialization, a set of parameters is pre-configured (or generated randomly by
RaPId)
The model is simulated with the parameter values given by RaPId.
The outputs of the model are recorded and compared to the user-provided
measurements
A fitness function is computed to judge how close the measured data and simulated
data are to each other
Using results from (5) a new set of parameters is computed by RaPId.
1
2
3
4
5
2’
ymeas
t
ymeas,ysim
tSimulink Container
With Modelica FMU Model
Simulations continue until a min. fitness or max no. of iterations (simulation runs) are reached.
1
2
3
4
5
THE RAPID TOOLBOX
Application Examples of
Application Example
• SVC 4x90 Mvar TCR
• Measurements taken during the testing of a
wide-area damper in 2011.
• Perturbations to the system: disconnection
and reconnection of 420 kV line.
• Reduced PSS/E Model from Statnett:
Model Development and Parameter Identification for a SVC in the Norwegian Grid - HSD
PMU
Measurements
used as input
signals
HSD Modelica model and
Simulink Container
Voltage
source
Voltage source
SVCs
parameters
to be
calibrated
Available
measurements
Available
measurements
Simulink Container
with FMU of the
Modelica Model
HSD Model Validation
Video Demo!
Using RaPId’s
GUI
Application Example
• Measurements from tests are imported from a
.pdf into MATLAB using a tool developed by
AIA:
Δοκιμή 1/ 60% MCR/-200 mHz/ 900sec.
220
230
240
250
260
270
280
19:58:11
19:58:58
19:59:45
20:00:32
20:01:19
20:02:06
20:02:53
20:03:40
20:04:27
20:05:14
20:06:01
20:06:48
20:07:35
20:08:22
20:09:09
20:09:56
20:10:43
20:11:30
20:12:17
20:13:04
20:13:51
20:14:38
20:15:25
20:16:12
20:16:59
Ώρα
Ισχύς
99.5
99.6
99.7
99.8
99.9
100
100.1 Συχνότητα(%)ωςποσοτότων
50Hz
Pow er output
(MW)
Injected
Signal (%)
Model Development and Parameter Identification for a Greek Generating Plant
Objective: To estimate p={R, Ts} by minimization of the fitness
function:
iGrGen Model
where:
FMU in Simulink
for RaPId
Optim. Algos.: PF vs. PSO
Particle Filter PSO
Assumption:
The Particle Filter approach will reduce the
solution space to samples that will result in a
lower values of the fitness function (lower
error).
In contrast, PSO will have slower convergence as
it will evaluate the fitness function over the
whole solution space, for each iteration.
iGrGen Model
Identification/Validation
Video Demo!
Using RaPId’s Command Line and
integration of a user-implemented
optimization method (Particle Filtering)
Results using RaPId
for identification
Maximum Continuous Rating (MCR) refers
to the gas turbine output at which it enters
into the temperature limit control regime
under present air temperature/humidity
ambient conditions.
90% MCR/ +200 mHz/ 60 sec
An incremental signal - to the Fref input of
the governor to mimic the effect of a
variation of system frequency.
90% MCR/ +200 mHz/ 900 sec
Results using RaPId
for identification
• R has influence on height of ΔPm,
• Ts has influence on the raise and
fall time transient.
• The mismatch between the
model response and the real
system is product of the modeling
adequacy.
• The model cannot exactly
reproduce the system behavior.
• However, for practical purposes,
the results are satisfactory.
• The assumption on faster
convergence of the Particle Filter
over PSO appears to be valid
from the results.
The Cyber-Physical Future
 Consider the example of Wide-area control systems (WACS)
 WACS include an ICT platform that merges the input
measurement data and transforms it to a useful input
signal for controllable devices – it has been identified as
key technology for coping with uncertainties of renewable
energy sources and smart grid enabler.
 WACS consists of
(i) a number of synchronized phasor measurements units (PMUs – a
sort of GPS time-syncronized distributed sensor) from
geographically spread locations,
(ii) a computer system termed phasor data concentrator
(iii) a real-time computer system where control functions are
implemented, and
(iv) a communication network
 WACS represent a true cyber-physical system that requires:
– Tools for design,
– Tools for simulation and
– Tools for hardware firmware deployment
for which technology today is not available in the power
systems domain.
Power
System
Smart Control
Systems
(for different
tasks / services)
Controllable
Devices
Sensors
(eg. PMUs)
Comm
s
Comm
s
Conclusions and
Looking Forward
• Modeling power system components with Modelica (as compared with domain specific tools)
is very attractive:
– Formal mathematical description of the model (equations)
– Allows model exchange between Modelica tools, with consistent (unambiguous)
simulation results
• The FMI Standard allows to take advantage of Modelica models for:
– Using Modelica models in different simulation environments
– Coupling general purpose tools to the model/simulation (case of RaPId)
• There are several challenges for modeling and validated “large scale” power systems using
Modelica-based tools:
– A well populated library of typical components (and for different time-scales)
– Model builder from domain-specific tools “data files/base” (in development)
– Support/linkage with industry specific data exchange paradigm (Common Information
Model - CIM)
• Developing a Modelica-driven model validation for large scale power systems is more
complex challenge than the case of RaPId. However, the results obtained so far, are
encouraging.
• Cyber-physical power systems will need better tools than what we have been able to do in
our specific domain.
Questions?
luigiv@kth.se
Thank you!
82

More Related Content

DOC
Operational description of 400kv switchyard NTPC Ramagundam RSTPS
PPTX
Introduction of wide area mesurement syatem
PPTX
Protection Of Generator
PDF
SUMMER Training report AT NTPC FOR INSTRUMENTATION (kbunl)
PPTX
INTERLINE FLOW CONTROLLER
PPTX
Streamer theory
PDF
seminar report on optimal placement and optimal sizing of DG
PPT
An introduction to FACTS
Operational description of 400kv switchyard NTPC Ramagundam RSTPS
Introduction of wide area mesurement syatem
Protection Of Generator
SUMMER Training report AT NTPC FOR INSTRUMENTATION (kbunl)
INTERLINE FLOW CONTROLLER
Streamer theory
seminar report on optimal placement and optimal sizing of DG
An introduction to FACTS

What's hot (20)

DOCX
PDF
Swing equation
PPTX
Static var compensator
PPSX
POWER LINE CARRIER COMMUNICATION
PPTX
Protection schemes and zones
PPTX
Ppt turbo generator
PPTX
Voltage source Converters as a building block of HVDC and FACTS
PDF
BK T. P. P. Vocational Training Report
PPTX
Hvdc transmission seminar
PDF
Automatic load frequency control
PPTX
Wide area measurements (synchrophasor measurements) in Power Systems
PPT
Frequency Control & AGC.ppt
PDF
Doubly fed-induction-generator
PPTX
Protection and control of Microgrid
PPTX
WIDE AREA MONITORING SYSTEMS(WAMS)
PPTX
Gyro bus
PPTX
Thermal Power Plant - Full Detail About Plant and Parts (Also Contain Animate...
PPTX
Vector diagram and phasor diagram of synchronous motor
PPTX
Recent Trends In Power Generation
Swing equation
Static var compensator
POWER LINE CARRIER COMMUNICATION
Protection schemes and zones
Ppt turbo generator
Voltage source Converters as a building block of HVDC and FACTS
BK T. P. P. Vocational Training Report
Hvdc transmission seminar
Automatic load frequency control
Wide area measurements (synchrophasor measurements) in Power Systems
Frequency Control & AGC.ppt
Doubly fed-induction-generator
Protection and control of Microgrid
WIDE AREA MONITORING SYSTEMS(WAMS)
Gyro bus
Thermal Power Plant - Full Detail About Plant and Parts (Also Contain Animate...
Vector diagram and phasor diagram of synchronous motor
Recent Trends In Power Generation
Ad

Viewers also liked (9)

PDF
POWER ELECTRONICS IEEE 2014-2015 PROJECTS
PPTX
Matlab dc motor modeling
PPT
Power System Simulation Lab (Formation of Y-Bus & Z-Bus Matrix)
PPTX
Speed control of dc motor using matlab
PPTX
simulation of maximum power point tracking for photovoltaic systems
PPT
Solid State Control of Electric Drive
PPT
Electric drives
PPT
Power Electronics Chapter 7
DOCX
Report on speed control of d.c. motor using pwm method
POWER ELECTRONICS IEEE 2014-2015 PROJECTS
Matlab dc motor modeling
Power System Simulation Lab (Formation of Y-Bus & Z-Bus Matrix)
Speed control of dc motor using matlab
simulation of maximum power point tracking for photovoltaic systems
Solid State Control of Electric Drive
Electric drives
Power Electronics Chapter 7
Report on speed control of d.c. motor using pwm method
Ad

Similar to Power System Simulation: History, State of the Art, and Challenges (20)

PDF
Wanted!: Open M&S Standards and Technologies for the Smart Grid - Introducing...
PPTX
Modeling and Simulation of Electrical Power Systems using OpenIPSL.org and Gr...
PDF
Unit1 8
PPTX
The RaPId Toolbox for Parameter Identification and Model Validation: How Mode...
PPTX
Introduction and some other things that can
PPTX
lecture-1-_introduction_modelling_&_simulation (2).pptx
PPTX
Lecture 1-2 Introduction to mechnical.pptx
PPT
103479026-Expert-Lecture-on-Power-System-Modelling-and-Simulation.ppt
PPT
Unit1 pg math model
PDF
Power_System_Modelling_1234567890AFGBHJ.pdf
PDF
What is the likely future of real-time transient stability?
PDF
Power System Modeling and Simulation lab manual
PPTX
Lecture 03-modelling of systems
PPTX
Recorded Lecture 1-2 Introduction to energy systems.pptx
PPSX
Power System Dynamics Lecture 1 Introduction.ppsx
PDF
Power System Dynamics Stability and control By K R Padiyar - By EasyEngineeri...
PPTX
introduction to modeling, Types of Models, Classification of mathematical mod...
PDF
Compit 2013 - Torsional Vibrations under Ice Impact
ODP
Power systemsilablri
PPT
Tetiana Bogodorova "Data Science for Electric Power Systems"
Wanted!: Open M&S Standards and Technologies for the Smart Grid - Introducing...
Modeling and Simulation of Electrical Power Systems using OpenIPSL.org and Gr...
Unit1 8
The RaPId Toolbox for Parameter Identification and Model Validation: How Mode...
Introduction and some other things that can
lecture-1-_introduction_modelling_&_simulation (2).pptx
Lecture 1-2 Introduction to mechnical.pptx
103479026-Expert-Lecture-on-Power-System-Modelling-and-Simulation.ppt
Unit1 pg math model
Power_System_Modelling_1234567890AFGBHJ.pdf
What is the likely future of real-time transient stability?
Power System Modeling and Simulation lab manual
Lecture 03-modelling of systems
Recorded Lecture 1-2 Introduction to energy systems.pptx
Power System Dynamics Lecture 1 Introduction.ppsx
Power System Dynamics Stability and control By K R Padiyar - By EasyEngineeri...
introduction to modeling, Types of Models, Classification of mathematical mod...
Compit 2013 - Torsional Vibrations under Ice Impact
Power systemsilablri
Tetiana Bogodorova "Data Science for Electric Power Systems"

More from Luigi Vanfretti (20)

PPTX
Hopf Bifurcation Control of Power Systems Nonlinear Dynamics Via a Dynamic St...
PPTX
Hopf Bifurcation Control of Power System Nonlinear Dynamics via a Dynamic Sta...
PPTX
Vulnerability of Synchrophasor-based WAMPAC Applications’ to Time-Synchroniza...
PPTX
Model-Simulation-and-Measurement-Based Systems Engineering of Power System Sy...
PDF
Monitoring of Transmission and Distribution Grids using PMUs
PPTX
Hands-on-OpenIPSL.org using OpenModelica!
PPTX
Phasor State Estimation Weighting Coefficients for AC and Hybrid Networks wit...
PPTX
Real-Time Testing of a Decentralized PMU Data-Based Power Systems Mode Estim...
PPTX
A SGAM-Based Architecture for Synchrophasor Applications Facilitating TSO/DSO...
PPTX
A Three-Phase VSC-HVDC Average Value Model Implementation using Modelica and ...
PDF
Impact of GPS Signal Loss and Spoofing on Power System Synchrophasor Applicat...
PPTX
Open Source Software Tools for Synchrophasor Applications
PDF
Synchrophasor Applications Facilitating Interactions between Transmission and...
PDF
Optimal Multisine Probing Signal Design for Power System Electromechanical Mo...
PDF
Real-Time Simulation for MBSE of Synchrophasor Systems
PPTX
Vedran Peric's PhD Defense Presentation: Non-intrusive Methods for Mode Estim...
PDF
Workshop on Synchrophasors and Control Applications for Power Systems
PDF
Binding CIM and Modelica for Consistent Power System Dynamic Model Exchange a...
PDF
Real-Time Hardware-in-the-Loop Testing of an Excitation Control System for Os...
PDF
PMU-Based Real-Time Damping Control System Software and Hardware Architecture...
Hopf Bifurcation Control of Power Systems Nonlinear Dynamics Via a Dynamic St...
Hopf Bifurcation Control of Power System Nonlinear Dynamics via a Dynamic Sta...
Vulnerability of Synchrophasor-based WAMPAC Applications’ to Time-Synchroniza...
Model-Simulation-and-Measurement-Based Systems Engineering of Power System Sy...
Monitoring of Transmission and Distribution Grids using PMUs
Hands-on-OpenIPSL.org using OpenModelica!
Phasor State Estimation Weighting Coefficients for AC and Hybrid Networks wit...
Real-Time Testing of a Decentralized PMU Data-Based Power Systems Mode Estim...
A SGAM-Based Architecture for Synchrophasor Applications Facilitating TSO/DSO...
A Three-Phase VSC-HVDC Average Value Model Implementation using Modelica and ...
Impact of GPS Signal Loss and Spoofing on Power System Synchrophasor Applicat...
Open Source Software Tools for Synchrophasor Applications
Synchrophasor Applications Facilitating Interactions between Transmission and...
Optimal Multisine Probing Signal Design for Power System Electromechanical Mo...
Real-Time Simulation for MBSE of Synchrophasor Systems
Vedran Peric's PhD Defense Presentation: Non-intrusive Methods for Mode Estim...
Workshop on Synchrophasors and Control Applications for Power Systems
Binding CIM and Modelica for Consistent Power System Dynamic Model Exchange a...
Real-Time Hardware-in-the-Loop Testing of an Excitation Control System for Os...
PMU-Based Real-Time Damping Control System Software and Hardware Architecture...

Recently uploaded (20)

PDF
Arduino robotics embedded978-1-4302-3184-4.pdf
PPTX
Welding lecture in detail for understanding
PPTX
Lecture Notes Electrical Wiring System Components
PDF
Structs to JSON How Go Powers REST APIs.pdf
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
PDF
Well-logging-methods_new................
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
DOCX
573137875-Attendance-Management-System-original
PPTX
Foundation to blockchain - A guide to Blockchain Tech
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PPTX
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
PDF
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
PPTX
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
Construction Project Organization Group 2.pptx
PPTX
Lesson 3_Tessellation.pptx finite Mathematics
PPTX
CYBER-CRIMES AND SECURITY A guide to understanding
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
Arduino robotics embedded978-1-4302-3184-4.pdf
Welding lecture in detail for understanding
Lecture Notes Electrical Wiring System Components
Structs to JSON How Go Powers REST APIs.pdf
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
Embodied AI: Ushering in the Next Era of Intelligent Systems
Well-logging-methods_new................
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
573137875-Attendance-Management-System-original
Foundation to blockchain - A guide to Blockchain Tech
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
Construction Project Organization Group 2.pptx
Lesson 3_Tessellation.pptx finite Mathematics
CYBER-CRIMES AND SECURITY A guide to understanding
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...

Power System Simulation: History, State of the Art, and Challenges

  • 1. Prof.Dr.-Ing. Luigi Vanfretti Seminar – Linköping University June 8, 2015 Associate Professor, Docent E-mail: luigiv@kth.se Web: http://www.vanfretti.com KTH Royal Institute of Technology Stockholm, Sweden Power System Simulation History, State of the Art and Challenges
  • 2. Outline • Background: – Modeling and simulation in power systems – History – An opportunity for evolution in power system simulation • The iTesla Project • Power system modeling and simulation using Modelica – Limitations of current modeling approaches used in power systems – iTesla Power Systems Modelica Library – Where is Modelica used in the iTesla toolbox? • Mock-up SW prototype for model validation/estimation at the component and cluster level: – Model validation software architecture based using Modelica tools and FMI Technologies – Prototype proof-of-concept implementation: the Rapid Parameter Identification Toolbox (RaPId) • The cyber-physical future? • Conclussions
  • 3. MODELING AND SIMULATION How to anticipate problems during operation?
  • 4. How to study a system? • What is a system? – An object or collection of objects whose properties we want to study. • Why study a system? – To understand it in order to [buil it/operate it/maintain it/expand it] • How can we study a system? – Experiments: • We learn if its possible to excite the system by controlling it’s inputs. • We apply a set of external conditions to the accessible inputs and observe the reaction of the system by measuring the outputs. • Difficulties: – Many inputs are not accessible, controllable or measurable (internal states) – Cost: possible to damage the system / human safety. – Danger: as in training of nuclear plant operators. – The system may not yet exist (we are building it) – The difficulties in experimentation lead us to the development of models. • A model of the system allows investigation and to answer many questions regarding the real system iif the model is realistic enough.
  • 5. Models and Simulation (1/2) • What is a model? – A model of a system is anything an “experiment” can be applied to in order to answer questions about that system. • Without doing experiments on the real system. – Instead simplified experiments are performed on the model – We thus have a “simplified system” that reflects properties of the real system. • There are many types of models, in engineering we mainly deal with two types: – Physical Model: a physical object that mimics some properties of a real system to help us answer questions about the system. – Mathematical model: A description of the system where the relationships between variables of the system are expressed in mathematical form – the form: equations! “The change of motion is proportional to the motive force impressed “ – Newton
  • 6. Models and Simulation (2/2) • Model knowledge is stored in books and human minds which computers cannot access – this means that equations need to be translated into computer readable form – the form: computer programs. • The artifacts represented by mathematical models in a computer are called virtual prototypes (in most industries at least). • What is simulation? – Simulare from latin, means to pretend. A simulation is an experiment performed on a model. – We focus on models that can be written in computer-representable forms. – Hence, we perform numerical experiments by performing computations in a computer. • The value of simulation is completely dependent on how well the model represents the real system regarding the questions to be answered.
  • 7. Why do we develop models and perform simulations? • To reduce the lifetime cost of a system – In requirements: trade-off studies – In test and design: fewer proto-types – In training: avoid accidents – In operation: anticipate problems The prospective pilot sat in the top section of this device and was required to line up a reference bar with the horizon. 1910. More than half the pilots who died in WW1 were killed in training.
  • 8. • European “blackout” ocurred on 4/11/2006 • The frequency drops to 49 Hz, which causes automatic load shedding. • Real power surplus of 6000 MW Costly Operation and Failure (1/2): Need of Modern Tools for Power System Modeling and Simulation 8
  • 9. • Others: WECC 1996 Break-up, European Blackout (4-Nov.-2006), London (28- Aug-2003), Italy (28-Sep.-2003), Denmark/Sweden (23-Sep.-2003) • Current modeling and simulation tools were unable to predict these events. Costly Operation and Failure (2/2): Need of Modern Tools for Power System Modeling and Simulation
  • 10. General Approach for Studying Physical Systems 10 Physical System Model Hypotheses (assumptions) Simplifications (approximations) Equations Analytical methods Numerical methods Closed-form solution Numerical (iterative) solution Analyses Modeler/Analyst Duality Modeler Analyst
  • 11. How Computers Are Used In Modeling of Power Systems (a.k.a. The caveman approach)! 11 Physical System Model Equations Available Algorithms Analyses Numerical/Iterative Solutions Hypotheses and Simplifications Modeler with understanding of the physical system Limitations: - Software used Modeler/analyst able to interpret results Analyst able to interpret solution Note! The model and algorithms aplied are not separated!
  • 12. General Mathematical Model • The most general form of representing power systems is: – is a vector of first order derivatives of the state variables. – is a vector of state variables. – is a vector of discrete variables. These variables model discrete changes in the system, e.g. breakers, tap changers. – is the vector of first-order differential equations, governing the dynamics (depending on time) of the system. – The various differential equations can have different time scales ranging from fast dynamics in μs (e.g line switching) to hours in a quasi–steady state (e.g. slow load variations). ( ), ,tj=ξ ξ u &% %%% ξ &% u% ξ% j%
  • 13. Power system dynamics challenges for simulation 10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104 Lightning Line switching SubSynchronous Resonances, transformer energizations… Transient stability Long term dynamics Daily load following seconds The presence of large time constants and small time constants and large amount of discrete switches. Difficult to simulate very large networks. This is usually deal with by discretizing the model and to solve it using discrete solvers. Models are simplified (averaged) to allow for simulation of very large networks. Ad-hoc solvers have been developed to reduce simulation time, but usually the “model” is “interlaced” with the solver (inline integration) Generally there are no discrete events. (Ad-hoc DAE solvers) The models are simplified further by neglecting most dynamics (replacing most differential equations by algebraic equations). (Ad-hoc DAE solvers)
  • 14. Time-Scale Modeling • Solving/simulating can be difficult. • Typically we simplify the equation above by separating the differential equations by their time constants: ( ), ,tj=ξ ξ u &% %%% ( ) ( ) ( ) , , , , , , , , , i i fi f f i f s s s i s s f t t t j j j é ù é ù ê ú ê ú= ê ú ê ú ê ú ê ú= =ê ú ê ú ê ú ê ú=ê ú ê ú ê ú ë ûë û ξ ξ ξ uξ ξ ξ ξ ξ ξ u ξ ξ ξ ξ u & % % %% %% & &% % % % %%% &% % % %%% Slow dynamics, large time constants. Dynamics of interest. Fast dynamics, small time constants. : Slow, variations can be neglected: use as parameters and discard . sξ% : Of interest, keep the differential equations .iξ% : Fast, consider variations instantaneous: replace differential equations with algebraic equations. fξ% ij% sj%
  • 15. Simplified General DAE Form • We can now rewrite , using the assumptions in the previous slide, to a simplified general form: – is the vector of state variables, . – is the vector of algebraic variables, . – is the vector of parameters, from discarding and letting – is the vector of discrete variables. – are the differential equations, . – are the algebraic equations, . ( ), ,tj=ξ ξ u &% %%% ( ) ( ) , , , , , , , , , . f t g t = = x x y η u 0 x y η u & % % x y η ( )f × u% s =ξ η% ( ) ( )if j× º ×% sj% f=y ξ% ( )g × ( ) ( )fg j× º ×% i=x ξ%
  • 16. • The power system needs to be in balance, i.e. after a disturbance it must converge to an equilibrium (operation point). - Q: How can we find this equilibrium? - A: Set derivatives to zero and solve for all unknown variables! • Some observations that can be made: - The algebraic equations in corresponded to having the fast differential equations at equilibrium all the time (in the model and in the timescale considered). - Finding the equilibrium when most of the variables are unknown will become very difficult if we try to solve this equation system simultaneously. - NB: power system tools do not generally do this! - Hence, we attempt to sequentially solve the equation system for each t. - First, we need to solve the algebraic equations that only depend on the algebraic variables… this is were power systems deviates from other fields. Finding the ”Power Flow” Equilibria ( ) ( ) , , , , , , , , , . f t g t = = 0 x y η u 0 x y η u % % ( )g ×
  • 17. •We will separate the algebraic equations into two sets: 1. Is the part which governs how dynamic models will evolve, since they depend on both and , e.g. generators and their control systems. 2. Is the network model, consisting of transmission lines and other passive components which only depends on algebraic variables, Power System Simulation Approach Separation into Network and Dynamic Component Models. ( ) ( ) ( ) ( )} ( ) 1 2 , , , , , , , 1 , , , 2. . f g g ü= ïï ý ï= ïþ = x x y η u 0 x y η u 0 y η u & % % % x y y
  • 18. Power system dynamics 10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104 Lightning Line switching SubSynchronous Resonances, transformer energizations… Transient stability Long term dynamics Daily load following seconds Electromechanical Transients Electromagnetic Transients Quasi-Steady State Dynamics Phasor Time- Domain Simulation
  • 19. Power System Dynamics in Europe February 19th 2011 49.85 49.9 49.95 50 50.05 50.1 50.15 08:08:00 08:08:10 08:08:20 08:08:30 08:08:40 08:08:50 08:09:00 08:09:10 08:09:20 08:09:30 08:09:40 08:09:50 08:10:00 f[Hz] 20110219_0755-0825 Freq. Mettlen Freq. Brindisi Freq. Wien Freq. Kassoe Synchornized Phasor Measurement Data
  • 20. Power System Dynamic Simulation Approach Practically unchanged since the 1970s
  • 21. Power System Power Flow Solution Approach Practically unchanged since the 1970sPractically unchanged since the 1970s
  • 22. 10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104 Lightning Line switching SubSynchronous Resonances, transformer energizations… Transient stability Long term dynamics Daily load following seconds Power system phenomena and domain specific simulation tools Broad range of time constants results in specific domain tools for simulation. Non-exhaustive list. There exists other proprietary and few OSS tools. Algebraic “Steady State” (Power Flow) Ad-hoc Initialization of Dynamic States ~ Dynamic equilibrium Simulation PSS/E
  • 23. Power System Phasor-Time Domain Modeling and Simulation Status Quo 10-7 10-6 10-5 10-4 10-3 10-2 10-1 1 10 102 103 104 Lightning Line switching SubSynchronous Resonances, transformer energizations… Transient stability Long term dynamics Daily load following seconds Phasor Time- Domain Simulation PSS/E Status Quo: Multiple simulation tools, with their own interpretation of different model features and data “format”. Implications of the Status Quo: - Dynamic models can rarely be shared in a straightforward manner without loss of information on power system dynamics. - Simulations are inconsistent without drastic and specialized human intervention. Beyond general descriptions and parameter values, a common and unified modeling language would require a formal mathematical description of the models – but this is not the practice to date. These are key drawbacks of today’s tools for tackling pan-European problems.
  • 24. A Short History of power system analysis software (1/2) • Back in the 60s & 70s, all scientific communities were in the same condition: most software was open source de facto and was shared among experts in the area. – Software for power flow and transient stability became available around mid 60s. – Programs ran in mainframes, GE and Westinghouse were the main service providers. – Large companies that had mainframes (for billing) started looking into using them for power system studies. – By the late 60s many utilities in the USA had developed their own power flow and stability programs: Philadelphia Electric Co. (PECO) and BPA’s became widely used programs for planning. – These programs and their source code were freely given away (the term “open source” did not exist yet), and the BPA SW was in the public domain because it was developed by a US gov. entity.
  • 25. A Short History of power system analysis software (2/2) • Back in the 60s & 70s, all scientific communities were in the same condition: most software was open source de facto and was shared among experts in the area. – BPA and PECO had well-known groups of power engineers who developed, maintained and improved the SW throughout the 70s and into the 80s. – Other power companies that used these software, did not had their own groups to support it and BPA and PECO could not provide support. – Thus, vendors of planning SW who could provide such user support also thrived in parallel. – By the late 80s even PECO and BPA decided to disband their in-house expertise in SW development and the use of these packages dwindled. – There are few traces of these programs left, except for their mention in the technical literature from those days.
  • 26. A word of caution: Lessons from the history of power system analysis software • In the early stages of power system software development, there was no concept of “open source software” and so, there was no understanding of the importance and consequences of sharing with the community the code implemented. • After the paradigm of proprietary software appeared, companies locked out code and imposed their products by different lock-in methods (e.g. model data format) • The main reason that relatively few OSS SW are available today for power system analysis (mainly academic research projects or government funded efforts) is that: – The potential market in power system analysis was/is relatively small and composed of a few powerful companies (at least until the world-wide deregulation began in the 21st century) – A lot of the early software was heavily hardware dependent (specially code developed in Europe by ENEL in Italy, Alstom and Areva in France) – Expertise was/is concentrated in relatively few groups of people, most of which developed the proprietary tools now commonly in use
  • 27. Effects of the Status Quo: Evolution of Computing vs Power System Simulation Solutions Power System Simulation Experts (*) Majority of Tools Very few tools
  • 28. An opportunity for evolution: The European Drive for Information Exchange in Power Systems • The Third Energy Package of the EC resulted in Regulation 714/2009 which established the European Network of Transmission Operators (ENTSO-E) • ENTSO-E bears the responsibility of ensuring secure and reliable operation of the European electricity system. • The regulation underlined the need of coordination between transmission system operators (TSOs), which • “should use a common transmission model dealing efficiently with interdependent physical loop-flows and having regard to discrepancies between physical and commercial flows” • This model should be used by ENTSO-E to support “common network operation tools to ensure coordination of network operation I normal and emergency conditions”
  • 29. An opportunity for evolution: The European Drive for Information Exchange in Power Systems – Mandate M/490 to the EU standarization bodies CEN/CENELEC and ETSI resulted in a report that recommends integration of technology to facilitate: • The “establishment of a common information model that is to be used throughout many applications and systems” – The report also highlighted the importance of the Common Information Model (CIM) – IEC 61968, 61970, and 62325. – ENTSO-E has made large efforts to comply with the mandates – and as a result the Common Grid Model Exchange Standard was approved – Conformity of the tools to CGMES has been carried out to Inter- Operability (IOP) tests, however, it is a challenge to develop CIM to fulfill all the functions to comply with the regulation – specially for unambiguous modeling and simulation of power system dynamics – Regulation, however, brings an opportunity to make new tools that will comply with CGMES and use modern computing approaches: • That who conform first might set the new status quo in power systems.
  • 30. THE ITESLA PROJECT How to anticipate problems during operation? In a “coordinated” way, and across the whole EU?
  • 31. Why are new simulation-based tools needed for power system operations? To operate large power networks, planners and operators need to analyze variety of operating conditions – both off-line and in near real-time (power system security assessment). Different SW systems have been designed for this purpose. But, the dimension and complexity of the problems are increasing due to growth in electricity demand, lack of investments in transmission, and penetration of intermittent resources. New tools are needed! Current/new tools will need to perform simulations: • Of complex hybrid model components and networks with very large number of continuous and discrete states. • Models need to be shared, and simulation results need to be consistent across different tools and simulation platforms… • If models could be “systematically shared at the equation level”, and simulations are “consistent across different SW platforms” – we would still need to validate each new model (new components) and calibrate the model to match reality.
  • 32. Common Architecture of « most » Available Power System Security Assessment Tools Online Data acquisition and storage Merging module Contingency screening (static power flow) Synthesis of recommendations for the operator External data (forecasts and snapshots) “Static power flow model” That means no (dynamic) time-domain simulation is performed. The idea is to predict the future behavior under a given ‘contingency’ or set of contingencies. BUT, the model has no dynamics – only nonlinear algebraic equations. Computations made on the power system model are based on a “power flow” formulation. Result : difficult to predict the impact of a contingency without considering system dynamics!
  • 33. iTesla Toolbox Architecture How to Validate Dynamic Models? Focus of this presentation Online Offline Sampling of stochastic variables Elaboration of starting network states Impact Analysis (time domain simulations) Data mining on the results of simulation Data acquisition and storage Merging module Contingency screening (several stages) Time domain simulations Computation of security rules Synthesis of recommendations for the operator External data (forecasts and snapshots) Improvements of defence and restoration plans Offline validation of dynamic models Where are Dynamic Models used in iTesla?
  • 34. POWER SYSTEM MODELING AND SIMULATION USING MODELICA Modeling and Simulation
  • 35. Power System Modeling limitations, inconsistency and consequences • Causal Modeling: – Most components are defined using causal block diagram definitions. – User defined modeling by scripting or GUIs is sometimes available (casual) • Model sharing: – Parameters for black-box definitions are shared in a specific “data format” – For large systems, this requires “filters” for translation into the internal data format of each program • Modeling inconsistency: – For (standardized casual) models there is no guarantee that the model definition is implemented “exactly” in the same way in different SW – This is even the case with CIM (Common Information Model) dynamics, where no formal equations are defined, instead a block diagram definition is provided. – User defined models and proprietary models can’t be represented without complete re-implementation in each platform • Modeling limitations: – Most SWs make no difference between “model” and “solver”, and in many cases the model is somehow implanted within the solver (inline integration, eg. Euler or trapezoidal solution in transient stability simulation) • Consequence: – It is almost impossible to have the same model in different simulation platforms. – This requires usually to re-implement the whole model from scratch (or parts of it) or to spend a lot of time “re- tuning” parameters. This is very costly! An equation based modeling language can help in avoiding all of these issues!
  • 36. • Modeling and simulation should not be ambiguous: it should be consistent across different simulation platforms. • For unambiguous modeling, model sharing and simulation, Modelica and Modelica Tools can be used due to their standarized equation-based modeling language. • We have utilized Modelica in iTesla to provide: – Building blocks for power system simulation: iTelsa PS Modelica Library – The possibility to use FMUs for model sharing in general purpose tools and exploiting generic solvers Unambiguous Power System Modeling and Simulation
  • 37. iTesla Power Systems Modelica Library • Power Systems Library: – The Power Systems library developed using as reference domain specific software tools (e.g. PSS/E, Eurostag, PSAT and others) – The library is being tested in several Modelica supporting software: OpenModelica, Dymola, SystemModeler – Components and systems are validated against proprietary tools and one OSS tool used in power systems (domain specific) • New components and time-driven events are being added to this library in order to simulate new systems. – PSS/E (proprietary tool) equivalents of different components are now available and being validated. – Automatic translator from domain specific tools to Modelica will use this library’s classes to build specific power system network models is being developed. Model Editing in OpenModelica
  • 39. SW-to-SW Validation of Models in Domain Specific Tools used by TSOs • Includes dynamic equations for – Eletrocmagnetic dynamics – Motion dynamics – Saturation • Boundary equations – Change of coordinates from the abc to dq0 frame – Stator voltage equations • Initial condition (guess) values for the initialization problem are extracted from a steady-state solution Validation of a PSS/E Model: Genrou
  • 40. Typical SW-to-SW Validation Tests Modelica vs. PSS/E • Basic Test Network • Perturbation scenarios
  • 41. • Set-up a model in each tool with the simulation scenario configured • In the case of Modelica, the simulation configuration can be done within the model • In the case of PSS/E, a Python script is created to perform the same test. • Sample Test: 1. Running under steady state for 2s. 2. Vary the system load with constant P/Q ratio. 3. After 0.1s later, the load was restored to its original value . 4. Run simulation to 10s. 5. Apply three phase to ground fault. 6. 0.15s later clear fault by tripping the line. 7. Run simulation until 20s. Experiment Set-Up of SW-to-SW Validation Tests and Results Modelica PSS/E Python
  • 42. SW-to-SW Validation of Larger Grid Models Original “Nordic 44” Model in PSS/E Line opening Bus voltages Implemented “Nordic 44” Model in Modelica
  • 43. SW-to-SW Validation - Nordic 44 Grid Sample Simulation Experiment PSS/E Dymola DELT (simulation time step): 0.01 Number of intervals: 1500 (number chosen in order to have almost the same simulation points as PSSE) Network solution tolerance: 0.0001 Algorithm: Rkfix2 Tolerance: 0.0001 Fixed Integrator Step: 0.01 Simulation time 0-10 sec Type and location of fault Line opening between buses 5304-5305 Fault time t=2 sec Simulation Configuration in PSS/E and Dymola Simulation Configuration in PSS/E and Dymola
  • 44. SW-to-SW Validation - Nordic 44 Grid Experiment Results
  • 45. Reminder: models are used as a key enabler of the iTesla Toolbox! Sampling of stochastic variables Elaboration of starting network states Impact Analysis (time domain simulations) Data mining on the results of simulation Data acquisition and storage Merging module Contingency screening (several stages) Time domain simulations Computation of security rules Synthesis of recommendations for the operator External data (forecasts and snapshots) Improvements of defence and restoration plans Offline validation of dynamic models Data management Data mining services Dynamic simulation Optimizers Graphical interfaces Modelica use for time-domain simulation
  • 46. THE RAPID TOOLBOX Mock-Up Software Prototype for Component and Aggregate Level Model Validation
  • 47. What is required from a SW architecture for model validation? Models Static Model Standard Models Custom Models Manufacturer Models System Level Model Validation Measurements Static Measurements Dynamic Measurements PMU Measurements DFR Measurements Other Measurement, Model and Scenario Harmonization Dynamic Model SCADA Measurements Other EMSMeasurements Static Values: - Time Stamp - Average Measurement Values of P, Q and V - Sampled every 5-10 sec Time Series: - GPSTime Stamped Measurements - Time-stamped voltage and current phasor meas. Time Serieswith single time stamp: - Time-stamp in the initial sample, use of samplingfrequency to determine the time-stamp of other points - Three phase (ABC), voltage and current measurements - Other measurements available: frequency, harmonics, THD, etc. Time Seriesfrom other devices(FNET FDRsor Similar): - GPSTime Stamped Measurements - Single phase voltage phasor measurement, frequency, etc. Scenario Initialization State Estimator Snap-shop Dynamic Simulation Limited visibility of custom or manufacturer models will by itself put alimitation on the methodologies used for model validation • Support “harmonized” dynamic models • Process measurements using different DSP techniques • Perform simulation of the model • Provide optimization facilities for estimating and calibrating model parameters • Provide user interaction
  • 48. FMI and FMUs • FMI stands for flexible mock-up interface: – FMI is a tool independent standard to support both model exchange and co-simulation of dynamic models using a combination of xml-files and C-code, originating from the automotive industry • FMU stands for flexible mock-up unit – An FMU is a model which has been compiled using the FMI standard definition • What are FMUs used for? – Model Exchange • Generate C-Code of a model as an input/output block that can be utilized by other modeling and simulation environments – FMUs of a complete model can be generated in one environment and then shared to another environment. • The key idea to understand here is that the model is not locked into a specific simulation environment! • We use FMI technologies to build a mock up software for model validation. The FMI Standard is now supported by 40 different simulation tools.
  • 49. User Target (server/pc) Model Validation Software iTesla WP2 Inputs to WP3: Measurements & Models Mockup SW Architecture Proof of concept of using MATLAB+FMI EMTP-RV and/or other HB model simulation traces and simulation configuration PMU and other available HB measurements SCADA/EMS Snapshots + Operator Actions MATLAB MATLAB/Simulink (used for simulation of the Modelica Model in FMU format) FMI Toolbox for MATLAB (with Modelica model) Model Validation Tasks: Parameter tuning, model optimization, etc. User Interaction .mat and .xml files HARMONIZED MODELICA MODEL: Modelica Dynamic Model Definition for Phasor Time Domain Simulation Data Conditioning iTesla Data Manager Internet or LAN .mo files .mat and .xml files FMU compiled by another tool FMU
  • 50. Proof-of-Concept Implementation The RaPId Mock-Up Software Implementation • RaPId is our proof of concept implementation (prototype) of a software tool for model estimation and validation. The tool provides a framework for model identification/validation, mainly parameter identification. • RaPId is based on Modelica and FMI – applicable to other systems, not only power systems! • A Modelica model is fed through an Flexible Mock-Unit (i.e. FMU) to Simulink. • The model is simulated and its outputs are compared against measurements. • RaPId tunes the parameters of the model while minimizing a fitness criterion between the outputs of the simulation and the experimental measurements of the same outputs provided by the user. • RaPId was developed in MATLAB. – The MATLAB code acts as wrapper to provide interaction with several other programs (which may not need to be coded in MATLAB). • Advanced users can simply use MATLAB scripts instead of the graphical interface. • Plug-in Architecture: – Completely extensible and open architecture allows advanced users to add: • Identification methods • Optimization methods • Specific objective functions • Solvers (numerical integration routines) Options and Settings Algorithm Choice Results and Plots Simulink Container Output measurement data Input measurement data
  • 51. What does RaPId do? Output (and optionally input) measurements are provided to RaPId by the user. At initialization, a set of parameters is pre-configured (or generated randomly by RaPId) The model is simulated with the parameter values given by RaPId. The outputs of the model are recorded and compared to the user-provided measurements A fitness function is computed to judge how close the measured data and simulated data are to each other Using results from (5) a new set of parameters is computed by RaPId. 1 2 3 4 5 2’ ymeas t ymeas,ysim tSimulink Container With Modelica FMU Model Simulations continue until a min. fitness or max no. of iterations (simulation runs) are reached. 1 2 3 4 5
  • 53. Application Example • SVC 4x90 Mvar TCR • Measurements taken during the testing of a wide-area damper in 2011. • Perturbations to the system: disconnection and reconnection of 420 kV line. • Reduced PSS/E Model from Statnett: Model Development and Parameter Identification for a SVC in the Norwegian Grid - HSD PMU Measurements used as input signals
  • 54. HSD Modelica model and Simulink Container Voltage source Voltage source SVCs parameters to be calibrated Available measurements Available measurements Simulink Container with FMU of the Modelica Model
  • 55. HSD Model Validation Video Demo! Using RaPId’s GUI
  • 56. Application Example • Measurements from tests are imported from a .pdf into MATLAB using a tool developed by AIA: Δοκιμή 1/ 60% MCR/-200 mHz/ 900sec. 220 230 240 250 260 270 280 19:58:11 19:58:58 19:59:45 20:00:32 20:01:19 20:02:06 20:02:53 20:03:40 20:04:27 20:05:14 20:06:01 20:06:48 20:07:35 20:08:22 20:09:09 20:09:56 20:10:43 20:11:30 20:12:17 20:13:04 20:13:51 20:14:38 20:15:25 20:16:12 20:16:59 Ώρα Ισχύς 99.5 99.6 99.7 99.8 99.9 100 100.1 Συχνότητα(%)ωςποσοτότων 50Hz Pow er output (MW) Injected Signal (%) Model Development and Parameter Identification for a Greek Generating Plant
  • 57. Objective: To estimate p={R, Ts} by minimization of the fitness function: iGrGen Model where: FMU in Simulink for RaPId
  • 58. Optim. Algos.: PF vs. PSO Particle Filter PSO Assumption: The Particle Filter approach will reduce the solution space to samples that will result in a lower values of the fitness function (lower error). In contrast, PSO will have slower convergence as it will evaluate the fitness function over the whole solution space, for each iteration.
  • 59. iGrGen Model Identification/Validation Video Demo! Using RaPId’s Command Line and integration of a user-implemented optimization method (Particle Filtering)
  • 60. Results using RaPId for identification Maximum Continuous Rating (MCR) refers to the gas turbine output at which it enters into the temperature limit control regime under present air temperature/humidity ambient conditions. 90% MCR/ +200 mHz/ 60 sec An incremental signal - to the Fref input of the governor to mimic the effect of a variation of system frequency. 90% MCR/ +200 mHz/ 900 sec
  • 61. Results using RaPId for identification • R has influence on height of ΔPm, • Ts has influence on the raise and fall time transient. • The mismatch between the model response and the real system is product of the modeling adequacy. • The model cannot exactly reproduce the system behavior. • However, for practical purposes, the results are satisfactory. • The assumption on faster convergence of the Particle Filter over PSO appears to be valid from the results.
  • 62. The Cyber-Physical Future  Consider the example of Wide-area control systems (WACS)  WACS include an ICT platform that merges the input measurement data and transforms it to a useful input signal for controllable devices – it has been identified as key technology for coping with uncertainties of renewable energy sources and smart grid enabler.  WACS consists of (i) a number of synchronized phasor measurements units (PMUs – a sort of GPS time-syncronized distributed sensor) from geographically spread locations, (ii) a computer system termed phasor data concentrator (iii) a real-time computer system where control functions are implemented, and (iv) a communication network  WACS represent a true cyber-physical system that requires: – Tools for design, – Tools for simulation and – Tools for hardware firmware deployment for which technology today is not available in the power systems domain. Power System Smart Control Systems (for different tasks / services) Controllable Devices Sensors (eg. PMUs) Comm s Comm s
  • 63. Conclusions and Looking Forward • Modeling power system components with Modelica (as compared with domain specific tools) is very attractive: – Formal mathematical description of the model (equations) – Allows model exchange between Modelica tools, with consistent (unambiguous) simulation results • The FMI Standard allows to take advantage of Modelica models for: – Using Modelica models in different simulation environments – Coupling general purpose tools to the model/simulation (case of RaPId) • There are several challenges for modeling and validated “large scale” power systems using Modelica-based tools: – A well populated library of typical components (and for different time-scales) – Model builder from domain-specific tools “data files/base” (in development) – Support/linkage with industry specific data exchange paradigm (Common Information Model - CIM) • Developing a Modelica-driven model validation for large scale power systems is more complex challenge than the case of RaPId. However, the results obtained so far, are encouraging. • Cyber-physical power systems will need better tools than what we have been able to do in our specific domain.