Beam dynamics studies for the relativistic klystron two-beam accelerator experiment

Two-beam accelerators (TBAs) have been proposed as efficient power sources for next generation high-energy linear colliders. Studies have demonstrated the possibility of building TBAs from X-band 8 12 GHz through Ka-band 30 35 GHz frequency regions. The relativistic klystron two-beam accelerator project, whose aim is to study TBAs based upon extended relativistic klystrons, is described, and a new simulation code is used to design the latter portions of the experiment. Detailed, self-consistent calculations of the beam dynamics and of the rf cavity output are presented and discussed together with a beam line design that will generate nearly 1.2 GW of power from 40 rf cavities over a 10 m distance. The simulations show that beam current losses are acceptable and that longitudinal and transverse focusing techniques are sufficiently capable of maintaining a high degree of beam quality along the entire beam line.


I. INTRODUCTION
Two-beam accelerators (TBAs) based upon free-electron lasers (FELs) or relativistic klystrons (RK-TBAs) have been proposed as efficient power sources for next generation high-energy linear colliders.Studies have demonstrated the possibility of building RK-TBAs in the X-band ͑ϳ8 12 GHz͒ [1,2] and FEL-TBAs in the Ka-band ͑ϳ30 35 GHz͒ frequency regions [3][4][5].Provided that further prototyping shows stable beam propagation with minimal current loss and production of good quality, high-power rf fields, this technology is compatible with current schemes for electron-positron colliders in the multi-TeV center-of-mass scale.
Previous work [6] has shown that considerable microwave power can be developed in a relativistic klystron amplifier (RKA) configuration.With high beam current (2-11 kA) and low kinetic energy ϳ500 keV, these devices were typically limited by transport dynamics to have single output structures.The cavities comprising the rf circuit are designed to maximize the emitted microwave power at the output structure.Even though the peak output power is high, the total efficiency is still low, and much of the available kinetic energy in the beam is wasted at the beam dump.The concept of the RK-TBA [1,2] was developed to dramatically increase the overall device efficiency.In these devices, less charge is transported ͑ϳ0.5 2 kA͒, but at greater kinetic energy (1)(2)(3)(4)(5)(6)(7)(8)(9)(10) than in an RKA.Also, the rf circuit is designed to produce only the required power for a single or, at most, double length of high gradient accelerating structure.As a result, the beam in an RK-TBA is much stiffer and is perturbed much less than in an RKA configuration.The beam may be transported over *Electronic address: SMLidia@lbl.govlong distances to produce useful rf power in tens to hundreds of output structures.The use of suitably designed induction reacceleration cavities and permanent quadrupole focusing increases the net efficiency of these devices to a level that is very competitive with traditional klystrons.The stiffness of their beams makes them attractive candidates for producing rf power at higher frequencies than traditional klystrons can attain.
The high intrinsic efficiency of RK-TBAs derives from the use of induction linear accelerators.This technology is capable of generating and propagating electron beams with kiloampere peak currents, megavolt-scale energies, pulse lengths up to microseconds, and at repetition rates stretching up to the megahertz range [7][8][9].The pulse format of the drive beam in the RK-TBA can be tailored to match that of the high-energy accelerator, and losses in the energy conversion and transfer processes can be minimized.
RK-TBAs must deal with extremely challenging beam dynamics.Induction linacs, in general, and induction linac-driven TBAs, in particular, are known to suffer from potentially debilitating cumulative transverse beam breakup (BBU) instabilities [10][11][12].A low-impedance, low-frequency transverse BBU mode resides within the induction cavities, while a high-impedance, high-frequency BBU mode is present within the rf output structures.However, it has been shown theoretically that the effect of these instabilities can be greatly decreased with appropriate design of the beam line transport and focusing system, and by tailoring some of the beam parameters [13].Increasing the beam's energy spread induces rapid betatron phase mixing which effectively cancels the effects of the low-frequency mode, and adjusting the focusing lattice to place the rf output structures at half-integral betatron wavelength separation can reduce the growth in transverse BBU from exponential to linear.This linear growth will eventually limit the length of the device, placing a cap on achievable efficiency.The induction cell cavities may also respond to the beam modulation and extract rf power and/or affect the bunching.
Additionally, a strong longitudinal density modulation must be imposed upon the beam and maintained over the entire "active" length of the RK-TBA.Previous experiments conducted at Lawrence Livermore National Laboratory (LLNL) examined the use of longitudinal (velocity) modulation [14] and transverse (chopping) modulation [15] techniques to generate a bunched beam which then powered a number of different rf output structures.These early relativistic klystron experiments demonstrated that hundreds of megawatts of peak power could be generated over many tens of nanoseconds pulse duration, with phase stability sufficient to drive high-gradient accelerating structures.Further experiments [16,17] demonstrated that the drive beams in these klystrons could be reaccelerated between rf power extraction structures, while the beam modulation was maintained in the presence of strong debunching forces.
Previous simulation efforts have shown that this is possible if the output cavities are appropriately detuned in their resonance away from the central frequency carried by the beam's modulation [18][19][20].Inductive detuning, in which the cavity resonant frequency ͑f͒ is tuned slightly higher than the beam modulation frequency ͑f b ͒, introduces a phase offset between the beam microbunches (rf buckets) and the cavity mode oscillation such that the earlier arriving particles in any microbunch lose more energy than the later arriving particles.After transiting the cavity, the beam head is moving more slowly than the beam tail, and rebunching can occur.A correlation between arrival time and axial velocity thus opposes the debunching space charge forces.For higher energy beams, using a transverse chopping and modulation scheme, relatively small ͑ϳ30 ± ͒ detuning angles were found to maintain the beam's modulation over many extraction structures, even though a significant fraction of the beam current must be discarded during the initial modulation process.For lower energy beams, using a longitudinal modulation scheme, larger ͑ϳ70 ± 90 ± ͒ detuning angles become necessary, but no loss of current is necessary for the initial modulation.
As discussed below, larger detuning angles induce a large (up to 650%) energy spread in the ensemble of particles comprising the individual microbunches.The effect of this energy spread needs to be accounted for in the description of the transverse beam dynamics.It also remains to be demonstrated experimentally in a beam line significantly longer than previously attempted.
The relativistic klystron two-beam accelerator (RTA) project has been established at Lawrence Berkeley National Laboratory in collaboration with LLNL to study these and other issues.The primary effort of this test facility is the construction of a prototype RK-TBA subunit.Presently, an experiment is underway to study BBU and transverse dynamics in a periodic system with strong focusing [21].Concurrently, the theoretical program is continuing to develop simulation tools and to design the remaining portions of the RTA beam line.
The purpose of this paper is to present the first fully 3D, self-consistent results from simulations of the beam dynamics and rf power production in a prototype RK-TBA device from the modulation section through 10 m of the main TBA section.In Sec.II, we discuss the basic layout of the RTA experimental beam line and describe the components of the modulation and main TBA sections in detail.Section III describes the algorithms and code used to perform the simulations.The longitudinal beam dynamics are then described in Sec.IV, and connections are made to a simple 1D equilibrium theory.Transverse dynamics are described in Sec.V, and the influence of the longitudinal dynamics upon the evolution of the transverse beam envelopes is described for the first time.The development of rf power in the cavities is discussed in Sec.VI, and the relation of the steady-state behavior of the individual cavities to the evolution of the longitudinal beam phase space is examined.The operating scheme of the RK-TBA prototype is extended to include operation in an "afterburner" configuration, which is described in Sec.VII.Finally, the results are summarized and conclusions drawn in Sec.VIII.

