Skip to content

v0.1.2

Choose a tag to compare

@ADGEfficiency ADGEfficiency released this 03 Jul 10:23
· 41 commits to main since this release
5565f39

energypylinear in PyPI

$ pip install energypylinear

Asset API

The asset API can be used to optimize one asset:

import energypylinear as epl

#  2.0 MW, 4.0 MWh battery
asset = epl.battery.Battery(power_mw=2, capacity_mwh=4, efficiency=0.9)

results = asset.optimize(
  electricity_prices=[100.0, 50, 200, -100, 0, 200, 100, -100]
)

Site API

The asset API can be used to optimize many assets:

import energypylinear as epl

site = epl.Site(assets=[
  epl.Battery(power_mw=2.0, capacity_mwh=4.0),
  epl.Generator(
    electric_power_max_mw=100,
    electric_power_min_mw=30,
    electric_efficiency_pct=0.4
  ),
  epl.EVs(
      chargers_power_mw=[100, 100],
      charge_events_capacity_mwh=[50, 100, 30, 40],
      charge_events=[
          [1, 0, 0, 0, 0],
          [0, 1, 1, 1, 0],
          [0, 0, 0, 1, 1],
          [0, 1, 0, 0, 0]
      ]
  )
])

results = site.optimize(
  electricity_prices=[100, 50, 200, -100, 0],
  high_temperature_load_mwh=[105, 110, 120, 110, 105],
  low_temperature_load_mwh=[105, 110, 120, 110, 105]
)

Documentation

0.1.2 - latest.