1.3K Star 2K Fork 3.6K

GVPMindSpore / mindquantum

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
mindquantum.algorithm.compiler.qs_decompose.rst 777 Bytes
一键复制 编辑 原始数据 按行查看 历史
donghufeng 提交于 2023-11-01 01:16 . re-organize docs

mindquantum.algorithm.compiler.qs_decompose

.. py:function:: mindquantum.algorithm.compiler.qs_decompose(gate: QuantumGate, with_barrier: bool = False)

    任意维幺正量子门的矩阵的香农分解。

    该分解方法中的CNOT门数量为:

    .. math::

        O(4^n)

    了解更多详细信息,请参考 `Synthesis of Quantum Logic Circuits <https://arxiv.org/abs/quant-ph/0406176>`_。

    参数:
        - **gate** (:class:`~.core.gates.QuantumGate`) - 量子门实例。
        - **with_barrier** (bool) - 是否在分解时加入 :class:`~.core.gates.BarrierGate`。默认值: ``False``。

    返回:
        :class:`~.core.circuit.Circuit`,由单比特门和CNOT门构成的量子线路。
Python
1
https://gitee.com/mindspore/mindquantum.git
git@gitee.com:mindspore/mindquantum.git
mindspore
mindquantum
mindquantum
master

搜索帮助