source: PSPA/madxPSPA/doc/usrguide/match/match_main.html @ 430

Last change on this file since 430 was 430, checked in by touze, 11 years ago

import madx-5.01.00

File size: 7.7 KB
Line 
1<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
2<html>
3<head>
4   <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
5   <meta name="GENERATOR" content="Mozilla/4.77 [en] (Windows NT 5.0; U) [Netscape]">
6   <title>MATCH / ENDMATCH</title>
7<!-- Changed by: Chris ISELIN, 27-Jan-1997 -->
8<!-- Changed by: Oliver Bruning, 20-Jun-2002 -->
9<!-- Changed by: Hans Grote, 30-Sep-2002 -->
10<!-- Changed by: Riccardo de Maria, 9-Jan-2008 -->
11</head>
12<body bgcolor="#FFFFFF">
13
14<center>EUROPEAN ORGANIZATION FOR NUCLEAR RESEARCH<img SRC="mx7_25.gif"  align=RIGHT></center>
15
16<center>
17<h2>
18Enter and Leave <a href="match.html">Matching
19Mode</a></h2></center>
20Before matching at least one <a href="../Introduction/sequence.html">SEQUENCE</a>
21must be selected by means of a <a href="../control/general.html#use">USE</a>
22command. The matching module can act on more than one sequence simultaneously
23by specifying more than one sequence when <a href="../match/match_main.html#match">INITIATING</a>
24the matching mode:
25<h2>
26<a NAME="match"></a>Initiating the Matching Module</h2>
27The 'match' command can be either used for matching a periodic cell or
28for matching an insertion to another part of the machine. Both matching
29modes are initiated by the MATCH command.
30<ul>
31<li>
32<a NAME="cell"></a>Cell matching:</li>
33
34<p><br>In the first mode the matching routine is initiated only with one
35attribute specifying the sequence(s) the matching module will work on. In
36this matching mode the periodicity of the optics functions is enforced
37at the beginning and end of the selected range.
38<p>MATCH, SEQUENCE='name1', 'name2',..,nema-n';
39<br>&nbsp;
40<li>
41Insertion matching:</li>
42
43<p><br>In the second mode, called insertion matching, the matching routine
44is initiated with two attributes: one specifying the sequence(s) the matching
45module will work on and one specifying the initial conditions of the optic
46functions for each sequence. In this case the initial values are assumed
47as exact.
48<ul>
49<li>
50Specification of Initial Values: The initial values of the optical functions
51for the insertion matching can either be specified in form of a <a href="../control/general.html#savebeta">SAVEBETA</a>
52command or by explicitly stating the individual optic function values after
53the 'MATCH' command. The two options can be entered as</li>
54
55<pre>MATCH,sequence='name1','name2',..,'name-n',BETA0='beta01','beta02',..,'beta0n';</pre>
56or
57<pre>MATCH,SEQUENCE='sequence-name', BETX=real,ALFX=real,MUX=real,&nbsp;
58&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BETY=real,ALFY=real,MUY=real,
59&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; X=real,PX=real,Y=real,PY=real,
60&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; DX=real,DY=real,DPX=real,DPY=real,&nbsp;
61&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; DELTAP=real;</pre>
62> Examples:
63<ul>
64<li>
65Example 1:</li>
66
67<pre>CELL: SEQUENCE=(...) ;
68INSERT: SEQUENCE=(...) ;
69USE,PERIOD=cell;
70SAVEBETA,LABEL=bini,place=#e;
71TWISS,SEQUENCE=cell;
72USE,PERIOD=insert;
73MATCH,SEQUENCE=insert,BETA0=bini;
74CONSTRAINT,SEQUENCE=insert,RANGE=#e,MUX=9.345,MUY=9.876;</pre>
75This matches the sequence 'INSERT' with initial conditions to a new phase
76advance. The initial conditions are given by the periodic solution for
77the sequence CELL1.
78<li>
79Example 2:</li>
80
81<pre>USE,PERIOD=INSERT;&nbsp;
82MATCH,SEQUENCE=insert;
83CONSTRAINT,SEQUENCE=insert,RANGE=#e,MUX=9.345,MUY=9.876;</pre>
84This matches the beam line 'INSERT' with periodic boundary conditions to
85a new phase advance.</ul>
86The initial conditions can also be transmitted by a combination of a <a href="../control/general.html#savebeta">SAVEBETA</a>
87command and explicit optic function specifications:
88<pre>USE,CELL1;
89SAVEBETA,LABEL=bini,PLACE=#E;&nbsp;
90TWISS,SEQUENCE=CELL1;
91USE,PERIOD=LINE1;&nbsp;
92MATCH,SEQUENCE=LINE1,BETA0=bini,MUX=1.234,MUY=4.567;</pre>
93This example transmits all values of the SAVEBETA array 'bini' as initial
94values to the MATCH command and overrides the initial phase values by the
95given values.</ul>
96An additional <a href="match_con.html#constraint">CONSTRAINT</a>
97may be imposed in other places, i.e. intermediate or end values of the
98optics functions at the transition point.
99<br>&nbsp;
100<li>
101More than one active sequence:</li>
102
103<p><br>The matching module can act on more than one sequence simultaneously
104by specifying more than one sequence after the MATCH command:
105<pre>MATCH,SEQUENCE=LINE1,CELL1,BETA0=bini1,bini2;</pre>
106This example initiates the matching mode for the 'LINE1' and the 'CELL1'
107sequence. The <a href="../twiss/twiss.html">Twiss
108module</a> function of the two sequences are calculated with fixed initial
109conditions. The SAVEBETA array 'bini1' is used for calculating the optics
110functions of sequence 'LINE1' and the SAVEBETA array 'bini2' for calculating
111the optics functions of sequence 'CELL1'. Without the initial conditions
112the matching module will work in the <a href="match_main.html#cell">CELL</a>
113mode.
114<p><br>
115<li> <font color="#ff0000">
116Special flag:</li></ul>
117<p><br>
118The "slow" attribute enforces the old and slow matching procedure which allows
119to use the special columns <tt>mvar1, ..., mvar4</tt>, if they are added to the twiss table.
120Recently a number of parameter, like "RE56", have been
121added to list of matchable parameters. Nevertheless, some parameters
122might only be available when using the "slow" attribute.
123</font>
124<h2>
125<a NAME="match"></a><font size=+2>Further attributes of the TWISS statements
126are:</font></h2>
127
128<ul>
129<li>
130RMATRIX: If this flag is used the one-turn map at the location of every
131element is calculated and prepared for storage in the TWISS table.</li>
132
133<br>Target values for the matrix elements at certain positions in the sequence
134can be specified with the help of the <a href="match_con.html#constraint">CONSTRAINT</a>
135command and the
136keywords: <b>RE, RE11...RE16...RE61...RE66</b>, where <b>REij</b> refers
137to the "ij" matrix&nbsp; component.
138<br>&nbsp;
139<br>> Examples:
140<ul>
141<pre>Example 1:
142MATCH,RMATRIX,SEQUENCE='name',BETA0='beta-block-name';
143CONSTRAINT,SEQUENCE=insert,RANGE=#e,RE11=-2.808058321,re22=2.748111197;
144VARY,NAME=kqf,STEP=1.0e-6;
145VARY,NAME=kqd,STEP=1.0e-6;</pre>
146This matches the sequence 'name' with initial conditions to new values
147for the matrix elements 'RE11' and 'RE22' by varying the strength of the
148main quadrupole circuits.</ul>
149<li>
150CHROM: If this flag is used the chromatic functions at the location of every
151element are calculated and prepared for storage in the TWISS table.</li>
152
153<br>Target values for the chromatic functions at certain positions in the
154sequence can be specified with the help of the <a href="match_con.html#constraint">CONSTRAINT</a> command and the keywords <a href="../Introduction/tables.html#normal">WX, PHIX, WY, PHIY,...</a>.
155
156</ul>
157
158<h2>
159<a NAME="endmatch"></a>Leave Matching Mode</h2>
160The ENDMATCH command terminates the matching section and deletes all tables
161related to the matching run.
162<pre>ENDMATCH;</pre>
163
164<hr>
165<address>
166<a href="http://bruening.home.cern.ch/bruening/">Oliver Br&uuml;ning</a>,
167October, 2003;
168<a href="http://rdemaria.home.cern.ch/rdemaria/">Riccardo de Maria</a>, January, 2008.
169</address>
170
171</body>
172</html>
Note: See TracBrowser for help on using the repository browser.