pyqubo.Array.div

Array.div(other)[source]

Returns division of self by other.

Parameters:other (int/float) – Divisor.
Returns:Array

Example

>>> from pyqubo import Array, Binary
>>> array_a = Array([[Binary('a'), Binary('b')], [Binary('c'), 2]])
>>> array_a / 5
Array([[(Binary(a)*Num(0.2)), (Binary(b)*Num(0.2))],
       [(Binary(c)*Num(0.2)), 0.4]])