-
Notifications
You must be signed in to change notification settings - Fork 18
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
Discrepancy in clock-qubit fields #24
Comments
I was suprised, when I saw the ionphys was implementing numerical differentiation. I'm always inclined to use a package. Numpy has somehting like this. |
The numbers in my thesis are based on the analytic derivative of the BR formula. If we want something accurate then that is what we should do in this package as well. I think there is a |
IMO this code should be explicitly special cased (and documented) to only handle Might be nice to add a test that compares the BR to the diagonalisation for the energy levels. |
Yes you could do that, but if one wanted to find out df/dB or any other derivative for any other transitions, you'd get the wrong answer. You could add in the special case of analytic BR, but the function we currently have shouldn't numerically give the wrong answer. |
Is that something that comes up? I've never wanted to know that for a transition outside the ground level. (If I only want a rough idea I'd tend to reach for pen and paper rather than bothering to open python and write code). But, yes, if we use the BR then we either need to (a) raise an exception if The concern I have with relying on numerics is accuracy. e.g. for |
Not for our usecase. However, quadrupole clock transitions are sometimes used. |
Yes, but only really at 0 field. I can't think of an experiment that has used an intermediate field quadrupole clock transition, so I'm not convinced that this is something we need to cater for. As a piece of philosophy/design goals, I think it's important to remember that we're building a framework that people can use to solve all kinds of problems, but it's okay if they have to do some of the legwork/write glue code themselves. It's fine to have some utility code to reduce boilerplate in really common cases, but we have to make sure that it's sufficiently useful to justify its place in the library as opposed to user code (or a user library). With that in mind, it's not even clear to me that the current code should be in the |
And, again, if you're building a clock then you really want to use the analytic routines to make sure you understand the numerics. |
I have noticed that the magic-fields for the clock-qubits don't quite match the numbers in TPH thesis.
I have calculated the fields using the ion_phys package example "clock_qubits.py", as well explicitly using the Breit-Rabi formula. Both the ion_phys package and the BR formula agree when using the same optimisation procedure. However, if one plots the transition frequency and manually looks at the minimum field, it does agree with TPH.
We currently calculate the gradient by adding a small positive change to B (see below), but this skews the result as it is not symmetric about the original B.
We should calculate the gradient symmetrically about a point. I have checked both methods for calculating the magic fields using the BR formula and ion_phys, and if you do it symmetrically you get agreement with TPH thesis. Not sure what the best way to implement this change, but something like
maybe?
The text was updated successfully, but these errors were encountered: