constraint_names.hpp file
Canonical constexpr name constants used in LP row labels.
Centralises the class_name and constraint_name string_view values used by the structural-build LP layers so callers reference one canonical constant per row type instead of duplicating string literals at use sites.
- Per-element-class names (e.g.
"Bus","Reservoir","LngTerminal") live on each data struct asstatic constexpr LPClassName class_name {"…"}. Reach them viaBus::class_name.full_name()etc. (orBusLP::Element::class_name.full_name()in generic contexts) — single source of truth on the data struct; not duplicated here. - Aggregator / coordinator names (
"System","Cascade","Sddp","Kirchhoff") describe LP rows that are NOT owned by a single*LPelement class. They are defined asstd::string_viewconstants below. - Constraint-type names (
"flow_link","emission_cap", …) classify rows by purpose within an element class and are also defined below.
Cut-related names (sddp_*_constraint_name, sddp_*_class_name) live in gtopt/sddp_types.hpp next to their CutTag definitions.
The values here are the same strings that extract_row_type in linear_problem.cpp derives from row labels for the per-row-type stats breakdown — adding a new type means adding a constant here AND ensuring the row name still parses through extract_row_type cleanly (<class>_<constraint>_<…>).
Namespaces
- namespace gtopt