energy package¶
The energy package gathers the energy units, poles and nodes modules:
The energy units inherit from the EnergyUnit
object which
itself inherit from the Unit
object.
Energy_units module¶
** This module defines the energy units of OMEGALPES. The production, consumption and storage unit will inherit from it. **
The energy_units module defines the basic attributes and methods of an energy unit in OMEGALPES.
- It includes the following attributes and quantities:
- p : instantaneous power of the energy unit (kW)
- p_min : minimal power (kW)
- p_max : maximal power (kW)
- e_tot : total energy during the time period (kWh)
- e_min : minimal energy of the unit (kWh)
- e_max : maximal energy of the unit (kWh)
- u : binary describing if the unit is operating or not at t (delivering or consuming P)
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.units.energy_units.
EnergyUnit
(time, name, flow_direction='in', p=None, p_min=-10000.0, p_max=10000.0, e_min=-1000000.0, e_max=1000000.0, starting_cost=None, operating_cost=None, min_time_on=None, min_time_off=None, max_ramp_up=None, max_ramp_down=None, co2_out=None, availability_hours=None, energy_type=None, operator=None, verbose=False)[source]¶ Bases:
omegalpes.general.optimisation.core.OptObject
** Description **
- Module dedicated to the parent class (EnergyUnit) of :
- production units
- consumption units
- storage units
-
minimize_CO2_emissions
(weight=1)[source]¶ Parameters: weight – Weight coefficient for the objective Returns:
-
set_energy_limits_on_time_period
(e_min=0, e_max=None, start='YYYY-MM-DD HH:MM:SS', end='YYYY-MM-DD HH:MM:SS', period_index=None)[source]¶ Parameters: - e_min – Minimal energy set during the time period (int or float)
- e_max – Maximal energy set during the time period (int or float)
- start – Date of start of the time period YYYY-MM-DD HH:MM:SS ( str)
- end – Date of end of the time period YYYY-MM-DD HH:MM:SS (str)
-
class
omegalpes.energy.units.energy_units.
FixedEnergyUnit
(time, name: str, p: list, flow_direction='in', starting_cost=None, operating_cost=None, co2_out=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.EnergyUnit
Description
Energy unit with a fixed power profile.Attributs
- p : instantaneous power known by advance (kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the EnergyUnit
-
class
omegalpes.energy.units.energy_units.
SawtoothEnergyUnit
(time, name, flow_direction, p_peak, p_low, alpha_peak, t_triangle, t_sawtooth, mandatory=True, starting_cost=None, operating_cost=None, co2_out=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.ShiftableEnergyUnit
-
class
omegalpes.energy.units.energy_units.
SeveralEnergyUnit
(time, name, fixed_power, pmin=1e-05, pmax=100000.0, imaginary=False, e_min=0, e_max=1000000.0, nb_unit_min=0, nb_unit_max=None, flow_direction='in', starting_cost=None, operating_cost=None, max_ramp_up=None, max_ramp_down=None, co2_out=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.VariableEnergyUnit
Description
Energy unit based on a fixed power curve enabling to multiply several times (nb_unit) the same power curve
Be careful, if imaginary == True, the solution may be imaginary as nb_unit can be continuous. The accurate number of the power unit should be calculated later
Attributs
- fixed_power : fixed power curve
-
class
omegalpes.energy.units.energy_units.
ShiftableEnergyUnit
(time, name: str, flow_direction, power_values, mandatory=True, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.VariableEnergyUnit
Description
EnergyUnit with shiftable power profile.Attributs
- power_values : power profile to shift (kW)
- mandatory : indicates if the power is mandatory : True
- or not : False
- starting_cost : cost of the starting of the EnergyUnit
- operating_cost : cost of the operation (€/kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the EnergyUnit
-
class
omegalpes.energy.units.energy_units.
SquareEnergyUnit
(time, name, p_square, n_square, t_between_sq, t_square=1, flow_direction='in', starting_cost=None, operating_cost=None, co2_out=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.VariableEnergyUnit
-
class
omegalpes.energy.units.energy_units.
TriangleEnergyUnit
(time, name, flow_direction, p_peak, alpha_peak, t_triangle, mandatory=True, starting_cost=None, operating_cost=None, co2_out=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.ShiftableEnergyUnit
-
class
omegalpes.energy.units.energy_units.
VariableEnergyUnit
(time, name, flow_direction='in', p_min=-10000.0, p_max=10000.0, e_min=-1000000.0, e_max=1000000.0, starting_cost=None, operating_cost=None, min_time_on=None, min_time_off=None, max_ramp_up=None, max_ramp_down=None, co2_out=None, availability_hours=None, energy_type=None, operator=None)[source]¶
Consumption_units module¶
** This module defines the consumption units**
The consumption_units module defines various classes of consumption units, from generic to specific ones.
- It includes :
ConsumptionUnit : simple consumption unit. It inherits from EnergyUnit, its power flow direction is always ‘in’.
- 3 Objectives are also available :
- minimize consumption, maximize consumption and minimize
consumption costs.
FixedConsumptionUnit : consumption with a fixed load profile. It inherits from ConsumptionUnit.
VariableConsumptionUnit : consumption unit allowing for a variation of power between pmin et pmax. It inherits from ConsumptionUnit.
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.units.consumption_units.
ConsumptionUnit
(time, name, p=None, p_min=1e-05, p_max=100000.0, e_min=0, e_max=1000000.0, co2_out=None, starting_cost=None, consumption_cost=None, min_time_on=None, min_time_off=None, max_ramp_up=None, max_ramp_down=None, availability_hours=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.EnergyUnit
Description
Simple Consumption unitAttributes
- p : instantaneous power demand (kW)
- pmax : maximal instantaneous power demand (kW)
- pmin : minimal instantaneous power demand (kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- consumption_cost : cost associated to the energy consumption
- operator : stakeholder how owns the consumption unit
-
class
omegalpes.energy.units.consumption_units.
FixedConsumptionUnit
(time, name, p: list = None, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.FixedEnergyUnit
,omegalpes.energy.units.consumption_units.ConsumptionUnit
Description
Consumption unit with a fixed consumption profile.Attributes
- p : instantaneous power demand known in advance (kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- consumption_cost : cost associated to the energy consumption
- operator : stakeholder how owns the consumption unit
-
class
omegalpes.energy.units.consumption_units.
SeveralConsumptionUnit
(time, name, fixed_cons, pmin=1e-05, pmax=100000.0, e_min=0, e_max=1000000.0, nb_unit_min=0, nb_unit_max=None, co2_out=None, starting_cost=None, operating_cost=None, max_ramp_up=None, max_ramp_down=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.consumption_units.VariableConsumptionUnit
,omegalpes.energy.units.energy_units.SeveralEnergyUnit
Description
Consumption unit based on a fixed consumption curve enabling to multiply several times (nb_unit) the same consumption curveAttributs
- fixed_cons : fixed consumption curve
-
class
omegalpes.energy.units.consumption_units.
SeveralImaginaryConsumptionUnit
(time, name, fixed_cons, pmin=1e-05, pmax=100000.0, e_min=0, e_max=1000000.0, nb_unit_min=0, nb_unit_max=None, co2_out=None, starting_cost=None, operating_cost=None, max_ramp_up=None, max_ramp_down=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.consumption_units.VariableConsumptionUnit
,omegalpes.energy.units.energy_units.SeveralEnergyUnit
Description
Consumption unit based on a fixed consumption curve enabling to multiply several times (nb_unit) the same consumption curve. Be careful, the solution may be imaginary as nb_unit can be continuous. The accurate number of the consumption unit should be calculated later- Attributs
- fixed_cons : fixed consumption curve
-
class
omegalpes.energy.units.consumption_units.
ShiftableConsumptionUnit
(time, name: str, power_values, mandatory=True, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.ShiftableEnergyUnit
,omegalpes.energy.units.consumption_units.VariableConsumptionUnit
Description
Consumption unit with shiftable consumption profile.Attributs
- power_values : consumption profile to shift (kW)
- mandatory : indicates if the consumption is mandatory : True
- or not : False
- starting_cost : cost of the starting of the consumption
- operating_cost : cost of the operation (€/kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the consumption unit
-
class
omegalpes.energy.units.consumption_units.
SquareConsumptionUnit
(time, name, p_square, duration, n_square, t_between_sq, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.SquareEnergyUnit
,omegalpes.energy.units.consumption_units.VariableConsumptionUnit
Description
- Consumption unit with a fixed value and fixed duration.
- >> Only the time of beginning can be modified >> Operation can be mandatory or not
Attributs
- p : instantaneous power consumption (kW)
- duration : duration of the power delivery (hours)
- mandatory : indicates if the power delivery is mandatory or not
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- consumption_cost : cost associated to the energy consumption
- operator : stakeholder how owns the consumption unit
-
class
omegalpes.energy.units.consumption_units.
VariableConsumptionUnit
(time, name, pmin=1e-05, pmax=100000.0, e_min=0, e_max=1000000.0, co2_out=None, starting_cost=None, operating_cost=None, min_time_on=None, min_time_off=None, max_ramp_up=None, max_ramp_down=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.VariableEnergyUnit
,omegalpes.energy.units.consumption_units.ConsumptionUnit
Description
Consumption unit with a variation of power between pmin et pmax.Attributs
- pmax : maximal instantaneous power consumption (kW)
- pmin : minimal instantaneous power consumption (kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the consumption unit
Production_units module¶
** This module defines the production units**
The production_units module defines various kinds of production units with associated attributes and methods.
- It includes :
ProductionUnit : simple production unit inheriting from EnergyUnit and with an outer flow direction. The outside co2 emissions, the starting cost, the operating cost, the minimal operating time, the minimal non-operating time, the maximal increasing ramp and the maximal decreasing ramp can be filled.
- Objectives are also available :
- minimize starting cost, operating cost, total cost
- minimize production, co2_emissions, time of use
- maximize production
FixedProductionUnit : Production unit with a fixed production profile.
VariableProductionUnit : Production unit with a variation of power between pmin et pmax.
- And also :
- SeveralProductionUnit: Production unit based on a fixed production curve enabling to multiply several times (nb_unit) the same production curve
- SeveralImaginaryProductionUnit: Production unit based on a fixed production curve enabling to multiply several times (nb_unit) the same production curve. Be careful, the solution may be imaginary as nb_unit can be continuous. The accurate number of the production unit should be calculated later
- SquareProductionUnit: Production unit with a fixed value and fixed duration.
- ShiftableProductionUnit: Production unit with shiftable production profile.
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.units.production_units.
FixedProductionUnit
(time, name: str, p: list = None, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.FixedEnergyUnit
,omegalpes.energy.units.production_units.ProductionUnit
Description
Production unit with a fixed production profile.Attributes
- p : instantaneous power production known by advance (kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the production unit
-
class
omegalpes.energy.units.production_units.
ProductionUnit
(time, name, p=None, p_min=1e-05, p_max=100000.0, e_min=0, e_max=1000000.0, co2_out=None, starting_cost=None, operating_cost=None, min_time_on=None, min_time_off=None, max_ramp_up=None, max_ramp_down=None, availability_hours=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.EnergyUnit
Description
Simple Production unitAttributes
- co2_out: outside co2 emissions
- starting_cost: the starting cost
- operating_cost: the operating cost
- min_time_on : the minimal operating time
- min_time_off : the minimal non-operating time
- max_ramp_up : the maximal increasing ramp
- max_ramp_down ; the maximal decreasing ramp
-
class
omegalpes.energy.units.production_units.
SeveralImaginaryProductionUnit
(time, name, fixed_prod, pmin=1e-05, pmax=100000.0, e_min=0, e_max=1000000.0, nb_unit_min=0, nb_unit_max=None, co2_out=None, starting_cost=None, operating_cost=None, max_ramp_up=None, max_ramp_down=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.production_units.VariableProductionUnit
,omegalpes.energy.units.energy_units.SeveralEnergyUnit
Description
Production unit based on a fixed production curve enabling to multiply several times (nb_unit) the same production curve. Be careful, the solution may be imaginary as nb_unit can be continuous. The accurate number of the production unit should be calculated laterAttributes
- fixed_prod : fixed production curve
-
class
omegalpes.energy.units.production_units.
SeveralProductionUnit
(time, name, fixed_prod, pmin=1e-05, pmax=100000.0, e_min=0, e_max=1000000.0, nb_unit_min=0, nb_unit_max=None, co2_out=None, starting_cost=None, operating_cost=None, max_ramp_up=None, max_ramp_down=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.production_units.VariableProductionUnit
,omegalpes.energy.units.energy_units.SeveralEnergyUnit
Description
Production unit based on a fixed production curve enabling to multiply several times (nb_unit) the same production curve nb_unit is an integer variableAttributes
- fixed_prod : fixed production curve
-
class
omegalpes.energy.units.production_units.
ShiftableProductionUnit
(time, name: str, power_values, mandatory=True, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.ShiftableEnergyUnit
,omegalpes.energy.units.production_units.VariableProductionUnit
Description
Production unit with shiftable production profile.Attributes
- power_values : production profile to shift (kW)
- mandatory : indicates if the production is mandatory : True or not : False
- starting_cost : cost of the starting of the production
- operating_cost : cost of the operation (€/kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the production unit
-
class
omegalpes.energy.units.production_units.
SquareProductionUnit
(time, name, p_square, duration, n_square, t_between_sq, co2_out=None, starting_cost=None, operating_cost=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.SquareEnergyUnit
,omegalpes.energy.units.production_units.VariableProductionUnit
Description
Production unit with a fixed value and fixed duration. Only the time of beginning can be modified Operation can be mandatory or notAttributes
- p : instantaneous power production (kW)
- duration : duration of the power delivery (hours)
- mandatory : indicates if the power delivery is mandatory or not
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the production unit
-
class
omegalpes.energy.units.production_units.
VariableProductionUnit
(time, name, pmin=1e-05, pmax=100000.0, e_min=0, e_max=1000000.0, co2_out=None, starting_cost=None, operating_cost=None, min_time_on=None, min_time_off=None, max_ramp_up=None, max_ramp_down=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.VariableEnergyUnit
,omegalpes.energy.units.production_units.ProductionUnit
Description
Production unit with a variation of power between pmin et pmax.Attributes
- pmax : maximal instantaneous power production (kW)
- pmin : minimal instantaneous power production (kW)
- energy_type : type of energy (‘Electrical’, ‘Heat’, …)
- operator : stakeholder how owns the production unit
Conversion_units module¶
** This module defines the conversion units, with at least a production unit and a consumption unit and using one or several energy types**
The conversion_units module defines various classes of conversion units, from generic to specific ones.
- It includes :
- ConversionUnit : simple conversion unit. It inherits from OptObject.
- ElectricalToHeatConversionUnit : Electrical to heat Conversion unit with an electricity consumption and a heat production linked by and electrical to heat ratio. It inherits from ConversionUnit
- HeatPump : Simple Heat Pump with an electricity consumption, a heat production and a heat consumption. It has a theoretical coefficient of performance COP and inherits from ConversionUnit.
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.units.conversion_units.
ConversionUnit
(time, name, prod_units=None, cons_units=None, operator=None)[source]¶ Bases:
omegalpes.general.optimisation.core.OptObject
Description
Simple Conversion unitAttributes
- time : TimeUnit describing the studied time period
- prod_units : list of the production units
- cons_units : list of the consumption units
- operator : stakeholder who owns the conversion unit
- poles : dictionary of the poles of the conversion unit
-
class
omegalpes.energy.units.conversion_units.
ElectricalToHeatConversionUnit
(time, name, pmin_in_elec=1e-05, pmax_in_elec=100000.0, p_in_elec=None, pmin_out_heat=1e-05, pmax_out_heat=100000.0, p_out_heat=None, elec_to_heat_ratio=1, operator=None)[source]¶ Bases:
omegalpes.energy.units.conversion_units.ConversionUnit
Description
Electrical to heat Conversion unit with an electricity consumption and a heat productionAttributes
- heat_production_unit : heat production unit (heat output)
- elec_consumption_unit : electricity consumption unit (electrical input)
- conversion : Dynamic Constraint linking the electrical input to the heat output through the electrical to heat ratio
-
class
omegalpes.energy.units.conversion_units.
HeatPump
(time, name, pmin_in_elec=1e-05, pmax_in_elec=100000.0, p_in_elec=None, pmin_in_heat=1e-05, pmax_in_heat=100000.0, p_in_heat=None, pmin_out_heat=1e-05, pmax_out_heat=100000.0, p_out_heat=None, cop=3, losses=0, operator=None)[source]¶ Bases:
omegalpes.energy.units.conversion_units.ConversionUnit
Description
Simple Heat Pump with an electricity consumption, a heat production and a heat consumption. It has a theoretical coefficient of performance COP and inherits from ConversionUnit.Attributes
- heat_production_unit : heat production unit (condenser)
- elec_consumption_unit : electricity consumption unit (electrical input)
- heat_consumption_unit : heay consumption unit (evaporator)
- COP : Quantity describing the coefficient of performance of the heat pump
- conversion : Dynamic Constraint linking the electrical input to the heat output through the electrical to heat ratio
- power_flow : Dynamic constraint linking the heat output to the electrical and heat inputs in relation to the losses.
Storage_units module¶
** This module defines the storage units**
The storage_units module defines various kinds of storage units with associated attributes and methods, from simple to specific ones.
- It includes :
- StorageUnit : simple storage unit inheriting from EnergyUnit, with storage specific attributes. It includes the objective “minimize capacity”.
- Thermocline storage : a thermal storage that need to cycle (i.e. reach SOC_max) every period of Tcycle
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.units.storage_units.
StorageUnit
(time, name, pc_min=1e-05, pc_max=100000.0, pd_min=1e-05, pd_max=100000.0, capacity=None, e_0=None, e_f=None, soc_min=0, soc_max=1, eff_c=1, eff_d=1, self_disch=0, self_disch_t=0, ef_is_e0=False, cycles=None, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.energy.units.energy_units.VariableEnergyUnit
Description
Simple Storage unitAttributes
- capacity (Quantity): maximal energy that can be stored
- e (Quantity): energy at time t in the storage
- set_soc_min (DynamicConstraint): constraining the energy to be above the value : soc_min*capacity
- set_soc_max (DynamicConstraint): constraining the energy to be below the value : soc_max*capacity
- pc (Quantity) : charging power
- pd (Quantity) : discharging power
- u_c (Quantity) : binary variable describing the charge of the storage unit : 0 : Not charging & 1 : charging
- calc_e (DynamicConstraint) : energy calculation at time t ; relation power/energy
- calc_p (DynamicConstraint) : power calculation at time t ; power flow equals charging power minus discharging power
- on_off_stor (DynamicConstraint) : making u[t] matching with storage modes (on/off)
- def_max_charging (DynamicConstraint) : defining the max charging power, avoiding charging and discharging at the same time
- def_max_discharging (DynamicConstraint) : defining the max discharging power, avoiding charging and discharging at the same time
- def_min_charging (DynamicConstraint) : defining the min charging power, avoiding charging and discharging at the same time
- def_min_discharging (DynamicConstraint) : defining the min discharging power, avoiding charging and discharging at the same time
- set_e_0 (ExternalConstraint) : set the energy state for t=0
- e_f (Quantity) : energy in the storage at the end of the time horizon, i.e. after the last time step
- e_f_min (Constraint) : e_f value is constrained above soc_min*capacity
- e_f_max (Constraint) : e_f value is constrained below soc_max*capacity
- set_e_f (Constraint) : when e_f is given, it is set in the same way the energy is, but after the last time step
- calc_e_f (Constraint) : when e_f is not given, it is calculated in the same way the energy is, but after the last time step
- ef_is_e0 (ExternalConstraint) : Imposing ef=e0 on the time period.
- cycles (ExternalDynamicConstraint) : setting a cycle constraint e[t] = e[t+cycles/dt]
-
class
omegalpes.energy.units.storage_units.
ThermoclineStorage
(time, name, pc_min=1e-05, pc_max=100000.0, pd_min=1e-05, pd_max=100000.0, capacity=None, e_0=None, e_f=None, soc_min=0, soc_max=1, eff_c=1, eff_d=1, self_disch=0, Tcycl=120, ef_is_e0=False, operator=None)[source]¶ Bases:
omegalpes.energy.units.storage_units.StorageUnit
Description
Class ThermoclineStorage : class defining a thermocline heat storage, inheriting from StorageUnit.Attributes
- is_soc_max (Quantity) : indicating if the storage is fully charged 0:No 1:Yes
- def_is_soc_max_inf (DynamicConstraint) : setting the right value for is_soc_max
- def_is_soc_max_sup (DynamicConstraint) : setting the right value for is_soc_max
- force_soc_max (ExtDynConstraint) : The energy has to be at least once at its maximal value during the period Tcycl.
Energy_nodes module¶
** This module defines the energy nodes that will allow energy transmission between the various energy units and conversion units **
The energy_node module includes the EnergyNode class for energy transmission between production, consumption, conversion and storage. Defining several energy nodes and exporting/importing energy between them can also allow for a better demarcation of the energy system.
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.energy_nodes.
EnergyNode
(time, name, energy_type=None, operator=None)[source]¶ Bases:
omegalpes.general.optimisation.core.OptObject
This class defines an energy node.
-
add_pole
(pole: omegalpes.energy.io.poles.Epole) → None[source]¶ Add an energy pole to the poles_list
Parameters: pole – Epole
-
connect_units
(*units)[source]¶ Connecting all EnergyUnit to the EnergyNode
Parameters: units (list) – EnergyUnits connected to the EnergyNode
-
create_export
(node, export_min, export_max)[source]¶ Create the export from the EnergyNode (self) to the EnergyNode (node)
Parameters: - node – EnergyNode to whom power can be exported
- export_min – Minimal value of exported power when there is export
- export_max – Maximal value of exported power when there is export
Returns: Quantity that defines the power exported
-
export_to_node
(node, export_min=1e-05, export_max=100000.0)[source]¶ Add an export of power from the node to another node
Parameters: - node – EnergyNode to whom power can be exported
- export_min – Minimal value of exported power when there is export
- export_max – Maximal value of exported power when there is export
-
get_connected_energy_units
¶ Return the list of connected EnergyUnits in the EnergyNode
-
get_exports
¶ Return the list of exports to the EnergyNode
-
get_flows
¶ Get all the power flows of the energy node :rtype: list :return: list of power flows
-
get_imports
¶ Return the list of imports to the EnergyNode
-
get_poles
¶ Return the list of energy poles in the EnergyNode
-
Poles module¶
** This module defines inputs and outputs of as poles**
- The poles module includes :
- FlowPole : this class defines a pole with a directed flow (in or out)
- EPole : this class define an energy pole
Copyright 2018 G2Elab / MAGE
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
class
omegalpes.energy.io.poles.
Epole
(p, direction, energy_type=None)[source]¶ Bases:
omegalpes.energy.io.poles.FlowPole
** Description **
Definition of an energetic pole, power and power flow direction convention ‘in’ or ‘out’