&correct does not work

Moderators: cyao, michael_borland

simone.dimitri
Posts: 46
Joined: 09 Jun 2008, 01:19

&correct does not work

Post by simone.dimitri » 13 Oct 2020, 06:02

Dear Michael and everybody,
I am running an MBA lattice with the very latest version of Elegant.

Problem 1:
&correct does not produce outputs and the program stops without errors or warnings.
Only mode=trajectory + method=thread produces outputs (but correctors strengths are not saved).
Please notice that also with older lattice files, &correct seems to do nothing.

Problem 2:
If I add more and larger errors, I receive the message:
"particle acquired undefined slopes when integrating through kick multipole"
which, I understand, is signature of too large amplitudes, and has nothing to do with the definition of the multipoles.

Please find my files in attachment, with small errors.
Thank you in advance for your support. Cheers,
Simone
Attachments
elettra_run1.ele
(4.08 KiB) Downloaded 226 times
lattice.lte
(62.77 KiB) Downloaded 236 times

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

Re: &correct does not work

Post by michael_borland » 14 Oct 2020, 15:49

Simone,

The condition number for the response matrix inversion is 10^19, which will result in correctors running off to infinity.
Try adding

Code: Select all

minimum_SV_ratio[0] = 2*1e-4
to the &correct command.

Also, it will be much faster if you set

Code: Select all

use_response_from_computed_orbits = 0
-Michael

simone.dimitri
Posts: 46
Joined: 09 Jun 2008, 01:19

Re: &correct does not work

Post by simone.dimitri » 16 Oct 2020, 01:55

Thank you Michael for looking to this. I tried, but with no success.
I am still not totally convinced: all files I have, now present the same problem, and I am pretty sure they worked before I installed the very last release.
If you find the time, please also look to this linac lattice, for example. Again, the program stops at the computation of the correction matrix.
Might there be some new default parameter in &correct, which was set in a different manner in previous versions of Elegant? Still, I played with all of them anyway...
Attachments
run1.new
(16.43 KiB) Downloaded 214 times
run2.ele
(4.28 KiB) Downloaded 221 times

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

Re: &correct does not work

Post by michael_borland » 19 Oct 2020, 16:53

Simone,

I tried your input files and they worked as expected. A single step of correction was taken for x, then y.

I also tried with version 2019.4 and 2019.1, with the same results. It might be a platform-specific issue. I think an update was issued very recently for the latest Windows version, so perhaps that will help if you are using Windows.

--Michael

simone.dimitri
Posts: 46
Joined: 09 Jun 2008, 01:19

Re: &correct does not work

Post by simone.dimitri » 20 Oct 2020, 11:02

Correct Michael, &correct now works as expectd after installation of the very latest release of Elegant.
Many thanks for the check.
S.

simone.dimitri
Posts: 46
Joined: 09 Jun 2008, 01:19

Re: &correct does not work

Post by simone.dimitri » 28 Oct 2020, 06:37

Dear Michael,
another step forward. I would like to thread the beam first through the ring (&correct in trajectory mode and thread method), then refine the correction (&correct in orbit mode and global method). However, the thread mode does not save the corrector strengths, from which I would like to start my next correction step. Any hint to save the correctors' setting in thread mode? Thanks. S.

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

Re: &correct does not work

Post by michael_borland » 28 Oct 2020, 14:06

Simone,

You should be able to load the correctors from the parameter file for the previous stage, e.g.,

Code: Select all

&run_setup
  ...
   parameters = run1.param
&end
...
&correct
...
&end
...
&track
&end
The file run1.param will contain the steering strengths and every other numerical parameter of the lattice. The parameters of interest have names matching *KICK (e.g., HKICK, VKICK).

Code: Select all

&run_setup
 ...
&end

&load_parameters
 filename = run1.param
 include_item_pattern = "HKICK,VKICK,XKICK,YKICK,KICK"
&end
...
&correct
 prezero_correctors = 0
&end
...
Setting prezero_correctors=0 is essential so that elegant doesn't overwrite the corrector values that you loaded.

--Michael

Hwang, Ji-Gwang
Posts: 40
Joined: 21 Jan 2010, 02:27

Re: &correct does not work

Post by Hwang, Ji-Gwang » 31 Mar 2021, 04:03

Dear Michael

I have tried the posted example "run1.new and run2.ele" in Elegant version 2020.5 (Dec 11, 2020) as well as 2020.3 (Jul 30, 2020) but the &correct does not work on Windows PC.
It is terminated abnormally at the step of "computing correction matrix". Could you check the issue?

Best regards

Ji-Gwang Hwang

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

Re: &correct does not work

Post by michael_borland » 21 Apr 2021, 16:15

Ji-Gwang,

Please ensure that you have the latest version installed. I don't have any issues with this run.

--Michael

Benedikt.buesing
Posts: 2
Joined: 20 Oct 2021, 10:53

Re: &correct does not work

Post by Benedikt.buesing » 20 Oct 2021, 14:43

Hello all,

i have the same problem at the moment. I installed the newest version of elegant today

Code: Select all

Running elegant at Wed Oct 20 20:23:34 2021

This is elegant 2021.3.0, Sep 21 2021, by M. Borland, J. Calvey, M. Carla', N. C
armignani, AJ Dick, Z. Duan, M. Ehrlichman, L. Emery, W. Guo, R. Lindberg, V. Sa
jaev, R. Soliday, Y.-P. Sun, C.-X. Wang, Y. Wang, Y. Wu, and A. Xiao.
and if i run the run2.ele posted here before it ends with

Code: Select all

Found monitor BPM_PK_L4.7#1 (type MONI) at s=1.519136e+02
computing response matrix...
start   ET:     00:00:00 CP:    0.07 BIO:0 DIO:0 PF:0 MEM:0
done   ET:     00:00:00 CP:    0.08 BIO:0 DIO:0 PF:0 MEM:0
Computing correction matrix    ET:     00:00:00 CP:    0.08 BIO:0 DIO:0 PF:0 MEM
:0
but the output files are empty.
I am also using a windows computer, did anybody solved this problem or any idea what the problem might be?

Best regards,
Benedikt

Post Reply