0% found this document useful (0 votes)
55 views11 pages

Hands-On Exercise 2

The document provides instructions for using the SAND Interface to create an energy system optimization model in OSeMOSYS. It describes how to create a new model file, define the duration of time slices in 96 time periods representing hours in a year, add year split values to allocate each time period as a fraction of a year, and check that the depreciation method and discount rate parameters are set to their default values. The document guides the user through setting up the key components of an energy system model in the SAND Interface.

Uploaded by

Abdulfatai Yakub
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
55 views11 pages

Hands-On Exercise 2

The document provides instructions for using the SAND Interface to create an energy system optimization model in OSeMOSYS. It describes how to create a new model file, define the duration of time slices in 96 time periods representing hours in a year, add year split values to allocate each time period as a fraction of a year, and check that the depreciation method and discount rate parameters are set to their default values. The document guides the user through setting up the key components of an energy system model in the SAND Interface.

Uploaded by

Abdulfatai Yakub
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 11

Energy and Flexibility

Modelling
Hands-on 2
Please use the following citation for:

• This exercise

Cannone, Carla, Allington, Lucy, & Howells, Mark. (2021, March). Hands-on 2: Energy and
Flexibility Modelling (Version 3.1.). Zenodo. https://doi.org/10.5281/zenodo.4605256

• clicSAND Software

Cannone, C., Allington, L., De Wet, N., Shivakumar, A., Goyns, P., Valderrama, C., Howells, M.
(2021). clicSAND [computer software]. http://doi.org/10.5281/zenodo.4593100

• OSeMOSYS Google Forum

Please sign up to the help Google forum here. If you are stuck, please ask questions here. If
you get ahead, please answer questions in the same forum. Please state that you are using
the ‘clicSAND’ Interface.

______________________________________________________________________________________

Learning outcomes
By the end of this exercise, you will be able to:

1. Create a new model in SAND Interface


2. Learn the main functionalities of SAND Interface
3. Define the duration of Time slices
4. Add Year Split values
5. Check Depreciation Method and Discount Rate values

1 of 11
Create a new model
After installing the software and downloading the files needed (as for Hands-on 1) you are
ready to create your first model in OSeMOSYS using the interface named SAND. This is an
Excel-based (Macro-Enabled) file where you can input the data needed for OSeMOSYS to
find the optimal solution to your problem. Let’s learn how to save and manage your files.

Try it:

1. We will start by creating a folder called “HO2” for this Hands-on 2.


2. Then open the clicSAND folder -> double click on the clicSAND.

3. Click on “Export Templates” (highlighted in orange) to the HO2 folder in you


created.

This will automatically save a blank copy of:

a. SAND Interface (Excel Macro Enabled Workbook)


b. Results Database (Access database to store the results obtained)

2 of 11
c. Results Template (Excel Macro Enabled Workbook)
d. OSeMOSYS_code_Hands-on (Text file)

Please rename these files as:

a. SAND_Interface_HO2
b. Results_Database_HO2
c. Results_Template_HO2
d. The code will be the same for all the exercise so there is no need to rename it

Watch out: Every time you make substantial changes to your model, save it as a new
version in the correspondent folder. For example, if I want to test different options in my
Hands-on 2 file, I will create a new file in the folder Hands-on 2 called
“SAND_Interface_HO2_v2” and so on.

Repeat these steps for each Hands-on (New folder-> ModelRunner-> ExportTemplates in
the HOX folder)

Important: The files should not be saved or sync in One Drive for clicSAND to work

Voilà: you now know how to manage your folders and files!

Main functionalities of SAND Interface


Now the next step is learning how to use SAND Interface. Don’t worry, it looks more
complicated than it really is.

3 of 11
SETS, Parameters and ToDataFile Sheets represent the core of the Interface, and they are
entirely interconnected to each other.

Try it: let’s move around and check what we can do in each of these Sheets:

1. SETS - this is the place where you can define the name of your Technologies (in
column B), Commodities (in column E) and Emissions (in column H).

These three columns are linked to the “ToDataFile” Sheet that has the format needed by
the solver to find the optimal solution. Therefore, whenever you specify the name of a
Technology, Commodity or Emission in these columns, it is automatically reported in the
respective cell in the ToDataFile Sheet.

You have the freedom to change names as many times as necessary without
losing the data previously added for that specific entry.

Watch out: Technologies, Commodities and Emissions codes in your model should be
named following the guidelines explained in Lecture 3.

2. Parameters - this is a giant Sheet where you will be adding data for each
OSeMOSYS parameter. To make things easier and faster for you, there are filters at
the top of each column where you can filter for either Parameter (column A),
Technology (Column C), Commodities/Fuel (Column F). Columns K to BN is
where you can insert data from 2015 to 2070.

