ommx.v1.sos1_pb2

Classes

SOS1

A message representing a [Spcial Ordered Set constraint of Type 1](https://en.wikipedia.org/wiki/Special_ordered_set#Types) (SOS1).

Module Contents

class ommx.v1.sos1_pb2.SOS1(*, binary_constraint_id: int = ..., big_m_constraint_ids: collections.abc.Iterable[int] | None = ..., decision_variables: collections.abc.Iterable[int] | None = ...)

A message representing a [Spcial Ordered Set constraint of Type 1](https://en.wikipedia.org/wiki/Special_ordered_set#Types) (SOS1). SOS1 constraint on non-negative variables x_1, …, x_n requires that at most one of x_i can be non-zero.

ClearField(field_name: Literal['big_m_constraint_ids', b'big_m_constraint_ids', 'binary_constraint_id', b'binary_constraint_id', 'decision_variables', b'decision_variables']) None
BIG_M_CONSTRAINT_IDS_FIELD_NUMBER: int
BINARY_CONSTRAINT_ID_FIELD_NUMBER: int
DECISION_VARIABLES_FIELD_NUMBER: int
property big_m_constraint_ids: google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]

The IDs of the big-M constraint on non-binary variables.

binary_constraint_id: int

The ID of the SOS1 constraint on binary variables.

property decision_variables: google.protobuf.internal.containers.RepeatedScalarFieldContainer[int]

The list of ids of decision variables that are constrained to be one-hot.