VariableScaleMap class
#include <gtopt/variable_scale.hpp>
Lookup table for variable scales built from an array of VariableScale.
Resolution order for lookup(class_name, variable, uid):
- Entry matching (class_name, variable, uid) — per-element
- Entry matching (class_name, variable, -1) — per-class
- Fallback: 1.0
Constructors, destructors, conversion operators
- VariableScaleMap() defaulted
- VariableScaleMap(std::span<const VariableScale> scales) explicit
Public functions
Function documentation
double gtopt:: VariableScaleMap:: lookup(std::string_view class_name,
std::string_view variable,
Uid uid = unknown_ uid) const noexcept
Look up the scale for a (class, variable, uid) triple. Returns the most specific match, or 1.0 if none found.