forked from MethodicalAcceleratorDesign/MAD-X
-
Notifications
You must be signed in to change notification settings - Fork 0
/
taper.tex
139 lines (114 loc) · 5.82 KB
/
taper.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
%%\title{TAPER}
% Time-stamp: <15 October 2021 11:59:08 ghislain>
\chapter{TAPER: strength tapering for energy variation}
\label{chap:taper}
\texttt{TAPER} calculates the adjustment to the strengths of elements to
account for small momentum variations through RF cavities or synchrotron
radiation.
\madbox{
TAPER, \= ITERATE=integer, STEPSIZE=real, FILE=filename, RESET=logical;
}
%\vspace{5mm}
The attributes for the \texttt{TAPER} command are:
\begin{madlist}
\ttitem{ITERATE} the number of iterations through the element maps. \\
Because the energy loss in dipoles is strongly non linear, \madx
can cycle \texttt{ITERATE} times through the dipole map to converge to the
appropriate tapering value of the element corresponding to the energy
loss through the adjusted bending magnet. \\
For quadrupoles, sextupoles, octupoles and multipoles, a tracking
through the map is done only once for any positive non-zero value of
\texttt{ITERATE}. \\
If \texttt{ITERATE=0} is specified, the tapering is only calculated
from the momentum deviation at the entrance of the element and no
account is taken of the energy loss through the current element. \\
A maximum value of \texttt{ITERATE=10} is enforced. (Default:~3)
\ttitem{STEPSIZE} the tapering step size for stepwise tapering. if
\texttt{STEPSIZE} is non-zero and positive, tapering values are
calculated as multiples of \texttt{STEPSIZE}. (Default:~0)
\ttitem{FILE} causes \madx to write the tapering values applied to
each sequence node to the file specified. The file can be
\texttt{LOAD}ed in a subsequent \madx run. \\
(Default: ``taper.madx'')
\ttitem{RESET} causes \madx to reset tapering values of all nodes
in the current sequence to zero values. All other command parameters
are ignored.
\end{madlist}
The \texttt{TAPER} command is only meaningful when at least one of the
following conditions is true for the \texttt{SEQUENCE} being used:
\begin{itemize}
\item the \texttt{SEQUENCE} contains at least one active
\texttt{RFCAVITY} providing energy gain,
\item the energy loss by synchrotron radiation is enabled with
\hyperref[sec:beam]{\texttt{BEAM, RADIATE=true;}}.
\end{itemize}
In these conditions the energy of the reference particle changes along
the beam line and the nominal strength of elements after the location
where energy variation occurs are not ideally adapted to the actual
energy of the reference particle.
The tapering is calculated as a \textbf{relative} change in strength
between the nominal strength and the strength adapted to the local
energy of the reference particle, relative to the nominal strength,
taken as the average between the local energies at the entrance and at
the exit of the element.
For a quadrupole, the focusing strength \texttt{K1act}
actually used is calculated from the nominal strength \texttt{K1nom} and
\texttt{KTAP} as \madxmp{K1act = K1nom * (1 + KTAP)}
For a dipole with a given geometric \texttt{ANGLE} and \texttt{LENGTH},
the tapering value \texttt{KTAP} is applied through the
\hyperref[sec:bend]{\texttt{KO}} mechanism with the actual strength of
the dipole calculated as \texttt{K0 * LENGTH = ANGLE * (1 + KTAP)}.
The \texttt{KTAP} attribute can be calculated and stored, or applied
from input file, for each node of type \texttt{BEND},
\texttt{QUADRUPOLE}, \texttt{SEXTUPOLE}, \texttt{OCTUPOLE} or
\texttt{MULTIPOLE} in the active sequence.
If \texttt{STEPSIZE} is not specified or specfied as zero, the
calculated value is stored and each node has a unique value
for tapering.
If \texttt{STEPSIZE} is non-zero the calculated value is rounded to the
nearest multiple of the \texttt{STEPSIZE} resulting in a quantization of
the tapering values; the same tapering value can be assigned to several
adjacent nodes in the sequence.
Setting \texttt{STEPSIZE} to a non-zero value is useful to explore tolerances of a
beamline to tapering and determine a likely strategy for stepwise and/or piecewise
tapering, {\it i.e.} applying the same tapering to a set of elements or
part of a beamline.
\texttt{TAPER} uses the closed orbit finding algorithm of the
\hyperref[chap:twiss]{\texttt{TWISS}} package to calculate the
tapering values of all elements if \texttt{STEPSIZE} is zero.
If \texttt{STEPSIZE} is non-zero it could be difficult to ensure a
closure condition for the tapering values and the first turn algorithm
of \madx is used instead, also from the
\hyperref[chap:twiss]{\texttt{TWISS}} package. Hence for evaluation of
tapering of an open line the \texttt{STEPSIZE} should be set to a
non-zero value.
Every call to the \texttt{TAPER} command first resets all tapering
values to zero in order to be able to adjust the
\hyperref[chap:beam]{\texttt{BEAM}} before recalculating the orbit with
tapering. This is also the case when the \texttt{TAPER} command is
called internally from \hyperref[chap:twiss]{\texttt{TWISS}} or
\hyperref[chap:match]{\texttt{MATCH}} command with option
\texttt{TAPERING=true}.
\textbf{Example:}
\madxmp{
BEAM, ENERGY = 100.0, RADIATE=true; \\
TAPER;
}
calculates tapering in the current sequence where each node is
attributed a tapering value corresponding to the local energy of the
reference particle. The \texttt{STEPSIZE} is zero and the calculation is
done with closed orbit finding algorithm.
\textbf{Example:}
\madxmp{
BEAM, ENERGY=100.0, RADIATE=true; \\
TAPER, STEPSIZE=1.e-3, FILE=''mytaper'';
TWISS;
}
calculates tapering in the current sequence where each node is
attributed a tapering value corresponding to the local energy of the
reference particle, but rounded to the nearest multiple of the
\texttt{STEPSIZE} which is one per mil. The calculation is done with the
first turn algorithm only. The tapering values are written out to the
file ``mytaper''. The following \texttt{TWISS} command will use the
tapered values for calculating the closed orbit and twiss parameters.
% end of file