Skip to content

Commit

Permalink
Merge pull request #16 from RAMP-project/development
Browse files Browse the repository at this point in the history
Development
  • Loading branch information
FLomb authored Jun 23, 2021
2 parents 4aeb34d + cefedc4 commit c2ebf4b
Show file tree
Hide file tree
Showing 5 changed files with 105 additions and 6 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@
Release History
===============

0.3.1 (2021-06-23)
------------------

**|new|** added "input_file_3" as an example of e-cooking loads

**|changed|** the way in which input files are called in the ramp_run script has been changed to be more explicit and user-friendly

**|changed|** the readme.md has been updated to describe the purpose of the 3 provided input files, 1: basic electric appliances, 2: DHW, 3: cooking

**|changed|** the pubs_list.md has been updated with two new publications


0.3.0 (2021-05-28)
------------------

Expand Down
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,16 @@ The model is developed in Python 3.6, and requires the following libraries:
* random

## Quick start
To get started, download the repository and simply run the "ramp_run.py" script. The console will ask how many profiles (i.e. independent days) need to be simulated, and will provide the results based on the default inputs defined in `input_file_1`.py and `input_file_2`. To change the inputs, just modify the latter files. Some guidance about the meaning of each input parameter is available in the `core.py` file, where the *User* and *Appliance* Python classes are defined and fully commented.
To get started, download the repository and simply run the "ramp_run.py" script. The console will ask how many profiles (i.e. independent days) need to be simulated, and will provide the results based on the default inputs defined in `input_file_x`.py. To change the inputs, just modify the latter files. Some guidance about the meaning of each input parameter is available in the `core.py` file, where the *User* and *Appliance* Python classes are defined and fully commented.

### Example input files
Three different input files are provided as example representing three different categories of appliancces that can be modelled with RAMP.

