mode of operation of the misalignment DX, DY and DZ in QUAD element

Moderators: cyao, michael_borland

Post Reply
Ikpfelix
Posts: 15
Joined: 24 May 2016, 06:50

mode of operation of the misalignment DX, DY and DZ in QUAD element

Post by Ikpfelix » 07 Dec 2016, 13:41

Hi Michael,

I want to investigate the effect of x-, y-, and z-displacements of my quadrupole magnets on several quantities (for example the envelope in x-direction and R56).
sketch.png
I thought I can solve my problems with the quantities DX, DY, and DZ in the QUAD-element, but at this point I do not understand how these quantities are working: I expected that for example DZ=1 leads to a shift of the quadrupole magnet in z-direction by 1 meter, but it doesn’t work. For example:

My idea was, to convert the original lattice

Code: Select all

D1a: DRIFT,L=2
Q1: QUAD,L=2, K1=1 
D1a: DRIFT,L=2
to

Code: Select all

D1a: DRIFT,L=3
Q1: QUAD,L=2, K1=1 
D1b: DRIFT,L=1
by using

Code: Select all

D1a: DRIFT,L=2
Q1: QUAD,L=2, K1=1 , DZ=1
D1b: DRIFT,L=2
but the second and third lattice show different results:
sigmaXforTESTLINE1_2_3.png
Furthermore I thought DX and DY work like shifting in the transverse positions, and if so, then I expected that the displacement of the quadrupole magnet in transverse direction leads to a “new” element which works like the superposition of a dipole magnet and a quadrupole magnet, or to say it in other words, B(x)=B_0*x becomes B(x)=B_0*x+B_1. If this is the case, R56 should only change in the range of this new element (because it is like a bending magnet), but in my example it changes even in the drift area behind the quadrupole magnet. I don’t understand this fact, because R56 is defined by $\int R16/\rho ds$ and the absolute value of $\rho$ should be infinity in the drift area, so R56 should not change. Besides this, R56 is zero in the quadrupole magnet (range 2 to 4 meters), but R16 is not zero in this range, so with regard to the aforementioned formula, R56 should start changing at postion s=2 meters, if the new element works like described before.

This is the result of R16 and R56, if I use the 4th test-beamline, using DX=1:
R16_R56_TESTLINE4.png
Can you please explain how DX, DY, and DZ are working, and if I can solve my problem with the already existing elegant elements.

Thanks in advance and best regards,

Felix

Ikpfelix
Posts: 15
Joined: 24 May 2016, 06:50

Re: mode of operation of the misalignment DX, DY and DZ in QUAD element

Post by Ikpfelix » 07 Dec 2016, 13:43

Unfortunately, I can only attach 3 files. Therefore here the elegant files in a new post.

Best regards,

Felix
Attachments
examples.rar
(266.92 KiB) Downloaded 267 times

michael_borland
Posts: 1933
Joined: 19 May 2008, 09:33
Location: Argonne National Laboratory
Contact:

Re: mode of operation of the misalignment DX, DY and DZ in QUAD element

Post by michael_borland » 12 Dec 2016, 10:19

Can you upload the files in another format? I use linux and RAR files are not supported. zip or tar.gz would work.

--Michael

Ikpfelix
Posts: 15
Joined: 24 May 2016, 06:50

Re: mode of operation of the misalignment DX, DY and DZ in QUAD element

Post by Ikpfelix » 13 Dec 2016, 09:30

I attached them in zip format.

Best regards,

Felix
Attachments
examples.zip
(272.4 KiB) Downloaded 262 times

michael_borland
Posts: 1933
Joined: 19 May 2008, 09:33
Location: Argonne National Laboratory
Contact:

Re: mode of operation of the misalignment DX, DY and DZ in QUAD element

Post by michael_borland » 15 Dec 2016, 09:42

Felix,

I found several things in your tests that may have resulted in confusion. First, the displacements are of the same order of magnitude as the lengths of the elements. This may result in confusion about what 's' means in the output files. To address this, I reduced the displacement to 0.1m and I also split the elements into 100 pieces (element_divisions parameter in run_setup). Note that DZ errors are implemented as hidden matrices up and downstream of the element. Quantities at the entrance to and exit from the displaced element are reported at the nominal location, even though they may pertain to a much different position (1m different in your case).

As for your transversely-displaced quad test, the element is so long and is displaced so much that it is not a good approximation to a combined-function dipole. For one thing, the quad is a straight element while the dipole is curved. Even with more reasonable parameters, you can't expect R56 to agree in these two cases. R16 and R26 agree fairly well.

I've reworked your test cases and attached it here.

--Michael
Attachments
testSet.zip
(1.31 KiB) Downloaded 312 times

Ikpfelix
Posts: 15
Joined: 24 May 2016, 06:50

Re: mode of operation of the misalignment DX, DY and DZ in QUAD element

Post by Ikpfelix » 17 Jan 2017, 11:12

Hi Michael,

I am sorry; I read your response and forgot to answer.

Thanks for your response and your files. Of course you are right, the values of the displacements are way too big; I only chose them to illustrate my issues and to see differences in the results more easily. The real values for the displacements are below 0.01 m and the length of each quad is in the range of 0.1 m to 0.3 m.

Thanks for the hint “quad straight, dipole curved”; I did not take this into account at my tests, and of course it influences the results.

Thanks also for the suggestion to use the “element_divisions” parameter. It was helpful for further tests.

Best regards,
Felix

Post Reply