qutip / qutip-tutorials

QuTiP Tutorials
BSD 3-Clause "New" or "Revised" License
36 stars 36 forks source link

Porting Steady-State tutorial for Optomechanical Systems to QuTiP 5 #97

Closed obliviateandsurrender closed 3 months ago

obliviateandsurrender commented 4 months ago

Porting the demo Steady-State: Optomechanical System in the Single-Photon Strong-Coupling Regime tutorial to QuTiP 5 (v5) as noted in #92

  1. Added description of new solvers and methods based on v5 docstring.
  2. Adapted the steady-state solution code for v5.
  3. Adapt for accessing ndarrays for the Dense representation of Qobj.
  4. Change an argument name for plt.spy visualization.
  5. Add an assertion for non-zero elements for sanity check.
hodgestar commented 4 months ago

Thank you for taking a look. Could you try make some better assertions on the results and move them into Testing section at the end? See the other tutorials for examples (some have better checks than others).

I've activated CI. If the CI run produces any errors, please update the PR to fix them.

obliviateandsurrender commented 4 months ago

I don't think the current build error is related to my changes, any ideas on fixing it? 🤔

ArturDomingues commented 4 months ago

There is problem with compatibility of qutip-jax and qutip, which is being solved by https://github.com/qutip/qutip/pull/2448 but, until this fix is accepted, the thing that was done in #98 is the temporary fix PS.: It seems that https://github.com/qutip/qutip/pull/2448 was accepted, try to rerun the CI build and see if it passes without altering anything

obliviateandsurrender commented 4 months ago

@hodgestar, let me know if this needs more modifications!