II. DESCRIPTION OF THE RTA BEAM LINE
The entire proposed RTA experiment beam line is shown in Fig. 1.In the present design, the injector for the system delivers a 1.0 MeV beam to the accelerator, which boosts the energy to 2.5 MeV.This energy is not optimal for either the SL4 klystron (velocity modulation at ϳ1 2 MeV) or the Choppertron (transverse modulation at ϳ3 5 MeV) [15].Nevertheless, these simulations demonstrate that the SL4 can produce sufficient modulation in a higher energy beam to initiate the bunching process and allow for high power generation.A similar study utilizing the Choppertron will be conducted in the near future.
A detailed schematic of the SL4 and the beginning of the main TBA is shown in Fig. 2, displaying the focusing elements, reacceleration modules, and the first nine rf cavities.The remaining portion of the beam line used in the simulation is a continuation of the periodic main TBA section shown.to deliver a 2.5 MeV, 1.0 kA beam with a 1000p mm mrad normalized edge emittance (250p mm mrad normalized rms emittance) to the entrance of the SL4.Over the beam pulse, the beam energy is taken to be constant while the current rises from 0 A to its steady-state value of 1000 A, with a 100 ns rise time and 150 ns flattop.

A. The SL4 klystron modulator
The beam modulation section of the RTA device is the input and gain cavities of a previously designed and tested relativistic klystron, the SL4 [14].Figure 3 shows a schematic of the input and gain section of the klystron modulator.The cavity properties are shown in Table I.The first (input) cavity accepts rf power from a low power (#5 kW), X-band, traveling-wave tube or magnetron source, operating at a nominal frequency of 11.424 GHz.The beam enters from the left in the schematic (z 0 m).The input rf power modulates the beam energy in cavity #1 and initiates the bunching process.The following cavities are then driven by the rf component of the beam current, which develops in the drift spaces between the cavities.
Beam confinement in this section is performed by a set of four independent solenoid magnets (shown as a single solenoid in Fig. 2).The solenoids have an inner radius of 9.6 cm, an outer radius of 12.8 cm, and a length of 15.5 cm.An iron field clamp (shunt) is placed at the exit plane of the SL4 (z 0.98 m) to terminate the solenoid field.

B. Main TBA section
A schematic of a single period of the main TBA extraction section is shown in Fig. 4.Each module in the lattice holds one output rf cavity with dual output waveguides, six focusing and defocusing quadrupoles, and two complete induction reacceleration cells with gaps.
The rf properties of the modules are shown in Table II.The first rf cavity in the main TBA lattice is cavity #5.
where I dc is the average (dc) current carried by the beam, b represents the degree of bunching in the beam, Q ext is the external coupling (i.e., "waveguide"-)loaded cavity mode quality factor, ͓ R Q ͔ is the mode shunt impedance factor, and c is the mode tuning angle with respect to the beam modulation frequency (1.2 or 1.3 rad in our case) defined by  The cavities are designed to produce 50 MW of rf power from a beam modulated at 11.424 GHz with a bunching factor of b ϳ 0.7 and carrying 950 A of dc current.In this process, the output rf power is derived from the kinetic energy of the beam.The induction reacceleration modules are then required to replace this lost beam energy by supplying 26.25 kV across each of the two gaps in each module.
Transverse focusing is accomplished by permanent magnet quadrupoles arranged into the standard FODO (focus-drift-defocus-drift-focus) lattice [22,23].There are six quadrupoles in each 25 cm long TBA period, making three complete FODO cells.The betatron phase advance per FODO cell is 60 ± , so that the net phase advance between rf cavities is 180 ± , or one-half of a full betatron period.To achieve this, the permanent magnets must produce a 14 T͞m quadrupole gradient.With a 4 cm beam pipe diameter, the magnet blocks must then have a remanent field of 2800 G.While high, this is well within the field strengths achievable with ferrites.

BBU considerations
As previously mentioned, cumulative beam breakup instabilities stemming from the resonant excitation of transverse dipole ͑HEM 11 ͒ modes in the rf output structures pose the most severe constraint on the ultimate length of beam line that will produce usable rf power in an RK-TBA system.It is thought that limiting the growth of the instability to four e-folds (i.e., e 4 or approximately 10 2 ) over the length of the entire device is sufficient to transport the majority of the beam pulse.
In our beam line design presented here, the rf cavities also support a set of dipole modes with resonant frequencies near 18.6 GHz.The mode with minimal external port coupling ͑Q ext ϳ 200͒ shows a transverse shunt impedance ͓Z Ќ ͞Q͔ ϳ 120 V͞m.We have simulated the growth in the transverse mode amplitudes with the OMICE code [24] for our beam parameters and this beam line.With no energy spread across a given beam slice (other than that due to the space charge depression -typically ϳ1%), and without appropriately spacing the cavities with respect to the betatron wavelength of the on-energy particles, the cumulative BBU instability is seen to grow by ϳ8 orders of magnitude in the amplitude over the 10 m of main TBA beam line.Appropriately tuning the betatron wavelength to the nominal beam energy so that the rf cavities are spaced an integer number of half-wavelengths apart (the "betatron node tune"), the growth factor in the instability amplitude drops to less than 10.Additionally, increasing the microbunch energy spread increases the amount of betatron phase mixing present in the beam which also damps the instability, even when the average bunch energy varies from the nominal (i.e., the betatron node tune).The phase-mixed damping improves with increasing energy spread until it reaches a saturation point when the energy spread is greater than ϳ625%, at which point the growth factor is less than 10.As will be shown in the simulations discussed in this paper, the microbunches in the beam will develop an energy spread of up to ϳ650% from filamentation of the longitudinal phase space due to the inductively detuned rf structures.Hence, cumulative dipole BBU is not expected to be an issue in RTA operation.However, the importance of this technique to the successful operation of the RTA cannot be overestimated.With this in mind we are currently performing a lowenergy (1 MeV) beam transport experiment to measure the effectiveness of betatron node tuning in a real system [21].

III. SIMULATION CODE
Particle dynamics in relativistic klystrons pose several thorny problems for simulations.The electron beams are typically intense (hundreds to thousands of amperes) while only moderately relativistic (hundreds of kilovolts to tens of megavolts).Possibly the most important element of the dynamics in an RK-TBA occurs in the longitudinal phase space.The beam is modulated at high frequencies , and each microbunch (rf bucket) carries a charge of tens of nC.Space charge effects will produce debunching forces which are counteracted by (inductively) detuning the rf output structures.A microbunch will undergo numerous synchrotron oscillations during transport through the full-scale device.Also, the microbunches are not short compared to the rf wavelength.Hence, they sample very nonlinear fields in the rf output structures.
From this description we can identify the main problems present in a device simulation.The beams are sufficiently intense that longitudinal space charge forces present more than a small perturbation.The beam line elements are necessarily spaced close together, and this requires treatment of overlapping, nonlinear fringe fields.Transverse focusing is strong so that a half betatron oscillation occurs between rf output cavities.Transverse emittance, while low, is still sufficiently large that particles at the beam edge sample significant nonlinearities in the fields of the beam line elements.The instantaneous energy spread is large ͑10% 100%͒ to constrain the low-frequency BBU and to produce the bunching by rf synchrotron rotation.The particle simulation, of necessity, must track many particles to provide adequate sampling of both the beam phase space and the fields experienced.

041001-4
041001-4 Fully electromagnetic and relativistic particle-in-cell (PIC) simulations, popular in the plasma physics community, can and do simulate all these processes.Codes of this type have found their way into the accelerator community as a means of studying high-perveance beams in klystrons, for example.However, the computational resources required are far too great to perform routine design and optimization on significant lengths of the full-scale TBA.On the other hand, typical tracking codes in the accelerator physics community track a relatively small number of particles with a small phase space extent in complex external field environments.Self-field interactions are either completely neglected since the beams are usually tenuous and ultrarelativistic, or included only approximately with semianalytic models.Maxwell-Vlasov, Fokker-Planck, and envelope codes can track beam distributions in the presence of self-fields, but these tend to track only a few of the lower order moments, while ignoring evolution of the detailed phase-space distributions.
Past design efforts have utilized simulation codes that could model only certain aspects of the entire problem.1D simulations [4] of the longitudinal dynamics in an extended relativistic klystron do not account for the transverse dynamics.2D [18,25] simulations cannot accurately model beam dynamics in both solenoid and quadrupole transport lattices.Previous 3D simulations concentrated on modeling the physics involved in the transverse dipole BBU instability [24], but not the dominant rf bucket dynamics and power production in the cavity output structures.Additionally, all the previous results have utilized a simplified model of the forces due to the self-fields (and image fields) of the beam.These models do not accurately account for the details of the full beam distribution, and hence cannot predict any changes in that distribution that may subsequently affect the interaction of the beam with the focusing lattice and rf structures.
The current generation of simulation code has been developed to account for all time-dependent and 3D effects, and the details of the 6D particle distribution [20,26,27].The entire beam pulse length is divided into a sequence of microbunches with longitudinal extent corresponding to the modulation wavelength.These microbunches are then tracked over the beam line.There are three main components to this simulation.
The first is a tracking algorithm to generate nonlinear transfer maps for pushing noninteracting particles through the external fields based upon a Lie-algebraic approach [28][29][30].A mapping algorithm is used so that tens of thousands of macroparticles can be pushed from the solution of a few hundreds of differential equations.A single-particle, relativistic Hamiltonian is used to derive exact equations of motion for a small number of "guide," or fiducial, orbits, where 2p t is identified with the total energy of the particle.The external fields enter through a vector potential, A͑ r, t͒.A gauge is chosen such that the scalar potential F is identically zero.The equations of motion are then solved numerically over a given beam line interval.The individual fiducial particles are chosen by partitioning the entire microbunch phase space and selecting a representative, hypothetical particle from each partition.The partitions may be created in any manner.For these simulations, we have chosen to partition along the longitudinal arrival-time coordinate.A set of approximate Hamiltonians is also constructed from a 6D Taylor series expansion around the individual fiducial orbits.The coordinates and momenta in these approximate Hamiltonians represent the difference between the actual coordinates and momenta and those of the fiducial particles, and are called "deviation" coordinates and momenta.The Taylor series is expanded to fourth order in these deviation variables, and provide equations of motion accurate to third order.The remaining particles in each partition are then propagated along the beam line by the equations of motion generated by the deviation Hamiltonians (see Appendix A) The second component in the code is a particle-in-cell algorithm [31] that solves a set of Helmholtz equations for the self-fields, including the conducting boundary condition of the beam tube.A multigrid algorithm [32] is utilized to speed the convergence of the PIC algorithm.The generated impulses themselves constitute a "kick" map, and are interleaved with the single-particle maps by means of a split-operator algorithm [33][34][35][36] .This technique is based on splitting the Hamiltonian into pieces that can be solved exactly (or through some desired order of accuracy) and then combining the separate maps to produce an approximate net mapping for the full Hamiltonian over some step ͑Dz͒ along the beam line.In the secondorder scheme we adopt, the split-operator method produces a net mapping that is second-order accurate in the step size represented by the mapping [i.e., the error introduced by splitting the operator is of the order of ͑Dz͒ 3 ].Split-operator symplectic integration algorithms, including the well-known leapfrog algorithm of plasma physics simulations [31,37], are widely used in the treatment of Hamiltonian systems.The total Hamiltonian is represented in the form where H kin is the kinetic portion describing singleparticle motion in the absence of all fields, H ext is the contribution from external fields, and H self is the contribution from self-fields.The maps from the first two contributions are calculated together by the single-particle formalism described above, while the map resulting from self-forces is calculated separately.A combined map is then produced to advance particles over an interval t.

041001-5 041001-5
Accurate through second order in this step, the combined map is expressed as The third component is an equivalent circuit equation solver that advances the modal rf cavity fields in time due to excitation by the modulated beam (see Appendix B).The derivation of the equivalent circuit equation is well covered in the available literature [38][39][40].What is new and significant here is the introduction of a description of the beam using a periodic Klimontovich distribution.This will allow us to calculate the average interaction of the rf mode with any 6D beam distribution, automatically accounting for slippage and beam loading effects by incorporating actual particle trajectories.This method accounts for only individual cavity modes, but is many times faster than an electromagnetic PIC algorithm.Finally, the circuit equation is separated into two distinct time scales, and a first order ordinary differential equation is derived for the slow scale time evolution.This is then solved analytically in the limit of short (slow) time scale intervals.Hence, by observing closely what happens to a single microbunch during its traversal of a cavity, we may study the transient dynamics in the entire system without the need to track each consecutive microbunch.For a slowly evolving system, we need only track those microbunches separated by a large fraction of the mode's free-oscillation decay time, which can be tens or hundreds of rf bucket lengths.

A. Simulation parameters
We have modeled the beam dynamics and the evolution of the cavity fields from initial transients into the steadystate regime.The main parameters of the simulation are given in Table III.In this simulation 8192 macroparticles were used, and initially loaded into a 3D semi-Gaussian distribution. 1The initial normalized rms transverse emittance, averaged over any given microbunch, is 250p mm mrad (1000p mm mrad normalized edge emittance).The rf and induction cavity field profile distributions in z are taken to be Gaussian with standard deviations of 4.03 and 5.0 mm, respectively.
For the self-field calculations, the Helmholtz equation computational volume encloses a single 11.424 GHz (2.624 cm long) rf bucket, extending transversely to the inner surface of the 4 cm diameter beam pipe.Since the selffield potential is solved in the beam's rest frame, the microbunch length is dilated from the laboratory frame by a factor of g and extends over approximately 15.5 cm.In this frame, the longitudinal to transverse aspect ratio is approximately 4:1.This computational volume encloses only a single rf bucket so we impose periodic boundary conditions between the head and tail.Prior to bunching, the particles in this volume are distributed more or less uniformly in longitudinal position.During the bunching process, this is no longer true.However, the distribution of particles in longitudinal position will still extend over most of this volume.Looking at frequency components carried by the beam modulation, we expect that the first few harmonics of the spectrum will dominate.It is then possible to utilize only a relatively small number of longitudinal grid points to adequately describe the variation of self-field forces with longitudinal position.In a similar manner, we expect the transverse variation of the beam density to vary quite significantly.Hence, we must use a larger number of grid points in the x or y direction.For the simulations discussed here, the computational volume was discretized into a grid with dimensions 33 3 33 3 8.

B. Inclusion of transverse rf dipole mode effects
These simulations do not include the influence of transverse dipole modes in the induction modules or rf cavities.Thus, we have not included the important BBU instabilities that have shown to limit current transport in RK-TBAs.There are certain computational issues regarding the inclusion of multiple frequencies that lie outside the range of the fundamental and its harmonics.In particular, the simulation tracks individual slices of the beam pulse with longitudinal extent corresponding to an rf wavelength where the temporal rf frequency is specified initially.This frequency is taken to be the one of greatest interest.For the results presented in this paper, this fundamental frequency corresponds to that of the resonant monopole mode of the rf cavities.A separate simulation based around the dipole mode frequency as the fundamental (and only including the dipole cavity modes) can be accomplished, though we do not discuss it at this time.Currently, several new computational strategies are being pursued that could enable 041001-6 041001-6 multifrequency simulations.It is hoped that this will be presented in a subsequent work.However, as a step forward in the sophistication of modeling RK-TBA systems, this simulation shows that pure rf monopole modes, 3D space charge effects, and quadrupole transport do not significantly increase the transverse emittance in the beam.

IV. LONGITUDINAL PHASE-SPACE EVOLUTION
The longitudinal dynamics of the particles in an rf bucket constitute the heart of any RK-TBA.The energy extracted from the microbunches in the rf cavities must be replaced in the induction modules.The detuning of the cavity introduces a nonlinear correlation between energy and phase for particles within the microbunch.This induces the particles within the rf bucket to rotate in longitudinal phase space.The reacceleration in the induction modules is weakly dependent upon the dc beam current, but the rf cavity field excitation is strongly dependent upon both the dc current and the bunching parameter.
In the simulation, we see that the dc current carried by a microbunch in the middle of the pulse decreases at a slow rate over the length of the device (Fig. 5), and the bunching parameter varies significantly along the beam line.In Fig. 6, we show the variation of the bunching parameter along the beam line, with the positions of the rf output cavities indicated.This figure clearly shows the synchrotron oscillation that follows from the microbunch rotation.In Fig. 7, the longitudinal phase-space distribution of the bunch is shown after passing through a cavity at various locations along the beam line.The individual particle arrival time ͑t͒ at the cavity exit plane is scaled by the speed of light, and then translated with respect to the central fiducial arrival time ͑t 0 ͒, s c͑t 2 t 0 ͒.
We also see another effect of inductive detuning.The average energy of a microbunch in the steady-state portion of the beam pulse increases in the first segment of the main TBA beam line (Fig. 8), as the bunching increases from its initial unbunched state to the final bunched state.Simultaneously, the energy spread of a microbunch will increase from its initial value to its final value (Fig. 9).
The cavities are designed to extract their design power from microbunches with the nominal design value of the bunching parameter (i.e., b 0.70) and dc current (950 A).The beam will continue to gain energy from the induction modules until this equilibrium state is reached.Once the nominal bunching has been achieved, there will be no net energy gain by the individual microbunch.
However, due to the synchrotron rotation required for longitudinal stability, the beam will experience periodic debunching and rebunching as it progresses along the beam line.Neglecting the small decrease in total current carried by an individual microbunch, this will result in the microbunch periodically losing more or less of its design energy as it passes through the series of rf output cavities.This behavior is to be compared directly with the variation of bunching parameter along the beam line (Fig. 6), and is shown in Fig. 8. Additionally, we see that the net energy of the microbunch gradually increases.This increase in net beam energy can be eliminated by slightly decreasing the voltage in the reacceleration gaps of the induction modules.However, the synchrotron rotation will still result in oscillation of the microbunch energy about some equilibrium value.
The steady-state theory [20] provides some insight into the relation between cavity parameters, power generation, and synchrotron oscillations.For particles near the beam line axis, the change in kinetic energy from the interaction with the excited cavity mode is given by the expression where t is the difference in arrival time between an individual particle and the center of the microbunch.Averaging over the rf bucket, the net beam power loss is then given by which is equal to the sum of the power absorbed by the cavity walls plus that transmitted out of the cavity by the external coupling ports.For the values of Q wall and Q ext considered here (Table II), we can neglect the tiny fraction of the total power lost to wall heating, compared to that coupled out the external ports.The energy modulation given to the individual particles ͑ ͑ ͑Dg͑ t͒͒ ͒ ͒, relative to the net energy loss of the microbunch as a whole ͑Dg ͒, is then The induced energy spread along the microbunch due to the interaction with an rf cavity can then be expressed as which shows a strong, nonlinear dependence upon the tuning angle.For small tuning angles the induced spread is a smaller fraction of the net microbunch energy loss, while larger tuning angles can produce very large energy spreads.The tuning angle must be large enough to induce a correlated energy spread that overcomes space charge debunching, while small enough to limit the energy spread so that the particles within a microbunch can be captured and contained by synchrotron oscillations.A 1D linear, equilibrium theory formulation [41] based on standard rf longitudinal dynamics [22,23,42,] can be used to find the equilibrium synchrotron oscillation wave number  and the depth of the separatrix with Here, k b ( 2pf b ͞c) is the beam modulation wave number, L is the distance between rf cavities, g 0 is the equilibrium beam relativistic factor (with b 2 0 1 2 1͞g 2 0 ), mc 2 ͞e is approximately 511 kV, and the separatrix turning point f 0 is determined by solution of the transcendental equation The separatrix depth determines the energy spread that can be accommodated in a stable rf bucket that undergoes synchrotron oscillations with wave number k s .Several values of f 0 from a numerical solution to (13), as well as factor F͑c, f 0 ͒, are tabulated in Table IV.Comparing values generated by (11) with the phase-space distributions in Fig. 7, we see that the simple 1D formula agrees to within ϳ20%.

V. TRANSVERSE PHASE-SPACE EVOLUTION
The behavior of the microbunches in longitudinal phase space affect the transverse dynamics as well.In particular, we notice that an initially matched transport system loses that feature as the microbunch compresses longitudinally and its energy spread increases.An effect of this compression will be to enhance the peak radial, defocusing self-fields in the presence of the conducting beam pipe, while the enhanced energy spread introduces lower energy particles into the transport lattice.These two effects can, in principle, be dealt with by appropriately adjusting the strength of the quadrupoles along the beam line.In our studies we have maintained a constant parameter FODO lattice for simplicity of design.In Fig. 10 we show the evolution of the two transverse rms envelopes (x and y) along the beam line for microbunches in the steady-state portion beam pulse.Visible is the slight increase in the average envelope radius at locations of peak bunching (near z 4 m and z 8.5 m).There is evidence here of an apparent state of quasiequilibrium since the synchrotron oscillation period encompasses many betatron periods.In this situation, the rms envelopes of the microbunch can respond to the slowly increasing (or decreasing) current density by slow expansion (or contraction).
In Fig. 11, we show the evolution of the normalized rms transverse emittance.In the usual definition of the rms transverse emittance [43], (and similarly for y), the phase space is defined in terms of position ͑x͒ and paraxial angle ͑x 0 Х y x ͞y z ͒, and ensemble averages are performed over the particles in an rf bucket (denoted by the angle brackets, ͗ ͘).In these simulations, where a Hamiltonian approach is used, the normalized canonical momentum ͑ px p x ͞mc gb x ͞mc 1 qA x ͞mc͒ is employed instead of x 0 .We will, however, continue to refer to the emittance calculated with px as the rms transverse emittance.For particles born in a field-free region, the two definitions yield identical results.There are some important differences, though, which show up in the simulations.
From Fig. 11, we may observe distinct types of behavior.First, we see that transverse emittance exhibits slow, steady growth over the beam line, increasing by approximately 8% over 10 m.Secondly, there is evidence of an oscillation in the transverse emittances correlated to the synchrotron oscillation.The emittance increases in the regions of the beam line where the beam experiences bunching or rebunching, and decreases in the debunching cycle of the synchrotron oscillation.This is another indication of the quasiequilibrium discussed above.
The first observation can be explained by noting that the beam is far from stationary in any part of this beam line.The detailed beam distribution is not matched, since the beam rms energy spread is growing from a nominal few tenths of a percent to 25%.We would expect some growth in the transverse emittance.
The oscillation of the transverse emittance following the synchrotron oscillation has a more direct explanation.As the microbunches are compressed during bunching or rebunching, the particles at the center of each microbunch see an increasing charge density.The local transverse space charge forces are now stronger and, over a period of several betatron wavelengths, the rms beam envelope expands in response.At the opposite end of the synchrotron oscillation cycle, the particles in the center of the microbunch see weakening transverse space charge forces as the microbunch expands.The envelope now contracts.This state of quasiequilibrium is shown in Fig. 10.However, as the beam envelope expands, particles with large amplitude excursions find themselves at ever greater distances from the beam line axis.Hence, they sample stronger nonlinearities in the fringe fields of the beam line elements.These nonlinear fields then enter the emittance computation via the

041001-10
041001-10 canonical momentum.In this way, the rms transverse emittance may oscillate along with the bunching parameter.
The transverse phase-space distributions of the microbunches at locations corresponding to the output planes of several cavities along the beam line are shown in Fig. 12.It is seen that the distribution does not undergo any significant changes during propagation, and that the microbunch remains stable along the beam line.

VI. DEPENDENCE OF RF PRODUCTION UPON BEAM DYNAMICS
After an initial transient evolution of the cavity fields in time, the mode amplitudes enter the steady-state regime.This evolution is shown in Fig. 13, where the abscissa is the time elapsed ͑DT ͒ as the beam pulse head entered the simulation at z 0 m, scaled by the speed of light, s 0 cDT.The input cavity sustains a constant power level reflected from the cavity.The power shunted to the loads in the SL4 gain cavities is shown to indicate the rise of the cavity mode amplitude from one cavity to the next, betraying the increase in modulation amplitude.Finally, the power shunted to the exit waveguides in the output structures are displayed.We see that the output power levels in the main TBA section cavities vary by a factor of 2-3, and generally agree with the analytic estimate given by Eq. ( 1).The synchrotron oscillations affect the coupling of the microbunch to the rf cavities, resulting in an oscillation along the beam line of the steady-state output power levels of the cavities, shown in Fig. 14.In a very long device, one that allows the bunches to rotate through many synchrotron oscillations, it is expected that the particles will more evenly fill the rf bucket in longitudinal phase space through the process of filamentation so that the variation in the steady-state output power among  later cavities decreases.In fact, it may even be desirable in an actual device to increase the initial energy spread in a microbunch, or to sharply decrease the synchrotron wavelength at the front end of the RK-TBA, just to enhance the rate at which the longitudinal phase-space bucket is filled.
Similarly, the output phases also show a periodic behavior.While remaining relatively constant in the regions of rebunching and maximum compression, there is a rapid change in the phase during the cycles of debunching and minimum compression, shown in Fig. 14.

VII. EXTENSION TO AN AFTERBURNER CONFIGURATION
At the end of a generic RK-TBA is an "afterburner" section, the primary purpose of which is to increase overall system efficiency by extracting more power out of the modulated beam at the end of the main TBA.This section has a number of rf extraction cavities, permanent magnets for focusing, but no reacceleration cells.The beam line design presented here also gives us the ability to study beam dynamics in the afterburner section of a main TBA.In this case, no reacceleration is applied to the beam after z 4 m.

041001-11
041001-11 The evolution of the average energy and energy spread of the microbunch along the beam line is shown in Fig. 15.We see that without the benefit of reacceleration, the average energy in the microbunch will decrease at a steady rate.As a result of this decrease in the microbunch average energy, the normalized energy spread will continue to grow.
The transverse phase space is affected by this decrease in energy.The transverse components of the Lorentz force are proportional to 1͞g, and hence become more important as the energy drops.We see the emittance growing rapidly as the energy continues to drop, accompanied by growth in the beam envelopes (Fig. 16).The transverse phase distribution of the microbunch after the 40th rf cavity is shown in Fig. 17.The vertical phase-space distribution has become significantly diluted, increasing from approximately 270p mm mrad in the previous scenario (Fig. 11) to approximately 310p mm mrad in the present case, with the majority of this growth occurring in the last 2 m of beam line.
The increase in emittance and the beam envelope causes a slight increase in the rate of current loss from scraping.Meanwhile, the longitudinal Lorentz force is proportional to 1͞g 3 so that the drop in energy and increase in energy spread results in a shortening of the synchrotron oscillation period (Fig. 18).This effect also shows up in the output power and phase variation in the cavities along the beam line (Fig. 19), which also demonstrate the synchrotron oscillations.We also see that the beam quality in the longitudinal phase space is greatly diminished after the 40th cavity (Fig. 20), compared to our previous scenario (Fig. 7).

VIII. SUMMARY
The results of a detailed simulation of the beam dynamics in the proposed RTA beam line have been presented.These results show that a prototype RK-TBA can be designed to produce 1.2 GW of power at 11.424 GHz using 40 rf cavities and driven by a 1-kA, 2.5-MeV electron beam.Beam losses amount to only 7% over the 10-m long bunching and extraction section, while the average transverse beam envelopes remain nearly constant.In this same distance, the normalized rms transverse emittances grow by only 8%.This occurs even though the 6D beam distribution is nonstationary and the rms energy spread increases from a few tenths of a percent to 25% of the average energy.By "turning off" most of the induction reacceleration modules in the simulation, it has been demonstrated that this same beam line can be operated in an afterburner mode, with useful power generated with greater efficiency.This will allow a single experiment to test different segments of a complete RK-TBA system.The lower limit in energy for a kiloamp scale RK-TBA seems to be approximately 2.5 MeV.Below this energy, the equilibrium beam size is too large to propagate through the output structures without incurring unacceptable losses [44].However, the allowable normalized edge emittance ͑1200p mm mrad͒ is twice that previously expected ͑600p mm mrad͒ from earlier studies [45].Hence, constraints on emittance growth during beam generation and propagation to the modulator section can be relaxed somewhat, if tighter control can be maintained once the beam is in the main TBA section.
The transverse envelopes can be matched in moving between solenoidal and magnetic quadrupole focusing lattices.However, matching the longitudinal sector of the beam dynamics proves more difficult.This will be true of any TBA device that attempts to match into a channel with constant rf cavity parameters.To avoid the large variation in output power levels from the various cavities along the beam line, it will be necessary to incorporate a second-order design strategy.This strategy may vary the parameters of the cavities to attempt to achieve nearly constant rf power extraction from every cavity.Doing so might prove to be unnecessary if a transverse modulation scheme is used so that only a fraction of the longitudinal 041001-13 041001-13 phase space defined by the separatrices are occupied by beam particles.Larger detuning angles than previously considered (70 ± instead of 30 ± ), and larger microbunch energy spreads (up to 650%), can be safely transported in the main TBA section.This has important implications for reducing low-frequency BBU via phase-mixed damping.The larger energy spread induces rapid cycling of the synchrotron oscillation, further enhancing longitudinal stability.

ACKNOWLEDGMENTS
The author would like to acknowledge the following individuals for their support during the time this work was performed: Simon Yu, Glen Westenskow, Swapan Chattopadhyay, Andrew Sessler, and Winston Ko.Invaluable discussions were held with Robert Ryne, Timothy Houck, and David Whittum.Comments and feedback on the manuscript were gratefully received from John Barnard and William Fawley.The simulations were performed on a DEC Alpha 21264 workstation owned by the Stanford Synchrotron Radiation Laboratory (SSRL).The author would like to thank the staff of SSRL, especially Roger Carr and Harvey Rarback, for graciously allowing this work to be completed there.This work was supported by the Director, Office of Science, Office of High Energy and Nuclear Physics, Division of High Energy Physics under U.S. Department of Energy Contract No. DE-AC03-76SF00098.

APPENDIX A: FIDUCIAL TO DEVIATION HAMILTONIAN
In this Appendix we derive the single-particle Hamiltonian function which describes the dynamics of the beam particles lying close to the fiducial orbit.A simple canonical transformation is applied to the Hamiltonian (3) by constructing a generating function.The resulting transformed Hamiltonian is then expressed in terms of the deviation coordinates and expanded in a power series representation.
We find it easier to analyze the Hamiltonian (3) by first renormalizing the momenta, energy, time coordinate, and potentials.To do so, we first define the normalized quantities: K K͞mc, pЌ p Ќ ͞mc, 2g p t ͞mc 2 , and s ct.Additionally, the potentials are normalized via Ã q A͞mc.With this normalization the Hamiltonian function (3) becomes

Fiducial orbit
A single-particle guiding orbit (the fiducial orbit) is calculated which usually represents the motion of the beam centroid or barycenter.Given a set of initial conditions, the equations of motion derived from the Hamiltonian (A1) are solved to obtain an exact orbit for the fiducial particle.This 041001-14 041001-14 orbit is represented as a function of z and has the scalar components j g ͑z͒ ͑x g , pxg , y g , pyg , s g , 2g g ͒ ͑z͒ . (A2) The fiducial orbit described above produces a particular "chart" in phase space, connecting initial to final values.For particles with initial conditions near those of the fiducial particle, the chart is equivalent to a mapping, taking initial values to final values.This mapping can be derived analytically from the fiducial orbit and the underlying Hamiltonian flow.

Canonical transformation to deviation coordinates
Individual particles are characterized in their initial values by the difference of their phase space coordinates from that of the fiducial orbit.The phase space coordinates of a given particle are defined as j͑z͒ ͑x, px , y, py , s, 2g͒ ͑z͒ .(A3) The deviation coordinates are defined as where j g ͑z͒ denotes the coordinates of the fiducial, or "guide," orbit.These fiducial coordinates are scalar functions of the affine parameter z and are used to construct a canonical transformation via the type-2 generating function [46] Carrying out the derivation yields

Power series expansion
This Hamiltonian can now be expanded in a power series2 in the deviation coordinates, The lowest-order term in this expansion does not contribute to the equations of motion since it is only a function of z, and so it is neglected.By defining the particle phase space coordinates in terms of deviations from the fiducial orbit coordinates, the linear term in the expansion is explicitly zero. 3The remaining terms are of second-and higher-order in the deviation coordinates.For small deviations from the fiducial orbit, this power series will rapidly converge.We will only consider terms in the Hamiltonian up to fourth order.This gives equations of motion valid to third order.It is useful to perform this power series expansion to examine the effects of particular nonlinearities.We first introduce a little shorthand notation.The vector potential is also represented as a power series expansion in the configuration space coordinates about the fiducial orbit The lowest-order term in this expansion gives the values of the vector potential components along the fiducial orbit, with higher-order terms adding contributions due to deviations from this orbit.The fiducial orbit relativistic factor g g has an associated normalized velocity, b g p 1 2 1͞g 2 g .Of course, this assumes that the fiducial orbit does not reverse direction.If this were to occur, the clauses of the implicit function theorem would be violated and the entire framework presented here would be invalid.This could conceivably be tolerated as long as the calculation of the maps ceases when the forward momentum of the fiducial reaches zero.At this point, we could switch Hamiltonians from K 2p z to H 2p t , reparametrizing the phase space, and keep integrating the equations of motion.Physically, we are in danger of invalidation only if we were to attempt modeling systems such as conventional klystrons, where the beam is violently decelerated over a short distance.Fortunately, that is not the case in RK-TBA systems.
The kinetic momentum differs from the canonical momentum which appears in the Hamiltonian functions.If we denote the (normalized) transverse kinetic momentum by p, where p pЌ 2 ÃЌ , then we may write Higher-order terms, p2 , etc., can be defined as the opposites of the corresponding term in the transverse 041001-15 041001-15 PRST-AB 4 STEVEN M. LIDIA 041001 (2001) vector potential expansion, but this distinction will not be emphasized.The deviation Hamiltonian is then expressible in the deviation variables as Combining terms in the deviation Hamiltonian, After a little algebra, we obtain The expression (A16) is now in a state from which we can derive terms of the power series representation.We can see that the terms of the series represent powers of the ratio of transverse momentum deviation:forward momentum.Thus, this series will converge more rapidly for beams of small normalized emittance.It should be noted, however, that the ratio is what really matters.The fiducial trajectory is, in theory, calculated exactly.It may represent an orbit with classical or relativistic energies equally well (as long as it does not reflect at some position z).
Performing the power series expansion on (A16) to fourth order, neglecting terms which are independent of the deviation coordinates, and noting that terms of first order in j cancel identically with the first term, we find (dropping the "g" subscript from guide orbit quantities, g g , b zg ) after some algebra Along with the equations of motion for the fiducial trajectory, the power series expansion (A17)-(A19) provides a basis for linear and order-by-order nonlinear analysis and solution of the equations of motion for the entire ensemble of particles comprising the beam.
In the situation where no dipole fields exist, and the fiducial orbit has no transverse excursion from the beam line axis, these expressions simplify immensely.In this case, p0 0 b Ќ , and b z b p 1 2 1͞g 2 .The deviation Hamiltonian series terms (A17)-(A19) take the limiting form, Comparing the two sets of expansions, (A17)-(A19) and (A20)-(A22), we see that the coupling of the off-axis fiducial momentum components with the vector potential introduces new terms.These can be treated and analyzed as pseudomultipoles.In most cases of interest, the fields in the accelerator beam line are only weakly nonlinear, so that the power series can be seen to rapidly converge.Even in the cases (such as rf fields) where there is one coordinate (in the rf cavity case, the arrival time ŝ) along which the fields have a strongly nonlinear variation, taking multiple fiducial elements along the range of that coordinate can restore the accuracy of the finite power series expansion.

APPENDIX B: BEAM-CAVITY INTERACTION
This Appendix summarizes the theory and formalism in the beam-cavity interaction we expect to find in relativisticklystron two-beam accelerator systems.

Fundamental elements and dynamics
In this section we describe the main elements that take part in the dynamics: the cavity voltage and convection current (beam).We will not undergo here the full discussion or derivation of the basic interaction as embodied in the circuit equation.These are well covered in the available texts [38][39][40].We will merely make their introduction and briefly discuss some of their properties.The particular model of the current density which provides the bridge between the circuit analogy and the tracking code will be presented.

a. Modal elements and dynamics
We are specifically concerned with the interaction of the beam with the fundamental monopole mode ͑TM 010 ͒ in a single standing-wave (SW) idler or output cavity, and with the fundamental TE 10 mode in any coupled, external waveguide.Application to transverse deflecting or focusing modes can also be handled with this formalism, with little variation.
We will assume that the fields in the cavity are dominated by a single monopole mode.We express the cavity electric field as a product of a time-dependent mode amplitude with a spatial mode profile (indexed by l), E͑ r, t͒ a l ͑t͒ The spatial profile of the mode is assumed to have the so-called "Slater" normalization [38], Other normalizations are sometimes used.Another one we employ will be described later.The spatial field profile is assumed to be static; all of the temporal behavior of the field enters through the mode amplitude.This is the quantity which is used to describe the cavity voltage as seen by the beam, and is proportional to the electric field in any output waveguide.Knowing the spatial mode profile, and the total electric field at time t, the mode amplitude can be defined by The other dynamical quantity is the current density representing the beam traveling through the cavity structure.We define a modal current density by computing the overlap of the time-dependent current density with the spatial profile of the mode electric field, The cavity may have coupling that permits rf power to enter or leave.This coupling can be weak or strong.Viewed in terms of steady-state behavior, this coupling is typically characterized by an external-coupling quality factor, Q ext , of the cavity.We may also describe the coupling as an impedance transformation from the mode amplitudes (for incoming and outgoing waves) of the attached waveguide, through the coupling port surface, to the mode amplitude of the resonant cavity.This coupling surface is usually taken to lie in the transverse plane of the connecting waveguide, a short distance ͑,l͒ from the cavity.Slater [38] calls this surface "the plane of the detuned short."Collin [40] defines this plane as to lie sufficiently far from the physical cavity aperture that evanescent mode amplitudes are negligible.In either case, we define a relationship based on the continuity of the transverse electric field at the port surface between the incoming ͑1͒ and outgoing ͑2͒ waveguide mode amplitudes and the cavity mode amplitude, Here, the external coupling parameter V 1l measures the overlap between the cavity mode ("l") and the fundamental waveguide mode ("1").This is a reasonable assumption for klystron input/output ports.The external coupling parameter may be related to the external Q value of the cavity via the relation where Z c1 is the characteristic impedance of the waveguide mode.This coupling can be calculated, or measured, on the bench with a network analyzer.
As detailed in Refs.[38,39], we write down an equivalent circuit equation describing the time evolution of the mode amplitude due to excitation by both the external rf current drive and the incoming waveguide mode, and losses from wall heating, beam loading, and coupling to the outgoing waveguide mode, This equation is equivalent to a damped harmonic oscillator, driven by two independent source terms.The undriven oscillator term contains two external parameters related to the resonant mode: the angular frequency v l and the wall-loss quality factor Q w .They can be determined from cold-cavity experiments or numerical simulations.
Since the temporal structure of the fields and currents is predominantly harmonic in nature with an angular frequency v b close to the resonant frequency of the cavity, it will be helpful to consider the corresponding frequency domain description.We may assume that the modal amplitudes and spatial profiles are real-valued functions.For quasi-steady-state harmonic oscillation at the modulation rf frequency, we express the time dependence of the rf amplitudes as V 6  1 ͑t͒ Х ŷ6 cos͑v b t 1 w 6 ͒ .It will be convenient to also use complex-valued quantities.In this case we may express the time-dependent rf modal amplitudes as real parts (denoted by Re) of a complex phasor, V 6  1 ͑t͒ Х Re͕ ỹ7 exp͓2i͑v b t 1 w 6 ͔͖͒ .These time-dependent mode amplitudes have constant coefficients.This is approximately correct on the time scale of the rf modulation period ͑T b ͒, but these amplitudes also possess a slow time variation as well.This slow variation will be discussed further in Sec. 2 of this Appendix.

b. Normalization of the cavity electric field
Returning to the problem of the beam-cavity interaction, we observe that the simulation model employs a paraxial approximation based upon a description of the fields near the beam line axis.In particular, we consider only the on-axis longitudinal electric field profile and assume that it is a function of only longitudinal position (z), with a separable time dependence.The values of the field and its derivatives along the axis are used to generate all other electric and magnetic field components (permitted by symmetry) near the axis by construction of the vector potential A z ͑ r, t͒.From the point of view of the simulation, we need only those field components along the axis, a complete description of the rest of the cavity is unnecessary.
However, without the detailed description of the total electric field profile throughout the entire cavity, we are unable to normalize the modes according to the Slater prescription (B2).But, this normalization need not be performed in the particle tracking simulation; it may also be done when the modes are initially generated by electromagnetic codes [SUPERFISH, URMEL, MAFIA, GDFIDL, etc.].This can be performed through a combination of analytical modeling of the on-axis field profile with numerical calculation of the circuit ͓r͞Q͔.This relates the on-axis voltage seen by the beam to the total energy stored in the cavity.
The longitudinal component of the monopole mode electric field profile in single-cell cavities with open beam pipes is well approximated by a Gaussian distribution along the beam line axis.The standard deviation ͑s͒ can be obtained from simulation data by appropriate fitting procedures.The longitudinal field profile of the monopole mode can then be represented by for a cavity centered at z 0. Here, N l is the normalization constant that we wish to determine.In terms of the modal fields, the circuit ͓r͞Q͔ is defined for constant velocity ͑b z ͒ particles as An accelerator ͓R͞Q͔ is also widely used in the accelerator literature, where ͓R͞Q͔ 2͓r͞Q͔.
To derive an expression for the normalization constant, we substitute our analytical approximation for the on-axis field profile.Incurring a negligible error, we extend the limits of integration in the above integral to 6`.We then find our normalization constant to be 041001-18 041001-18 ) This defines the connection between the modal fields used in the circuit analogy and the fields used in determining the beam dynamics.We refer to this definition of the field, e 0 ͑z͒, as the "line voltage" normalization such that `dz e 0 ͑z͒ 1 . (B14)

c. Periodic Klimontovich current distribution
The connection between the discrete particle description employed by the tracking code and the current density used in the circuit equation is made by appealing to the Klimontovich distribution [47].Since the rf amplitude of the modulated current density varies only very slowly on the rf time scale, the charge per microbunch and the distribution function appear to be periodic when observed over a few rf periods' duration.We describe the time dependence of the charge density distribution by expanding in a Fourier series basis defined over a single rf period J͑ r, t͒ Here, N is the number of particles carried in a simulated microbunch and Q b is the total charge carried by the beam current past a stationary observer in a time T b .Hence, the beam dc current averaged over an rf period is I b Q b ͞T b .We further assume that the particle distribution within the microbunches is quasiperiodic with period T b .Individual particles in the microbunch pass the beam line position z 0 at times t n ͑z 0 ͒ and at transverse positions r Ќn ͑z 0 ͒.The relativistic nature of the beam allows us to neglect the transverse current density components, provided the rf power extracted from the beam in single cavity is only a small fraction of the total beam power.
We compute the Fourier components of the current density, Integrating, we obtain Reassembling the Fourier components, The modal current density at time t 0 is now calculated to be We have denoted with angular brackets, ͗ ͘, an average over the distribution of particles within an rf bucket.Here, t͑z͒ is the arrival time at beam line position z with transverse offset r Ќ of an element of the current density.Again, it will be convenient to use the real parts of complex-valued quantities, This particular integral of the modal electric field occurs so often that we will just define 041001-19 041001-19 The phase convention employed in this definition corresponds to t͑z mid ͒ 0, where z mid is the longitudinal position at the center of the cavity.This convention is applied to the fiducial orbit only; all other particle orbits introduce relative phase changes.
The particular function defined by (B23) plays an extremely important role in the dynamics of the beam and the evolution of the cavity field amplitude.It serves to define the cavity voltage, and hence the mode ͓R͞Q͔ and shunt impedance.It contains transit time effects, and, when applied to beam particle trajectories in the presence of a background rf field, it will then compute beam loading contributions to the shunt impedance and the net energy deposited into the mode.We will refer to it as the mode transit function.
The modal current density in (B10) can then be expressed as Re͕exp͓2ilv b t͔ ͗ wy ͑lv b , r Ќ ͖͒͘ .

(B24)
For the beams we consider here, only the l 1 term is necessary to retain for the monopole mode.Higher-order azimuthal modes may couple to higher harmonic components in the beam's spectrum.

Analysis of the circuit equation
Here we will employ the elements developed in the previous section.We will assume that there exist two distinct time scales of interest.A fast time scale, where variations are seen to occur within an rf period, and a slow time scale.The latter can be taken to be the fill time of the cavity ͑T F T b Q l ͞p͒, the rise time of the driving current, or some other relevant time scale.The mode amplitude and current density are modulated at the fast time scale.But the evolution of the amplitude, as well as any phase drift, occur on the slow time scale.As a result, we may rewrite the governing circuit equation in terms of these slowly varying quantities and the slow time scale.

a. Slow time-scale equation of motion
We introduce slow time variations into the modal amplitudes and phases, âl âl ͑t͒, w l w l ͑t͒ , Ĵl 2I b ͑t͒ ͗ wy ͑v, r Ќ ͒͘, (B25) ŷ6 ŷ6 ͑t͒, w 6 w 6 ͑t͒ , where the time-dependent quantities are all real-valued functions.These functions are required to be slowly varying in time with respect to the rf period.For a quantity f͑t͒, this means that j df dt j ø jfv b j.We substitute these into the circuit equation (B8) and neglect second-order time derivatives of slowly varying quantities µ This equation can be simplified by introducing a voltage normalization.We define an on-axis cavity circuit voltage ͑ Ṽc ͒ and forward ͑ ṼF ͒ and reverse ͑ ṼR ͒ port voltages in the mode transit normalization via where w0 w͑v b , r Ќ 0͒.In this normalization, the continuity of the transverse electric field at the port plane is expressed as Ṽc ṼF 1 ṼR . (B28) In the absence of any beam, the mode transit function w is undefined.However, there may still be fields present in the cavity as well as coupling through the ports.In this case, we will utilize a different scheme, the port overlap normalization, As defined, these voltages are complex valued.The microbunch-averaged accelerator shunt impedance is de- With these definitions, the circuit equation (B26) becomes (in the mode transit normalization) Using the continuity condition (B28), we may express the reverse voltage in terms of the cavity and forward voltages.Doing so, the circuit equation becomes µ The loaded quality factor Q l has been introduced with the definition which is a statement of net power loss in the cavity's fields in the absence of beam coupling.
From standard microwave terminology, we recall the definitions of the tuning angle c, cavity fill time T F , and coupling parameter b, and introduce the phase change in a fill time n vT F .The circuit equation can now be written as Since Q w is typically several thousand or more, we neglect terms of order O͑ 1 4Q 2 w ͒, and express derivatives in terms of t t͞T F (using primes to indicate derivation).We also introduce the supplementary parameters In Sec. 3 of this Appendix, it will be shown that the shunt impedance as defined here is a complex-valued quantity, but that it can be expressed as is a manifestly real-valued quantity and F b is a complexvalued distribution-dependent form factor, with magnitude of the order of unity.This form factor provides a measure of the space time overlap of the microbunch distribution with the mode on the time scale of the rf period.Its calculation takes into account the individual electron trajectories, and hence accounts for beam-loading effects.With the distribution independent shunt impedance, the circuit equation takes its final form, This is the main result of this section.We solve (B43) for the special case of linear variation of the current with time.This will give us solutions valid for both the initial and final ramping portions of the beam current as well as the flattop.We do not attempt to find a global solution over time, which requires inclusion of the self-consistent interaction of the cavity back upon the beam.Rather, we will seek a local solution, valid only over a short time duration (though still long compared to the fast time scale), as an approximation to use within the numerical simulation to advance the cavity mode voltages in time.

b. Analytic solution for short (slow scale) time duration
The circuit equation above (B43) can be simplified slightly by introducing parameters that absorb the local time dependence of the beam current and forward power, Both of these factors become unity under steady-state conditions.Equation (B43) is now We integrate this differential equation over a brief time interval compared to the slow time scale, but over many rf 041001-21 041001-21 periods.We assume that the microbunch dependent form factor ͑F b ͒ is nearly constant, which is a good approximation provided the cavity voltage does not change by a significant fraction of the beam voltage over the interval of integration.In other words, we assume the intrabunch particle motion remains nearly identical from microbunch to microbunch, so that the bunch-averaged quantities such as emittance and energy spread do not appreciably vary over the interval of integration.This particle motion is calculated by the tracking algorithm based upon fields excited from the passage of previous microbunches and the coupling of external rf power into the cavity.We allow for a linear time dependence of the current and forward power, so that both B b and B F are constant over the time interval.After integrating the equation between times t 1 and t 2 , and dropping terms of order O ͑ 1 4Q 2 w ͒, we find our short term solution This solution is seen to track both losses and phase shifts due to beam loading and phase slippage on the slow time scale.

c. Observed fields and power flow
The physical observables, the time-dependent rf mode amplitudes, are derived from these circuit voltages.The observables have the time dependence Depending upon the voltage normalization scheme (B27) and (B29), the amplitudes and phases of the fields and modes are then and in the port overlap normalization.Of interest is the amount of rf power flowing into and out of the cavity derived from the Poynting flux.The waveguide modes are normalized such that the transverse electric fields satisfy a relation similar to (B2).The net rms power flowing in the waveguide, again assuming a single mode, can then be shown to be with denoting the forward and reverse rms power flows in the connecting waveguide, respectively.Translating this into the normalization schemes gives (B58) in the mode transit and port overlap schemes, respectively.Note that the reverse voltage has been expressed in terms of the forward and cavity voltages.
The rms value of the energy stored in the cavity is given by U c e 0 2 j âl j 2 . (B60) The rms power shunted to the walls and to the reverse waveguide mode can be derived by appealing to the definition of the quality factor, Hence, the wall-loss power and the reverse power are given by P w v l U c Q w e 0 v l 2Q w j âl j 2 , (B62) 041001-22 041001-22 as expected.From energy conservation, the sum of these shunted powers must equal the power obtained from the beam and the forward power, The reverse power flow is then In the absence of any forward power flow, all power is shunted from the beam into the cavity walls as well as coupled through the exterior waveguide.The power loss to the beam is then where we identify the bunching parameter b as b jF b j .(B73)

Internal microbunch dynamics and the averaged shunt impedance
In this section we calculate the bunch-averaged value of the shunt impedance.This will necessitate a somewhat closer inspection of the intrabunch particle dynamics as the beam crosses the cavity.In particular, we need to examine slippage effects that determine the beam loading effects in the interaction.
From our definition of the shunt impedance (B30) we recall and w0 w͑v b , r Ќ 0͒.In the usual linac formulation, the function w0 is calculated by assuming a constant velocity b 0 of particles through the cavity.In that case, t͑z͒ t 0 1 ͑z 2 z 0 ͒͑͞b 0 c͒.Here, we allow for intrabunch particle motion resulting from a finite beam energy spread and from the influence of rf fields preexisting with the cavity.We determine the value of t from the fiducial orbit.
To calculate the trajectory dependent mode transit function, wy ͑v b , r Ќ ͒, we maintain the spirit of our tracking code and appeal to the power series expansion.For a SW monopole mode, we use where r 2 Ќ x 2 1 y 2 , and the auxiliary functions are (primes denoting total derivatives with respect to z) f 0 ͑z͒ E zl ͑ r Ќ 0, z͒ N l e 0 ͑z͒ , (B77) In evaluating these integrals during the simulation, we break up the interval covering the entire longitudinal length of the cavity into a set of shorter subintervals (on the order of 10).In each subinterval, we will assume that individual particle transverse coordinates do not change appreciably.Then, for each particle in the simulation, we replace r In these integrals, the arrival time in the exponential is a dynamical coordinate of each particle.We may express the arrival time of an individual particle as the sum of the fiducial arrival time with the time deviation coordinate of the particle, t t 0 1 t.
In computing the microbunch averages over the subintervals, we further assume that the individual particle longitudinal phases (i.e., arrival times) remain nearly constant with respect to the fiducial.We will use the notation where (k 0, 2, 4, etc.), and the integrals are to be performed over the fiducial quantities only.
For the beams of interest to us for RK-TBA devices, the longitudinal phase space is characterized by microbunches which subtend a significant fraction of the rf wavelength, with small instantaneous energy spread and significant correlation between energy and arrival time.By retaining nonlinearities in the equations of motion to only low orders, large errors are accumulated for particle orbits lying far from the fiducial.We ameliorate this situation by computing the transfer maps induced by multiple fiducials.The original fiducial (called the "central" fiducial) is retained to provide continuity, but temporary fiducials are added to more accurately describe the entire microbunch dynamics by sampling different portions of the longitudinal phase space.This can be rapidly evaluated in the simulation environment.
The bunch-averaged shunt impedance is evaluated by taking averages over the spatial and phase coordinates of the particles in the microbunch This last form serves to define the bunch-averaged form factor F b .In practice, the microbunch form factor (B86) is calculated by integrating the differential contribution to F b over all of the subintervals comprising the rf gap as described above.Doing so, the calculation of F b includes contributions from intrabunch particle motion during the interaction and, as such, includes any beam-loading effects.The microbunch form factor (B86) is seen to differ from the usual definition [48] f b ͗exp͓iu͔͘ , where u is the longitudinal phase of an individual electron in the microbunch, in that (B86) includes higher-order longitudinal and off-axis effects.These effects are usually described by a gap-coupling coefficient and/or a beamloading admittance [49] in the klystron literature.

FIG. 5 .
FIG.5.Microbunch current evolution from matching section through main extraction section.
FIG.6.(Color) Bunching parameter variation along beam line (dashed blue line).The beam pipe wall radius (in cm) and positions of the rf cavities are indicated by the solid red line.The entrance to the SL4 klystron corresponds to z 0.

FIG. 13
FIG. 13. (Color)Transient to steady-state power output in the RTA, displaying the reflected power in the input cavity, the power shunted to the loads in the gain cavities, and the power exiting the waveguides in the main TBA output structures.The abscissa is the elapsed time scaled by speed of light.

FIG. 14 .
FIG. 14. Steady-state output power (a) and phase (b) in the main TBA section.

P b 1 P 1 P w 1 P 2 .
In the limit of steady-state behavior, the differential circuit equation (B43) becomes the algebraic equation reverse power flow in terms of the forward power flow and beam coupling, ͑ r Ќ , z͒ exp͓2iv b t͑z͔͒ (B75)

TABLE I .
SL4 cavity parameters.GHz͒ from the beam modulation frequency ͑f b 11.424 GHz͒ to provide additional rotation and compression of the longitudinal phase space for the individual microbunches.All following cavities are detuned by 1.2 rad ͑f 11.72 GHz͒.The steady-state power output from each of these cavities can be estimated via the analytic formula (see Appendix B)

TABLE II .
Design parameters of main TBA cavities.

TABLE III .
Main TBA parameters.

TABLE IV .
Separatrix parameters from 1D theory.