-
Notifications
You must be signed in to change notification settings - Fork 39
PTC_TWISS A_ Initialization
piotrskowronski edited this page Aug 7, 2018
·
15 revisions
Initialization is done in subroutine initmap that is contained in subroutine ptc_twiss
The A_ map is inside variable A_script_probe in its field A_script_probe%x A_script_probe is
- define in the scope of subroutine
ptc_twiss - of type probe_8
There are 2 use cases
- Transfer lines with provided initial parameters
- Initialisation with Twiss parameters (beta, alpha and dispersion)
- A_ linear coefficients are read from a table, enabled with option
initial_ascript_manual=true - option
initial_matrix_manual=true - option
initial_matrix_table=true - option
initial_moments_manual=true - option
initial_map_manual=true
- Closed solution of rings
-
Initialisation with Twiss parameters (beta and alpha) It is activated when
betxandbetypassed toptc_twissare bigger than zero and all optionsinitial_*are false.It is implemented in subroutine
readinitialtwiss.-
It reads the arguments passed to
ptc_twiss- Orbit
- For transverse planes beta, alpha, dispersion
- For longitudinal beta and alpha
-
Beta and alpha is scaled with the reference momentum
do i=1,c_%nd be(i)= beta(i)/(1_dp+orbit(5)) al(i)=alpha(i)/(1_dp+orbit(5)) enddo
-
- Orbit is put as constant part of the map
A_script_probe%x=orbit - The polynomials for each of transverse variables are built as follows
do i=1,c_%nd A_script_probe%x(2*i-1)= orbit(2*i-1) + sqrt(be(i)) * morph((one.mono.(2*i-1)) ) A_script_probe%x(2*i) = orbit(2*i) + (one/sqrt(be(i)) * & (morph( (one.mono.(2*i)) )-(al(i)) * morph((one.mono.(2*i-1))))) enddo