Skip to content

GKLS TUTORIAL FILES - #1

Merged
julienblin-kothar merged 24 commits into
KotharComputing:mainfrom
carlos-rib:gkls-tutorial
Jun 9, 2026
Merged

GKLS TUTORIAL FILES#1
julienblin-kothar merged 24 commits into
KotharComputing:mainfrom
carlos-rib:gkls-tutorial

Conversation

@carlos-rib

@carlos-ribcarlos-rib commented May 27, 2026

Copy link
Copy Markdown
Contributor

Summary

This is a tutorial file which goal is, by using the vectorization method, make a GKLS time evolution using Krylov method, as symbolic as possible.

Checklist

  • I only changed files under docs/contributions/.
  • New/updated files and folders under docs/contributions/ use kebab-case names.
  • I ran npm run build locally and it succeeded.
  • I verified links and references in the changed docs pages.
  • I reviewed formatting and readability.

Notes for Reviewers

Since I dived the code in some utility layers and run layers, I hyperlinked the full code files in some part of the text for my own GitHub page. I don't know whether this is okay, but this is still a work in progress, just for the sake of visibility.

@AlexandreFoleyAlexandreFoley self-assigned this May 29, 2026

@AlexandreFoleyAlexandreFoley left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Regarding you aleph scripts: for our own ability to make promises regarding long-term availability of your contribution we will have to bring copies, and link to those copies in the tutorial. You can always submit updates to it if you believe it is worth the hassle!

Overall, I think this is a really good tutorial, well written and clearly explained. The accompanying code is well organized.

The validations could be done using the aleph test framework. Its been made public fairly recently, so it probably wasn't available when you began working on this.
See https://docs.kotharcomputing.com/docs/aleph-101#testing .
Don't feel obligated to make that change.

So a few corrections and whatever is needed to make the ci pass afterwards (I'll help with that), and then it's good to go!

Thank you for sharing that with us!

Comment threaddocs/contributions/gkls-vec-tutorial/index.mdx Outdated
where $B^{\mathsf T}$ is the transpose of $B$. This is the identity that turns left–right multiplication into a single linear action on the vectorized state.

:::note
The choice of row-stacking is not physically special. What matters is using one convention consistently. The validation files check that the symbolic Liouville-space action agrees with the direct dense GKLS equation under this convention.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I would go further: the choice of row stacking is not even mathematically special; indeed, its just a choice of basis for the size $d^2$ vector space of quantum operators. One could change basis at any moment, using a unitary transform in that vector space.

As usual, the choice of basis can have great numerical consequences, especially with sparse numerical methods.

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

Good point! I updated the note to say this is a basis choice in operator space, not something mathematically special, while keeping the warning about numerical consequences.

\frac{d}{dt}|\rho(t)\rangle\rangle=\mathcal{L}\,|\rho(t)\rangle\rangle,
$$

where $\mathcal{L}$ is the **Liouvillian (Lindbladian superoperator)** (a $d^2\times d^2$ matrix). In the row-stacking convention used here, $\mathcal{L}$ can be written explicitly in terms of Kronecker products of $H$ and the jump operators $L_k$ as

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I'm used to calling Liouvillian only the coherent part of the super-operator, and calling Lindbladian the Liouvillian augmented with dissipative term. But that may be because i'm not all that fluent in the domain of dissipative quantum systems.

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

Thanks for that point! To make things more background-agnostic, I added a short convention note there. I’ll use “Liouvillian” for the full Liouville-space generator in this tutorial, but I now explicitly mention that “Lindbladian” is also used for the full GKLS generator, and that the coherent/Hamiltonian part can be separated when needed.

Comment threaddocs/contributions/gkls-vec-tutorial/index.md
Comment threaddocs/contributions/gkls-vec-tutorial/index.md
Comment threaddocs/contributions/gkls-vec-tutorial/liouville-core.aleph
Comment threaddocs/contributions/gkls-vec-tutorial/liouville-core.aleph
Comment threaddocs/contributions/gkls-vec-tutorial/liouville-core.aleph
Comment threaddocs/contributions/gkls-vec-tutorial/liouville-core.aleph
Comment threaddocs/contributions/gkls-vec-tutorial/liouville-core.aleph
@carlos-rib

Copy link
Copy Markdown
ContributorAuthor

Hey, Alexandre! Thanks a lot for the careful review, and also for the kind words about the tutorial and code organization. I’ll be going through the direct fixes now.

I’m also interested in the Aleph test framework point. I saw the test_section / test syntax in the docs, and I’d be happy to convert the validation layer to native Aleph tests either in this PR or in a follow-up, depending on what you think is cleaner for the contribution.

On the Born approximation comment: I see your point about the wording being confusing. I had in mind the usual weak-coupling/factorized-state step in the open-systems derivation, but I agree the way I phrased it mixes terminology too much. I’ll rewrite that part in safer language rather than trying to name the approximation too aggressively.

carlos-riband others added 12 commits June 2, 2026 20:56
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Co-authored-by: Alexandre Foley <alexandre.foley@usherbrooke.ca>
Comment threaddocs/contributions/gkls-vec-tutorial/index.md
@AlexandreFoley

Copy link
Copy Markdown
Collaborator

I had to make quite a few changes to make the CI "build the webpage" part of the continuous integration test work.
The CI task themselves were untested it seems.
Those changes make the scope check test fail. That's normal and will have to be ignored this time.
Everything looks good as far as i'm concerned, but web development is much more alien to me than Lindbladians, So we'll wait on Julien to check that part.

@julienblin-kothar

julienblin-kothar commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

Thanks a lot @carlos-rib !

And sorry again about the missing files in the repo. You ended up being our guinea pig, and a great one at that.
I made a few small edits to the author format, and I’m approving and merging this now.

I’ll let you know as soon as it’s live on our official docs website.

@julienblin-kothar
julienblin-kothar merged commit a3e75a6 into KotharComputing:mainJun 9, 2026
2 checks passed
@julienblin-kothar

Copy link
Copy Markdown
Collaborator

Great news @carlos-rib, your contribution is now live on our official docs website!

https://docs.kotharcomputing.com/docs/contributions/gkls-vec-tutorial

Thanks again for being our first external contributor. Really happy to have this up!

Sign up for freeto 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.

4 participants

@carlos-rib@AlexandreFoley@julienblin-kothar@SebA-KC