High Brightness Electron Beam Diagnostics and their ... - CASA

High Brightness Electron Beam Diagnostics and their ... - CASA High Brightness Electron Beam Diagnostics and their ... - CASA

casa.jlab.org
from casa.jlab.org More from this publisher
04.08.2013 Views

ofthelinechargeandtheobserverelectron.Theretardedangle0isrelatedtothepresentangle directionfromthelinecenterandtheobserverelectron.Thequantityinbracketmustbeevaluated forthepresentanglesrij(resp.fij)thatcorrespondstotheanglebetweentherear(resp.front) wherei,iaretheusualLorentzfactorsfortheorbitinglinei,bnijisthenormedvectoralongthe wherejisthetotaltransversedisplacementoftheobserverelectronwithrespecttothetrajectory ofthelinecharge. ThedenominatorofEqn.(B.9)canalsobeexpressedasafunctionoftheretardedtimeusinggeo- iandtheobserverjwehave: byatranscendequationderivedfromgeometricalconsideration.Forinstanceforthelinecharge metricalconsideration. 2iR2i(0)2=2j+2Ri(Ri+xj)(1cos(0)) (B.10) linechargecanbereplacedbyamacroparticlewhichcarry,asinPARMELA,auniformcharge. Theextensiontoabunchofelectrondescribedbyamacroparticlemodelisstraightforward:the whereNisthenumberofmacroparticleinthemodel. Infactthis\pointbypoint"typemacroparticlealgorithmhasalreadybeenimplementedinthe Thereforethetotalelectriceldproducedbythebunchofmacroparticleataretardedtimeonan JLabPARMELAversiontosimulatemacropaticleinteractionviaspace-chargeforce.Hencewe observermacroparticleatthepresenttimesimplywritesasthesum: caneasilymodifytheexistingalgorithmtosimulateCSRselfinteraction. TheretardedangleisevaluatedasdescribedbyCarlstenusinganiterativeprocesstosolvethe Etotal j=NXi=1Ei;j (B.11) transcendentequationEqn.(B.10).ThemodeldescribedintheprevioussectionasbeenimplementedintheJLabversionofPARMELA(bothaHP9000andaCrayC90versions).Pratically, whenthebunchentersabendinwhichtheuserwishtoincludeCSRinteraction,theradiusofthe trajectoryofeachmacroparticleisealuatedandthen,basedongeometricalconsideration,allthe parameterinEqn.(B.9)arecomputedandtheeldduetobunchonamacroparticleisevaluated. intheBENDCSRcardthesubroutinecsriscalled. Thisoperationisperformedforeachmacroparticleandthereforealargenumberofiterationis BENDcard.Thiscardmustbeusedtoindicatethebendingmagnetwheretheuserwishtosimulate CSRinteraction.Secondly,wehavemodiedtheprogramPARMDYNsothatwhentheelectronsare showningrey:rstlywehaveintroducedanewcardBENDCSRwhichfollowthesamesyntaxasthe needed.TypicalCPUtimeneededtorunoneFELchicaneisapproximately1hrwallclock.A blockdiagramofthePARMELAcodeispresentedinFig.B.1.Themodicationperformedare

Initialization MAIN Stop INPUT DECK INPUT BEAM START/RESTART PARMDYM (particle dynamics) SCHEFF Space-Charge Loop on time steps Loop on particles SAVE CSR Csr Interaction FigureB.1:Parmelasimpliedalgorithm. BENDCSR BEND DRIFT QUAD POISSON CELL SWAP/ OUPUT BRANCHES Yes No LAST PARTICLE OUPUT No End Yes END

ofthelinecharge<strong>and</strong>theobserverelectron.Theretardedangle0isrelatedtothepresentangle directionfromthelinecenter<strong>and</strong>theobserverelectron.Thequantityinbracketmustbeevaluated forthepresentanglesrij(resp.fij)thatcorrespondstotheanglebetweentherear(resp.front) wherei,iaretheusualLorentzfactorsfortheorbitinglinei,bnijisthenormedvectoralongthe<br />

wherejisthetotaltransversedisplacementoftheobserverelectronwithrespecttothetrajectory ofthelinecharge. ThedenominatorofEqn.(B.9)canalsobeexpressedasafunctionoftheretardedtimeusinggeo- i<strong>and</strong>theobserverjwehave: byatranscendequationderivedfromgeometricalconsideration.Forinstanceforthelinecharge<br />

metricalconsideration. 2iR2i(0)2=2j+2Ri(Ri+xj)(1cos(0)) (B.10)<br />

linechargecanbereplacedbyamacroparticlewhichcarry,asinPARMELA,auniformcharge. Theextensiontoabunchofelectrondescribedbyamacroparticlemodelisstraightforward:the<br />

whereNisthenumberofmacroparticleinthemodel. Infactthis\pointbypoint"typemacroparticlealgorithmhasalreadybeenimplementedinthe Thereforethetotalelectriceldproducedbythebunchofmacroparticleataretardedtimeonan<br />

JLabPARMELAversiontosimulatemacropaticleinteractionviaspace-chargeforce.Hencewe observermacroparticleatthepresenttimesimplywritesasthesum:<br />

caneasilymodifytheexistingalgorithmtosimulateCSRselfinteraction. TheretardedangleisevaluatedasdescribedbyCarlstenusinganiterativeprocesstosolvethe Etotal j=NXi=1Ei;j (B.11)<br />

transcendentequationEqn.(B.10).ThemodeldescribedintheprevioussectionasbeenimplementedintheJLabversionofPARMELA(bothaHP9000<strong>and</strong>aCrayC90versions).Pratically, whenthebunchentersabendinwhichtheuserwishtoincludeCSRinteraction,theradiusofthe trajectoryofeachmacroparticleisealuated<strong>and</strong>then,basedongeometricalconsideration,allthe parameterinEqn.(B.9)arecomputed<strong>and</strong>theeldduetobunchonamacroparticleisevaluated. intheBENDCSRcardthesubroutinecsriscalled.<br />

Thisoperationisperformedforeachmacroparticle<strong>and</strong>thereforealargenumberofiterationis BENDcard.Thiscardmustbeusedtoindicatethebendingmagnetwheretheuserwishtosimulate CSRinteraction.Secondly,wehavemodiedtheprogramPARMDYNsothatwhentheelectronsare showningrey:rstlywehaveintroducedanewcardBENDCSRwhichfollowthesamesyntaxasthe needed.TypicalCPUtimeneededtorunoneFELchicaneisapproximately1hrwallclock.A blockdiagramofthePARMELAcodeispresentedinFig.B.1.Themodicationperformedare

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!