- `input_file_1.py`: represents the most basic electric appliances, is an example of how to model lightbulbs, radios, TVs, fridges, and other electric appliances. This input file is based on the ones used for [this publication](https://doi.org/10.1016/j.energy.2019.04.097).

- `input_file_2.py`: shows how to model thermal loads, with the example of a "shower" appliance. The peculiarity of thermal appiances is that the nominal power can be provided as external input as a "csv" file (in this case, `shower_P.csv`). For the example "shower" appliance, the varying nominal power accounts for the effect of groundwater temperature variation throughout the year. This input file is based on that used for [this publication](https://doi.org/10.3390/app10217445).

- `input_file_3.py`: represents an example of how to model electric cooking appliances. This input file is used in [this publication](https://doi.org/10.1109/PTC.2019.8810571)

## Authors
The model has been developed by:
Expand Down
4 changes: 3 additions & 1 deletion docs/pubs_list.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
## List of publications
This is an up-to-date list of all publications featuring RAMP.

*Giacomo Falchetta, Nicolò Stevanato, Magda Moner-Girona, Davide Mazzoni, Emanuela Colombo, Manfred Hafner, M-LED: Multi-sectoral Latent Electricity Demand Assessment for Energy Access Planning, FEEM Working Papers (2020), https://www.econstor.eu/handle/10419/223636*
*Giacomo Falchetta, Nicolò Stevanato, Magda Moner-Girona, Davide Mazzoni, Emanuela Colombo, Manfred Hafner, The M-LED platform: advancing electricity demand assessment for communities living in energy poverty, Environmental Reasearch Letters (2021), https://doi.org/10.1088/1748-9326/ac0cab*

*Nicolò Stevanato, Lorenzo Rinaldi, Stefano Pistolese, Sergio Balderrama, Sylvain Quoilin, Emanuela Colombo, Modeling of a Village-Scale Multi-Energy System for the Integrated Supply of Electric and Thermal Energy, Applied Sciences (2020), https://doi.org/10.3390/app10217445*

*Francesco Lombardi, Sylvain Quoilin, Emanuela Colombo, Modelling distributed Power-to-Heat technologies as a flexibility option for smart heat-electricity integration, Proceedings of ECOS 2020, pp. 2369-2380, http://hdl.handle.net/11311/1143671*

Expand Down
75 changes: 75 additions & 0 deletions ramp/input_files/input_file_3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# -*- coding: utf-8 -*-

#%% Definition of the inputs
'''
Input data definition
'''

from ramp.core.core import User, np, pd
User_list = []


'''
This example input file represents a single household user whose only loads
are the "cooking" activities. The example showcases how to model electric cooking loads by means of
the Prefence Index and User Preference attributes.
'''

#Create new user classes
HH = User("generic household",1,3)
User_list.append(HH)

#Create new appliances

#Create Cooking appliances

HH_lunch1_soup = HH.Appliance(HH,1,1800,2,70,0.15,60, thermal_P_var = 0.2, pref_index =1, fixed_cycle=1)
HH_lunch1_soup.windows([12*60,15*60],[0,0],0.15)
HH_lunch1_soup.specific_cycle_1(1800,10,750,60,0.15)
HH_lunch1_soup.cycle_behaviour([12*60,15*60],[0,0])

HH_lunch2_rice = HH.Appliance(HH,1,1800,2,25,0.15,20, thermal_P_var = 0.2, pref_index = 2, fixed_cycle=1)
HH_lunch2_rice.windows([12*60,15*60],[0,0],0.15)
HH_lunch2_rice.specific_cycle_1(1800,10,750,15,0.15)
HH_lunch2_rice.cycle_behaviour([12*60,15*60],[0,0])

HH_lunch2_egg = HH.Appliance(HH,1,1200,2,3,0.2,3, thermal_P_var = 0.2 , pref_index = 2)
HH_lunch2_egg.windows([12*60,15*60],[0,0],0.15)

HH_lunch2_platano = HH.Appliance(HH,1,1800,2,10,0.15,5, thermal_P_var = 0.2, pref_index = 2, fixed_cycle=1)
HH_lunch2_platano.windows([12*60,15*60],[0,0],0.15)
HH_lunch2_platano.specific_cycle_1(1800,5,1200,5,0.15)
HH_lunch2_platano.cycle_behaviour([12*60,15*60],[0,0])

HH_lunch2_meat = HH.Appliance(HH,1,1200,2,7,0.15,3, thermal_P_var = 0.2, pref_index = 2)
HH_lunch2_meat.windows([12*60,15*60],[0,0],0.15)

HH_lunch3_beansnrice = HH.Appliance(HH,1,1800,2,45,0.2,30, thermal_P_var =0.2 , pref_index = 3, fixed_cycle=1)
HH_lunch3_beansnrice.windows([12*60,15*60],[0,0],0.15)
HH_lunch3_beansnrice.specific_cycle_1(1800,10,750,35,0.2)
HH_lunch3_beansnrice.cycle_behaviour([12*60,15*60],[0,0])

HH_lunch3_meat = HH.Appliance(HH,1,1200,2,10,0.2,5, thermal_P_var = 0.2, pref_index = 3)
HH_lunch3_meat.windows([12*60,15*60],[0,0],0.15)

HH_lunch_yuca = HH.Appliance(HH,1,1800,1,25,0.15,10, thermal_P_var = 0.2, pref_index =0, fixed_cycle=1)
HH_lunch_yuca.windows([13*60,14*60],[0,0],0.15)
HH_lunch_yuca.specific_cycle_1(1800,10,750,15,0.15)
HH_lunch_yuca.cycle_behaviour([12*60,15*60],[0,0])

HH_breakfast_huminta = HH.Appliance(HH,1,1800,1,65,0.15,50, thermal_P_var = 0.2, pref_index =0, fixed_cycle=1)
HH_breakfast_huminta.windows([6*60,9*60],[0,0],0.15)
HH_breakfast_huminta.specific_cycle_1(1800,5,750,60,0.15)
HH_breakfast_huminta.cycle_behaviour([6*60,9*60],[0,0])

HH_breakfast_bread = HH.Appliance(HH,1,1800,1,15,0.15,10, thermal_P_var = 0.2, pref_index =0, fixed_cycle=1)
HH_breakfast_bread.windows([6*60,9*60],[0,0],0.15)
HH_breakfast_bread.specific_cycle_1(1800,10,1200,5,0.15)
HH_breakfast_bread.cycle_behaviour([6*60,9*60],[0,0])

HH_breakfast_coffee = HH.Appliance(HH,1,1800,1,5,0.15,2, thermal_P_var = 0.2, pref_index =0)
HH_breakfast_coffee.windows([6*60,9*60],[0,0],0.15)

HH_mate = HH.Appliance(HH,1,1800,1,30,0.3,2, thermal_P_var = 0.2, pref_index =0)
HH_mate.windows([7*60,20*60],[0,0],0.15)

9 changes: 5 additions & 4 deletions ramp/ramp_run.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,12 @@
from core.stochastic_process import Stochastic_Process
from post_process import post_process as pp

# Define which input files should be considered and run.
# Files are specified as numbers in a list (e.g. [1,2] will consider input_file_1.py and input_file_2.py)
input_files_to_run = [1,2,3]

# Calls the stochastic process and saves the result in a list of stochastic profiles
# In this default example, the model runs for 2 input files ("input_file_1", "input_file_2"),
# but single or multiple files can be run restricting or enlarging the iteration range
# and naming further input files with progressive numbering
for j in range(2,3):
for j in input_files_to_run:
Profiles_list = Stochastic_Process(j)

# Post-processes the results and generates plots
Expand Down

0 comments on commit c2ebf4b

Please sign in to comment.