User’s Manual for elegant

Program Version 27.0.2
Advanced Photon Source
Michael Borland

February 11, 2015

Note: another source of help for elegant is the on-line forum. Users are encouraged to join and participate. At minimum, users should subscribe to the “Bugs” topic, since this is where bug notifications are posted. Contrary to previous practise, we will no longer announce bugs via email.

A brief overview of elegant is also available, which introduces the capabilities at a high-level.

1 Highlights of What’s New in Version 27.0
 1.1 Bug Fixes for Elements
 1.2 Bug Fixes for Commands
 1.3 New and Modified Elements
 1.4 New and Modified Commands
 1.5 Changes for Parallel Version Only
 1.6 Changes to Related Programs and Files
 1.7 Known Bugs, Problems, and Limitations
2 Credits
3 Introduction
 3.1 Program Philosophy
 3.2 Capabilities of elegant
4 Digression on the Longitudinal Coordinate Definition
5 Fiducialization in elegant
6 Preparing beams for bunch-mode simulations
7 Namelist Command Dictionary
 7.1 Commandline Syntax
 7.2 General Command Syntax
 7.3 Setup and Action Commands
 7.4 Table of elegant commands and their functions
 7.5 alter_elements
 7.6 amplification_factors
 7.7 analyze_map
 7.8 aperture_data
 7.9 bunched_beam
 7.10 change_particle
 7.11 chromaticity
 7.12 closed_orbit
 7.13 correct
 7.14 correction_matrix_output
 7.15 correct_tunes
 7.16 coupled_twiss_output
 7.17 divide_elements
 7.18 error_element
 7.19 error_control
 7.20 find_aperture
 7.21 floor_coordinates
 7.22 frequency_map
 7.23 global_settings
 7.24 insert_elements
 7.25 insert_sceffects
 7.26 linear_chromatic_tracking_setup
 7.27 link_control
 7.28 link_elements
 7.29 load_parameters
 7.30 matrix_output
 7.31 modulate_elements
 7.32 moments_output
 7.33 momentum_aperture
 7.34 optimize
 7.35 optimization_constraint
 7.36 optimization_covariable
 7.37 optimization_setup
 7.38 parallel_optimization_setup
 7.39 optimization_term
 7.40 optimization_variable
 7.41 print_dictionary
 7.42 ramp_elements
 7.43 rf_setup
 7.44 replace_elements
 7.45 rpn_expression
 7.46 rpn_load
 7.47 run_control
 7.48 run_setup
 7.49 sasefel
 7.50 save_lattice
 7.51 sdds_beam
 7.52 semaphores
 7.53 slice_analysis
 7.54 subprocess
 7.55 steering_element
 7.56 touschek_scatter
 7.57 transmute_elements
 7.58 tune_footprint
 7.59 twiss_analysis
 7.60 twiss_output
 7.61 track
 7.62 tune_shift_with_amplitude
 7.63 vary_element
8 Specialized Tools for Use with elegant
 8.1 astra2elegant
 8.2 coreEmittance
 8.3 csrImpedance
 8.4 doubleDist6
 8.5 haissinski
 8.6 ibsEmittance
 8.7 madto
 8.8 sddsanalyzebeam
 8.9 sddsbrightness
 8.10 sddsemitproc
 8.11 sddsfindresonances
 8.12 sddsfluxcurve
 8.13 sddsmatchtwiss
 8.14 sddsrandmult
 8.15 sddsurgent
 8.16 smoothDist6
 8.17 touschekLifetime
 8.18 view3dGeometry
9 Accelerator and Element Description
 9.1 Magnet Strength
10 Element Dictionary
 10.1 ALPH
 10.2 BMAPXY
 10.3 BUMPER
 10.4 CENTER
 10.5 CEPL
 10.6 CHARGE
 10.7 CLEAN
 10.8 CORGPIPE
 10.9 CSBEND
 10.10 CSRCSBEND
 10.11 CSRDRIFT
 10.12 CWIGGLER
 10.13 DRIF
 10.14 DSCATTER
 10.15 ECOL
 10.16 EDRIFT
 10.17 ELSE
 10.18 EMATRIX
 10.19 EMITTANCE
 10.20 ENERGY
 10.21 FLOOR
 10.22 FMULT
 10.23 FRFMODE
 10.24 FTABLE
 10.25 FTRFMODE
 10.26 GFWIGGLER
 10.27 HISTOGRAM
 10.28 HKICK
 10.29 HMON
 10.30 IBSCATTER
 10.31 ILMATRIX
 10.32 KICKER
 10.33 KOCT
 10.34 KPOLY
 10.35 KQUAD
 10.36 KQUSE
 10.37 KSBEND
 10.38 KSEXT
 10.39 LMIRROR
 10.40 LRWAKE
 10.41 LSCDRIFT
 10.42 LSRMDLTR
 10.43 LTHINLENS
 10.44 MAGNIFY
 10.45 MALIGN
 10.46 MAPSOLENOID
 10.47 MARK
 10.48 MATR
 10.49 MATTER
 10.50 MAXAMP
 10.51 MBUMPER
 10.52 MHISTOGRAM
 10.53 MODRF
 10.54 MONI
 10.55 MRFDF
 10.56 MULT
 10.57 NIBEND
 10.58 NISEPT
 10.59 OCTU
 10.60 PEPPOT
 10.61 PFILTER
 10.62 QUAD
 10.63 QUFRINGE
 10.64 RAMPP
 10.65 RAMPRF
 10.66 RBEN
 10.67 RCOL
 10.68 RECIRC
 10.69 REFLECT
 10.70 REMCOR
 10.71 RFCA
 10.72 RFCW
 10.73 RFDF
 10.74 RFMODE
 10.75 RFTM110
 10.76 RFTMEZ0
 10.77 RIMULT
 10.78 RMDF
 10.79 ROTATE
 10.80 SAMPLE
 10.81 SBEN
 10.82 SCATTER
 10.83 SCMULT
 10.84 SCRAPER
 10.85 SCRIPT
 10.86 SEXT
 10.87 SOLE
 10.88 SREFFECTS
 10.89 STRAY
 10.90 TFBDRIVER
 10.91 TFBPICKUP
 10.92 TMCF
 10.93 TRCOUNT
 10.94 TRFMODE
 10.95 TRWAKE
 10.96 TSCATTER
 10.97 TUBEND
 10.98 TWISS
 10.99 TWLA
 10.100 TWMTA
 10.101 TWPL
 10.102 UKICKMAP
 10.103 VKICK
 10.104 VMON
 10.105 WAKE
 10.106 WATCH
 10.107 WIGGLER
 10.108 ZLONGIT
 10.109 ZTRANSVERSE
11 Examples
12 The rpn Calculator
References