Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for cpp dynamics #2735

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

sacpis
Copy link
Collaborator

@sacpis sacpis commented Mar 14, 2025

Adding documentation for cpp dynamics

@sacpis sacpis changed the title Adding documentation for cpp dynamics Documentation for cpp dynamics Mar 14, 2025
@sacpis sacpis requested a review from efratshabtai March 14, 2025 18:54
github-actions bot pushed a commit that referenced this pull request Mar 14, 2025
Copy link

CUDA Quantum Docs Bot: A preview of the documentation can be found here.

:language: cpp
:start-after: [Begin Hamiltonian]
:end-before: [End Hamiltonian]

2. Time-dependent operator

We can also construct a time-dependent operator from a function that returns a complex matrix representing the time dynamics of
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are 3 more Python tabs in this file - do they have a C++ equivalent?
Also, for the table of integrators at the bottom, I believe these are just for python? Which C++ integrators should we document?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For remaining C++ examples, I will check with @1tnguyen.
The table of integrators is just for Python. From that table we are only using RungeKutta for C++.

In particular, `ScalarOperator` provides an easy way to model arbitrary time-dependent control signals.
Details about CUDA-Q `operator`, including builtin operators that it supports can be found :ref:`here <operators>`.

.. tab:: C++
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Python tab codes include setting the target to dynamics - should we add the equivalent in the C++ tabs?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. These are only snippets. We will have to add a Compile & Run section which will include the command with dynamics target.

int main() {
// [Begin Transmon]
// Parameters
double omega_z = 6.5;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we add these values to the Python tab as well?
Currently it doesn't have the specific values.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think @1tnguyen or @bettinaheim would have a better answer here.

github-actions bot pushed a commit that referenced this pull request Mar 14, 2025
Copy link

CUDA Quantum Docs Bot: A preview of the documentation can be found here.

sacpis added 5 commits March 16, 2025 16:16
Signed-off-by: Sachin Pisal <[email protected]>
Signed-off-by: Sachin Pisal <[email protected]>
Signed-off-by: Sachin Pisal <[email protected]>
@sacpis sacpis force-pushed the operators_documentation branch from e53efa1 to f9988d4 Compare March 16, 2025 23:16
sacpis added 2 commits March 16, 2025 16:33
Signed-off-by: Sachin Pisal <[email protected]>
Copy link

CUDA Quantum Docs Bot: A preview of the documentation can be found here.

github-actions bot pushed a commit that referenced this pull request Mar 17, 2025
github-actions bot pushed a commit that referenced this pull request Mar 17, 2025
Copy link

CUDA Quantum Docs Bot: A preview of the documentation can be found here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants