PLEXOS Training - Day1 - PLN

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 95

PLEXOS Basic Training

Perusahaan Listrik Negara, Indonesia


- DAY 1 -

Jakarta, 5-9th August 2019


Course Objectives
After this training course, the attendees will
1. Understand power system modelling using PLEXOS
2. Be able to navigate the PLEXOS interface
3. Be able to compose a database and perform simulation runs
4. Be able to retrieve and query simulation results

Approach
 Explain PLEXOS using a small databases and models
 Work with hands-on exercises

CONFIDENTIAL 2
Agenda

CONFIDENTIAL 3
PLEXOS 8 New Features

Slicing Block

Mixed Resolution

Multi-stage Stochastic Optimisation

Geographic Decomposition

CONFIDENTIAL
Day 1

CONFIDENTIAL 5
Energy Exemplar & PLEXOS

CONFIDENTIAL 6
About Us
A global leader in power system optimisation software since 1999
1,019 licenses at 200 sites in 47 countries

CONFIDENTIAL 7
PLEXOS Energy Model
Best In Class Cutting-edge Multi-task Transparent

Mathematical Not a black box


Power
Optimisation
Long
Medium
Short-term
Deterministic & Customisable
Gas
Stochastic Techniques

Water Robust
Integrated Tools

CONFIDENTIAL 8
Applications, Workflow &
Components

CONFIDENTIAL 9
PLEXOS Simulation Phases
New builds/retirements
LT Plan – Optimal investment

PASA – Optimal reserve share Maintenance schedule

MT – Resource allocation
Operating policies

ST – Chronological unit commitment Detailed by-period results

1 year 4 years 30 years

CONFIDENTIAL 10
PLEXOS Formulation

CONFIDENTIAL 11
The Optimisation Paradigm

• The elements that are under


Decision the control of the decision
variables maker
Objective
function • Example: Energy output of
generators
• A single objective function of
the decision variables
• Example: Minimise generation
Constraints
costs
• Restrictions on the decision
variables
• Example: Total generation is
equal to total demand

Best solution
CONFIDENTIAL 12
Generic Optimisation Model
• Min 𝑓 𝑥
Minimise the objective

• Subject to:
– 𝑔𝑖 𝑥 = 𝑏𝑖 for each 𝑖 ∈ 1, 𝑚 Satisfy the constraints

– 𝑥≥0

• Where:
– 𝑥 is the vector of decision variables
– 𝑓 and 𝑔𝑖 are functions
CONFIDENTIAL 13
PLEXOS Workflow
• Three-step process • Input comprises power
system description and
• Display solution data and analysis specification
1 • Enter and edit in GUI
charts applying multiple
filters and aggregation 3 • Link to external files
• Import data
• Export to Excel
• Solution query history and
Review Compose
view gallery available solution input

• Execute as single job or


in batch mode
• Display live results
Run
(optional) simulation
• Execute in parallel on
multi-core machines 2

CONFIDENTIAL 14
PLEXOS Basic Modelling (I)

CONFIDENTIAL 15
PLEXOS Interface and Data
Modelling

CONFIDENTIAL 16
PLEXOS Help
• Online PLEXOS Wiki*
• Local PLEXOS Help/Guide:
– Getting Started
– User Interface Guides
– Modelling Guide
– Technical References
– Class Reference
– Release Notes
• Context sensitive
– Place cursor at a variable in the input
or output interface then press F1 key
to view class or property description.

CONFIDENTIAL 17
PLEXOS Input Interface - Structure
Objects: Generators, Fuel, Region, Bus, Data File...

System Memberships: Generator.Bus, Generator.Fuel…

Properties: Unit, Max Capacity, Heat Rate…

Input Interface

Objects: Model, Horizon, Reports, LT, MT, ST…

Memberships: Scenario, Horizon…


Simulation
Properties: Settings of objects

CONFIDENTIAL 18
Elements of PLEXOS Input Interface
• Input interface layout has Ribbon menu
3 main elements:
– Ribbon menu
– Tree pane Memberships
Tree
– Data grid pane
• Tree pane: Objects
– Objects Tree Tree Data grid pane
– Memberships Tree
Tree pane
Properties
– Properties Tree Tree

CONFIDENTIAL 19
Three Layers of Hierarchy
1. Objects
 Entities to be modelled under system/simulation defined
classes
2. Memberships
 Relationships between objects
 Uniquely defined by a membership collection type
3. Properties
 Characteristics of objects
 Used to store data associated with objects
 Can be either single-point (static) data or multi-point
(dynamic) data
CONFIDENTIAL 20
Objects
• Entities to be modelled:
– Regions
– Nodes and transmission lines
– Markets (ancillary services, fuels, emissions)
– Generators
– Constraints
– Reserves
– Data files
• Simulation settings are also objects: Models,
Horizons, Reports…
• Objects are displayed in the Object tree pane
• Objects are organized by Class
• Objects can be grouped by user-defined
Categories

CONFIDENTIAL 21
Memberships
• Membership is a method used to define FUNCTIONAL and
LOGICAL relationships between objects:
– A generator burns a fuel
– A generator provides spinning reserve
– A transmission line connects two buses
– A bus belongs to a region
– A hydro generator uses water from a storage
– A constraint involves two generators
– A model (simulation run) uses a group of scenarios

CONFIDENTIAL 22
Properties
• Characteristics of objects:
– Maximum capacity of a generator
– Fuel price of a fuel
– Load profile of a region
– ….

1,000+ Input Properties Available!

CONFIDENTIAL 23
Database Structure in PLEXOS

CONFIDENTIAL 24
Data Entry

CONFIDENTIAL 25
Enabling Classes, Objects, and Properties
• New database is created with predefined default class, collection
and property display
• Config menu is used to select classes and properties to display

• Tick the class, object or property that you will use

CONFIDENTIAL 26
Creating Objects

• Ways to create new objects:


1) Use New Object command in the wizard dialog of the system collections

2) Enter the name of the new object on the objects grid

CONFIDENTIAL 27
Creating Memberships

1) Drag-and-drop the objects into


membership collections or directly to b)
other object
a) Drag “Node 1” onto Reg1, or
b) Drag Region “Reg A” into Region a)
Membership collection of Node 1
This will instruct PLEXOS that “Node 1”
belongs to “Reg A”

CONFIDENTIAL
28
Creating Memberships

2) Memberships Tree – Invoke Membership editor by:


a) double-clicking the membership collection you want to edit
b) right- clicking the membership collection and clicking the
Memberships command

Select region to be
added in Node’s region
Double click collection for membership collection
editing or right click on and click “Add”
Memberships command

CONFIDENTIAL 29
Creating Memberships

3) Memberships Grid - create a membership directly for respective


object by selecting membership Collection, Parent Name and
Child Name from the drop-down box

CONFIDENTIAL 30
Memberships

• Membership collections displayed in the Membership tree are colour coded:


– Black code: object is parent object in the membership
– Blue code: object is child object in the membership
– Red code: membership required
– Grey code: inferred membership, not editable

Gen1 is member of
Reg A since its Node 1
is member of Reg A
Region is a required
membership for Node

CONFIDENTIAL 31
Inputting Properties Static properties in
upper grid pane, no
change in simulations
Static Properties
– Property value is fixed and never
changes,
– Yellow icon in properties tree
– Static properties appear on the upper
half of data grid
Dynamic Properties Dynamic properties in
lower grid pane, can
– Property value can be changed over be changed by date,
the planning horizon and/or by timeslice or scenario
scenario
– Blue icon in properties tree
– Dynamic properties appear on the
lower half of data grid pane
CONFIDENTIAL 32
Changing Static Properties to Dynamic

1. Click ‘Config’ button of the ribbon menu


2. Tick boxes in ‘Dynamic’ column to
make property Static or Dynamic

Optional: Overriding selections to make


all properties Dynamic
• Tick “All Dynamic” box in lower left corner
of Config window

CONFIDENTIAL 33
Patterns
• Patterns are string expressions made up of one or more
statements separated by commas and semi-colons.
• Pattern symbols are not case sensitive and additional spaces in
the patterns will be skipped.
• The PLEXOS interface will sort data according to pattern as well
as date, etc.
– When giving a list of simple patterns like monthly values it is best to
use two digits for the month number i.e. M01, M02, M03, etc, this
way the values will display in the correct order.

CONFIDENTIAL 34
Dynamic Properties - Patterns
Symbol Range Meaning
Hour of the day (1=midnight to 1.00am, 24=11:00pm to 12
H 1-24
midnight)
W 1-7 Day of week (1=Sunday, 2=Monday, ...)
D 1-31 Day of month
M 1-12 Month of calendar year (1=January, 2=February, ...)
Trading period of day (depends on horizon settings e.g. if
1 - Num. Trading
P running with a 30 minute period then P1 means midnight to
Periods in Day
12:30am, P2 means 12:30am to 1:00am, etc.)
Q 1-4 Quarter of the year (1=Jan to March, 2=April to June, ...)
This is the "not operator" e.g. "!H1-6" means the data
! -
applies in hours other than 1-6.

CONFIDENTIAL 35
Pattern Examples
Pattern Interpretation
The value applies only when the hour of the day is
H1-6
between 1 and 6
The value applies when the hour of the day is between 1
H1-6,H18-24
and 6, and 18-24

The value applies in hours 1 to 6 but only for weekday


W1,H1-6;W7,H1-6
one and weekday seven, but not for other weekdays

The value applies to periods 30-48 e.g. in a 30-minute


P30-48
interval simulation model

CONFIDENTIAL 36
Linking Properties to External Files
1. Create a CSV file containing the input data in PLEXOS format.
2. Save it file in the location of the
3. Type its filename under Data File column of the corresponding property.

CONFIDENTIAL 37
Filtering Displayed Membership Data
• Use the memberships and properties trees as filters.
• Example: Display the fuel memberships of all generators in category “Gas.”

2. Highlight the
membership of interest.
3. Activate the
Memberships tab.

1. Highlight
Editable list of all generator-
the category.
fuel memberships for
generator category “Gas”

CONFIDENTIAL 38
Filtering Displayed Input Property Data
• Use the memberships and properties trees as filters.
• Example: Display the Max Capacities and MSL of all generators in category “Gas.”

3. Activate the
Properties tab.

1. Highlight
the category.

Editable list of all Max.


Cap and MSL for generator
in category “Gas”
2. Check the desired
properties. Highlight the
group folder (Production).

CONFIDENTIAL 39
Exercise 1:
Create Objects, Memberships & Properties

DATABASE: Database Setup_Base.xml

CONFIDENTIAL 40
Simulation Settings

CONFIDENTIAL 41
PLEXOS Simulation Phases

LT Plan PASA MT ST
Investment Maintenance Resource Chronological
Planning Schedule Allocation Commitment

Remember:
A Model needs at least one Simulation Phase
in order to run

CONFIDENTIAL 42
Simulation Settings
Object Descriptions
Required

Horizon Defines simulation horizon and granularity


Reports Specify which properties should be reported in the solution
Transmission Controls how the transmission system is modelled
Production Controls how unit commitment is optimised
Competition Enables competition models
Stochastic Defines stochastic simulation parameters
Performance Selects and parametrizes a solver
Diagnostic Issues algorithm diagnostic reports

CONFIDENTIAL 43
Horizon

CONFIDENTIAL 44
Horizon Object
Horizons Objects determine both the length and resolution of the simulation horizon.

Planning Horizon (LT and MT)

Resolution (same in both horizons)

Chronological Phase (ST)

CONFIDENTIAL 45
Horizon Settings: Examples

• Planning Horizon equal to 3 days and Chronological Phase equal to 2 days

Length Planning Horizon (PH) Correct Setting: CP subset of PH


Length Chronological Phase (CP)
0 2 3 Days

• Planning Horizon equal to 3 days and Chronological Phase equal to 2 days


Length Planning Horizon (PH)
Length Chronological Phase (CP)
0 2 3 Day
Incorrect Setting: CP is not a subset of PH
s

