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

Groundstate bug in QuTiP 5 #1937

Closed
christian512 opened this issue Jun 20, 2022 · 0 comments
Closed

Groundstate bug in QuTiP 5 #1937

christian512 opened this issue Jun 20, 2022 · 0 comments
Assignees
Milestone

Comments

@christian512
Copy link
Contributor

Bug Description

The groundstate() function seems to have a bug in the current version of dev.major.
When calling groundstate() on any Qobj, an error occurs.

Code to Reproduce the Bug

from qutip import destroy
H = destroy(2).dag() * destroy(2)
H.groundstate()

Code Output

File "/home/chris/git/qutip-dev-major/qutip/core/qobj.py", line 1632, in groundstate
    grndvec = Qobj(evecs[0], dims=new_dims)
TypeError: 'qutip.core.data.dense.Dense' object is not subscriptable

Expected Behaviour

The groundstate of H should be returned.

Your Environment

QuTiP Version:      5.0.0.dev0+98a8e7d
Numpy Version:      1.22.4
Scipy Version:      1.8.1
Cython Version:     0.29.30
Matplotlib Version: 3.5.2
Python Version:     3.8.10
Number of CPUs:     4
BLAS Info:          OPENBLAS
INTEL MKL Ext:      False
Platform Info:      Linux (x86_64)

Additional Context

No response

@hodgestar hodgestar added this to the QuTiP 5.0 milestone Jun 20, 2022
@Ericgig Ericgig self-assigned this Jun 20, 2022
@Ericgig Ericgig closed this as completed Jun 21, 2022
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

No branches or pull requests

3 participants