Hi Bethan,
I looked over your code briefly, and I think your problems might be related to oscillations in the OBEs not being properly accounted for.
The way generate_force_profile works for the OBEs is that it takes your position and velocity and integrates the OBEs for some period of time T. After integrating the OBEs, it then computes the force on the molecule. It then continues the integration
for another period of time T and computes the force again. It does this until either the average force over the integration period T no longer changes significantly, i.e., it converges, or the maximum number of iterations is reached.
If you pass debug=True to the obe.generate_force_profile function, it will print out useful information on every iteration. In particular, it will print out at what velocity and position it is evaluating at, then three numbers: the iteration index, the
the average force vector, and the average force vector squared. It is looking for convergence in the last number, and I suspect that your calculation is not converging, but instead maxing out the iterations.
Such a problem might be related to the fact that you are using a two-manifold model for CaF. While that is the easiest to set up, what it means in practice is that you have a single rotating frame for all seven transitions. Thus, there will be some rapid
oscillations for the transitions that have the largest detuning from the single rotating frame. So, in simulating the OBEs, I would first look at some of the computed solutions to (a) make sure they don’t have convergence issues and (b) try to get a sense
for over what period of time you have to integrate the solution for in order to really see a “steady state”: a set of oscillations that really repeats in a reasonable way, such that when the force is averaged over two adjacent periods of the same length, it
gives roughly the same answer.
Once you know what period you should integrate over, you can use the *undocumented* (ooops, sorry) arguments delta_r. delta_v, delta_tmax, and delta_func of obe.generate_force_profile to set the integration period of the OBEs to match the period that you
determined above. delta_func is probably the easiest one to use: for that, you pass a function that you construct that takes two arguments — the position vector and velocity vector -- and returns an integration time.
Then when you run obe.generate_force_profile with your delta_func function and debug=True, you should start to see convergence.
As an aside, there is probably a better way to find the “steady state”, but what I describe above is what is currently programmed. I’m open to suggestions for improvement on this front.
Hope that helps,
-Steve
--
Dr. Stephen Eckel
Physicist
Sensor Sciences Division
Thermodynamic Metrology Group
100 Bureau Drive, Stop 8364
Gaithersburg, MD 20899-8364
(301) 975-8571