Skip to content

thermal

Classes:

LawOption

Law options used for series generation. The uniform law is used by default.

LocalTSGenerationBehavior

Options related to time series generation. The option USE_GLOBAL is used by default.

Attributes:

  • USE_GLOBAL

    Use the global time series parameters.

  • FORCE_NO_GENERATION

    Do not generate time series.

  • FORCE_GENERATION

    Force the generation of time series.

ThermalCluster

ThermalCluster(
    thermal_service: BaseThermalService,
    area_id: str,
    name: str,
    properties: Optional[ThermalClusterProperties] = None,
)

Thermal cluster modelling object

Methods:

Attributes:

Source code in src/antares/craft/model/thermal.py
def __init__(
    self,
    thermal_service: BaseThermalService,
    area_id: str,
    name: str,
    properties: Optional[ThermalClusterProperties] = None,
):
    self._area_id = area_id
    self._thermal_service: BaseThermalService = thermal_service
    self._name = name
    self._id = transform_name_to_id(name)
    self._properties = properties or ThermalClusterProperties()

area_id property

area_id: str

Area ID.

id property

id: str

ID of the thermal cluster.

name property

name: str

Name of the thermal cluster.

properties property

Properties of the thermal cluster.

get_co2_cost_matrix

get_co2_cost_matrix() -> DataFrame

Get \(\ce{CO2}\) cost matrix.

Returns:

  • DataFrame

    The \(\ce{CO2}\) cost matrix.

Source code in src/antares/craft/model/thermal.py
def get_co2_cost_matrix(self) -> pd.DataFrame:
    """Get $\\ce{CO2}$ cost matrix.

    Returns:
        The $\\ce{CO2}$ cost matrix.
    """
    return self._thermal_service.get_thermal_matrix(self, ThermalClusterMatrixName.SERIES_CO2_COST)

get_fuel_cost_matrix

get_fuel_cost_matrix() -> DataFrame

Get fuel cost matrix.

Returns:

  • DataFrame

    The fuel cost matrix.

Source code in src/antares/craft/model/thermal.py
def get_fuel_cost_matrix(self) -> pd.DataFrame:
    """Get fuel cost matrix.

    Returns:
        The fuel cost matrix.
    """
    return self._thermal_service.get_thermal_matrix(self, ThermalClusterMatrixName.SERIES_FUEL_COST)

get_prepro_data_matrix

get_prepro_data_matrix() -> DataFrame

Get matrix corresponding to the TS-GENERATOR matrix in AntaresWeb.

Returns:

  • matrix ( DataFrame ) –

    Matrix with outage probabilities and durations to use inside the timeseries generation.

Source code in src/antares/craft/model/thermal.py
def get_prepro_data_matrix(self) -> pd.DataFrame:
    """Get matrix corresponding to the TS-GENERATOR matrix in AntaresWeb.

    Returns:
        matrix: Matrix with outage probabilities and durations to use inside the timeseries generation.
    """
    return self._thermal_service.get_thermal_matrix(self, ThermalClusterMatrixName.PREPRO_DATA)

get_prepro_modulation_matrix

get_prepro_modulation_matrix() -> DataFrame

Get matrix corresponding to the COMMON matrix in AntaresWeb.

Returns:

  • matrix ( DataFrame ) –

    Matrix for the "Marginal cost modulation", "Market bid modulation", "Capacity modulation" and "Min gen modulation".

Source code in src/antares/craft/model/thermal.py
def get_prepro_modulation_matrix(self) -> pd.DataFrame:
    """Get matrix corresponding to the COMMON matrix in AntaresWeb.

    Returns:
        matrix: Matrix for the "Marginal cost modulation", "Market bid modulation", "Capacity modulation" and "Min gen modulation".
    """
    return self._thermal_service.get_thermal_matrix(self, ThermalClusterMatrixName.PREPRO_MODULATION)

get_series_matrix

get_series_matrix() -> DataFrame

Get availibility matrix.

Returns:

  • DataFrame

    The availibility time-series of the thermal cluster.

Source code in src/antares/craft/model/thermal.py
def get_series_matrix(self) -> pd.DataFrame:
    """Get availibility matrix.

    Returns:
        The availibility time-series of the thermal cluster.
    """
    return self._thermal_service.get_thermal_matrix(self, ThermalClusterMatrixName.SERIES)

set_co2_cost

set_co2_cost(matrix: DataFrame) -> None

Set \(\ce{CO2}\) cost matrix.

Parameters:

  • matrix

    (DataFrame) –

    The \(\ce{CO2}\) cost matrix.

