next up previous
Next: DRIF Up: Element Dictionary Previous: CSRDRIFT

CWIGGLER

Tracks through a wiggler using canonical integration routines of Y. Wu (Duke University).
Parallel capable? : yes
Parameter Name Units Type Default Description
L $M$ double 0.0 Total length
B_MAX   double 0.0 Maximum on-axis magnetic field.
BX_MAX   double 0.0 Maximum on-axis magnetic field. Ignored if B_MAX is nonzero.
BY_MAX   double 0.0 Maximum on-axis magnetic field. Ignored if B_MAX is nonzero.
DX   double 0.0 Misaligment.
DY   double 0.0 Misaligment.
DZ   double 0.0 Misaligment.
TILT   double 0.0 Rotation about beam axis.
PERIODS   long 0 Number of wiggler periods.
STEPS_PER_PERIOD   long 10 Integration steps per period.
INTEGRATION_ORDER   long 4 Integration order (2 or 4).
BY_FILE   STRING NULL Name of SDDS file with By harmonic data.
BX_FILE   STRING NULL Name of SDDS file with Bx harmonic data.
BY_SPLIT_POLE   long 0 Use "split-pole" expansion for By?
BX_SPLIT_POLE   long 0 Use "split-pole" expansion for Bx?
SYNCH_RAD   long 0 Include classical synchrotron radiation?
ISR   long 0 Include incoherent synchrotron radiation (scattering)?
ISR1PART   long 1 Include ISR for single-particle beam only if ISR=1 and ISR1PART=1
SINUSOIDAL   long 0 Ideal sinusoidal wiggler? If non-zero, BX_FILE and BY_FILE are not used.
VERTICAL   long 0 If SINUSOIDAL is non-zero, then setting this to non-zero gives a vertical wiggler. Default is horizontal.

Tracks through a wiggler using canonical integration routines of Y. Wu (Duke University).
Parameter Name Units Type Default Description
HELICAL   long 0 Ideal helical wiggler? If non-zero and SINUSOIDAL is also non-zero, BX_FILE and BY_FILE are not used.
FORCE_MATCHED   long 1 Force matched dispersion for first harmonics? If non-zero, start and end of magnetic field will be inset from the ends of the device if phase is not 0 or $\pi$.
FIELD_OUTPUT   STRING NULL Name of file to which field samples will be written. Slow, so use only for debugging.
VERBOSITY   long 0 A higher value requires more detailed printouts related to computations.
GROUP   string NULL Optionally used to assign an element to a group, with a user-defined name. Group names will appear in the parameter output file in the column ElementGroup





N.B.: at present this element is not included in computations of beam moments (moments_output command).

This element simulates a wiggler or undulator using a modified version of Ying Wu's canonical integration code for wigglers. To use the element, one must supply an SDDS file giving harmonic analysis of the wiggler field. The field expansion used by the code for a horizontally-deflecting wiggler is (Y. Wu, Duke University, private communication).

\begin{displaymath}
B_y = -\left\vert B_0\right\vert \sum_{m,n} C_{mn}\cos(k_{xl} x) \cosh (k_{ym} y)
\cos(k_{zn} z + \theta_{zn}),
\end{displaymath} (12)

where $\left\vert B_0\right\vert$ is the peak value of the on-axis magnetic field, the $C_{mn}$ give the relative amplitudes of the harmonics, the wavenumbers statisfy $k^2_{ym} = k^2_{xl} + k^2_{zn}$, and $\theta_{zn}$ is the phase.

The file must contain the following columns:

In Version 17.3 and later, for matrix computations elegant uses a first-order matrix derived from particle tracking when it encounterse a CWIGGLER. Tests show that this gives good agreement in the tunes from tracking and Twiss parameter calculations. For radiation integrals, an idealized sinusoidal wiggler model is used with bending radius equal to $B\rho/(B_0 \sum C_{mn})$ for each plane. Energy loss, energy spread, and horizontal emittance should be estimated accurately.

