mindquantum.algorithm.nisq.Ansatz15
- class mindquantum.algorithm.nisq.Ansatz15(n_qubits, depth, prefix='', suffix='')[源代码]
- Arxiv 论文中所提及的量子线路15。   - 参数:
- n_qubits (int) - 量子线路的总比特数。 
- depth (int) - ansatz 的循环层数。 
- prefix (str) - 参数的前缀。默认值: - ''。
- suffix (str) - 参数的后缀。默认值: - ''。
 
 - 样例: - >>> from mindquantum.algorithm.nisq import Ansatz15 >>> Ansatz15(4, 1).circuit ┏━━━━━━━━┓ ┏━━━┓ ┏━━━━━━━━┓ ┏━━━┓ q0: ──┨ RY(p0) ┠─┨╺╋╸┠───────────────■───┨ RY(p4) ┠─────────■───┨╺╋╸┠───────── ┗━━━━━━━━┛ ┗━┳━┛ ┃ ┗━━━━━━━━┛ ┃ ┗━┳━┛ ┏━━━━━━━━┓ ┃ ┏━┻━┓ ┏━━━━━━━━┓ ┃ ┃ ┏━━━┓ q1: ──┨ RY(p1) ┠───╂───────────■───┨╺╋╸┠─┨ RY(p5) ┠─────────╂─────■───┨╺╋╸┠─── ┗━━━━━━━━┛ ┃ ┃ ┗━━━┛ ┗━━━━━━━━┛ ┃ ┗━┳━┛ ┏━━━━━━━━┓ ┃ ┏━┻━┓ ┏━━━━━━━━┓ ┏━━━┓ ┃ ┃ q2: ──┨ RY(p2) ┠───╂─────■───┨╺╋╸┠───────┨ RY(p6) ┠─┨╺╋╸┠───╂───────────■───── ┗━━━━━━━━┛ ┃ ┃ ┗━━━┛ ┗━━━━━━━━┛ ┗━┳━┛ ┃ ┏━━━━━━━━┓ ┃ ┏━┻━┓ ┏━━━━━━━━┓ ┃ ┏━┻━┓ q3: ──┨ RY(p3) ┠───■───┨╺╋╸┠─────────────┨ RY(p7) ┠───■───┨╺╋╸┠─────────────── ┗━━━━━━━━┛ ┗━━━┛ ┗━━━━━━━━┛ ┗━━━┛