mindquantum.core.gates.BitPhaseFlipChannel

查看源文件
class mindquantum.core.gates.BitPhaseFlipChannel(p: float, **kwargs)[源代码]

比特相位翻转信道。描述的噪声体现为:以 P 的概率翻转比特的量子态和相位(作用 Y 门),或以 1P 的概率保持不变(作用 I 门)。

比特相位翻转通道的数学表示如下:

ϵ(ρ)=(1P)ρ+PYρY

其中, ρ 是密度矩阵形式的量子态; P 是作用额外 Y 门的概率。

参数:
  • p (int, float) - 发生错误的概率。

样例:

>>> from mindquantum.core.gates import BitPhaseFlipChannel
>>> from mindquantum.core.circuit import Circuit
>>> circ = Circuit()
>>> circ += BitPhaseFlipChannel(0.02).on(0)
>>> print(circ)
      ╔══════════════╗
q0: ──╢ BPFC(p=1/50) ╟───
      ╚══════════════╝
matrix()[源代码]

返回该噪声信道的Kraus算符。

返回:

list,包含了该噪声信道的Kraus算符。