Programs for generating Landau damping curves

Introduction

Here you will find a collection of programs designed for the production of Landau damping curves. There are several programs which, given a set of parameters, will produce a two columns of numbers which are the x and y coordinates of the curve delimiting the threshold for Landau damping. In each case, the origin corresponds to the zero-current value of the mode frequency in question.

It is also possible to use the libraries supplied to use the generated Landau damping curves in your own code. See the source code for the executables to determine how to do this.

To use the Landau damping curves, simply plot the complex shifts of the modes you obtain by performing a computation assuming a linear lattice on the same graph that you plot the stability curve. If your modes lie below the Landau damping curve, the modes are stable. In principle, you can use the program vlasov, which can also be found at this site, to obtain these frequency shifts, but at the moment it is difficult to extract that real and imaginary parts of the shifts together (they are buried in a binary file). The next update of that program will correct that deficiency.

The programs plot Landau damping curves for the cases where the distribution about which you're perturbing is either Gaussian or quasi-parabolic. For the parabolic-like distributions, they all have a parameter \mu, which is defined such that the maximum coordinate of the distribution is \sqrt{2\mu} when \sigma is 1.

These programs lack a certain user-friendliness at the moment. This will be corrected in a future version. All existing documentation is below.

To obtain and compile the programs

A tarred and gzipped file of the code can be downloaded by clicking here. Compiling the code requires gcc version 2.7.2 or later. To compile the code, simply type gmake in the directory where the code is, where gmake is the name of your local version of GNU make. If you don't have gcc and/or GNU make, you should edit the makefile so that your version of make runs you C++ compiler to compile the code.

Using the programs

There are six programs supplied. All will output two columns of numbers which you can feed to your favorite plotting program.

gaussplt
Plots transverse Landau damping curves for a beam with a transverse Gaussian distribution. It takes 4 arguments
  1. The tune shift per unit emittance in the direction perpendicular to the oscillation direction
  2. The tune shift per unit emittance in the direction parallel to the oscillation direction
  3. The largest actual frequency shift to plot for
  4. The number of points to output
parabplt
Plots transverse Landau damping curves for a beam with a transverse parabolic-like distribution. It takes 5 arguments
  1. The tune shift per unit emittance in the direction perpendicular to the oscillation direction
  2. The tune shift per unit emittance in the direction parallel to the oscillation direction
  3. \mu
  4. The number of points to output
gbljgaplt
Plots Landau damping curves for a beam with a longitudinal Gaussian distribution, assuming the tune shift per unit emittance longitudinally is 1. It takes 3 arguments
  1. The longitudinal azimuthal mode number m
  2. The largest actual frequency shift to plot for
  3. The number of points to output
pbljgaplt
Plots Landau damping curves for a beam with a longitudinal parabolic-like distribution, assuming the tune shift per unit emittance longitudinally is 1. It takes 3 arguments
  1. The longitudinal azimuthal mode number m
  2. \mu
  3. The number of points to output
gaussdist
Plots a Gaussian distribution. The curve output will have a \sigma of 1. It takes two arguments:
  1. The amplitude to go to
  2. The number of points to output
parabdist
Plots a parabolic-like distribution. The curve output will have a \sigma of 1. It takes two arguments:
  1. \mu
  2. The number of points to output

Other Information

Please send me email at <Scott.Berg@cern.ch> if you have any questions, problems, suggestions, or would like to be notified of future improvements (which there will be!).

I don't recommend that you make any other use of any of the code for special functions included in this package. The approximations used work well for the purposes of generating Landau damping curves, but will fail in other situations!