-
Notifications
You must be signed in to change notification settings - Fork 8
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
[Tutorials] More examples #38
Comments
Hi, thanks for your interest, to clarify, this currently does not run a real quantum device, but only through a simulator as some of the protocols are not compatible with existing quantum devices due to various reasons. On the other hand, this package has been maintained for a while, so the algorithms implemented in this package are not the state of the art anymore. If you are working on research on solving ODEs with the quantum device, this package could be a playground, but using it for solving real problems is not something I'd recommend. regarding the examples, you can find them in the tests and examples folder, it accepts standard Julia DiffEq interface/definition of problems (you can refer to DiffEq.jl documentation for the interface definition) for example, the function f(du,u,p,t)
du[1] = -2*(u[2]^2)*u[1]
du[2] = 3*(u[1]^(1.5)) - 0.1*u[2]
end Regarding using DiffEq from Python, I'd recommend you ask at julia discourse or Julia slack's diffeq channel with more specific error reports or things you are trying. But I'd still recommend you to just program Julia - it's way easier than python for these tasks especially if you are using a Julia package. |
Hi @Roger-luo. Thanks for the help. I consulted the classical OrdinaryDiffEq Julia package and was able to solve the following DE: dx/dt = 3*x+4, x_initial=2, tspan = (0.0, 1.0). The code I used is (please note, I use the Python JuliaCall to manipulate Julia packages)
However, the same approach does not work with the QuDiffEq package.
Could you please point out my mistake? |
Hii @olgOk . I would suggest taking a look at
So you could try something like this
|
I noticed there is a big issue with the |
Hello! Thank you for your wonderful work on solving DE on quantum device.
I have never had experience with Julia, so I use Python JuliaCall. Could you please provide more examples how to submit DE to the QuDiffEq solver? I tried a really straightforward example such as dx/dt = 3x+4, but could not figure out a correct way of creating the M, b and x_initial matrices (I follow the notation dx/dt=Mx+b). What data types should I use for this matrices if M, x,b are numbers?
The text was updated successfully, but these errors were encountered: