# qiskit.aqua.operators.legacy.Z2Symmetries.two_qubit_reduction¶

static Z2Symmetries.two_qubit_reduction(operator, num_particles)[Quellcode]

Eliminates the central and last qubit in a list of Pauli that has diagonal operators (Z,I) at those positions

Chemistry specific method: It can be used to taper two qubits in parity and binary-tree mapped fermionic Hamiltonians when the spin orbitals are ordered in two spin sectors, (block spin order) according to the number of particles in the system.

Parameter
• operator (WeightedPauliOperator) – the operator

• num_particles (Union(list, int)) – number of particles, if it is a list, the first number is alpha and the second number if beta.

Rückgabe

a new operator whose qubit number is reduced by 2.

Rückgabetyp

WeightedPauliOperator