Coder Social home page Coder Social logo

patelshyamal / solarpv-der-simulation-utility Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tdcosim/solarpv-der-simulation-tool

0.0 0.0 0.0 1.43 MB

Allows user to run dynamics simulations for solar photovoltaic distributed energy resource connected to a stiff voltage source or to an external program. It allows modifying DER parameters, introducing external disturbance events, and visualizing the simulation results. The PV-DER (inverter) is modeled using dynamic phasor concept.

License: Other

Python 100.00%

solarpv-der-simulation-utility's Introduction

Status: Expect regular updates and bug fixes.

Utility for simulating dynamics of PV-DER

Build Status CodeFactor

Solar photovoltaic distributed energy resources (PV-DER) are power electronic inverter based generation (IBG) connected to the electric power distribution system (eg. roof top solar PV systems). This utility can be used to simulate the dynamics of a single DER connected to a stiff voltage source as shown in the following schematic:

schematic of PV-DER

Basics

The dynamics of the DER are modelled using dynamic phasors. Detailed description of the concepts behind this utility can be found in the IEEE publication Dynamic Modeling of Solar PV Systems for Distribution System Stability Analysis and detailed list of equations can be found in the Model specification document.

Links

Installation

You can install the module directly from GitHub with following commands:

git clone https://github.com/sibyjackgrove/SolarPV-DER-simulation-utility.git
cd SolarPV-DER-simulation-utility
pip install -e .

Use cases

Following projects are using Solar PV-DER simulation utility:

  1. Argonne Transmission and Distribution systems Co-Simulation tool (TDcoSim)
  2. OpenAI Gym Distributed Energy Resource Environment (Gym-DER)

Using the module

The module can be imported as a normal python module:

import pvder

Features

The following features are available currently:

  1. Single phase or three phase DER models (phase voltages may be unbalanced).
  2. Run simulation in stand alone mode with internal grid voltage source model.
  3. Run simulation in loop mode where grid voltage and frequency is supplied every time step by a third party program.
  4. Visualize or retrieve simulation results for voltages, current, active, and reactive power.
  5. Introduce solar insolation events (in all modes), grid voltage, and frequency change events (in stand alone mode).
  6. Retrive and modify model parameters from a third party program.
  7. Enable Low voltage ride through (LVRT) and Volt-VAR control logic.

Using the stand alone single phase DER model with 10 kW power rating

The following steps are required:

  1. First import the following classes:
from pvder.DER_components_single_phase import SolarPV_DER_SinglePhase
from pvder.grid_components import Grid
from pvder.dynamic_simulation import DynamicSimulation
from pvder.simulation_events import SimulationEvents
from pvder.simulation_utilities import SimulationResults
  1. Create a SimulationEvents object: This object is used to add or remove disturbance events occurs during the simulation.
events = SimulationEvents()
  1. Create a Grid object: This object describes the steady state model for the grid voltage source. It needs to be supplied with an SimulationEvents object.
grid = Grid(events=events)
  1. Create a SolarPV_DER_SinglePhase or SolarPV_DER_ThreePhase object: This object describes the dynamic DER model. It needs both an SimulationEvents object and a Grid object. The power rating of the DER are should also be provided.
PV_DER = SolarPV_DER_SinglePhase(grid_model=grid,events=events,Sinverter_rated = 10.0e3,standAlone = True)
  1. Create a DynamicSimulation object: This object runs the simulation and stores the solution. It takes SimulationEvents, Grid and, SolarPV_DER_SinglePhase objects as arguments.
sim = DynamicSimulation(grid_model=grid,PV_model=PV_DER,events = events)
  1. Create a SimulationResults object: This object is used to visualize the simulation results.
results = SimulationResults(simulation = sim)
  1. Add an event (for e.g. solar insolation change at 10.0 s):
events.add_solar_event(10,90)
  1. Specify simulation flags (for e.g. set the DEBUG_SIMULATION and DEBUG_POWER flag to true to observe the power at each time step.):
sim.DEBUG_SIMULATION = False
sim.DEBUG_POWER = False
  1. Specify simulation stop time (for e.g. 20.0 s):
sim.tStop = 20.0
  1. Run the simulation:
sim.run_simulation()
  1. Visualize the results (for e.g. the power output at PCC-LV side):
results.PER_UNIT = False
results.plot_DER_simulation(plot_type='active_power_Ppv_Pac_PCC')

Examples

Try out Jupyter notebooks with usage examples in Google Colab:

Basic usage: Basic usage

Updating model parameters: Updating model parameters

Module details

A schematic of the relationship between differen classes in the module is shown in the figure below: schematic of software architecture

Dependencies: SciPy, Numpy, Matlplotlib

Issues

Please feel free to raise an issue for bugs or feature requests.

Who is responsible?

Core developer:

Contributor:

Acknowledgement

This project was supported by Kemal Celik, U.S. DOE Office of Electricity, Solar Energy Technology Office through the SuNLaMP program.

The authors would like to acknowledge Shrirang Abhyankar and Puspal Hazra for their contribution.

Citation

If you use this code please cite it as:

@misc{pvder,
  title = {{SolarPV-DER-simulation-utility}: A simulation utility for or solar photovoltaic distributed energy resources},
  author = "{Siby Jose Plathottam,Karthikeyan Balasubramaniam}",
  howpublished = {\url{https://github.com/sibyjackgrove/SolarPV-DER-simulation-utility}},
  url = "https://github.com/sibyjackgrove/SolarPV-DER-simulation-utility",
  year = 2019,
  note = "[Online; accessed 19-March-2019]"
}

Copyright and License

Copyright © 2019, UChicago Argonne, LLC

Photovoltaic Distributed Energy Resource (PV-DER) Simulation Utility is distributed under the terms of BSD-3 OSS License.

solarpv-der-simulation-utility's People

Contributors

sibyjackgrove 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.