Tune / Resonance diagram

In Accelerator physics you often need a Tune diagram to display machine tunes. A quick Google search gave me no readily available Mathematica code for drawing one, so I came up with a Mathematica notebook that produces graphics similar to the following diagram:

The Mathematica notebook and package I used to generate the diagram can be found here, a demo Notebook showing the usage of the resonance diagram is included.

To find resonances up to order o I solve the equation
$latex a Q_x +bQ_y=n$
for a list of x and y between –o and o and then plot all those solutions after filtering out solutions for orders higher than desired order. Each solution gets a plot style from a list corresponding to its order.

Feel free to use and modify the notebook, it is, as everything here released under a creative commons license.

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.