Simon Cross
unread,Dec 4, 2022, 10:57:58 AM12/4/22Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to qu...@googlegroups.com
Hi Pascal,
This is indeed somewhat difficult to achieve in QuTiP 4. In the
upcoming QuTiP 5, QobjEvo supports taking a function f(t) --> Qobj
directly, but that is perhaps not immediately helpful to you.
In your case though, there is a semi straight forward approach. The
number operator N is diagonal, so you can easily calculate e^(-itN)
yourself and then write the resulting time-dependent matrix as a sum
over the projectors.
For example, if your Hilbert space is dimension 4, you could write:
e_itN = [
[ qutip.basis(4, n).proj(), f"exp(-1j * {n} * t)" ]
for n in range(4)
]
q = qutip.QobjEvo(e_itN)
Hopefully that helps!
Just because I'm curious, where does this collapse operator arise?
Regards,
Simon