h2integrate.converters.grid.grid#
Classes
|
An OpenMDAO component that computes costs for grid connections. |
|
Configuration for the grid cost model. |
|
Model a grid interconnection point. |
|
Configuration for the grid performance model. |
- class h2integrate.converters.grid.grid.GridPerformanceModelConfig(*, interconnection_size)#
Configuration for the grid performance model.
- Parameters:
interconnection_size (float)
- interconnection_size#
Maximum power capacity for grid connection in kW
- Type:
float
- interconnection_size: float#
- class h2integrate.converters.grid.grid.GridPerformanceModel(**kwargs)#
Model a grid interconnection point.
The grid is treated as the interconnection point itself: - electricity_in: Power flowing INTO the grid (selling to grid). - electricity_out: Power flowing OUT OF the grid (buying from grid).
This component handles: - Buying electricity from the grid (electricity flows out to downstream technologies). - Selling electricity to the grid (electricity flows in from upstream technologies). - Enforcing interconnection limits on buying flows.
The component can be instantiated multiple times in a plant to represent different grid connection points (for example, one for buying upstream and another for selling downstream).
- Inputs
interconnection_size (float): Maximum power capacity for grid connection (kW). electricity_in (array): Power flowing into the grid (selling) (kW). electricity_demand (array): Downstream electricity demand (kW).
- Outputs
electricity_out (array): Power flowing out of the grid (buying) (kW).
- initialize()#
Perform any one-time initialization run at instantiation.
- setup()#
Declare inputs and outputs.
- Available attributes:
name pathname comm options
- compute(inputs, outputs)#
Compute outputs given inputs. The model is assumed to be in an unscaled state.
An inherited component may choose to either override this function or to define a compute_primal function.
- Parameters:
inputs (Vector) -- Unscaled, dimensional input variables read via inputs[key].
outputs (Vector) -- Unscaled, dimensional output variables read via outputs[key].
discrete_inputs (dict-like or None) -- If not None, dict-like object containing discrete input values.
discrete_outputs (dict-like or None) -- If not None, dict-like object containing discrete output values.
- class h2integrate.converters.grid.grid.GridCostModelConfig(*, cost_year, interconnection_size, interconnection_capex_per_kw, interconnection_opex_per_kw, fixed_interconnection_cost, electricity_buy_price=None, electricity_sell_price=None)#
Configuration for the grid cost model.
- Parameters:
cost_year (int)
interconnection_size (float)
interconnection_capex_per_kw (float)
interconnection_opex_per_kw (float)
fixed_interconnection_cost (float)
electricity_buy_price (float | list[float] | ndarray | None)
electricity_sell_price (float | list[float] | ndarray | None)
- interconnection_size#
Maximum power capacity for grid connection in kW
- Type:
float
- interconnection_capex_per_kw#
Capital cost per kW of interconnection ($/kW)
- Type:
float
- interconnection_opex_per_kw#
Annual O&M cost per kW of interconnection ($/kW/year)
- Type:
float
- fixed_interconnection_cost#
One-time fixed cost regardless of size ($)
- Type:
float
- electricity_buy_price#
Price to buy electricity from grid ($/kWh), optional
- Type:
float | list[float] | numpy.ndarray | None
- electricity_sell_price#
Price to sell electricity to grid ($/kWh), optional
- Type:
float | list[float] | numpy.ndarray | None
- interconnection_size: float#
- interconnection_capex_per_kw: float#
- interconnection_opex_per_kw: float#
- fixed_interconnection_cost: float#
- electricity_buy_price: float | list[float] | ndarray | None#
- electricity_sell_price: float | list[float] | ndarray | None#
- class h2integrate.converters.grid.grid.GridCostModel(**kwargs)#
An OpenMDAO component that computes costs for grid connections.
This component handles: - CapEx based on interconnection size ($/kW) - OpEx based on interconnection size ($/kW/year) - Variable costs for electricity purchases (buy mode) - Revenue from electricity sales (sell mode) - Support for time-varying electricity prices
Note: Although the electricity units are in kW and the prices are in USD/kWh, this model assumes that each timestep represents 1 hour.
- setup()#
Declare inputs and outputs.
- Available attributes:
name pathname comm options
- compute(inputs, outputs, discrete_inputs, discrete_outputs)#
Computation for the OM component.
For a template class this is not implement and raises an error.