qrunch.quantum.algorithms.second_quantization.quantum_selected_configuration_interaction.reference_circuit_providers.reference_circuit_provider
Interface for preparing the circuits of the reference states of a ground state problem.
Classes
Prepare the circuits of one or more reference states, e.g. for quantum-selected configuration interaction. |
- class ReferenceCircuitProvider
Bases:
ProtocolPrepare the circuits of one or more reference states, e.g. for quantum-selected configuration interaction.
A provider is configured before the problem is known and is then asked for its circuits once per problem. The circuits use the qubit mapping of the problem’s Hamiltonian. Without the paired-electron approximation this is the fermionic mapping: alpha spin orbitals on qubits
0toN_s - 1and beta spin orbitals on qubitsN_sto2 N_s - 1, whereN_sis the number of spatial orbitals. With the paired-electron approximation it is the paired mapping: one qubit per spatial orbital, occupied by an electron pair.- __init__(*args, **kwargs)
- create_circuits(ground_state_problem: RestrictedGroundStateProblem | UnrestrictedGroundStateProblem, *, number_of_states: int, paired_electron_approximation: bool) tuple[Circuit, ...]
Create new circuits preparing the reference states of the given problem.
- Parameters:
ground_state_problem (RestrictedGroundStateProblem | UnrestrictedGroundStateProblem) – The ground state problem whose reference states are prepared.
number_of_states (int) – Positive number of lowest states requested from the calculation, the ground state included. Providers may use it to choose how many references to prepare.
paired_electron_approximation (bool) – Whether to prepare the reference states in the paired-electron approximation. Only valid if
supports_paired_approximation()isTrue.
- Return type:
tuple[Circuit, …]
- supports_paired_approximation() bool
Whether the provider can create its reference circuits in the paired-electron approximation.
- Return type:
bool