CONFIDENTIAL 46
Chronological Phase: Step Size
• ST Schedule is a chronological It is optimised in one or more steps
• The size of these steps is set by the Schedule

1 Year Horizon solved in 365 Steps of 1 Day

The smaller the step size the faster the step execution.
Tradeoff between runtime and results optimality should be considered

CONFIDENTIAL 47
Report Object

CONFIDENTIAL 48
Reports Properties
• Microsoft Access
Solution File • Flat Files
Formats • Compressed XML (native format)

• Options to write results in detail or


Period Types summary

• Control statistics and samples report for


Stochastics stochastic runs

• Allows objects to be selectively queried in


Filters the solution

CONFIDENTIAL 49
Reports Field List
 1200+ output available
 Access Field List to:
– Enable Object & Properties to report
– Control results granularity
– Choose Properties to report for each phase
– Save Samples & Statistics
– Write output to .csv

CONFIDENTIAL 50
Executing a Model

CONFIDENTIAL 51
Executing the Model

By default each database contains a ‘Base’


model with:
- Horizon
- Report
- ST Schedule

CONFIDENTIAL 52
Executing the Model

CONFIDENTIAL 53
Executing the Model

CONFIDENTIAL 54
Executing Options Queue models for execution

Choose how to execute the models


e.g. sequential or parallel runs?

CONFIDENTIAL 55
Solution Viewer

CONFIDENTIAL 56
Solution Folder

Name convention: Model <model name> Solution.zip

Saved in zipped XML file (.mbd also available)

Stored at the same location as the .xml database

Can be opened and view in the PLEXOS GUI

CONFIDENTIAL 57
Opening the Solution

CONFIDENTIAL 58
PLEXOS Solution Viewer

Data & Chart Tab


Ribbon menu

System tree

Tree and
Results pane
query pane
Result tab

Query parameters

CONFIDENTIAL 59
Solution Query
1. Highlight a Category or Object(s) from the System Tree
2. Define query parameters:
– Simulation phase
– Period type
– Date range (optional)
– Properties
3. Optional:
– Select a secondary property to generate a XY-axis chart
– Report by Timeslices if any (e.g. Peak, Offpeak)
– Display results by sample (Monte Carlo or stochastic simulation)
4. Execute the query

CONFIDENTIAL 60
Query Result Format
• Executed queries are displayed in the Results Pane
• Two format:
– Data/timeseries
– Chart
• Chart display options:
– Select chart format: line, bar, pie, 3D etc.
– Time series or duration curve
– Secondary Y-axis also available
• Solution charts can be copied to clipboard

CONFIDENTIAL 61
Export Solution Data
Write to flat files

Export to Excel

Right Click to Copy and Paste


selection of data

CONFIDENTIAL 62
Locating the Model Log File
• Ways to locate the model log file
1) Look for the Log File in the Solution Viewer

2) Open the solution file in the source directory

CONFIDENTIAL 63
Exercise 2: Model Execution & Results

DATABASE: Ex Model Execution_Base.xml

CONFIDENTIAL 64
Scenario-Based Analysis

CONFIDENTIAL 65
Scenario
A Typical representation of scenarios in energy modelling:

*Illustration is taken from US Department of Energy (http://energy.gov/eere/wind/maps/wind-vision)

CONFIDENTIAL 66
Scenarios in PLEXOS
1
• What is a scenario in PLEXOS?
– A set of properties values grouped
by a label under the Scenario field 2
• Specifying a scenario involves:
1. Create a Scenario Object
2. Link relevant properties to the 3
Scenario
3. Establish a membership between
a Scenario and a Model

CONFIDENTIAL 67
A Few Things to Remember
• Adding a Scenario to a Model instructs
PLEXOS to use:
• all the properties tagged with that scenario,
as well as,
• all the properties that have no tag i.e. base
data.
• Data from Scenarios overrides untagged data.
• Deleting a Scenario object – two options:
• Delete all properties associated with respective scenario
• Promote all properties associated with respective scenario to
base data

CONFIDENTIAL 68
Illustration of Scenario Usage

Property Value SCENARIO Model:


Low Efficiency
Gen 2 Pmax 50
High Load
Gen 2 Ramp Rate 5
Ramp
Gen 2 Heat Rate 10 Low Efficiency Pmax Heat Rate
rate
Gen 2 Heat Rate 8 High Efficiency
GEN2 50
GEN1 80
? ?
Gen 1 Pmax 80
Load
Gen 1 Ramp Rate 4 Low Efficiency
Gen 1 Ramp Rate 3 High Efficiency
NODE1 ?
Gen 1 Heat Rate 12 Low Efficiency
Gen 1 Heat Rate 10 High Efficiency Final input to simulation
Node 1 Load 70 Low Load
Node 1 Load 95 High Load

CONFIDENTIAL 69
Creating Scenario Object
• Use New Object command in the wizard dialog of the system collections.

CONFIDENTIAL 70
Tagging Properties with Scenario
• Label the dynamic properties with a Scenario in the dropdown list.

CONFIDENTIAL 71
Including Scenarios in Simulation
• Establish the membership between Model and Scenario by double-clicking
the Scenarios collection and selecting the Scenarios.

• Another approach is to drag-and-drop the Scenario object to the


Model object.

CONFIDENTIAL 72
Viewing Model/ Scenario Grid

• Model/Scenario grid – overview of


membership between simulation
models and scenarios

In object tree either right-click


“Models” or highlight Scenario
class, click Scenario Collection
and click on Model/Scenario Grid
button

CONFIDENTIAL 73
Exercise 3: Creating Scenario

DATABASE: Ex Creating Scenario_Base.xml

CONFIDENTIAL 74
PLEXOS Basic Modelling (II)

CONFIDENTIAL 75
Data Files

CONFIDENTIAL 76
Data Files
• Properties can be read from external data files
• Data files are objects that point to a comma separated values
(*.csv) file containing data which:
1. Contain dynamic property values (e.g. load, prices, etc.)
2. Can be used to build load and other input forecast
• Data files can be created from a database, text editor, or most
conveniently Excel
• After data input file is saved in “CSV” format
• Data Files can be viewed and edited Open directly in the GUI

CONFIDENTIAL 77
Data Files
• Linking object’s property to data file:
– Create a data file object
– Set the [Filename] property to name of the file containing the data e.g. Load.csv
– Filename may be specified as fully qualified or relative
1. Fully qualified - specifies the entire location: “C:\Data\Load\Load.csv”
2. Relative - contains only portion of the full file location: “Load\Load.csv”
In this case folder “Load” must be in the same location as the input file
– Right click the Data file and select “View” to view/edit values
– Set the desired property to use the data file object as its values e.g. Regional
load

CONFIDENTIAL 78
Data Files
• Several different text file layouts available
• Different layouts allow definition of data and time, period of day, bands for
multi band data, patterns for repeating values…
• Text file delimiter can be set to any ASCII character using the Settings menu
• The default characters are comma and tab
• Some layouts are sensitive to regional datetime setting on local computer
– Datetime format: UK: DD/MM/YYYY or US: MM/DD/YYYY
– Data File Locale property identifies the culture settings that were used when the
Data File was created: United States 1033
United Kingdom 2057

CONFIDENTIAL 79
Data File Layouts
• Every data file must have a header row which
describes layout format
• Date (time interval) and values can be
entered in following formats:
DATETIME format:
– Dates entered in date format which matches
the local regional settings
e.g. DD/MM/YYYY HH:MM:SS
– Refers to the start of the period
e.g. “1/1/2015 3:00 AM”
in hourly simulation refers to 3:00 – 4:00 AM

CONFIDENTIAL 80
Data File Layouts
PERIODS IN COLUMNS / ROWS format:
– using explicit YEAR, MONTH , DAY and
PERIOD fields
Periods in rows combined
– Period is a index of the day interval. e.g. 1-24 with Names in Columns
format
periods for hourly interval, 1-48 for half-hourly,
1-288 for 5 minute…
NAMES IN COLUMNS format:
– Specifying property values for multiple objects
– Names must correspond to respective object
names in database

CONFIDENTIAL 81
Data File Layouts
PATTERN format:
Profile that is being repeated
– To create data that repeat with certain every day in month January
pattern
– Using Timeslice PATTERN syntax
– Using created Timeslice objects
Many other formats and their combinations
available

CONFIDENTIAL 82
Exercise 4: Data Files

DATABASE: Ex Data Files_Base.xml

CONFIDENTIAL 83
Fuels

CONFIDENTIAL 84
Fuel Class
• The Fuel class is used to represent all types of fuel used for
generation and generating unit start up
• Limits to fuel consumption can be imposed by properties:
• Max Offtake – fuel consumption limit in simulation interval
(periods per day)
• Max Offtake [Hour, Day, Week, Month, Year] – fuel consumption
limit for respective period
• The cost of the Fuel is set by either:
– defining the Fuel Price property; or
– by associating the Fuel with Fuel Contract(s)

CONFIDENTIAL 85
Assigning Fuels to Generators
• Establish membership of the Generator and the Fuels
• Multiple Fuels can be assigned to a Generator
• User-defined fixed fuel mixture: Generator [Fuels] [Ratio]
• Fuel mixture ranges: Generator [Fuels] [Max Ratio] / [Fuels] [Min Ratio]
• Model determines the fuel mixture on an economical basis
• Define Generator fuel transport charge
• Fuel dispatch cost is increased by Generator [Fuels] [Transport Charge]
when calculating generator dispatch costs
• Different heat rates can be defined for different fuel burns:
Generator [Fuel] [Heat Rate]

CONFIDENTIAL 86
Setting Up Multiple Fuels
• Collections Generator Fuels and
Generator Start Fuels are one-to-one
by default!

• To model multiple fuels for


generation or start-up, the collection
should be changed to One-to-many
using in Config.

CONFIDENTIAL 87
Fuels Modelling
1. Define a Fuel object in Fuel class
2. Assign Fuels to Generators
3. Define fuel dispatch price or accounting price
 Optional:
• Define fuel accounting price
• Define Generator [Fuels] [Transport charge]
• Define fuel limits i.e. availability on different timescales

CONFIDENTIAL 88
Exercise 5: Creating Fuel Objects

DATABASE: Ex Fuels_Base.xml

CONFIDENTIAL 89
Fuel Contracts

CONFIDENTIAL 90
Fuel Contract
• Fuel Contract class provides a convenient
way to define fuel availability, cost, and take
or pay commitments.

• Add the Fuel involved in the contract to the


Fuel collection.
• Fuel can associated with any number of Fuel
Contract objects
• The contracts are additive (e.g. you may
have a number of contracts at different price
levels).

CONFIDENTIAL 91
Fuel Contract Properties
The details of the contract are defined with following properties:
• Fuel Price under contract
• The availability (upper limit on fuel usage) is set by the Quantity,
Quantity [Hour, Day, Week, Month, or Year] properties.
• Optional take or pay level (lower limit on fuel usage) is set by the
Take or Pay Quantity, Take or Pay Quantity [Hour, Day, Week, Month,
or Year] properties.
• The maximums are hard limits, but the take-or-pay levels can be
made as soft constraints with the penalty price defined by [Take or
Pay Price] property.

CONFIDENTIAL 92
Example of Take-of-Pay
Fuel Contract Property Value Units
GAS LT Price 3 $/GJ
GAS LT Quantity 1900 GJ
GAS LT Quantity Year 25000 TJ
GAS LT Take-or-Pay Quantity Day 50 TJ
GAS LT Take-or-Pay Price 0.25 $/GJ

• Contract price of fuel is $3/GJ.


• There is a limit for each period (e.g. hour) of 1900 GJ.
• The contract maximum in a year is 25000 TJ (note that all properties for daily,
weekly, etc. are in thousands of units).
• There is a take-or-pay obligation at the daily level of 50 TJ that can be
breached at $0.25/GJ.

CONFIDENTIAL 93
Exercise 6: Fuel Contracts

DATABASE: Ex Fuel Contracts_Base.xml

CONFIDENTIAL 94
End

CONFIDENTIAL 95

You might also like