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

A wish list:-) #66

Open
DevelopDaily opened this issue Nov 12, 2019 · 3 comments
Open

A wish list:-) #66

DevelopDaily opened this issue Nov 12, 2019 · 3 comments

Comments

@DevelopDaily
Copy link

I'd like to suggest you put more references into the API doc or source code comments, preferably as what SciPy people do in their "References" section. I don't mean that you spend a lot of time to put a "References" section into every piece of code. But, some references would be very helpful for understanding your particular implementation of those components of quintessential nature of quantum computing.

Thanks.

@vsoftco
Copy link
Member

vsoftco commented Jan 25, 2020

@DevelopDaily Great suggestion, and sorry for getting at this issue so late! Most of the implementations follow the conventions in Nielsen and Chuang. Some are my own. The only code that is not following in the two categories is explicitly documented. I guess I can mention in the Wiki, or in a README, as doing this for every function may be tedious.

Do you have any particular case in mind, so I can understand better what you mean? I.e., how'd you write some docs for some specific function?

@sergeysalata
Copy link

sergeysalata commented Dec 9, 2023

According to docs ket qpp::QEngine::get_psi(); returns state of quantum system. ket is vector, but state of quantum system should be a matrix with size 2^N x 2^N. How to get this full matrix?

@vsoftco
Copy link
Member

vsoftco commented Dec 10, 2023

@sergeysalata The state is a vector, as you evolve an initial pure state. What you're asking for is the density matrix, which can be obtained by ket psi = qengine.get_psi(); cmat rho = prj(psi);.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants