YaoFlux.jl
YaoFlux.jl copied to clipboard
[WIP] New VQE example
@MikeInnes
Roger told me that you are interested in "quantize" Zygote, and put it into your paper. Variational quantum eigensolver is one of the killer applications on quantum computers. The classical simulation requires differentiate over "quantum operations" on registers.
This PR is an example of VQE.
Ideally, we would expect Zygote
differentiate over the program without any additional effort. For the classical variational eigensolver, it is true!
However, mutatable array and other features are required for the quantum version. I wonder how much effort is required to make it work? Are you interested in adding features to make this example (the 3rd test) work?
PS: I tried merging mutate
branch of Zygote, but classical complex valued AD failed unexpectedly. So, please be careful about potential conflicts in the mutate
branch.