10.105 SLICE—Performs slice-by-slice analysis of the beam for output to a file.

Performs slice-by-slice analysis of the beam for output to a file.
Parallel capable? : yes
GPU capable? : no
Back-tracking capable? : no






Parameter Name UnitsType Default

Description






N_SLICES long 10

number of slices






START_PID long -1

starting particleID for particles to dump






END_PID long -1

ending particleID for particles to dump






INTERVAL long 1

interval for data output (in turns)






START_PASS long 0

pass on which to start






END_PASS long -1

pass on which to end (inclusive). Ignored if negative.






FILENAME STRING

output filename, possibly incomplete (see below)






LABEL STRING

output label






INDEX_OFFSET long 0

Offset for file indices for sequential file naming.






REFERENCE_FREQUENCY double -1

If non-zero, the indicated frequency is used to define the bucket center for purposes of computing time offsets.






DISABLE short 0

If nonzero, no output will be generated.






USE_DISCONNECT short 0

If nonzero, files are disconnected between each write operation. May be useful for parallel operation. Ignored otherwise.






BUNCH_SERIES short 0

If nonzero, successive instances of the same SLICE element are assigned to successive bunches. Overrides START_PID and END_PID values.






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






NB: This element has very poor parallel efficiency. Hence, the START_PASS, END_PASS, and INTERVAL options should be used to limit the frequency of computations to the minimum needed.

The output filename may be an incomplete filename. In the case of the SLICE element, this means it may contain one instance of the string format specification “%s” and one occurence of an integer format specification (e.g., “%ld”). elegant will replace the format with the rootname (see run_setup) and the latter with the element’s occurrence number. For example, suppose you had a repetitive lattice defined as follows:

S1: SLICE,FILENAME=’’%s-%03ld.s1’’  
Q1: QUAD,L=0.1,K1=1  
D: DRIFT,L=1  
Q2: QUAD,L=0.1,K1=-1  
CELL: LINE=(S1,Q1,D,2*Q2,D,Q1)  
BL: LINE=(100*CELL)

The element S1 appears 100 times. Each instance will result in a new file being produced. Successive instances have names like “rootname-001.s1”, “rootname-002.s1”, “rootname-003.s1”, and so on up to “rootname-100.s1”. (If instead of “%03ld” you used “%ld”, the names would be “rootname-1.s1”, “rootname-2.s1”, etc. up to “rootname-100.s1”. This is generally not as convenient as the names don’t sort into occurrence order.)

These files can be plotted together easily, for example,

sddsplot -column=Slice,ey *-???.s1 -graph=line,vary -order=spectral

For multi-bunch simulation, a variant of this feature can be used to create multiple files, one for each bunch. For example,

S1: SLICE,FILENAME=’’%s-%03ld.s1’’,BUNCH_SERIES=1  
Q1: QUAD,L=0.1,K1=1  
D: DRIFT,L=1  
Q2: QUAD,L=0.1,K1=-1  
CELL: LINE=(Q1,D,2*Q2,D,Q1)  
BL: LINE=(100*CELL,48*S1)

would result in the creation of 48 files, one for each of 48 bunches. If more than 48 bunches are present, they won’t be recorded. If fewer are present, the excess files will be empty.

SOLE