dimod.binary.BinaryQuadraticModel.fix_variable

BinaryQuadraticModel.fix_variable(v: Hashable, value: int)[source]

Remove a variable by fixing its value.

Parameters
  • v – Variable in the binary quadratic model to be fixed.

  • value – Value assigned to the variable. Values must match the Vartype of the binary quadratic model.