gtopt::LineDlrLP class

Public types

struct BlockRatings
struct Span
One resolved critical span.

Constructors, destructors, conversion operators

LineDlrLP(LineDlr dlr, const InputContext& ic, std::string_view class_name, Uid line_uid, const Name& line_name)

Public functions

auto has_emergency() const -> bool noexcept
True when any span has an emergency tier.
auto limit_mode() const -> const std::optional<LineDlrLimitMode>& noexcept
auto mode() const -> LineDlrSpanMode noexcept
void ratings_at(ScenarioUid scenario, StageUid stage, BlockUid block, double voltage_kv, BlockRatings& out) const
auto spans() const -> std::span<const Span> noexcept
auto voltage() const -> const std::optional<double>& noexcept
dlr.voltage [kV] when set (else the caller uses Line.voltage).

Function documentation

const std::optional<LineDlrLimitMode>& gtopt::LineDlrLP::limit_mode() const noexcept

dlr.limit_mode when set (else the caller uses model_options.dlr_limit_mode).

void gtopt::LineDlrLP::ratings_at(ScenarioUid scenario, StageUid stage, BlockUid block, double voltage_kv, BlockRatings& out) const

Evaluate every span's rating at (scenario, stage, block). Throws std::runtime_error when a weather value is missing or the voltage is not positive (data error the validator could not see, e.g. a file-backed schedule without that cell).