parallel optimizer has an apparent off-by-one error

Moderators: michael_borland, soliday

Post Reply
Posts: 34
Joined: 23 Jun 2009, 21:00

parallel optimizer has an apparent off-by-one error

Post by foshea » 09 Dec 2020, 12:29

I've discovered what looks like an off-by-one error in output of the parallel optimizer into the pop file. When I optimize a lattice, the stout printout gives me the following values for the optimized parameters:

Code: Select all

   Q13H.K1:  -5.183953524225921e+00    1.604647577407903e-02 (was  -5.200000000000000e+00)
   Q23H.K1:   5.197431547920151e+00   -2.568452079849237e-03 (was   5.200000000000000e+00)
   Q33H.K1:  -5.574865362008486e+00   -2.486536200848644e-02 (was  -5.550000000000000e+00)
   Q43H.K1:   1.101607155981992e+01    1.607155981992392e-02 (was   1.100000000000000e+01)
   Q53H.K1:  -8.236263406692085e+00    1.373659330791455e-02 (was  -8.250000000000000e+00)
   Q14H.K1:  -4.566388811423995e+00    3.361118857600509e-02 (was  -4.600000000000000e+00)
   Q24H.K1:   4.103041953779777e+00    3.041953779777451e-03 (was   4.100000000000000e+00)
   Q34H.K1:  -5.510413739744694e+00   -1.041373974469373e-02 (was  -5.500000000000000e+00)
   Q44H.K1:   1.178811341353174e+01   -1.188658646826468e-02 (was   1.180000000000000e+01)
   Q54H.K1:  -9.973277338605204e+00    2.672266139479618e-02 (was  -1.000000000000000e+01)
   Q15H.K1:  -3.651320707876051e+00   -1.320707876051319e-03 (was  -3.650000000000000e+00)
   Q25H.K1:   2.475846964822381e+00    2.584696482238069e-02 (was   2.450000000000000e+00)
   Q35H.K1:  -4.857298561159753e+00   -7.298561159753802e-03 (was  -4.850000000000000e+00)
   Q45H.K1:   1.202027210514868e+01    2.027210514868294e-02 (was   1.200000000000000e+01)
   Q55H.K1:  -1.140987210731737e+01    4.012789268262473e-02 (was  -1.145000000000000e+01)
      L0.L:   1.481287968706293e+00   -1.871203129370680e-02 (was   1.500000000000000e+00)
      L2.L:   1.777615128230319e+00    2.761512823031897e-02 (was   1.750000000000000e+00)
      L5.L:   5.022790388834280e-01    2.279038883427953e-03 (was   5.000000000000000e-01)
However, when I use sddsprintout to show the parameters of the .pop file created by the optimizer, I see the following:

Code: Select all

SVNVersion =                     unknown
Iteration =                            2
ElapsedTime (s) =           1.200000e+01
ElapsedCoreTime (s) =       4.800000e+01
OptimizationValue =         0.000000e+00
WorstOptimizationValue =    0.000000e+00
MedianOptimizationValue =   0.000000e+00
AverageOptimizationValue =  0.000000e+00
OptimizationValueSpread =  -5.183954e+00
Q13H.K1 (1/M$a2$n) =        5.197432e+00
Q23H.K1 (1/M$a2$n) =       -5.574865e+00
Q33H.K1 (1/M$a2$n) =        1.101607e+01
Q43H.K1 (1/M$a2$n) =       -8.236263e+00
Q53H.K1 (1/M$a2$n) =       -4.566389e+00
Q14H.K1 (1/M$a2$n) =        4.103042e+00
Q24H.K1 (1/M$a2$n) =       -5.510414e+00
Q34H.K1 (1/M$a2$n) =        1.178811e+01
Q44H.K1 (1/M$a2$n) =       -9.973277e+00
Q54H.K1 (1/M$a2$n) =       -3.651321e+00
Q15H.K1 (1/M$a2$n) =        2.475847e+00
Q25H.K1 (1/M$a2$n) =       -4.857299e+00
Q35H.K1 (1/M$a2$n) =        1.202027e+01
Q45H.K1 (1/M$a2$n) =       -1.140987e+01
Q55H.K1 (1/M$a2$n) =        1.481288e+00
L0.L (M) =                  1.777615e+00
L2.L (M) =                  5.022790e-01
L5.L (M) =                  0.000000e+00
Notice that the values for the quad strengths are all moved up by one row. When I look into the .pop file I see the off-by-one error there as well. So I don't think the problem is with sddsprintout. I am using version 2020.3.0 with the hybrid simplex optimizer.

This bug is probably related to the issues discussed in this thread, where the user shows the parameters for their quadrupoles shifting up one row as well. I experienced a possibly related issue (here) where the use of multiple MARKs of the same name caused convergence of the optimizer to do strange things.

The issue may be deeper than at creation of the .pop file.

Posts: 1926
Joined: 19 May 2008, 09:33
Location: Argonne National Laboratory

Re: parallel optimizer has an apparent off-by-one error

Post by michael_borland » 09 Dec 2020, 12:50

This is a problem in the creation of the population log file. It was fixed but didn't make it into 2020.4. The fix will appear in the next release.


Post Reply