MethodicalAcceleratorDesign / MAD-NG

MAD Next-Generation official repository
GNU General Public License v3.0
32 stars 11 forks source link

Fix charge dependancy of qsad_fringe #377

Closed jgray-19 closed 1 year ago

jgray-19 commented 1 year ago

Performing an ng vs ng test reveals that for the map to be fully reversed when chg is reversed, f2 must also be multiplied

HOWEVER I am not sure if f2 should also be multiplied by lw. It is not in PTC (but it's also not multiplied by charge), so this needs to be reviewed.

ldeniau commented 1 year ago

Let's fix it to be compatible with PTC. A cross-check with the SAD manual could confirm or not the problem...

jgray-19 commented 1 year ago

Reviewing the SAD manual, it seems that compared to entry and exit, a is flipped sign, but b is not. So it looks like we are correct. See https://www-kekb.kek.jp/Documentation/SAD/?Elements/QUAD#q=fringe for more detail