10.35 GFWIGGLER—Tracks through a wiggler using generate function method of J. Bahrdt and G. Wuestefeld (BESSY, Berlin, Germany).

Tracks through a wiggler using generate function method of J. Bahrdt and G. Wuestefeld (BESSY, Berlin, Germany).
Parallel capable? : yes
GPU capable? : no
Back-tracking capable? : no






Parameter NameUnitsType Default

Description






L M double 0.0

Total length






B_MAX T double 0.0

Maximum on-axis magnetic field at gap=GAP0 and equal longitudinal phases of PHASE_1,2,3,4






SHIM_SCALE double 1

Scaling factor of shim correction field.






DX M double 0.0

Misaligment.






DY M double 0.0

Misaligment.






DZ M double 0.0

Misaligment.






TILT RADdouble 0.0

Rotation about beam axis.






PERIODS long 0

Total number of wiggler periods. Include end poles






STEP long 1

Number of normal periods to track for each step






ORDER short 0

Order=3 including the 3rd order terms. Otherwise using 2nd order formula.






END_POLE short 1

The ending poles are treated as 2 half periods at each sides of the wiggler with reducing field strength, such as 0.25, -0.75, ..., 0.75, -0.25. Periods has to > 2






SHIM_ON short 0

Include shim correction






INPUT_FILE STRINGNULL

Name of SDDS file with By harmonic data given at GAP0 and equal longitudinal phases.






SHIM_INPUT STRINGNULL

Name of SDDS file with shim field integral harmonic data given at GAP0.






SYNCH_RAD short 0

Include classical, single-particle synchrotron radiation?






ISR short 0

Include incoherent synchrotron radiation (quantum excitation)?






GFWIGGLER continued

Tracks through a wiggler using generate function method of J. Bahrdt and G. Wuestefeld (BESSY, Berlin, Germany).






Parameter NameUnitsType Default

Description






ISR1PART short 1

Include ISR for single-particle beam only if ISR=1 and ISR1PART=1






X0 M double0.0

Offset of magnet row center in meter.






GAP0 M double0.0

Nominal magnetic gap.






D_GAP M double0.0

Delta gap: actual gap - nominal gap






PHASE_1 RADdouble0.0

Longitudinal phase of the first row (top right)






PHASE_2 RADdouble0.0

Longitudinal phase of the second row (top left)






PHASE_3 RADdouble0.0

Longitudinal phase of the third row (bottom left)






PHASE_4 RADdouble0.0

Longitudinal phase of the fourth row (bottom right)






VERBOSITY short 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 the generate function method given by J. Bahrdt and G. Wüstefeld (“Symplectic tracking and compensation of dynamic field integrals in complex undulator structures,” PRSTAB 14, 040703, 2011.).

To use the element, one must supply an SDDS file giving harmonic analysis of the wiggler field. The field expansion used by the code is for a wiggler working at the nominal gap and provide pure horizontal deflecting to the on-axis beam. See CWIGGLER, horizontal wiggler with normal poles, for detail explaination of the field expansion and format of the input file. Besides the required columns of Cmn, KxOverKw, KyOverKw, and KzOverKw by the CWIGGLER elements, two more input columns are needed:

If a file include all required columns from CWIGGLER and GFWIGGLER then user can use either of the both methods for simulating a horizontal planar wiggler.

An universal wiggler field, which be used for generating an arbitrary polarization, can be derived by given different longitudinal phase parameters: PHASE_1,2,3,4. The photon energy can be varied by a non-zero D_GAP value.

HISTOGRAM