cronian.electric_power

Attributes

add_prosumer_total_electricity_generated_locally_to_model

add_prosumer_total_electricity_withdrawn_from_grid_to_model

Functions

add_prosumer_electric_power(→ None)

Add prosumer's electric power variable to the model.

add_prosumer_total_electricity_expression_to_model(→ None)

Add total electricity (withdrawn or generated) expression to model.

add_prosumer_corrected_electric_demand_to_model(→ None)

Add the prosumer's corrected electric demand to the model.

check_if_prosumer_has_electric_demand(→ bool)

Check if the prosumer has an electric demand.

calculate_average_efficiency_of_assets_directly_supplying_electric_demand(→ float)

Calculate average efficiency of assets directly supplying electric demand.

Module Contents

cronian.electric_power.add_prosumer_electric_power(model: pyomo.environ.AbstractModel, prosumer: dict) None

Add prosumer’s electric power variable to the model.

The prosumer interacts with the rest of the system (grid/market) through its electric power variable. It is positive when the prosumer is net injecting electricity to the grid, and negative when net consuming from the grid.

Args:

model: Pyomo Abstract model. prosumer: Dictionary containing prosumer details.

cronian.electric_power.add_prosumer_total_electricity_expression_to_model(model: pyomo.environ.AbstractModel, prosumer_id: str, assets: dict, expression_type: str, asset_direction_of_electricity_flow: str, storage_asset_attribute: str, non_storage_asset_attribute: str) None

Add total electricity (withdrawn or generated) expression to model.

Args:

model: Pyomo Abstract model. prosumer_id: The prosumer’s unique ID. assets: Dictionary containing prosumer’s assets. expression_type: total_electricity expression type: withdrawn/generated. asset_direction_of_electricity_flow: Asset’s direction of electricity

flow: input or output.

storage_asset_attribute: charge if the direction of electricity flow is

input, and discharge if the direction of electricity flow is output.

non_storage_asset_attribute: electricity_consumption if the direction of

electricity flow is input, and electricity_supply if the direction of electricity flow is output.

cronian.electric_power.add_prosumer_total_electricity_generated_locally_to_model
cronian.electric_power.add_prosumer_total_electricity_withdrawn_from_grid_to_model
cronian.electric_power.add_prosumer_corrected_electric_demand_to_model(model: pyomo.environ.AbstractModel, prosumer: dict) None

Add the prosumer’s corrected electric demand to the model.

The corrected electric demand is calculated by summing the base and flexible electricity demand of the prosumer and dividing that by the average efficiency of assets directly supplying the electric demand.

Args:

model: Pyomo Abstract model. prosumer: Dictionary containing prosumer details.

cronian.electric_power.check_if_prosumer_has_electric_demand(prosumer: dict) bool

Check if the prosumer has an electric demand.

Args:

prosumer: Dictionary containing prosumer details.

Returns:

True if the prosumer has electric demand, False otherwise.

cronian.electric_power.calculate_average_efficiency_of_assets_directly_supplying_electric_demand(assets: dict) float

Calculate average efficiency of assets directly supplying electric demand.

Args:

assets: Dictionary containing prosumer’s assets.

Returns:

Average efficiency of assets directly supplying electric demand.