Giter VIP home page Giter VIP logo

piecewise-calliope's Introduction


Piecewise Calliope model

Installion

This study built from Calliope 0.4.1-dev to create a piecewise model.

The easiest way to install the necessary packages is to create a conda environment: conda create -n piecewise-calliope plotly. Activate the environment and install the necessary development branch:

pip install git+https://github.com/brynpickering/calliope.git@Piecewise_constrainedcurves

The study utilised CPLEX 12.6.2.0 for MILP solving.

Running models

Once Calliope installed, models can be run and results can be analysed as per the documentation.

Model run configurations can be found in the models folder, where each run configuration has been named as: run_[season]_[No. of breakpoints]bp_[linearisation method].yaml

The models will save their solutions as netCDF to an Output folder. These solution files are required for ex-post analysis functions to operate correctly.

Piecewise linearisation

The functions get_piecewise.py and minimize_linearisation_error.py are used to find breakpoint positions along technology nonlinear characteristic curves. Breakpoint allocation is done equidistantly as well as optimised (to reduce error vs. the nonlinear curve). The result of get_piecewise.py is a YAML file that is used by this modified version of Calliope to create piecewise constraints.

Ex-post analysis

ex-post.py contains a function for analysis of the error incurred by linearisation of consumption curves. Each linear model run is compared to its nonlinear counterpart, by applying the relevant nonlinear consumption curves to the technology outputs obtained using the linear optimisation. The output of this function is two xarray DataArrays, error and error_t. The former provides per technology & location error in consumption, heat to power ratio (for CHP) and cost. The latter additionally provides consumption and HTP error for each timestep.

How to cite

If you use this model or work derived from it in an academic publication, please cite the following paper:

Pickering, B. and Choudhary, R.. "Applying Piecewise Linear Characteristic Curves in District Energy Optimisation" 30th INTERNATIONAL CONFERENCE on Efficiency, Cost, Optimisation, Simulation and Environmental Impact of Energy Systems. San Diego, USA. 2017.

License

Copyright (c) 2016-2017 Bryn Pickering

License: CC BY-SA 4.0

This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

piecewise-calliope's People

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.