Orbit distortion and beam energy

Moderators: cyao, michael_borland

yongjun
Posts: 6
Joined: 05 Oct 2011, 15:17

Orbit distortion and beam energy

Post by yongjun » 06 Oct 2011, 07:54

Hi Michael,

The command "closed orbit" has an option "fixed_length", which can find a closed orbit with the same length as the design orbit by changing the momentum offset.

First I set this option to be a nonzero, then I introduced a kicker and calculated the closed orbit path-length and beam energy (momentum offset), I did find the path-length had been keep unchanged, and beam energy had a shift. It works fine!

Next, I switched this option off, I expected the path-length should have some offset, and energy deviation should be zero. But from the output, both of them are zeros. Why?

Regards,
Yongjun Li
BNL

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

Re: Orbit distortion and beam energy

Post by michael_borland » 06 Oct 2011, 07:59

Yongjun,

How are you checking the path-length? It needs to be done by tracking. E.g., you can track one turn and look at the "Cs" parameter in the "final" output file (&run_setup final=...).

--Michael

yongjun
Posts: 6
Joined: 05 Oct 2011, 15:17

Re: Orbit distortion and beam energy

Post by yongjun » 06 Oct 2011, 08:18

Hi Michael,

I printed out the parameters in the %s.orb: ( it works when I set the option to be a nonzero)

sddsprintout -par test.orb

here is output:
----------------------(fixed_length = nonzero)
Printout for SDDS file test.orb

Step = 0 xError (m) = -9.177912e-13 yError (m) = 0.000000e+00 delta = -2.614341e-04
lengthError (m) = 2.728484e-12

---------------------(fixed_length = zero)
Printout for SDDS file test.orb

Step = 0 xError (m) = -9.107298e-18 yError (m) = 0.000000e+00 delta = 0.000000e+00
lengthError (m) = 0.000000e+00

My understanding is finding a closed orbit is an iteration process of tracking, in the code, all information should be there already.

and even I can track one turn, I need to specify initial values and let them be convergent, which mean I am finding closed orbit manually, right?

Regards,
Yongjun

yongjun
Posts: 6
Joined: 05 Oct 2011, 15:17

Re: Orbit distortion and beam energy

Post by yongjun » 06 Oct 2011, 13:09

michael_borland wrote:Yongjun,

How are you checking the path-length? It needs to be done by tracking. E.g., you can track one turn and look at the "Cs" parameter in the "final" output file (&run_setup final=...).

--Michael
Hi Michael,

I tried the one turn track, then look at the Cs, but it only display 6 numbers after decimal point, which is not accurate enough for me. The momentum offset is 10^-4 ~-5 due to a trim coil.

Thanks,
Yongjun

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

Re: Orbit distortion and beam energy

Post by michael_borland » 06 Oct 2011, 14:21

Yongjun,

A few points:

1. You won't see anything in the lengthError parameter in the orbit output file. That's only there to tell you how close the algorithm got to the desired length when fixed_length=1. When fixed_length=0, it isn't used.

2. Ensure that the corrector you are changing is in a location with non-zero horizontal dispersion.

3. To check with tracking, track a single particle and set center_on_orbit=1 in &track. Then, look at the Cs parameter from the final file:
sddsprintout -parameter=Cs,format=%21.15e run.fin

See attached files for an example.

--Michael
Attachments
fixedLVsRegularOrbit.tar.gz
(1.5 KiB) Downloaded 5250 times

yongjun
Posts: 6
Joined: 05 Oct 2011, 15:17

Re: Orbit distortion and beam energy

Post by yongjun » 17 Oct 2011, 10:18

Hi Michael,

Thank you for help. I have some more questions related to orbit correction.

1) dipole's FSE: if a dipole is shorted, the actual bending angle and the path-length can NOT be scaled by FSE, the real trajectory depends on dipole fringe angle (like SBEND, or RBEND ) . And if the dipole has some gradients inside, the trajectory will become even more complicated. Did you include all the stuffs in your FSE model?, If yes, how can you do that?

2) I wonder if it is possible to read the corrector strength setting from an external sdds file, since most of correctors have the same Family-Name, but different locations. Could you please give an example?

Regards.
Yongjun

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

Re: Orbit distortion and beam energy

Post by michael_borland » 18 Oct 2011, 13:12

Yongjun,

For the SBEN elements, the derivation of the matrix includes the possibility of having a field strength error by distinguishing between the reference and actual curvature. Effectively, its like having a fractional energy error with delta=-FSE. Any effects on the path length for a sector magnet are taken into account in this way. Since the path length is defined in terms of transport from the entrance reference plane to the exit reference plane, there is no effect from the edge angles. This will introduce errors when the bending radius is very small.

CSBEND elements work a bit differently, in that no matrices are used. However, the idea of having a reference curvature, an actual curvature, and integrating for a sector magnet with edge effects implemented as kicks, is the same.

The NIBEND element is quite different. It actually integrates through the magnet with the magnet edges positioned according to the edge angles, then drifts forward/backward to the reference plane. Hence, this element should give the best treatment of the effects you describe.

In practice, I didn't seem much difference among them.

--Michael

yongjun
Posts: 6
Joined: 05 Oct 2011, 15:17

Re: Orbit distortion and beam energy

Post by yongjun » 19 Oct 2011, 11:12

Michael,

Thank for your help. I am close to the final answer.

What I am doing is to simulate the existence of stored beam for the top-off safety when:
(1) a single dipole (NIBEND) is being shorted gradually,
(2) the closed orbit correction is still functioning, but the corrector strength is limited (<0.8mrad),
(3) the RF frequency is fixed, so the path-length is fixed, then beam energy changes gradually.

Could you please check if the enclosed files are doing what I want to do correctly?

Regards,
Yongjun
Attachments
nsls2.tar.gz
(3.36 KiB) Downloaded 2175 times

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

Re: Orbit distortion and beam energy

Post by michael_borland » 24 Oct 2011, 17:31

Yongjun,

The files look ok, but I'd suggest two changes:

1. Assign an HGAP value for the dipoles to get the soft edge effects.

2. In the &correct namelist, assign n_iterations=3 and n_xy_cycles=3 to give more assurance of convergence.

I notice that once the correctors reach their limit, the momentum offset ceases to change. I'm not 100% sure this is right.

One way to check is to track a single particle with an rf cavity included. Using the &run_setup centroid output, you can average the particle coordinates over, e.g., 100 turns and compare this to the closed orbit. They should be quite close.

--Michael

yongjun
Posts: 6
Joined: 05 Oct 2011, 15:17

Re: Orbit distortion and beam energy

Post by yongjun » 26 Oct 2011, 12:20

Hi Michael,

Thank your suggestion. Here is the result.

1. Assign an HGAP value for the dipoles to get the soft edge effects.
- Done, no significant difference was found between using hard-edge and soft-edge.

2. In the &correct namelist, assign n_iterations=3 and n_xy_cycles=3 to give more assurance of convergence.
- Done, no significant difference. In fact, I deliberately use n_iterations=1 in my simulation, because once a dipole has a short, its field will drop off dynamically, so the orbit correction is also dynamical. Therefore orbit correction may not be able to have more than one iteration for each FSE, then have to proceed to the next FSE.

I notice that once the correctors reach their limit, the momentum offset ceases to change. I'm not 100% sure this is right.
- This phenomenon is partly understood-able:
- before corrector reach the limit: a local bump is formed to compensate the dipole short, the orbit path-length changes, then beam energy changes also. A new closed orbit with the pattern of the dispersion function is formed. The height of closed orbit increased with amount of dipole short and corrector strength, therefore beam energy are keeping growth until
- corrector reach the limit: the bump is not local, orbit correction mechanism is spoiled because no corrector can be set beyond the limit. The orbit pattern can't be kept, the average variation of the closed orbit path-length is random, and with a average of zero (or a very value, which may depend on the ring's size). -> the momentum offset ceases to change.

One way to check is to track a single particle with an rf cavity included. Using the &run_setup centroid output, you can average the particle coordinates over, e.g., 100 turns and compare this to the closed orbit. They should be quite close.
- Done, I checked the average trajectories of 100 turns, which agrees with the closed orbit output.

Thank you again.

-Yongjun

Post Reply