Commit 7caff6a5 authored by kraus's avatar kraus

adding missing input files; explain action of RestartTest-6

parent 58fd7632
Option, PSDUMPFREQ=50;
Option, STATDUMPFREQ=1;
Option, ECHO=FALSE;
Option, AUTOPHASE=4;
Title, string="Phase 1 of PSI FEL 250 Injector with CTF3 RF Photoinjector";
FINSB01_RACC_phi = 0;
FINSB02_RACC_phi = 0;
REPARTFREQ = 100;
MINSTEPFORREBIN = 600;
QB = 0.2e-9;
BF = 2998.0;
BC = QB*BF;
// Begin: CTF3 /////////////////////////////////////////////////////////////////////////////////////////////////
//
// Definition of CTF3 RF photoinjector.
//
//
// L: physical element length (real in m)
// VOLT: field scaling factor (real)
// FMAPFN: field file name (string)
// ELEMEDGE: physical start of the element on the floor (real in m)
// TYPE: specifies "STANDING" (default), "TRAVELLING" or "SINGLE GAP" structure
// FREQ: RF frequency of cavity (real in MHz).
//
FINSS_RGUN: RFCavity, L = 0.34986, VOLT = 100.0, FMAPFN = "CTF3_Ez_ASTRA.opal",
ELEMEDGE =0.0, TYPE = "STANDING", FREQ = BF,
LAG = -3.5/180.0*PI;
//
// L: physical element length (real in m)
// KS: field scaling factor (real)
// FMAPFN: field file name (string)
// ELEMEDGE: physical start of the element on the floor (real in m)
//
FIND1_MSOL10: Solenoid, L = 0.6, KS = 0.206, FMAPFN = "NEW_SINGLE_SOL_NOFRINGE_ASTRA.opal", ELEMEDGE = 0.3;
//
// L: physical element length (real in m)
// KS: field scaling factor (real)
// ELEMEDGE: physical start of the element on the floor (real in m)
//
FIND1_MQ10: Quadrupole, L=0.1, K1= 0.0, ELEMEDGE=1.38;
FIND1_MQ20: Quadrupole, L=0.1, K1= 0.0, ELEMEDGE=1.56;
FIND1_MQ30: Quadrupole, L=0.1, K1= 0.0, ELEMEDGE=1.74;
//elemento fittizio utilizzato per prolungare la linea del fascio
END: Solenoid, L=0.01, KS = 0.01, ELEMEDGE=100., FMAPFN="NEW_SINGLE_SOL_NOFRINGE_ASTRA.opal";
Injector: Line = (FINSS_RGUN, FIND1_MSOL10, FIND1_MQ10, FIND1_MQ20, FIND1_MQ30, END);
// End: CTF3 //////////////////////////////////////////////////////////////////////////////////////////////////
// Begin: Screen monitors ////////////////////////////////////////////////////////////////////////////////////
//
// Define screen monitors in beam line.
//
// L: physical element length (real in m). Always equal to 1 cm.
// ELEMEDGE: position of screen (real in m). This is where the particle information is taken.
// OUTFN: name of .h5 file to store data. Include ".h5" on end.
//
SCREEN1: Monitor, L = 0.01, ELEMEDGE = 0.902, OUTFN = "Screen1.h5";
SCREEN2: Monitor, L = 0.01, ELEMEDGE = 1.0165, OUTFN = "Screen2.h5";
//previous screen, virtual screen placed in the mid point of RFD
SCREEN3: Monitor, L = 0.01, ELEMEDGE = 1.1295, OUTFN = "Screen3.h5";
SCREEN4: Monitor, L = 0.01, ELEMEDGE = 2.2525, OUTFN = "Screen4.h5";
SCREEN5: Monitor, L = 0.01, ELEMEDGE = 2.735, OUTFN = "Screen5.h5";
SCREEN6: Monitor, L = 0.01, ELEMEDGE = 3.0, OUTFN = "Screen6.h5";
SCREEN7: Monitor, L = 0.01, ELEMEDGE = 3.126, OUTFN = "Screen7.h5";
SCREEN8: Monitor, L = 0.01, ELEMEDGE = 3.252, OUTFN = "Screen8.h5";
SCREEN9: Monitor, L = 0.01, ELEMEDGE = 4.126, OUTFN = "Screen9.h5";
SCREEN10: Monitor, L = 0.01, ELEMEDGE = 5.126, OUTFN = "Screen10.h5";
SCREENS: Line = (SCREEN1,SCREEN2,SCREEN3,SCREEN4,SCREEN5,SCREEN6,SCREEN7,SCREEN8,SCREEN9,SCREEN10);
// End: Screen monitors //////////////////////////////////////////////////////////////////////////////////////
// Begin: Fieldsolver ///////////////////////////////////////////
//
// Definition of first field solver.
//
Fs1:FIELDSOLVER, FSTYPE = FFT, MX = 32, MY = 32, MT = 64,
PARFFTX = true, PARFFTY = true, PARFFTT = true,
BCFFTX = open, BCFFTY = open, BCFFTT = open,
BBOXINCR = 1, GREENSF = INTEGRATED;
// End: Fieldsolver ////////////////////////////////////////////
Dist1:DISTRIBUTION, DISTRIBUTION = "GUNGAUSSFLATTOPTH",
sigmax = 0.000395,
sigmapx = 0.0,
corrx = 0.0,
sigmay = 0.000395,
sigmapy = 0.0,
corry = 0.0,
sigmat = 0.0,
pt = 0.0,
sigmapt = 0.0,
corrt = 0.0,
tRise = 7.45e-12,
tFall = 7.45e-12,
tPulseFWHM = 10.4e-12,
ekin = 0.4,
NBIN = 5,
DEBIN = 30;
beam1: BEAM, PARTICLE = ELECTRON, pc = P0, NPART = 20000, BFREQ = BF , BCURRENT = BC, CHARGE = -1;
SELECT, LINE=Injector;
// Simulation of the gun with step size DTGUN
TRACK, LINE= Injector, BEAM=beam1, MAXSTEPS=150, DT=5.0e-12, ZSTOP=0.5;
RUN, METHOD = "PARALLEL-T", BEAM = beam1, FIELDSOLVER = Fs1, DISTRIBUTION = Dist1;
ENDTRACK;
QUIT;
\ No newline at end of file
"RestartTest-6"
"Restart in a second simulation from the H5Part file written by the first simulation with T-Tracker"
stat "rms_x" last 1E-10 #this is a comment
stat "rms_y" last 1E-10 #this is a comment
stat "rms_s" last 1E-10 #this is a comment
\ No newline at end of file
Option, ECHO=FALSE;
Option, INFO=TRUE;
Option, PSDUMPFREQ=100;
Title, string="SwissFEL Injector, Phase 1 (Feb. 2010)";
FINSS_RGUN_phi= 0;
FINSB01_RACC_phi= 0;
FINSB02_RACC_phi= 0;
call, "FinPhase1.phases";
REPARTFREQ= 100;
value,{FINSS_RGUN_phi, FINSB01_RACC_phi, FINSB02_RACC_phi, REPARTFREQ};
FINSS_RGUN: RFCavity, L = 0.34986, VOLT = 100., FMAPFN = "FINSS-RGUN.dat",
ELEMEDGE = 0.0, TYPE = "STANDING", FREQ = 2998.0,
LAG = FINSS_RGUN_phi + (5.7/180.0*PI);
FIND1_MSOL10: Solenoid, L = 0.6, KS = 0.2089, FMAPFN = "FIND1-MSOL10.T7", ELEMEDGE = 0.0;
l1: Line = (FINSS_RGUN,FIND1_MSOL10,END);
// Define initial uniform beam distribution (== laser distribution)
// or use test particles for autophasing
Dist1:DISTRIBUTION, DISTRIBUTION = "GUNGAUSSFLATTOPTH",
sigmax = 0.000275 * 2.,
sigmapx = 0.0,
corrx = 0.0,
sigmay = 0.000275 * 2.,
sigmapy = 0.0,
corry = 0.0,
sigmat = 0.0,
pt = 0.0,
sigmapt = 0.0,
corrt = 0.0,
ekin = 0.63,
tRise = 0.7e-12,
tFall = 0.7e-12,
tPulseFWHM = 9.9e-12,
DEBIN = 80,
NBIN = 101 , INPUTMOUNITS=EV;
MINSTEPFORREBIN = 1000;
Fs1:FIELDSOLVER, FSTYPE=FFT, MX=16, MY=16, MT=32,
PARFFTX=true, PARFFTY=true, PARFFTT=true,
BCFFTX=open, BCFFTY=open, BCFFTT=open,
BBOXINCR=1, GREENSF=INTEGRATED;
qb=0.2e-9;
bfreq=2998.0;
bcurrent=qb*bfreq;
Edes=0.63;
gamma=(Edes+EMASS)/EMASS;
beam1: BEAM, PARTICLE=ELECTRON, GAMMA=gamma, pc=P0, NSLICE=101, BFREQ=bfreq, BCURRENT=bcurrent, CHARGE=-1;
Select, Line = l1;
// Simulation of the gun with step size 0.1 ps
track, line=l1, beam=beam1, MAXSTEPS=1000000, DT=1.0e-12, ZSTOP=1.0;
run, method = "PARALLEL-SLICE", beam = beam1, fieldsolver = Fs1, distribution = Dist1;
endtrack;
Quit;
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment