Skip to main content

is_unitary

Method of Operator.

is_unitary() -> bool

Returns true if the operator is unitary.

Returns

true if the operator is unitary, false otherwise.

Example

var u1 = is_unitary(RotZ(1.0, 0))   // true
var u2 = RotZ(0.5, 0).is_unitary() // true
var u3 = is_unitary(Proj0(0)) // false