Skip to content

Add introductory tutorial on Jaynes-Cummings-Hubbard Model #130

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

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

Conversation

Vanshaj0429
Copy link

Summary

This tutorial introduces the Jaynes-Cummings-Hubbard Model on a three-site cavity array, showcasing how to build and simulate light–matter interactions using QuTiP. It walks through Hamiltonian construction, ground state analysis, time evolution, and phase transition signatures, offering a compact, hands-on guide to exploring quantum dynamics in coupled cavity QED systems.

The notebook is written in Jupytext Markdown format and adheres to the qutip-tutorials contribution guidelines. All code cells execute successfully and pass pytest --nbmake.

Tutorial Highlights

Key Concepts Covered:

  • Construction of the full JCHM Hamiltonian for three coupled atom-cavity sites

  • Analysis of the ground state properties and atomic excitation

  • Time evolution of localized photon excitations using mesolve

  • Exploration of phase transition signatures using:

     Photon number fluctuations (Δn)
     Cavity field amplitude (⟨a⟩)
    

Effects of:

  • Varying hopping strength J
  • Detuning (Δ = ω_a - ω_c)
  • Atom-cavity coupling strength g

Tools & Techniques

  • Operator construction via tensor, qeye, destroy, and sigmaz
  • Diagonalization using eigenstates
  • Numerical time evolution via qutip.mesolve
  • Visualization with matplotlib

File Location

tutorials-v5/miscellaneous/JCHM-tutorial.md

Additional Notes

Let me know if:

  • You'd like more or less detail included in the notebook
  • Also if you'd like this notebook to be placed in other subfolder
  • Looking forward to any feedback or suggestions — happy to iterate!

@Vanshaj0429 Vanshaj0429 changed the title Add a introductory tutorial on Jaynes-Cummings-Hubbard Model Add introductory tutorial on Jaynes-Cummings-Hubbard Model Apr 21, 2025
@Vanshaj0429
Copy link
Author

Hi @Ericgig, I have opened this PR on possibility of adding a tutorial on Jaynes-Cummings-Hubbard model. Would love to have your feedback on it.

@Vanshaj0429
Copy link
Author

Hi @Ericgig!

This is my first contribution to the QuTiP tutorials, and I’ve added a new notebook titled JCHM-tutorial.md to tutorials-v5/miscellaneous/.

The notebook:

  • Runs cleanly from start to finish
  • Passes pytest --nbmake locally
  • Doesn’t contain any links (just math, code, and plots)

It looks like the CI failed because of dead links in some unrelated files:

heom-5a-fermions-single-impurity-model.md
013_nonmarkovian_monte_carlo.md

Since those aren’t touched by this PR, I believe the failure isn't caused by my changes.
Please let me know if I should open a separate PR to help fix those or I am missing something here and how to proceed forward?

Copy link
Member

@pmenczel pmenczel left a comment

Choose a reason for hiding this comment

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

This looks great! Thank you for your contribution. May I ask how you came up with creating this tutorial, and its contents? Is this a topic you are very familiar with?

@Vanshaj0429
Copy link
Author

This looks great! Thank you for your contribution. May I ask how you came up with creating this tutorial, and its contents? Is this a topic you are very familiar with?

Hi @pmenczel! Thanks for reviewing. I have been in talks with Eric to make some contribution as part of my GSoC application. I am a recent Master's graduate in physics from Cardiff University. There I worked on a project that focused on simulating features of Jaynes Cummings model using QuTiP. I also wanted to explore the Jaynes Cummings Hubbard model, but couldn't do it at the time due to time constraints. This tutorial is somewhat an extension of my previous work trying to simulate more rich models. https://github.com/Vanshaj0429/cavity-qed-simulations

If you have any more questions or feedback. I am happy to answer :)

@Vanshaj0429 Vanshaj0429 requested a review from pmenczel April 27, 2025 22:36
@pmenczel
Copy link
Member

Thank you for your replies! You have requested a review, but a few points are still open above (your name, e_ops, phase transition). Other than these, it looks ready to merge for me!

@Vanshaj0429
Copy link
Author

@pmenczel and @nwlambert, I have made the necessary changes, I think it looks good to me now. Apologies for the delay on this PR. Can you have a look?

pmenczel
pmenczel previously approved these changes Jul 28, 2025
@pmenczel pmenczel dismissed their stale review July 28, 2025 02:43

Missed formatting errors

@pmenczel
Copy link
Member

Hi, thank you for the changes. One more thing - sorry, I missed it previously. The CI tests fail because of the PEP8 check, could you please fix the formatting?

You can see the exact problems in the details of the failed tests, or by running nbqa flake8 JCHM-tutorial.md. The main problem seems to be the import *, which is discouraged.

@Vanshaj0429
Copy link
Author

Hi @pmenczel, I have fixed the formatting issues, I used nbqa black JCHM-tutorial.md. Can you check again?

@pmenczel
Copy link
Member

pmenczel commented Aug 4, 2025

There are still some errors

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