4 of 11
Try it: in Column A, filter for Parameters -> Tick Year Split -> OK. You will see that now
only data associated with the parameter called Year Split are shown on the table. You can
add as many filters as wanted. Play around with filters and get confident with this
functionality!

5 of 11
And this is what you will see if you filter out for the Parameter Year Split:

6 of 11
You see that from column K to column BN there are default values added: in this case 0.
We will add data for the year split at the end of this hands-on.

3. ToDataFile - this Sheet has the format needed by the solver to find the optimal
solution to your problem.

Watch out: never add data to this ToDataFile Sheet - data should only be added to the
Parameters and SETS sheets. The interface is made up in a way that all the entries will be
automatically read by the ToDataFile sheet.

4. Naming – here you will find the description of the parameters used in SAND
Interface. We are not going to use all the parameters listed here.

Define the duration of time slices


To carry out a modelling exercise with OSeMOSYS, it is necessary to assign values to the set
called Timeslices, which represents periods of the year with a similar demand. In this
model, the year was initially divided into 4 timeslices, representing two periods of 6 months
(two representative seasons) each of which has similar demand, further sub-divided into
day and night periods, called: Summer Day (SD), Summer Night (SN), Winter Day (WD),
Winter Night (WN).

However, in SAND Interface it is possible to define up to 96 timeslices, so these initial data


were manipulated to obtain a 24-hour representation of a reference day for each of SD, SN,
WD, and WN (24 hours each * 4 = 96 timeslices). Therefore, each year is divided into 96
periods instead of the previous 4.

It was assumed each season has an equal length, with an average hourly split per season
(24h representative). Therefore obtaining:

4 Seasons/year * 24h of a representative day/season = 96 Timeslices/Year

Each Timeslice represents an equal fraction of the Year in the following way, defined as the
Year Split:

1 Year / 96 Timeslices = 0.0104

Therefore, you should add this number to the Year Split column for each year.

7 of 11
Watch out! To help you deal with all the data, there is a Data Preparation Spreadsheet
that will allow you to copy-paste the data in a faster way. Click on the link and below the
preview you will see the tab called “Files”. Click Download next to Data_Prep_HO2.xlsx

IMPORTANT: Unfortunately, you cannot copy paste all the data in one go, so you need to
copy paste each line individually. This is because, when filters are applied, Excel will not
copy-paste the data into the correct rows of the spreadsheet if multiple lines are copy-
pasted at the same time. Therefore, if you select all the data at once, instead of line-by-line,
you will add data for completely wrong parameters and the model will not work.

To help you with this task, check the blue cells in the Data preparation file that highlight the
data you need to change every time.

Add Year Split values


After defining the duration of each time slice and calculating the Year Split profile we need
to add these values in SAND Interface.

Try it: let’s add the data for Year Split.

1. Go in Parameters Sheet and filter for Year Split (in Column A).

2. Copy-paste data obtained in Column C of the Data Preparation File to Column K


of SAND interface, corresponding to the year 2015.

IMPORTANT: right click on Cell K48662 and PASTE VALUES (second icon from the
left).

8 of 11
3. Go to Cell K48662; click ctrl+alt+down-arrow to select only the data in column K.
Drag and drop to copy them for the other years by moving to the right side until
column BK for the year 2070.

9 of 11
You should have now added the Year Split values for all 96 time slices available in SAND
Interface for every model year from 2015-2070.

Voilà: you added the data for the parameter Year Split from 2015 to 2070

Check Depreciation Method and


Discount Rate values
We will leave default values for Depreciation Method and Discount Rate. In the future, you
are free to change them following these steps.

Try it:

1. Go to Parameters Sheet -> In Column A filter out for “Depreciation Method” and
“Discount Rate” parameters -> click OK. You will see the following. Do not change
these numbers, we will use these defaults values.

The depreciation method will have a value of 1 and the discount rate of 0.1 (10% discount
rate). These are time independent variables; you will therefore see their value in Column J.

10 of 11
When a variable is time dependent instead, no values will be in Column J and there will be a
value for each of the modelling years (Column K to Column BN).

Name Description

Duration of a modelled time slice, expressed as a fraction of the year.


YearSplit
The sum of each entry over one modelled year should equal 1.

Region specific value for the discount rate, expressed in decimals


DiscountRate
(e.g. 0.1)

Binary parameter defining the type of depreciation to be applied. It


DepreciationMet
has value 1 for sinking fund depreciation, value 2 for straight-line
hod
depreciation.

11 of 11

You might also like