Adding propagator and hamiltonian_simulation docs#551
Open
v-agamshayit wants to merge 4 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds end-user documentation for the time-dependent evolution pipeline by introducing dedicated pages for the Propagator and HamiltonianSimulation algorithms, and by expanding the Magnus propagator’s in-code docstrings to better explain the underlying formulas and current implementation limitations.
Changes:
- Expanded
MagnusPropagatormodule/class docstrings with Magnus-expansion background, implementation status, and usage notes. - Added new Sphinx docs pages for
PropagatorandHamiltonianSimulationwith workflow-oriented guidance and settings tables. - Wired the new docs into the algorithms documentation index.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
| python/src/qdk_chemistry/algorithms/propagator/magnus_propagator.py | Adds richer theory/usage docstrings and clarifies current supported scope (order-1, driven container). |
| docs/source/user/comprehensive/algorithms/propagator.rst | New user guide for propagators, including workflow context and Magnus (“magnus”) implementation details. |
| docs/source/user/comprehensive/algorithms/index.rst | Adds propagator and hamiltonian_simulation to the algorithms docs index/toctree and summary table. |
| docs/source/user/comprehensive/algorithms/hamiltonian_simulation.rst | New user guide for Hamiltonian simulation, focused on the Euler integrator pipeline and settings. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+47
to
+49
| Accuracy | ||
| -------- | ||
| The order-1 propagator gives :math:`O(\Delta t^2)` accuracy. |
| :math:`H_\text{eff} = \Omega_1 / \delta t` (the time-averaged exponent | ||
| divided by :math:`\delta t = t_2 - t_1`) so that a time-stepping | ||
| integrator that multiplies by :math:`\delta t` recovers the full | ||
| exponent :math:`\Omega_1`. This gives :math:`O(\Delta t^2)` accuracy. |
Comment on lines
+193
to
+194
| Only the leading-order term is computed; this gives | ||
| :math:`O(\delta t^2)` accuracy. |
Comment on lines
+103
to
+105
| from qdk_chemistry.data import AlgorithmRef | ||
|
|
||
| euler.settings().set("propagator", AlgorithmRef("propagator", "magnus")) |
|
|
||
| where the drive integral is evaluated by numerical quadrature (``scipy.integrate.quad``). | ||
|
|
||
| This is the leading-order term of the Magnus expansion. This approximation gives :math:`O(\delta t^2)` accuracy. |
| - TimeDependentQubitHamiltonian → QubitHamiltonian | ||
| * - :doc:`HamiltonianSimulation <hamiltonian_simulation>` | ||
| - Time-dependent Hamiltonian simulation | ||
| - TimeDependentQubitHamiltonian + Observables → Energy |
| - Total evolution time :math:`T`. Default: ``1.0``. | ||
| * - ``dt`` | ||
| - float | ||
| - Time step size. Must be positive and not exceed ``total_time``. Default: ``0.0`` (must be set by user). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.