Link - Inputs
Links represent controllable power connections between two buses. Unlike lines (passive AC flow), links allow explicit control over power transfer and can convert between carriers. Below are all input attributes that you can set for link components.
Basic
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
type | string | n/a | n/a | No | static | Placeholder for link type. Not yet implemented. |
carrier | string | n/a | (empty) | No | static | Carrier type transported by the link: "DC" for electrical HVDC links, or "heat" or "gas" for thermal links. Used for categorization and energy balance constraints. |
active | boolean | n/a | True | No | static | Whether this link is active and should be included in network calculations. Set to False to temporarily disable the link without deleting it. |
Capacity
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
p_nom | float | MW | 0 | Yes | static | The maximum active power capacity of the link in MW. This sets the limit for power flow through the link. |
p_nom_mod | float | MW | 0 | No | static | The unit size for capacity expansion. When extending the nominal power (p_nom), it can only be increased in multiples of this module size. |
p_nom_extendable | boolean | n/a | False | No | static | Switch to allow the nominal power (p_nom) to be extended in optimization. |
p_nom_min | float | MW | 0 | No | static | If the nominal power (p_nom) is extendable in optimization, set its minimum value. |
p_nom_max | float | MW | inf | No | static | If the nominal power (p_nom) is extendable in optimization, set its maximum value (e.g. limited by technical potential or right-of-way constraints). |
build_year | int | year | 0 | No | static | The year when the link can be built or commissioned. Essential for multi-year capacity expansion planning models, which determine optimal investment timing and link retirement schedules. |
lifetime | float | years | inf | No | static | The operational lifetime of the link in years. Essential for multi-year capacity expansion planning models, which use this to determine when links retire (build year + lifetime). Set to "inf" for links that never retire. |
Energy
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
efficiency | float | per unit | 1 | No | static or timeseries | The efficiency of power transfer from bus0 to bus1. A value of 1.0 means no losses, while lower values represent transmission losses. Can be time-varying to model temperature-dependent performance (e.g., heat pump Coefficient of Performance). |
Power Limits
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
p_set | float | MW | 0 | No | static or timeseries | Fixed active power flow that the link must transfer from bus0 to bus1. Used when the link power flow is predetermined rather than optimized. |
p_min_pu | float | per unit | 0 | No | static or timeseries | The minimum power flow per unit of the nominal power (p_nom). Negative values allow reverse flow (from bus1 to bus0). Can be static or time-varying. |
p_max_pu | float | per unit | 1 | No | static or timeseries | The maximum power flow per unit of the nominal power (p_nom). Negative values allow reverse flow (from bus1 to bus0). Can be static or time-varying. |
Unit Commitment
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
committable | boolean | n/a | False | No | static | Enable unit commitment, allowing the link to be turned on or off with associated start-up and shutdown costs. Only available when the nominal power (p_nom) is not extendable. |
start_up_cost | float | currency | 0 | No | static | Cost to start up the link. Only read if committable is True. |
shut_down_cost | float | currency | 0 | No | static | Cost to shut down the link. Only read if committable is True. |
stand_by_cost | float | currency/h | 0 | No | static or timeseries | Stand-by cost for operating the link at null power flow. |
min_up_time | int | snapshots | 0 | No | static | Minimum number of snapshots for status to be 1. Only read if committable is True. |
min_down_time | int | snapshots | 0 | No | static | Minimum number of snapshots for status to be 0. Only read if committable is True. |
up_time_before | int | snapshots | 1 | No | static | Number of snapshots that the link was online before network.snapshots start. Only read if committable is True and min_up_time is non-zero. |
down_time_before | int | snapshots | 0 | No | static | Number of snapshots that the link was offline before network.snapshots start. Only read if committable is True and min_down_time is non-zero. |
Ramping
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
ramp_limit_up | float | per unit | 1 | No | static or timeseries | Maximum power flow increase from one snapshot to the next, per unit of the nominal power (p_nom). Ignored if 1. |
ramp_limit_down | float | per unit | 1 | No | static or timeseries | Maximum power flow decrease from one snapshot to the next, per unit of the nominal power (p_nom). Ignored if 1. |
ramp_limit_start_up | float | per unit | 1 | No | static | Maximum power flow increase at start up, per unit of the nominal power (p_nom). Only read if committable is True. |
Costs
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
capital_cost | float | currency/MW | 0 | No | static | The cost per MW of adding new link capacity. Includes investment costs (spread over the planning period) and fixed operations & maintenance costs. Only relevant when p_nom_extendable is True. |
marginal_cost | float | currency/MWh | 0 | No | static or timeseries | The variable cost of transferring 1 MWh from bus0 to bus1 (before efficiency losses). Used by the optimizer to determine economic dispatch. Only meaningful if p_max_pu >= 0 (unidirectional flow). |
marginal_cost_quadratic | float | currency/MWh² | 0 | No | static or timeseries | Quadratic term for non-linear cost curves. When set, the total cost includes a quadratic component that increases with the square of power flow, modeling increasing marginal costs at higher transfer levels. |
Electrical
| Attribute | Data Type | Unit | Default | Required | Storage Type | Description |
|---|---|---|---|---|---|---|
length | float | km | 0 | No | static | The physical length of the link in kilometers. Used for calculating capital costs, especially for transmission lines or pipelines. |
terrain_factor | float | per unit | 1 | No | static | Multiplier for capital cost to account for difficult terrain. Values greater than 1 increase the capital cost to reflect higher construction costs in challenging terrain (e.g., mountains, water crossings). |

