# cirq.SupportsMixture

An object that decomposes into a probability distribution of unitaries.

## Methods

### `_has_mixture_`

View source

Whether this value has a mixture representation.

This method is used by the global `cirq.has_mixture` method. If this method is not present, or returns NotImplemented, it will fallback to using mixture with a default value, or False if neither exist.

Returns
True if the value has a mixture representation, Falseotherwise.

### `_mixture_`

View source

Decompose into a probability distribution of unitaries.

This method is used by the global `cirq.mixture` method.

A mixture is described by an iterable of tuples of the form

``````(probability of unitary, unitary as numpy array)
``````

The probability components of the tuples must sum to 1.0 and be between 0 and 1 (inclusive).

Returns
A list of (probability, unitary) pairs.

[{ "type": "thumb-down", "id": "missingTheInformationINeed", "label":"Missing the information I need" },{ "type": "thumb-down", "id": "tooComplicatedTooManySteps", "label":"Too complicated / too many steps" },{ "type": "thumb-down", "id": "outOfDate", "label":"Out of date" },{ "type": "thumb-down", "id": "samplesCodeIssue", "label":"Samples / code issue" },{ "type": "thumb-down", "id": "otherDown", "label":"Other" }]
[{ "type": "thumb-up", "id": "easyToUnderstand", "label":"Easy to understand" },{ "type": "thumb-up", "id": "solvedMyProblem", "label":"Solved my problem" },{ "type": "thumb-up", "id": "otherUp", "label":"Other" }]