{High-energy ring optimisation for 5+10 scheme with VL's 1.332GeV linac
Cell geometry inherited from Vadim's Dec 9th 2013 e-mail (4+7/10GeV), I just vary the gradients and X offsets here
'a' variant includes 16th turn at 21164MeV}

#QLF=1.1;
#BLD=0.9;

#RADQF=293.945;
#RADBD=298.569;

{Parameter Value}
QX [-1cm,1cm]

{Multipole Length Angle Quad Xhere Fringe AlignMode}
QF2 #QLF# #QLF/RADQF# [-50,50] #-QX# 3cm Integral
BD2 #BLD# #BLD/RADBD# [-50,50] #QX# 3cm Integral

{Drift Length Angle}
D 0.290943623
HD #D.Length/2#

ArcCell2: HD,BD2,D,QF2,HD;

{MatchScan Estart Egoal Estep Species TuneMin TuneMax FOM SR_TopEnergy SR_Current SR_Length}
MatchHE 21164MeV 7944MeV 1322MeV Electron 0.035 0.4 SR 21164MeV -50mA #6*356.30044#m

{Match-Aperture} 
MatchEnd  

MatchHE,ArcCell2,MatchEnd;