StatevectorConverter

class perceval_interop.qiskit.converter_statevector.StatevectorConverter(encoding, polarization_base=(|{P:H}>, |{P:V}>), ancillae=[])
amplitude(sv)

Converts a logical StateVector from Perceval to an array of amplitudes. For a n-qubits StateVector, the returned array is of size 2^n with the first element corresponding to the n-qubits vector ‘00…0’ and the last element to ‘11…1’

remove_ancilla(sv)

Removes the auxiliary modes to obtain a proper n-qubits state

to_perceval(q_sv)

Converts a Statevector from qiskit or qutip to a StateVector from Perceval

to_qiskit(sv)

With the array of amplitudes, returns a Statevector from qiskit

to_qutip(sv)

With the array of amplitudes, returns a Statevector from qutip