elegant allows specifying field expansions for on-axis $B_y$ and $B_x$ components, so one can model a helical wiggler. However, in this case one set of components should have $\theta_{zn} = 0$ or $\theta_{zn}=\pi$, while the other should have $\theta_{zn} = \pm \pi/2$. Using Wu's code, the latter set will not have matched dispersion. Our modified version solves this by delaying the beginning of the field components in question by $\lambda/4$ and ending the field prematurely by $3\lambda/4$. This causes all the fields to start and end at the crest, which ensures matched dispersion. The downside is that the (typically) vertical wiggler component is missing a full period of field. One can turn off this behavior by setting FORCE_MATCHED=0.

Additional field expansions

Y. Wu's code included field expansions for a vertically-deflecting wiggler as well as the horizontally-deflecting wiggler given above. In both cases, these expansions are suitable for a wiggler with two poles that are above/below or left/right of the beam axis. They are not always suitable for devices with more complex pole geometries.

Another geometry that is important is a ``split pole'' wiggler, in which each pole is made from two pieces. Such configurations are seen, for example, in devices used to produce variable polarization. In such cases, the expansion given above may not be appropriate. Here, we summarize the form of the various expansions that elegant supports. For brevity, we show the form of a single harmonic component.

Horizontal wiggler, normal poles, produces $B_y$ only on-axis. Specified by setting BY_SPLIT_POLE=0, and giving BY_FILE or SINUSOIDAL=1 with VERTICAL=0.

$\displaystyle B_x$ $\textstyle =$ $\displaystyle \left\vert B_0\right\vert \frac{k_x \cos (k_z z + \phi) \sin (k_x x) \sinh (k_y y)}{k_y}$ (13)
$\displaystyle B_y$ $\textstyle =$ $\displaystyle - \left\vert B_0\right\vert \cos (k_x x) \cos (k_z z + \phi) \cosh (k_y y)$ (14)

where $k_y^2 = k_x^2 + k_z^2$.

Horizontal wiggler, split poles, produces $B_y$ only on-axis. Specified by setting BY_SPLIT_POLE=1, and giving BY_FILE or SINUSOIDAL=1 with VERTICAL=0.

$\displaystyle B_x$ $\textstyle =$ $\displaystyle -\left\vert B_0\right\vert \frac{k_x \cos (k_z z + \phi) \sin (k_y y) \sinh (k_x x)}{k_y}$ (15)
$\displaystyle B_y$ $\textstyle =$ $\displaystyle -\left\vert B_0\right\vert \cos (k_y y) \cos (k_z z + \phi) \cosh (k_x x)$ (16)

where $k_x^2 = k_y^2 + k_z^2$.

Vertical wiggler, normal poles, produces $B_x$ only on-axis. Specified by setting BX_SPLIT_POLE=0, and giving BX_FILE or SINUSOIDAL=1 with either VERTICAL=1 or HELICAL=1.

$\displaystyle B_x$ $\textstyle =$ $\displaystyle \left\vert B_0\right\vert \cos (k_y y) \cos (k_z z + \phi) \cosh (k_x x)$ (17)
$\displaystyle B_y$ $\textstyle =$ $\displaystyle -\left\vert B_0\right\vert \frac{k_y \cos (k_z z + \phi) \sin (k_y y) \sinh (k_x x)}{k_x}$ (18)

where $k_x^2 = k_y^2 + k_z^2$.

Vertical wiggler, split poles, produces $B_x$ only on-axis. Specified by setting BX_SPLIT_POLE=1, and giving BX_FILE or SINUSOIDAL=1 with either VERTICAL=1 or HELICAL=1.

$\displaystyle B_x$ $\textstyle =$ $\displaystyle \left\vert B_0\right\vert \cos (k_x x) \cos (k_z z + \phi) \cosh (k_y y)$ (19)
$\displaystyle B_y$ $\textstyle =$ $\displaystyle \left\vert B_0\right\vert \frac{k_y \cos (k_z z + \phi) \sin (k_x x) \sinh (k_y y)}{k_x}$ (20)

where $k_y^2 = k_x^2 + k_z^2$.
next up previous
Next: DRIF Up: Element Dictionary Previous: CSRDRIFT
Robert Soliday 2014-03-21