qrunch.quantum.algorithms.second_quantization.quantum_selected_configuration_interaction.krylov_subspace_state_generator
Krylov subspace state generator for quantum-selected configuration interaction.
Classes
Generate Krylov subspace states for quantum-selected configuration interaction. |
- class KrylovSubspaceStateGenerator
Bases:
SubspaceStateGeneratorGenerate Krylov subspace states for quantum-selected configuration interaction.
For each Krylov order \(k = 1, \ldots, d\) (with \(d\) the maximum order) and each randomization, this generator produces a state preparing (an approximation of) the Krylov vector
\[\ket{\Psi_k} = e^{-iH k \tau} \ket{\Psi_\text{ref}} ,\]where \(\tau\) is the time step and \(\ket{\Psi_\text{ref}}\) is prepared by the reference circuit. Each time-evolution operator \(e^{-iH k \tau}\) is compiled by the injected
HamiltonianTimeEvolutionstrategy, once the caller realizes the state.- __init__(time_evolution: HamiltonianTimeEvolution, *, maximum_krylov_order: int = 3, time_step: float = 1.0, number_of_randomizations: int = 1) None
Initialize the Krylov subspace state generator.
- Parameters:
time_evolution (HamiltonianTimeEvolution) – Strategy compiling each time-evolution operator into a circuit.
maximum_krylov_order (int) – The largest Krylov order \(d\); states are generated for every order \(k = 1, \ldots, d\).
time_step (float) – The reference time step \(\tau\); the evolution time for order \(k\) is \(k \tau\).
number_of_randomizations (int) – Number of states generated per Krylov order.
- Return type:
None
- generate() Iterator[SubspaceState]
Yield the Krylov subspace states.
- Return type:
Iterator[SubspaceState]