dimod.AdjVectorBQM.set_quadratic

AdjVectorBQM.set_quadratic(self, u, v, Bias b)

Set the quadratic bias of (u, v).

Parameters:
  • u (hashable) – A variable in the binary quadratic model.
  • v (hashable) – A variable in the binary quadratic model.
  • b (numeric) – The linear bias of v.
Raises:

TypeError – If u or v is not hashable.