Source code in src/antares/craft/model/thermal.py
def set_co2_cost(self, matrix: pd.DataFrame) -> None:
    """Set $\\ce{CO2}$ cost matrix.

    Args:
        matrix: The $\\ce{CO2}$ cost matrix.
    """
    self._thermal_service.set_thermal_matrix(self, matrix, ThermalClusterMatrixName.SERIES_CO2_COST)

set_fuel_cost

set_fuel_cost(matrix: DataFrame) -> None

Set fuel cost matrix.

Parameters:

  • matrix

    (DataFrame) –

    The fuel cost matrix.

Source code in src/antares/craft/model/thermal.py
def set_fuel_cost(self, matrix: pd.DataFrame) -> None:
    """Set fuel cost matrix.

    Args:
        matrix: The fuel cost matrix.
    """
    self._thermal_service.set_thermal_matrix(self, matrix, ThermalClusterMatrixName.SERIES_FUEL_COST)

set_prepro_data

set_prepro_data(matrix: DataFrame) -> None

Set matrix corresponding to the TS-GENERATOR matrix in AntaresWeb.

Parameters:

  • matrix

    (DataFrame) –

    Matrix with outage probabilities and durations to use inside the timeseries generation.

Source code in src/antares/craft/model/thermal.py
def set_prepro_data(self, matrix: pd.DataFrame) -> None:
    """Set matrix corresponding to the TS-GENERATOR matrix in AntaresWeb.

    Args:
        matrix: Matrix with outage probabilities and durations to use inside the timeseries generation.
    """
    self._thermal_service.set_thermal_matrix(self, matrix, ThermalClusterMatrixName.PREPRO_DATA)

set_prepro_modulation

set_prepro_modulation(matrix: DataFrame) -> None

Set matrix corresponding to the COMMON matrix in AntaresWeb.

Parameters:

  • matrix

    (DataFrame) –

    Matrix for the "Marginal cost modulation", "Market bid modulation", "Capacity modulation" and "Min gen modulation".

Source code in src/antares/craft/model/thermal.py
def set_prepro_modulation(self, matrix: pd.DataFrame) -> None:
    """Set matrix corresponding to the COMMON matrix in AntaresWeb.

    Args:
        matrix: Matrix for the "Marginal cost modulation", "Market bid modulation", "Capacity modulation" and "Min gen modulation".
    """
    self._thermal_service.set_thermal_matrix(self, matrix, ThermalClusterMatrixName.PREPRO_MODULATION)

set_series

set_series(matrix: DataFrame) -> None

Set availibility time-series.

Parameters:

  • matrix

    (DataFrame) –

    Availibity time-series.

Source code in src/antares/craft/model/thermal.py
def set_series(self, matrix: pd.DataFrame) -> None:
    """Set availibility time-series.

    Args:
        matrix: Availibity time-series.
    """
    self._thermal_service.set_thermal_matrix(self, matrix, ThermalClusterMatrixName.SERIES)

update_properties

Update properties of the thermal cluster.

Parameters:

Returns:

Source code in src/antares/craft/model/thermal.py
def update_properties(self, properties: ThermalClusterPropertiesUpdate) -> ThermalClusterProperties:
    """Update properties of the thermal cluster.

    Args:
        properties: Properties to update.

    Returns:
        The updated thermal properties.
    """
    new_properties = self._thermal_service.update_thermal_clusters_properties({self: properties})
    self._properties = new_properties[self]
    return self._properties

ThermalClusterGroup

Enumeration of the different possibilities of thermal cluster group.

Attributes:

  • NUCLEAR

    Nuclear.

  • LIGNITE

    Lignite.

  • HARD_COAL

    Hard coal.

  • GAS

    Gas.

  • OIL

    Oil.

  • MIXED_FUEL

    Mixed fuel.

  • OTHER1

    Other 1.

  • OTHER2

    Other 2.

  • OTHER3

    Other 3.

  • OTHER4

    Other 4.

ThermalClusterProperties dataclass

ThermalClusterProperties(
    enabled: bool = True,
    unit_count: int = 1,
    nominal_capacity: float = 0,
    group: str = value,
    gen_ts: LocalTSGenerationBehavior = USE_GLOBAL,
    min_stable_power: float = 0,
    min_up_time: int = 1,
    min_down_time: int = 1,
    must_run: bool = False,
    spinning: float = 0,
    volatility_forced: float = 0,
    volatility_planned: float = 0,
    law_forced: LawOption = UNIFORM,
    law_planned: LawOption = UNIFORM,
    marginal_cost: float = 0,
    spread_cost: float = 0,
    fixed_cost: float = 0,
    startup_cost: float = 0,
    market_bid_cost: float = 0,
    co2: float = 0,
    nh3: float = 0,
    so2: float = 0,
    nox: float = 0,
    pm2_5: float = 0,
    pm5: float = 0,
    pm10: float = 0,
    nmvoc: float = 0,
    op1: float = 0,
    op2: float = 0,
    op3: float = 0,
    op4: float = 0,
    op5: float = 0,
    cost_generation: ThermalCostGeneration = SET_MANUALLY,
    efficiency: float = 100,
    variable_o_m_cost: float = 0,
)

