Can elegant perform dynamic Aperture optimization ?

Moderators: cyao, michael_borland

shancai
Posts: 25
Joined: 07 Jul 2008, 20:12

Can elegant perform dynamic Aperture optimization ?

Post by shancai » 19 Mar 2009, 05:23

Can elegant perform dynamic Aperture optimization or tune scan?
If can, can post some examples?
Thanks a lot!

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

Re: Can elegant perform dynamic Aperture optimization ?

Post by michael_borland » 19 Mar 2009, 08:17

Shancai,

At APS we use elegant and a genetic optimization script for combined dynamic/momentum aperture optimization. However, it requires a linux cluster, since the individual runs take about 1 hour each. You can also perform driving term minimization to improve dynamic/momentum aperture, although I don't use this myself because I find the genetic optimization works better. (You can find out more about driving term calculation from the twiss_output command manual entry).

As for a tune scan, I assume you are again referring to dynamic aperture. You'd have to write a script that runs elegant repeatedly with different tunes.

I'll try to post a few examples in the next week or so.

--Michael

shancai
Posts: 25
Joined: 07 Jul 2008, 20:12

Re: Can elegant perform dynamic Aperture optimization ?

Post by shancai » 23 Mar 2009, 02:22

I use the attached file to optimize dynamic aperture.
I want to correct chromaticities each time. But it Adjust chromaticities many times.
What's wrong with it?

Thanks a lot!
Attachments
emitOpt.ele
(1.39 KiB) Downloaded 908 times
parTrack.lte
(2.66 KiB) Downloaded 843 times

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

Re: Can elegant perform dynamic Aperture optimization ?

Post by michael_borland » 23 Mar 2009, 11:56

Shancai,

The chromaticity is corrected for each function evaluation. You want this, because you are changing quadrupoles. If the chromaticity isn't corrected each time, you'll almost certainly have a result you can't use (dynamic aperture optimized but wrong chromaticity).

If you want to correct the chromaticity just once, then you need to run elegant separately and save the results, then reload them for the DA optimization.

A few more suggestions for your input file:
* Consider simplex optimization instead of random-walk
* Set n_steps=1 instead of n_steps=10. Otherwise, you'll run the same optimization 10 times.
* You don't need radiation_integrals=1 in twiss_output, since you haven't included an SREFFECTS element and aren't optimizing any radiation-related quantities.
* Set concat_order=2 in twiss_output to get slightly better performance

--Michael

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

Re: Can elegant perform dynamic Aperture optimization ?

Post by michael_borland » 23 Mar 2009, 12:01

Shancai,

Attached are some files to demonstrate performing a tune scan to optimize dynamic aperture. The scripts work on linux, but may require modification to work on Windows.

Also attached is a plot showing what the result looks like.

A word of caution: this analyzes only the dynamic aperture. The momentum aperture will also vary with tune. A proper lattice design has to compromise between the two of these.

--Michael
tuneScan.png
Attachments
DATuneScan.tar.gz
(640.91 KiB) Downloaded 857 times

shancai
Posts: 25
Joined: 07 Jul 2008, 20:12

Re: Can elegant perform dynamic Aperture optimization ?

Post by shancai » 25 Mar 2009, 19:10

I test the example on my windows system.
The only changing is change elegant to elegant.exe.
It can run no problem.

hsayed
Posts: 8
Joined: 22 Jul 2008, 12:51

Re: Can elegant perform dynamic Aperture optimization ?

Post by hsayed » 20 Oct 2009, 13:09

Hi Micheal,

I'm interested in the same kind of problem. For some reason the attached files are no longer available.
Thanks
Hisham

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

Re: Can elegant perform dynamic Aperture optimization ?

Post by michael_borland » 29 Oct 2009, 14:23

Hisham,

Please try again. It should work now.

--Michael

csun
Posts: 6
Joined: 14 Apr 2010, 13:15

Re: Can elegant perform dynamic Aperture optimization ?

Post by csun » 19 Apr 2010, 11:38

hello Michael,

Thank for the explanation. We are also interested in the same kind of problem. Could you post an example using resonance driving terms to improve the dynamics aperture? You mentioned the genetic optimization works better than driving terms optimization. May I ask for your genetic optimization script. Thanks!

CSUN

wguo
Posts: 41
Joined: 13 Jun 2008, 12:54

Re: Can elegant perform dynamic Aperture optimization ?

Post by wguo » 22 Apr 2010, 14:48

Attached is an example file that optimizes dynamic aperture through resonance term minimization.

Instructions can be found in the file.

Good luck,

Weiming Guo
DA-optimize-example.ele
Dynamic aperture optimization through resonance term minimization
(4.8 KiB) Downloaded 975 times
Last edited by wguo on 18 Aug 2010, 14:28, edited 3 times in total.

Post Reply