DecisionVariableRole

DecisionVariableRole#

class DecisionVariableRole#

How a decision variable obtains its value in an Instance.

Roles are derived from the Instance’s current structure and can change after transformation. They are separate from Binary, Integer, or other variable kinds. Query one role with decision_variable_role(), or all roles with decision_variable_roles().

Role

Meaning

Value for candidate evaluation

Active

Belongs to the current Active Formulation

Supplied by the caller

Fixed

A retained variable outside the Active Formulation with a recorded fixed value

Restored from that value

Dependent

Neither active nor fixed; represented by an expression in other variables

Computed from that expression

Irrelevant

Neither active, fixed, nor dependent

Supplied by the caller, or filled with a default when omitted

Active constraints include regular and special constraints, including an Indicator’s controlling Binary variable. References only from named functions, inactive constraints, output objectives, or dependency right-hand sides do not make a variable active. Being irrelevant to solver input does not mean its value cannot affect reporting.

populate_state() explains reconstruction, defaults, canonicalization, and consistency assertions with executable examples.

Active#

Belongs to the Active Formulation through its objective or active constraints

Dependent#

Defined by decision_variable_dependency

Fixed#

Fixed by the instance-owned fixed-value table and outside the Active Formulation

Irrelevant#

Not active, fixed, or dependent