Thermal cluster properties.

Attributes:

  • enabled (bool) –

    Whether the cluster is enabled in the simulation.

  • unit_count (int) –

    Number of generation units in the cluster.

  • nominal_capacity (float) –

    Nominal capacity of a single unit in MW.

  • group (str) –

    Type of thermal generation to organize clusters.

  • gen_ts (LocalTSGenerationBehavior) –
  • min_stable_power (float) –
  • min_up_time (int) –

    Duration needed for the cluster to reach its nominal capacity from an initial off state.

  • min_down_time (int) –

    Duration needed for the cluster to shutdown from its nominal capacity.

  • must_run (bool) –

    Whether the cluster must run or not.

  • spinning (float) –
  • volatility_forced (float) –
  • volatility_planned (float) –
  • law_forced (LawOption) –
  • law_planned (LawOption) –
  • marginal_cost (float) –

    Marginal cost.

  • spread_cost (float) –

    Spread cost.

  • fixed_cost (float) –
  • startup_cost (float) –

    Start up cost of a unit.

  • market_bid_cost (float) –

    Market bid cost.

  • co2 (float) –

    Emission rate of \(\ce{CO2}\) in t/MWh.

  • nh3 (float) –

    Emission rate of \(\ce{NH3}\) in t/MWh.

  • so2 (float) –

    Emission rate of \(\ce{SO2}\) in t/MWh.

  • nox (float) –

    Emission rate of \(\ce{NOx}\) in t/MWh.

  • pm2_5 (float) –

    Emission rate of \(\ce{PM_{2.5}}\) in t/MWh.

  • pm5 (float) –

    Emission rate of \(\ce{PM5}\) in t/MWh.

  • pm10 (float) –

    Emission rate of \(\ce{PM10}\) in t/MWh.

  • nmvoc (float) –

    Emission rate of \(\ce{NMVOC}\) in t/MWh.

  • op1 (float) –

    Emission rate of other polluant 1 in t/MWh.

  • op2 (float) –

    Emission rate of other polluant 2 in t/MWh.

  • op3 (float) –

    Emission rate of other polluant 3 in t/MWh.

  • op4 (float) –

    Emission rate of other polluant 4 in t/MWh.

  • op5 (float) –

    Emission rate of other polluant 5 in t/MWh.

  • cost_generation (ThermalCostGeneration) –

    Generation cost.

  • efficiency (float) –

    Efficiency of the cluster.

  • variable_o_m_cost (float) –

    Variable O&M costs.

enabled_capacity property

enabled_capacity: float

The enabled capacity is the installed capacity if the cluster is enabled, otherwise it's 0.

installed_capacity property

installed_capacity: float

Installed capacity corresponding to the product of the nominal capacity times the number of units.

ThermalClusterPropertiesUpdate dataclass

ThermalClusterPropertiesUpdate(
    enabled: Optional[bool] = None,
    unit_count: Optional[int] = None,
    nominal_capacity: Optional[float] = None,
    group: Optional[str] = None,
    gen_ts: Optional[LocalTSGenerationBehavior] = None,
    min_stable_power: Optional[float] = None,
    min_up_time: Optional[int] = None,
    min_down_time: Optional[int] = None,
    must_run: Optional[bool] = None,
    spinning: Optional[float] = None,
    volatility_forced: Optional[float] = None,
    volatility_planned: Optional[float] = None,
    law_forced: Optional[LawOption] = None,
    law_planned: Optional[LawOption] = None,
    marginal_cost: Optional[float] = None,
    spread_cost: Optional[float] = None,
    fixed_cost: Optional[float] = None,
    startup_cost: Optional[float] = None,
    market_bid_cost: Optional[float] = None,
    co2: Optional[float] = None,
    nh3: Optional[float] = None,
    so2: Optional[float] = None,
    nox: Optional[float] = None,
    pm2_5: Optional[float] = None,
    pm5: Optional[float] = None,
    pm10: Optional[float] = None,
    nmvoc: Optional[float] = None,
    op1: Optional[float] = None,
    op2: Optional[float] = None,
    op3: Optional[float] = None,
    op4: Optional[float] = None,
    op5: Optional[float] = None,
    cost_generation: Optional[ThermalCostGeneration] = None,
    efficiency: Optional[float] = None,
    variable_o_m_cost: Optional[float] = None,
)

Update thermal cluster properties.

Attributes: