IsingMatrix

class IsingMatrix

Bases: Matrix

Methods

__init__

evaluate

evaluate

to_poly

to_poly

Attributes

constant

constant property

linear

linear property

quadratic

quadratic property

variable_array

variable_array property

__add__(self, arg: Constraint | ConstraintList, /) Model

__add__

Parameters:

arg (Constraint | ConstraintList) –

Return type:

Model

__eq__(self, arg: Matrix, /) bool

__eq__

Parameters:

arg (Matrix) –

Return type:

bool

__init__(*args, **kwargs)
__init_subclass__()

This method is called when a class is subclassed.

The default implementation does nothing. It may be overridden to extend subclasses.

__ne__(self, arg: Matrix, /) bool

__ne__

Parameters:

arg (Matrix) –

Return type:

bool

__radd__(self, arg: Constraint | ConstraintList, /) Model

__radd__

Parameters:

arg (Constraint | ConstraintList) –

Return type:

Model

__repr__(self) str

__repr__

Return type:

str

__str__(self) str

__str__

Return type:

str

evaluate(self, values: Values) float
evaluate(self, values: Values, default: float) float

evaluate

Overloading:

1. evaluate(self, values: amplify.Values) -> float

Args:
  • values (amplify.Values):

Returns:

float:

2. evaluate(self, values: amplify.Values, default: float) -> float

Args:
  • values (amplify.Values):

  • default (float):

Returns:

float:

to_poly(self) Poly

to_poly

Return type:

Poly

__deprecated__ = 'IsingMatrix is deprecated since amplify v1.0.0 and will no longer support in the near future.\nUse Matrix instead. Please see the migration guide for details: https://amplify.fixstars.com/docs/amplify/v1/migration.html'
__dict__ = mappingproxy({'__module__': 'amplify._backward', '__dict__': <attribute '__dict__' of 'IsingMatrix' objects>, '__weakref__': <attribute '__weakref__' of 'IsingMatrix' objects>, '__doc__': None, '__new__': <staticmethod(<function Matrix.__new__>)>, '__init_subclass__': <function IsingMatrix.__init_subclass__>, '__deprecated__': 'IsingMatrix is deprecated since amplify v1.0.0 and will no longer support in the near future.\nUse Matrix instead. Please see the migration guide for details: https://amplify.fixstars.com/docs/amplify/v1/migration.html', '__annotations__': {}})
__weakref__

list of weak references to the object (if defined)

property constant

constant property

Return type:

float

property linear

linear property

Return type:

ndarray

property quadratic

quadratic property

Return type:

ndarray

property variable_array

variable_array property

Return type:

PolyArray