Hello all,
Imagine i have beamline ..say Q1 Q2 Q3.... Qn. where n is the number of quads. Now, I use elegant to calculate the overall R-matrix (.fin).
Say, if i insert a skew quad somewhere along the beamline.. The lattice becomes Q1 Q2..... SK... Qn..
a] How to compute R-matrix for only that part of the beamline say beginning from...SK.. QjQk.. Qn..using a script and without changing the lattice?
b] How to compute the R-matrix for a single element say the skew quad alone?
Thanks.
regards,
Charles
R-matrix question
Moderators: cyao, michael_borland
-
- Posts: 2006
- Joined: 19 May 2008, 09:33
- Location: Argonne National Laboratory
- Contact:
Re: R-matrix question
Charles,
For (1), use matrix_output and set the start_from field to "SK". Set the SDDS_output field to the name of a file to hold the matrix output.
For (2), use matrix_output and set individual_matrices=1. Alternatively, you can use the printout field to get a printout of all the matrices, which by default contains the individual matrices.
--Michael
For (1), use matrix_output and set the start_from field to "SK". Set the SDDS_output field to the name of a file to hold the matrix output.
For (2), use matrix_output and set individual_matrices=1. Alternatively, you can use the printout field to get a printout of all the matrices, which by default contains the individual matrices.
--Michael
Re: R-matrix question
That reply was much faster than my computer ! Thanks
when you set individual_matrices = 1, the mpr file has after every element a C row followed by the R matrix..What is this C row supposed to mean?
Charles
when you set individual_matrices = 1, the mpr file has after every element a C row followed by the R matrix..What is this C row supposed to mean?
Charles
-
- Posts: 2006
- Joined: 19 May 2008, 09:33
- Location: Argonne National Laboratory
- Contact:
Re: R-matrix question
Charles,
The C row is the centroid vector. If you have, for example, a MALIGN element or a dipole with a strength error, this effect is incorporated in the C component.
Normally, however, only the 5th component is nonzero, since that represents longitudinal coordinate (the distance traveled).
--Michael
The C row is the centroid vector. If you have, for example, a MALIGN element or a dipole with a strength error, this effect is incorporated in the C component.
Normally, however, only the 5th component is nonzero, since that represents longitudinal coordinate (the distance traveled).
--Michael
-
- Posts: 8
- Joined: 09 Nov 2009, 16:18
Re: R-matrix question
Hello,
What are T11, T12, T13 ... following C row and R matrix in .mpr file?
Ilkyoung
What are T11, T12, T13 ... following C row and R matrix in .mpr file?
Ilkyoung
-
- Posts: 2006
- Joined: 19 May 2008, 09:33
- Location: Argonne National Laboratory
- Contact:
Re: R-matrix question
Ilkyoung,
You can get the Tijk elements from matrix_output as follows:
&matrix_output
printout = %s.mpr,
printout_order = 2,
&end
if you want text output, or
&matrix_output
SDDS_output = %s.mat,
SDDS_output_order = 2
&end
if you want SDDS output, or
&matrix_output
printout = %s.mpr,
printout_order = 2,
SDDS_output = %s.mat,
SDDS_output_order = 2
&end
if you want both SDDS and text output.
--Michael
You can get the Tijk elements from matrix_output as follows:
&matrix_output
printout = %s.mpr,
printout_order = 2,
&end
if you want text output, or
&matrix_output
SDDS_output = %s.mat,
SDDS_output_order = 2
&end
if you want SDDS output, or
&matrix_output
printout = %s.mpr,
printout_order = 2,
SDDS_output = %s.mat,
SDDS_output_order = 2
&end
if you want both SDDS and text output.
--Michael