Closed mrs504aa closed 3 months ago
One thing that pops out is that you didn't actually use the LockedAmplitude
in the Hamiltonian.
hamiltonian(HStatic, (HOmega, Omega), (HDelta, Delta))
should be
hamiltonian(HStatic, (HOmega, OmegaAmp), (HDelta, DeltaAmp))
(BTW, if you ever want someone else to read your code, don't use CamelCase for variable names in Julia. CamelCase indicates Module or Types names)
I noticed that there are ShapedAmplitude and LockedAmplitude described in the documentation. I happen to calculate a optimization problem in which there is one time-dependent parameter that I don't want to optimize. So I defined this parameter as
And I have another time-dependent parameter to be optimized
The I throw them into the Hamiltonian which is
When I defined the problem, there is a warning says that
And when I run the optimization, an error message shows up
My question is that did I mis-understand the usage of LockedAmplitude? Is there any way to put in a time-dependent parameter which should not be optimized?