Elegant Optimization Convergence Problems
Posted: 29 Nov 2009, 11:48
Hello Michael and All the Good People,
Recently I have been evaluating elegant for use at the Canadian Light Source. Until now we have primarily used the DIMAD code with some limited use of AT. One major drive for evaluating elegant is the ability to import RADIA generated kickmaps into the lattice. I like what I see so far with elegant but seem to have hit a snag. My snag concerns the optimization function of elegant. I'll try to detail my problem here and I have attached my elegant lattice and command files. As always, I am open to any constructive criticisms that may help me get more out of elegant (even if it doesn't directly relate to this issue!).
I am trying to learn elegant's optimization abilities by performing a task that I had previously done with DIMAD. I start with two cells of our lattice and put a very simple model of a 4.2T superconducting wiggler into the straight section which takes into account only the vertical focusing of the device:
DBF1:DRIFT, L=0.624
BMITMAT:EMATRIX, r11=1, r22=1, r33=1, r44=1, r55=1, r66=1, &
r43=-0.028
BMITFOCUS:LINE=(DB2, BMITMAT, DBF1, BMITMAT, DB2)
The parameter r43 was chosen to reproduce the same vertical tune shift that I measured from the real device. I then used DIMAD to compute values for the quadrupole strengths in the two cells surrounding the wiggler to match the beta functions, dispersion and their derivatives as well as to get the desired tune advance. It converged with this solution
QA41: KQUAD,L=0.18,K1=0.20335562554245E+01
QB41: KQUAD,L=0.18,K1=0.13001734942086E+01
QC42: KQUAD,L=0.26,K1=0.20459314819491E+01
QB42: KQUAD,L=0.18,K1=0.15712472303806E+01
QA42: KQUAD,L=0.18,K1=0.18839122868023E+01
QA51: KQUAD,L=0.18,K1=0.18168283397009E+01
QB51: KQUAD,L=0.18,K1=0.16562848609754E+01
QC51: KQUAD,L=0.26,K1=0.20459314819491E+01
QB52: KQUAD,L=0.18,K1=0.13001734942086E+01
QA52: KQUAD,L=0.18,K1=0.20335562554245E+01
meaning that a solution does exist.
I have tried to implement the same procedure in elegant. If I put the DIMAD solution into the elegant lattice file, I get the correct answer. However, if I try to find a solution in elegant using the same initial conditions as I did with DIMAD, elegant does not converge. I have tried with different initial conditions. At this point I'm stumped. Is elegant getting trapped in a local minimum of the optimization function? Am I doing something silly?
Thanks in advance,
Ward
Ward A. Wurtz
Accelerator Physicist
Accelerator Operations and Development
Canadian Light Source
University of Saskatchewan
101 Perimeter Road
Saskatoon, SK S7N 0X4
Canada
Phone: (306) 657-3810
Fax: (306) 657-3535
Email: ward.wurtz@lightsource.ca
Recently I have been evaluating elegant for use at the Canadian Light Source. Until now we have primarily used the DIMAD code with some limited use of AT. One major drive for evaluating elegant is the ability to import RADIA generated kickmaps into the lattice. I like what I see so far with elegant but seem to have hit a snag. My snag concerns the optimization function of elegant. I'll try to detail my problem here and I have attached my elegant lattice and command files. As always, I am open to any constructive criticisms that may help me get more out of elegant (even if it doesn't directly relate to this issue!).
I am trying to learn elegant's optimization abilities by performing a task that I had previously done with DIMAD. I start with two cells of our lattice and put a very simple model of a 4.2T superconducting wiggler into the straight section which takes into account only the vertical focusing of the device:
DBF1:DRIFT, L=0.624
BMITMAT:EMATRIX, r11=1, r22=1, r33=1, r44=1, r55=1, r66=1, &
r43=-0.028
BMITFOCUS:LINE=(DB2, BMITMAT, DBF1, BMITMAT, DB2)
The parameter r43 was chosen to reproduce the same vertical tune shift that I measured from the real device. I then used DIMAD to compute values for the quadrupole strengths in the two cells surrounding the wiggler to match the beta functions, dispersion and their derivatives as well as to get the desired tune advance. It converged with this solution
QA41: KQUAD,L=0.18,K1=0.20335562554245E+01
QB41: KQUAD,L=0.18,K1=0.13001734942086E+01
QC42: KQUAD,L=0.26,K1=0.20459314819491E+01
QB42: KQUAD,L=0.18,K1=0.15712472303806E+01
QA42: KQUAD,L=0.18,K1=0.18839122868023E+01
QA51: KQUAD,L=0.18,K1=0.18168283397009E+01
QB51: KQUAD,L=0.18,K1=0.16562848609754E+01
QC51: KQUAD,L=0.26,K1=0.20459314819491E+01
QB52: KQUAD,L=0.18,K1=0.13001734942086E+01
QA52: KQUAD,L=0.18,K1=0.20335562554245E+01
meaning that a solution does exist.
I have tried to implement the same procedure in elegant. If I put the DIMAD solution into the elegant lattice file, I get the correct answer. However, if I try to find a solution in elegant using the same initial conditions as I did with DIMAD, elegant does not converge. I have tried with different initial conditions. At this point I'm stumped. Is elegant getting trapped in a local minimum of the optimization function? Am I doing something silly?
Thanks in advance,
Ward
Ward A. Wurtz
Accelerator Physicist
Accelerator Operations and Development
Canadian Light Source
University of Saskatchewan
101 Perimeter Road
Saskatoon, SK S7N 0X4
Canada
Phone: (306) 657-3810
Fax: (306) 657-3535
Email: ward.wurtz@lightsource.ca