A 750 MHz radio frequency quadrupole with trapezoidal vanes for carbon ion therapy

High-frequency linear accelerators are very suitable for carbon ion therapy, thanks to the reduced operational costs and the high beam quality with respect to synchrotrons, which are presently the only available technology for this application. In the framework of the development of a new linac for carbon ion therapy, this article describes the design of a compact 750 MHz Radio Frequency Quadrupole (RFQ) with trapezoidal vanes. A new semi-analytic approach to design the trapezoidal-vane RFQ is introduced together with the relevant beam dynamics properties. The RFQ is split into two decoupled rf cavities, both of which make use of a novel dipole detuning technique by means of length adjustment. The splitting is described both from the rf and the beam dynamics point of view. The paper concludes with the rf design of the full structure, including maximum surface field and thermal studies.


I. INTRODUCTION
The hadron therapy market is continuously expanding because of the advantages that this treatment brings with respect to conventional radiotherapy. One of the main limitations to the accessibility to hadron therapy is the cost of the accelerators needed to provide it. For this reason a lot of effort has been put into the development of compact and less expensive machines.
The idea of using high-frequency linear accelerators for hadron therapy was proposed in the early 90s [1]. Together with the advances in the development of the accelerators, the interest in this research field has only grown since then. While proton therapy linacs have reached the industrialization phase-two machines are presently under construction or commissioning [2,3]-the same cannot be said for carbon-ion machines, which are still at a conceptual design stage. For this reason it is important to explore new possible solutions tailored to reduce size and costs of the accelerator and thought in a way that ease the transition between research and industrialization.
One of the most recent proposals, fully described in Ref. [4], introduced the design of a 3 GHz "bent linac". The rationale of such a machine is to improve the aspect ratio of its footprint, studying a solution that could better fit into a hospital facility without affecting the treatment beam properties. In the low energy section of the machine, fully stripped carbon ions ( 12 C 6+ ) are produced by the ion source (TwinEBIS, operating at CERN [5]), transported in the Low Energy Beam Transport (LEBT) [6] and matched to the Radio Frequency Quadrupole (RFQ), which represents the first rf accelerating structure. The RFQ has the critical role of shaping the beam in both the transverse and the longitudinal plane and prepare it for the injection in the following accelerating structures.
In order to reduce as much as possible the operational and building costs of the accelerator, all of its components have to be designed finding the best compromise between compactness, power consumption, and feasibility of construction. Driven by such requirements, a compact Carbon-RFQ operating at 750 MHz, a subharmonic of 3 GHz, has been developed at CERN. The proposed design ( Fig. 1) follows the 750 MHz HF-RFQ for proton therapy, designed and built at CERN, that has successfully been commissioned in 2018 [7][8][9][10][11].
The rf design is based on the experience gained with the HF-RFQ and PIXE-RFQ [9,[12][13][14]. However, with a length of 475 cm ≈ 12λ being more than twice as long as the HF-RFQ, the Carbon-RFQ had to be split into two separate rf cavities to ensure a stable field distribution. The length of each of the two fully decoupled cavities was used as a free parameter for dipole mode detuning, such that other dedicated detuning techniques are not necessary. This novel technique was conceptually proposed in Ref. [13] and has now been implemented for the first time. Two quadrupole vane extensions were used to rematch the beam across the inter-cavity drift.
The paper is structured as follows: Section II describes in detail the beam dynamics design, starting with four considered version of the standard-vane design (II A), followed by the transition to the trapezoidal design with the help of the sixteen-term potential function (II B), which is validated by means of particle tracking simulations (II C). In Section III, the splitting of the RFQ into two cavities is discussed from an rf perspective in terms of dipole detuning (III A), and a beam dynamics point of view (III B). Finally, Section IV covers the remaining aspects of the rf design, including cavity shape (IV A), surface electric fields (IV B), auxiliaries and power couplers (IV C), as well as thermal simulation (IV D).

II. BEAM DYNAMICS DESIGN
Section II discusses the two stages of the Carbon-RFQ beam dynamics design. First, the standard-vane RFQ was developed, taking two possible versions into account. Then, the final design choice was redesigned with trapezoidal vanes. An in-depth comparison by means of particle tracking follows.

General Design Choices
The choice of the characteristic parameters used for the RFQ design was driven by different constraints. The 12 C 6+ -ion beam energy was defined by the maximum accelerating voltage that the LEBT can hold, in this case 30 kV, that leads to an input energy of 15 keV/u at the entrance of the RFQ. Concerning output energy, two different solutions at 2.5 MeV/u and 5 MeV/u were proposed in order to widen the range of options in the selection of the accelerating structure following the RFQ.
The frequency of the RFQ was chosen to be a subharmonic of the linac frequency (3 GHz) in order to allow the longitudinal beam injection. The specific frequency of 750 MHz was chosen as a compromise between the gain in the length of the structure, which decreases as the frequency increases, the power consumption, which scales as V 2 0 ·f 3/2 [15], the beam acceptance, which decreases as the frequency increases, and the machinability. More detailed considerations on the frequency choice can be found in Ref. [8].
The minimum vane aperture a (minimum distance between two opposite vanes) and the inter-vane voltage V 0 are strictly bound to the maximum surface field E s,max that can be held by the vanes without breakdown. The Carbon-RFQ was designed aiming at E s,max = 50.6 MV/m, corresponding to 2.0 Kilpatrick [16,17]. Recently, the HF-RFQ for medical applications has been successfully commissioned [11], featuring the same frequency and maximum surface electric field, as well as a similar pulse length. As shown in Fig. 2, reducing the aperture a results in an increasing surface field E s,max . At the same time, E s,max can be reduced by decreasing the inter-vane voltage. Aperture and vane voltage are to be chosen finding the best compromise between power consumption (P 0 ∝V 2 0 ) and acceptance, which decreases with a, keeping E s,max below the threshold. A summary After the main RFQ parameters were fixed, the vane shape had to be defined. The choice of the vane profiles depends on a wide range of parameters that determine the beam dynamics in the RFQ. The main driver in the definition of modulation m, minimum aperture a, and synchronous phase φ s along the structure is the kind of application the RFQ is tailored to. In the present work,  Table II, where the consequences of the different design choices become clear in terms of particle transmission, length, rf power loss, and output longitudinal emittance. In the following, the main characteristics of each option are described in detail and the criteria used for the final choice are explained.

High-transmission RFQ
The vane parameters of the high-transmission RFQ were at first calculated using the LANL (Los Alamos National Laboratory) RFQ codes (Curli, RFQuick, Pari, and parmteq) [18]. Once a baseline set of parameters was fixed, the vane profile was optimized further, increasing the maximum modulation and reshaping the vane profile in the gentle buncher (see Ref. [4] for more details). The function m(z) = m 0 e rz0 + m 1 e rz e rz0 + e rz (1) was used to describe the modulation profile in the gentle buncher, depending on the four parameters, r, z 0 , m 0 , and m 1 . While m 0 and m 1 are fixed, corresponding to the modulation values at the entrance and exit of the gentle buncher, r and z 0 can be optimized to minimize beam losses and E s,max along the gentle buncher. An example of the parametric function is shown in Fig. 3. The final modulation m, minimum aperture a, and synchronous phase φ s profiles resulting from the optimization are plotted in Fig. 4. The design algorithms used by the LANL codes are implemented to respect the adiabatic bunching condition and, moreover, to keep the bunch space-charge density constant along the RFQ, as detailed in Ref. [19]. In order to meet both conditions, the acceleration efficiency is kept very low in the first section of the RFQ (the shaper), that becomes the longest part of the 2.5 MeV/u variant, as can be seen in Fig. 4. The high transmission, therefore, comes at the price of a long structure and, consequently, a high power consumption.

Compact RFQ
The dimensions of the RFQ could be reduced by shortening the shaper and the gentle buncher, increasing the synchronous phase ramp-up. However, if the phase ramp was too steep, the capture process could not take place, resulting in uncontrolled losses. To overcome this issue, the synchronous phase at the entrance of the RFQ was increased from the conventional −90°to −50°. In such a way, the phase increase is smooth enough to guarantee the beam bunching in the phase-energy phase space and the length of the shaper can be dramatically reduced. The use of this technique, also implemented by HF-RFQ and PIXE-RFQ [8], provides a powerful tool to shape the beam on the longitudinal plane according to the requirements of the structure coming downstream the RFQ. The higher the input synchronous phase is, the lower is the output longitudinal emittance,because of the reduced amount of transmitted particles. As a drawback, the particles that are not captured are lost, resulting in a decreased transmission. As shown in Fig. 5, by increasing the phase, the longitudinal acceptance of the RFQ is decreased, meaning that about 50 % of the particles entering the RFQ are not captured. Nevertheless, the amount of losses can be chosen by design and all the losses occur at injection energy, avoiding activation issues. The design of the gentle buncher of the compact RFQ was carried out using the same function described by Eq. (1). The modulation m, minimum aperture a and synchronous phase φ s profiles of the compact RFQ are plotted in Fig. 4.

Final design choice
In order to choose one of the proposed design options it is important to consider how carbon ion therapy treatment requirements translate in terms of machine technical specifications. The treatment dose per unit volume and time usually amounts to 2 Gy/(min L), which corresponds to 4 × 10 5 carbon ions per pulse at f rep = 200 Hz repetition rate. The amount of ions per pulse extracted by the TwinEBIS source is expected to be above 1 × 10 9 ions/pulse, much higher than a common treatment requirement. If a transmission of 50 % is considered, the ion rate at the end of the RFQ would be 5 × 10 8 ions/pulse, thus still three order of magnitudes higher than the required one. The transmission of the RFQ is therefore not a critical concern in this specific application. Moreover, as shown in Table II, the phaseenergy emittance at the end of the compact RFQ is more than two times smaller than for the high-transmission one, allowing for lossless bunch-to-bucket injection into a 3 GHz structure. For these reasons, the compact RFQ was chosen among the proposed options.
The RFQ is designed to accept a nominal current of 1 × 10 9 ions/pulse ions in a pulse of 5 µs, which translates in a pulse current of 0.19 mA. In Ref. [4], particle tracking was performed for beams with different currents, and it was highlighted that the space charge effects for the nominal current are negligible.
Two possible accelerating structures were considered to come downstream the RFQ. The first one consists of a 750 MHz IH-structure, described in Ref. [20]. This structure works at the same frequency as the RFQ, allowing for easy longitudinal injection, and can accept particles at 2.5 MeV/u, being reason why this energy was taken into account as a possible alternative. In the bent linac design, a 3 GHz SCDTL (Side Coupled Drift Tube Linac) [21] was chosen after few considerations discussed in Ref. [4]. The cell length in such structure equals c = βλ, where β is the relativistic velocity and λ the rf wavelength. At 3 GHz and 2.5 MeV/u, the cell length would be c = 7.3 mm, too short to be physically machined. At 5 MeV/u, c = 10.3 mm. An SCDTL structure with such cell length has already been machined and demonstrated to work on the LIGHT machine [22]. Thus, it was decided that the RFQ performs the acceleration up to 5 MeV/u.

B. Design with Trapezoidal Vanes
The compact 5 MeV/u option arose as the final design choice from previous consideration. In the following, it was modified to feature trapezoidal vanes, increasing its acceleration efficiency.

Trapezoidal Vane Geometry
A trapezoidal cell generally consists of two straight parts connected by a sinusoidal curve, providing a smooth longitudinal cell profile with a continuous firstorder derivative. While other transitions may be used, we adopted the trapezoidal cell geometry proposed in Ref. [23]. From here on, the sinusoidal junction is denoted as the accelerating gap with length g. Furthermore, we let r 0 identify the mid-cell aperture, a the min-imum aperture, m the modulation factor, and L the cell length (Fig. 7). The longitudinal vane-tip profile follows where a = 2r 0 /(m + 1). The profile of the y-vane is mirrored with respect to the cell center L/2. Note that for g = L, Eq. (2) just delivers the profile of a sinusoidal cell. The 3D geometry of the four-vane Carbon-RFQ trapezoidal cell with flat semicircular vanes is shown in Fig. 7. It is obtained by sweeping the transverse vane profile, a semi-circle with constant radius = 0.9r 0 , along the trajectory given by the longitudinal profile.  Figure 8a shows the longitudinal electric field E z along the beam axis of an exemplary trapezoidal cell (m = 2.7, L = 10.5r 0 , = 0.9r 0 ) for varying normalized accelerating gap lengths g/L. While the spatial average of the peak accelerating field E 0 = E z stays virtually constant, the transit-time factor T of the synchronous particle [24] is increased. For an ideal standard cell following the two-term potential, T = π/4 ≈ 0.786. While for purely sinusoidal cells (g/L = 1) the transit-time factor is already slightly higher, it could be increased to T = 0.988 by decreasing g/L within the cell parameter space of the Carbon-RFQ. This value is close to the theoretical limit of T = 1. The increase in T is equivalent to an increase in acceleration efficiency A 1,0 . Figure 8b shows the quantities as functions of g/L. Generally, the increased acceleration comes at the price of a smaller quadrupole focusing term A 0,1 . This is also the case for sinusoidal cells when increasing the modulation m-but not for RFQs featuring standard two-term potential cells, where the focusing is generally kept constant.
Another important figure is the maximum surface electric field E s,max , representing one of the major performance limits for any linac [24]. The lower plot of the field enhancement κ = E s /(V 0 /r 0 ). Figure 9 visualizes the maximum field region as the accelerating gap is decreased: the maximum field increases, and its location changes from a wide-spread area in concave region of the electrode surface (a) to a more localized hot spot in the convex region (d). Although the increased field poses a performance limit to accelerating cells located towards the end of an RFQ, such as the one studied here, the value is significantly surpassed by the short cells found in the gentle buncher during the modulation ramp-up (Fig. 11d). The bottleneck thus remains in the upstream stages of the RFQ.

Sixteen-term Potential Function
The electric field of trapezoidal vanes cannot be described by the two-term or eight-term potential function used by the available RFQ design codes [18,[24][25][26][27][28], parmteq [18] being the most common. Previously, 3D simulation code was employed to design RFQs with trapezoidal electrodes, taking the electrode geometry directly into account [23,[29][30][31][32][33][34]. While this procedure delivers highly accurate results, it is also time-consuming, as for each parameter change new simulations have to be performed to solve the Laplace equation.
In this paper, we augment the well-known eight-term potential function by higher-order terms, accounting for the particular field pattern of the trapezoidal electrode. A similar approach has recently been published in Ref. [35]. Figure 10 shows the approximation of the simulated on-axis electric field E z by the potential function. By adding the longitudinal coefficients A 5,0 , A 7,0 , A 9,0 , and A 11,0 , the approximation error falls below 1 % of the peak field. Additionally, the four coefficients A 4,1 , A 6,1 , A 4,3 , and A 6,3 are included in order to accurately describe possible distortions of the transverse quadrupole field. The full sixteen-term potential reads +A 1,0 I 0 (kr) cos(kz) + A 3,0 I 0 (3kr) cos(3kz) +A 5,0 I 0 (5kr) cos(5kz) + A 7,0 I 0 (7kr) cos(7kz) +A 9,0 I 0 (9kr) cos(9kz) + A 11,0 I 0 (11kr) cos(11kz) +A 1,2 ϕ 1,2 (r) with ϕ µ,ν (r) = I 2ν (µkr) cos(2νϑ) cos(µkz).  Multipole coefficients and maximum surface field are precomputed and stored in a lookup table similar to parmteq [18,25] for a discrete number of cells in the parameter space of interest. The coefficients for a specific cell geometry are then obtained by interpolation. In general, the trapezoidal cell of a four-vane RFQ with transverse semi-circular vane tips (Fig. 7) is described by six independent parameters: L, m, g, , r 0 , and V 0 , all of which may vary along the RFQ. For the computation of the potential field and its coefficients, however, V 0 merely appears as a scalar factor, while length quantities can be replaced by the dimensionless parameters L/r 0 , g/L, and /r 0 . Furthermore, for the Carbon-RFQ, the transverse curvature radius is constant. The remaining three free parameters were swept over the ranges 0.75 ≤ L/r 0 ≤ 20, 0.15 ≤ g/L ≤ 1, and 1 ≤ m ≤ 3.2. A limit to the parameter space is given by the longitudinal radius of curvature L : The theoretical lower limit is given by the transverse radius of curvature, L,min = = 0.9r 0 , which must be smaller than the longitudinal radius of curvature in order to construct a physically possible geometry. In practice however, L,min is limited by the radius of the cutter tool used to machine the RFQ vanes. The cuboid spanned by the parameter ranges is incomplete starting from the corner corresponding to short cells with short accelerating gaps and large modulations. In total, 2280 different cell geometries were precomputed for the Carbon-RFQ using the Finite Element Method (FEM) Laplace equation solver of comsol Multiphysics® [36]. Figure 11 shows a selection of the computed multipoles over the parameter space. Most important for the beam dynamics design are the quadrupole term A 0,1 (a) and the acceleration efficiency A 1,0 (b). The plots highlight that decreasing g/L has in first approximation the same effect as increasing m-increasing acceleration at the expense of focusing. This equivalence can also be seen from the newly introduced coefficient A 5,0 (c), which further highlights the importance of the newly introduced higherorder terms for cells with g/L 1. Finally, Fig. 11d shows the field enhancement as a function of the three parameters. Here it becomes clear that-for a constant V 0 and r 0 -one should expect the maximum surface field in the short cells in the bunching section at the beginning of the RFQ. A decrease in g/L raises the field only slightly. This was confirmed during the rf design (Section IV B, Fig. 25). One can take advantage of this fact by designing an RFQ with nonuniform V 0 and r 0 , for example by increasing the field amplitude towards the high-energy end of the RFQ, evenly distributing the maximum surface field strength. While this technique has occasionally been used in RFQs featuring standard or sinusoidal electrodes, it seems particularly useful for trapezoidal-electrode RFQs with their highly efficient accelerator sections that still feature comparatively low field enhancement. However, the Carbon-RFQ was realized with constant voltage, mid-cell aperture, and trans-verse radius for simplified rf design and construction.

Cell-by-cell Design
The Carbon-RFQ with trapezoidal vanes was designed using a simple cell-by-cell algorithm respecting the linac synchronism conditions [24]: The cell length is given by where β in and β out denote the velocity of the synchronous particle at cell entrance and cell exit, respectively. The synchronous energy gain upon traversing the cell amounts to The trapezoidal design is a modification of the compact 5 MeV/u RFQ devised using the parmteq codes with standard-vane geometry based on the two-term potential function (Section II A 3, Fig. 6). From this design, the same synchronous phase φ s (z) and modulation m(z) provided the algorithm input. 1 With r 0 and V 0 constant, and k = π/L, the remaining free parameter is the accelerating gap length g. Optimizing the RFQ for maximum acceleration efficiency, g was chosen as small as possible while maintaining a minimum longitudinal curvature radius of L,min = 2 mm. With Eq. (4), g is given by as g/L must not exceed unity. Equations (5), (6), and (7) form a nonlinear system that is easily solved iteratively, converging within a few iterations. The determined output energy W out is then used as input energy W in for the subsequent cell, and the procedure is repeated until the required output energy is reached. Emphasis is placed on the fact that the acceleration efficiency A 1,0 in Eq. (6) is obtained by multidimensional linear interpolation from the precomputed lookup table (Fig. 11b) for a given geometry, avoiding repetitive electrostatic simulation. Using this technique, the vane design required merely a few seconds. Furthermore, an electro-quasistatic field map can be produced rapidly based on the sixteen-term potential function, which allows for particle tracking in a tool of choice to validate the design. Figure 12 shows the beam dynamics parameters of the finalized RFQ with trapezoidal vanes. Instead of the quadrupole term A 0,1 , we depict the effective focusing force

Design Analysis
A comparison between the most relevant parameters of the standard-vane and trapezoidal-vane RFQ is shown in Fig. 13. Additionally, the parameters of a purely sinusoidal design are shown, corresponding to the special case of the trapezoidal geometry where g/L = 1. This allows to assess which differences solely originate in changing from two-term potential cells to sinusoidal cells, and which differences come from introducing the straight vane parts to the sinusoidal cell, i.e. choosing g/L < 1. First, it is important to note that the modulation m of trapezoidal and sinusoidal vanes is higher than that of the standard vane. The reason comes from the definition of the geometrical parameters of the RFQ cell. For the first two cases, the mid-cell aperture amounts to r 0 = a(m + 1)/2, while for standard vanes, which originate directly from the two-term potential function, it is given as r 0 = aX −1/2 [24], where X = I 0 (ka) + I 0 (mka) m 2 I 0 (ka) + I 0 (mka) .
Therefore, in order to keep r 0 and the minimum aperture a equal to the original design, m had to be increased, leading to the difference in Fig. 13. The larger modulation directs more electric field in longitudinal direction, increasing acceleration efficiency A 1,0 (Fig. 13). Consequently, choosing sinusoidal over standard vanes already leads to a shorter RFQ. This is only amplified by reducing the accelerating gap length, such that the trapezoidal vanes allow for reaching the final energy with a shorter-and thus less power consumingcavity. The increased acceleration efficiency comes at the expense of focusing strength B in the accelerator section of the RFQ where the modulation is maximum. The consequence is a non-negligible reduction in transverse phase advance σ 0 [24]. The trapezoidal geometry also changes the distribution of the maximum surface electric field E s,max on the vanes, which results to be lower than for standard vanes despite the smaller longitudinal curvature radius.

C. Particle Tracking Results
The beam dynamics design was validated by means of particle tracking simulation. The input distribution, as expected from the LEBT, was tracked into field maps of both the standard-vane and the trapezoidal-vane RFQ. The tracking was performed using two different codes (Travel [37] and RF-Track [38]) to cross-check the results.

Semi-analytic vs. FEM-based Field Map
Both for the standard-vane and the trapezoidal-vane RFQ, two field maps were used: the first was built using the eight-term or sixteen-term potential function defined in Section II B 2, where the physical vane geometry is not included and the aperture is approximated by a circular aperture with radius r 0 along the entire RFQ. The second map is the result of an FEM electrostatic simulation performed with comsol Multiphysics® [36], and takes the physical vane geometry into account.
In Table III and Fig. 14, the beam distributions resulting from the tracking of 10 000 macroparticles into the four maps are compared. Noticeable for both designs is that the transmission was lower when the comsol FEM map was used instead of the potential map. This can be explained by the different aperture definition in the two cases. From Fig. 14, it can be seen that for the FEM map tracking the halo around the transverse phase space is less spread and defined by a more net line. The reason is found in the transverse acceptance defined by the mid-cell aperture r 0 , being slightly bigger than the one defined by the physical vane geometry, thus allowing transmission of the more exterior particles of the distribution that are cut by the physical vane. This translates directly to a reduced output transverse emittance. Despite these observations, the differences in the transverse plane are smaller than 10 %. In the longitudinal plane, larger discrepancies can be found. Although the potential function is a very good approximation of the axial accelerating field, differences of few percent remain with respect to the comsol FEM map, as indicated in Section II B 2. Additional deviations may originate in the cell-to-cell tapering of the vane profile, that has to be implemented to obtain a smooth electrode surface, but is only approximately considered by the potential function field map. Therefore, the final energy and the longitudinal phase advance are slightly different, as are particle distributions. This effect is more marked for the trapezoidal vanes, where the difference between potential and FEM map is larger than in the case of the standard vane design. However, the discrepancies are small enough, such that the (sixteen-term) potential function remains a highly useful tool for rapidly designing the trapezoidal-vane RFQ. Figure 15 shows the rms beam envelopes of standardvane and trapezoidal-vane RFQ. The corresponding output phase spaces are depicted in Figs. 14b and 14d. As expected, the envelopes are nearly identical in the first 90 cm of the RFQ, and then start to differ. This occurs at the same point in z where the profiles of effective focusing strength B, acceleration efficiency A 1,0 , and consequently of the transverse phase advance σ 0 , for the standard-vane and trapezoidal-vane RFQs start to differ (Fig. 13). As mentioned in Section II A 3, one of the main advantages of the beam dynamics design choices adopted for the compact RFQ-with both standard or trapezoidal vanes-is that all the losses occur at injection energy, preventing activation issues. The particle tracking in the comsol FEM maps allows for recording the actual losses on the vanes. The results are summarized in Fig. 16, where the percentage of lost particles as a function of the particle energy is plotted for both designs. It is noticed that almost the totality of the losses is concentrated in the first bin, which corresponds to the injection energy.

III. SPLITTING INTO TWO CAVITIES
With a length of 475 cm ≈ 12λ, the Carbon-RFQ had to be split into two separate rf cavities to ensure a stable field distribution. Several (eight) independent rf power sources are planned to be used to feed the RFQ. Thus, instead of commonly used coupling cells, the cavities are fully decoupled from the rf perspective, but share vacuum. By this, both cavities may be designed, tuned, commissioned, and maintained separately. Furthermore, field amplitude and phase could be adjusted independently.
Designing the transition required close cooperation between beam dynamics and rf design, namely, choosing the appropriate cavity lengths for dipole detuning (Section III A), and rematching the beam across the intercavity drift (III B). Thus, we discuss it here in a separate section, while remaining aspects of rf design are covered in Section IV.

A. Dipole Detuning by Length Adjustment
In any four-vane RFQ, the frequency separation between the operating TE 210 mode and the closest dipole modes is maximized to increase field stability and robustness against machining errors [24], which is commonly referred to as dipole mode detuning. For both RFQ1 and RFQ2, the detuning was achieved solely by adjusting the cavity length, a novel technique proposed in Ref. [13]. Avoiding the use of any dedicated geometric features, RF power losses were reduced and the machining was simplified.

Transmission Line Model
A transmission line model (TLM) was used to calculate quadrupole and dipole frequencies in order to rapidly estimate the required length. The TLM is shown in Fig. 17, and the equivalent matrix equation reads (10) Here, v(z) is the voltage profile along the RFQ, and models the mode propagation along the RFQ obeying the well-known dispersive wave equation [24,39].
The position-dependent wavenumber k 2 (z) = (ω/c) 2 − k 2 co (z), where k co (z) = 1/[c 2 L (z)C (z)], is obtained from the lumped circuit parameters by simulating thin RFQ slices (Fig. 23, second and third plot). The RFQ was modeled as an inhomogeneous waveguide consisting of many homogeneous slices by multiplying the corresponding matrices. The 3D end geometries were modeled by additional matrices [39] M e = 1 0 describing shunt LC circuits. C e and L e depend on the vane nose and on the shape of the vane undercut window, respectively. L e was chosen such that the ends appear as perfect open-circuit boundaries to the TE 210 operating mode. On all other modes they act as mismatched impedances that perturb frequency and field distribution.
The specific values of C e and L e were determined by 3D eigenmode simulations of short end segments. The eigenmode frequencies are found by (numerically) solving [M RFQ ] 2,1 = 0, i.e. finding the frequencies for which the longitudinal current v (L RFQ ) at the end of the RFQ vanishes for any given voltage v(0).

Resulting Spectra
The TLM was used to estimate the required length of the two RFQ cavities in order to maximize the spectral margin between the operating TE 210 mode and the closest dipole modes. The length of RFQ1 was determined by the plane of splitting, which can be freely positioned at the end of any accelerating cell. The remaining accelerating cells give a preliminary length for RFQ2. We chose to split such that similar lengths, and thus similar rf and mechanical designs arose for both cavities. This positions the TE 210 mode between TE 113 and TE 114 (Fig. 18). As the preliminary length of RFQ2 did not result in an acceptable spectrum, additional accelerating cells were appended to shift the TE 210 mode symmetrically between TE 114 and TE 115 .
Passing on to eigenmode simulations performed in CST Microwave Studio® [40] for an initial 3D model, we noticed that the dipole mode frequencies were slightly lower than those calculated from the TLM. The deviations of the dipole modes closest to the TE 210 mode read approximately 1 MHz for RFQ1 and 2 MHz to 3 MHz for RFQ2. While the relative error in frequency is less than 0.5 %, it corresponds to an error in length of roughly two RFQ cells. Thus, the 3D models were adjusted in a second iteration. Figure 18 shows the spectra of the finalized RFQ1 (a) and RFQ2 (b) cavities. Both 3D simulation and TLM results of the second iteration are depicted. The spectral margins between TE 210 mode and the closest dipole modes approximately read ±8 MHz for RFQ1, which features a length of 235 cm and 597 accelerating cells. In RFQ2, ±11 MHz mode separation was obtained by appending two accelerating cells, increasing its output energy from 5.02 MeV/u to 5.06 MeV/u and its length to 233 cm (129 cells). The quadrupole mode margin (distance between TE 210 and TE 211 ) amounts to 2.7 MHz in both cavities.

B. Beam Rematching across the Drift
A drift of 4 cm between the output matching plane of RFQ1 and the input matching plane of RFQ2 is required. The drift length not only arose from mechanical considerations [41], but also ensures that the field coupling through the bead-pull holes in the adjacent end- plates is negligibly small. This length corresponds to 1.35βλ for the synchronous energy of 2.56 MeV/u at the end of RFQ1. The drift breaks the periodicity of the time-dependent focusing lattice provided by the RF electric quadrupole field. Without any corrections, i.e., ending RFQ1 with a fringe field region (FF) directly after the last accelerating cell, and entering RFQ2 via a radial matcher (RM) [24,42], the beam would be mismatched in RFQ2 (Fig. 21). This would result in strong transverse oscillations, phase space filamentation, and particle losses at high energies (Fig. 21, dotted lines).
In Ref. [43], Crandall introduced the RFQ transition cell (TC) to smoothly connect an acceleration cell with high modulation (m > 1) to a zero-modulation cell (m = 1), which from hereon we refer to as quadrupole cell. While the transition cell is commonly used to remove uncertainty in the output energy of an RFQ [24], Crandall pointed out its applicability to divide one long RFQ into two shorter ones. By choosing the length of the quadrupole cell (QC1) after the transition cell, the designer can control the output transverse phase space ellipses at the end of RFQ1. Similarly, RFQ2 starts with an RM much shorter than βλ/2, followed by another quadrupole cell (QC2), followed by a transition cell Potential Φ (kV) FIG. 19. Field map of the lattice used to transfer the beam from the last accelerating cell of RFQ1 to the first accelerating cell of RFQ2. After the transition cells (TC), the vanes are extended by the quadrupole cells QC1 and QC2, whose lengths is chosen such that the envelope oscillation in RFQ2 is minimal.
from m = 1 to the previous high modulation, followed by the first accelerating cell of RFQ2 [43]. Figure 19 shows an electrostatic field map computed in comsol Multi-physics® [36] of the described lattice.
As RFQ1 and RFQ2 are independent cavities, their RF phases can in principle be chosen arbitrarily. However, the offset is effectively fixed by the longitudinal synchronism requirements: ∆φ = ∆z/(βλ), where ∆z is the distance between the end of the last accelerating cell of RFQ1 and the start of the first accelerating cell in RFQ2.

Analytic Estimate
The two degrees of freedom for the rematching are the lengths of the two quadrupole cells, L Q1 and L Q2 . As an analytic estimate, we considered entering the drift with a symmetric beam, i.e. upright transverse ellipses (α = 0). In an ideal RFQ, the beam will be in this configuration at φ = 0, ±180°, when the electric field is maximum. The phase at the end of the last accelerating cell of RFQ1 is φ s + 90°. The required phase advance between this point and the end of the quadrupole cell, where we want φ = 180°, thus reads 90°− φ s . The corresponding length is divided into the transition cell of length L T and the quadrupole cell of length L Q1 . Both feature a focusing strength B(m = 1) = 2.12 [Eq. 8] that is significantly stronger than the B(at cut) = 1.77 of the surrounding accelerating cells featuring high modulation (Fig. 12). We take this into account by introducing a simple scaling factor, ignoring the time-dependence of the focusing. The approximate length of the RFQ1 exit quadrupole cell is thus given by By similar reasoning, we obtain for the RFQ2 entrance quadrupole cell. These formulas ignore the focusing effect of the short fringe field region and radial matcher at the end of the vanes. The final values for L Q1 and L Q2 were determined by numerical optimization by means of semi-analytic field maps generated from the sixteen-term potential function and the tracking code RF-Track [38]. The goal was to minimize the maximum transverse rms beam envelopes σ x,max = max z∈RFQ2 σ x (z), σ y,max = max z∈RFQ2 σ y (z) (15) in RFQ2. Figure 20 shows a parametric scan of these quantities as functions of the quadrupole cell lengths. Minimizing the expression σ x,max + σ y,max + |σ x,max − σ y,max |

Numerical Optimization
delivers the numerical optimum. It differs from the analytic estimate by less than 1 mm ≈ 0.03βλ. The plots highlight that the two individual minima for each transverse envelope are offset against each other, corresponding to solutions with asymmetric beams. The combined optimum is a compromise between the two. In expression (16), the third term ensures that the beam is as symmetric as possible.  Figure 21 shows the beam envelopes in both Carbon-RFQ cavities before and after the rematch. The dotted lines show that without any corrections, the beta beating in RFQ2 (z > 235 cm) would be unacceptably strong, leading to large beam losses. With the optimum determined above, the transverse envelope beating of the original design (Fig. 15) was almost completely recovered and high-energy particle losses are avoided.

IV. RF DESIGN
Both methodology and choices of the rf design of the four-vane Carbon-RFQ were adapted from the HF-RFQ [7][8][9][10][11] and PIXE-RFQ [9,[12][13][14]-the obvious exception being the novel dipole mode detuning discussed in Section III A. Here, we summarize the remaining rf design considerations, including cavity geometry (Section IV A), maximum surface electric field (Section IV B), auxiliaries and power couplers (IV C), and thermal simulations (IV D).

A. Cavity Geometry
While the circular quadrant represents the optimum shape for the four-vane cavity in terms of rf losses [24], it is not feasible to construct in practice. Several restrictions apply, which are shown in Fig. 22 (red): The vane tips are of finite thickness and fixed by the beam dynamics design. For mechanical stability and cooling purposes, the vanes itself must be significantly wider than their tips. Between water cooling channels and vacuum domain, at least 4 mm of bulk copper are kept to avoid leakage [41]. The back wall is wide enough such that the auxiliary port apertures intersect solely with a pla-nar surface, hence b c = (c c + 19 mm)/ √ 2 for the cavity parameters in Fig. 22. By simulating individual RFQ cells in Ansys HFSS® [44], an optimum cavity dimension c c was obtained as a function of the longitudinal coordinate z. These simulations furthermore delivered the quadrupole and dipole capacitance C , the dipole cutoff frequency f co , and the 2D quality factorQ 0 , which are shown in Fig. 23. They were used to construct the transmission line (Section III A, Fig. 17), and for the power loss calculation (Section IV C). Each of the two Carbon-RFQ cavities consists of four individually brazed modules (Fig. 1). The lengths of the copper pieces were chosen such that the inter-module gaps are placed in the center of an RFQ cell, and less than 60 cm to facilitate machining [41]. The optimum c c with respect to f 0 = 750 MHz and maximum Q 0 was obtained by averaging the ideal c c (z)-function (Fig. 23, upper plot) over each of the eight modules, such that module-wise constant cross sections were obtained. The cavity cross section and its magnetic field is shown in Fig. 24b.

B. Surface Electric Fields
High surface electric fields may lead to electron emission and sparking, culminating in rf breakdown. Thus, the maximum peak surface electric field E s,max is an important quantity to consider, and a major performance limit for any linac [24].
The 2D cross section simulation, which assumes vane geometry without modulation, delivered an initial E s,max = 46.5 MV/m for a given V 0 = 50 kV. This value is only an approximation of the actual maximum field driven by the 3D vane modulation, and in particular small geometric features at the inter-module gaps. Simulation for the PIXE-RFQ have shown that the 3D value can be up to 20 % higher than the 2D estimate [13].
Taking the vane modulation into account, a value of 50.5 MV/m was obtained, located in the bunching section of the RFQ (Fig. 25a). One advantage of the trapezoidal vane is the reduced surface field in high-modulation cells in the accelerating section of the RFQ. Although being driven by the sinusoidal step in the center of the cell (Figs. 8b, 9, 25b), the E s,max is 7 % lower compared to a standard cell with otherwise same parameters (Fig. 13). However, the overall bottleneck-neglecting any laterintroduced gaps-remains in the short high-modulation cells in the bunching section (Fig. 25a).
The subdivision of the RFQ into modules introduced gaps into the vane geometry. The gaps are placed in the center of a cell, minimizing effects on the beam. In both RFQ1 and RFQ2, three gaps are present each, which determine the overall maximum electric field due to the small rounding radius. The field at the gap is shown in Fig. 25 for a bunching-section cell (c) and an accelerator-section cell (d). The E s,max reads 57.5 MV/m, independent of the particular cell. Even though this value exceeds the initially targeted 50.6 MV/m by 14 %, we are confident in the rf breakdown resistance of the Carbon-RFQ, as the recently commissioned HF-RFQ features the same inter-module gap geometry at an even higher voltage.

C. Auxiliaries and Power Couplers
Each cavity features 32 slug tuners, twelve vacuum pumping ports, and four input power couplers. Additional eight flanges are foreseen for pick-up antenna installation. The auxiliary geometries were optimized for minimum surface losses, and their penetrations into the cavity are adjusted to not perturb the operating mode resonant frequency. Figure 26 shows the surface magnetic field H t proportional to the surface current density on the tips of tuner (a), vacuum pumping port (b), and power coupler (c).

Tuning System
The tuning system consists of 32 copper slug tuners for the 240 cm = 6λ long RFQ cavities, corresponding to 1.3 tuners/λ/quadrant. Although 6λ is considered close to the limit of field stabilization using only piston tuners, we are confident in the capabilities of this tuning system considering the available spectral margins (Fig. 18). The slightly shorter (5λ) HF-RFQ has been successfully tuned with this configuration [10]. Each slug features a movement range of ±11 mm with respect to nominal, such that the available frequency tuning range amounts to ±11 MHz. Because of the more inhomogenous capacitance profile (Fig. 23), we expect the tuning of RFQ1 to be more challenging, as the field is more tilted when the tuners are in nominal position. However, the necessary corrections are well within the piston movement range.

RFQ Power and Couplers
The power loss of both RFQ cavities was calculated by means of the method presented in Ref. [13], which has been shown to agree with a full 3D eigenmode computation up to an error of ≈ 1 %. Each RFQ was considered as a concatenation of segments that coincide with the ports of tuners, pumping ports, couplers, and ends. 2 The nth segment contributes an rf power loss of P n = ω 0 W n /Q 0,n , where the stored energy W n is obtained by integrating the capacitance profile (Fig. 23, second plot). Q 0,n was calculated both from the contribution of the vane modulation (Fig. 23, bottom plot), and from 3D eigenmode computation of individual segments. The obtained rf quantities are summarized in Table IV.
Each cavity will be supplied by four magnetic loop couplers. While each coupler is strongly under-coupled individually, combined they are over-coupled by a margin of 30 % (β c = Q 0 /Q ex = 1.32 and 1.35, respectively). The couplers will be mounted on rotatable flanges, allowing to fine-tune the coupling with the help of rf measurements after assembly. In the case of critical coupling (β c = 1), each coupler supplies a (peak) power of 60 kW. Highpower tests with the HF-RFQ have demonstrated that the coupler can transmit up to 100 kW. More details on coupler geometry and vacuum window are found in Ref. [13]. During operation, rf losses act as a heat source on the copper structure. The resulting temperature increase causes deformation of the cavity and detuning of the resonant frequency. Thermal and structural simulations were conducted using comsol Multiphysics® [36] to study this behavior and determine cooling system requirements.
Because of the low duty cycle of d = T pls f rep = 0.1 %, the cooling system must dissipate only 240 W per RFQ. It rather serves for frequency stabilization. In Fig. 27, the frequency shift ∆f is shown as a function of the duty cycle d and the cooling water temperature T w . The average water speed in the cooling channels amounts to 1 m/s, corresponding to a convection coefficient of 3900 W/m 2 /K. Two configurations are compared: a design with two channels per vane, used by the HF-RFQ and the PIXE-RFQ [12,13], and a new design with only one channel per vane. The plot highlights that the difference between the two options is only marginal, such that the mechanically simpler design with one channel per vane is selected. Figure 27 visualizes the available frequency tuning range for a given water temperature range: ∂f /T w = 15.3 kHz/K. Furthermore, the frequency is a linearly decreasing function of the duty cycle with ∂f /∂d = −151 kHz/%. Thus, to recover the design resonance frequency at nominal operation, the cooling water temperature must be reduced by approximately 1 K ( in Fig. 27). Figure 28 shows the distributions of copper temperature T (a) and the deformation field u (b) in the 2D cross section for this point of operation. Because of the temperature gradient in the vane, the vane tips move closer towards each other, increasing the capacitance C and thus lowering the frequency with increasing duty cycle. This is compensated for by decreasing cavity temperature and thus volume, hereby lowering the inductance L, such that with ∂f /f = −(∂L/L + ∂C/C)/2 the design resonant frequency is restored.   Fig. 27).

V. CONCLUSION AND OUTLOOK
A 750 MHz RFQ with trapezoidal vanes for fully stripped carbon ions was designed at CERN, to be integrated as part of a carbon ion therapy facility. It represents the first rf accelerating structure of the recently proposed "bent linac." All of its components were optimized to match the requirements of compactness, low power consumption, and simplification of construction in view of industrialization.
Considering both high-transmission and compact options, as well as different output energies, a compact RFQ with standard two-term potential vanes was designed, which accelerates particles with a charge-to-mass ratio of 1/2 to 5 MeV/u. In this configuration, particle losses at energies higher than a few 10 keV were minimized.
The standard-vane RFQ was then redesigned to feature trapezoidal vanes, reducing power consumption and length by 15 %. A novel semi-analytic technique using sixteen terms of the multipole potential function was used to determine the vane shape in a cell-by-cell manner. The beam dynamics design was validated by particle tracking simulation with both semi-analytic and FEM-based field maps. These simulation showed that the augmented potential function can describe both longitudinal and transverse beam dynamics in close agreement with an FEM simulation of the real vane geometry, and thus provides a highly useful tool for rapidly designing RFQs with trapezoidal vanes.
The rf design of the Carbon-RFQ has been completed, focusing on minimized power loss and simplified construction. The geometries of cavity, auxiliaries, and power couplers were determined. A major feature is the subdivision into two fully decoupled rf cavities. The rematching of the beam across the drift was accomplished by two quadrupole vane extensions, which were optimized for minimum beam envelope oscillations. The length of each of the two RFQ cavities was used as a manner of dipole mode detuning. By means of this novel method, maximum spectral margins were achieved without the use of any other dedicated detuning technique. The rf design was validated by accurately simulating the maximum electric field on the most critical surfaces, as well as thermal simulations.
In the framework of a collaboration between CERN and CIEMAT (Centro de Investigaciones Energéticas, Medioambientales y Tecnológicas), the Carbon-RFQ will be built as part of a demonstrator of the low-energy part of linacs for carbon ion therapy. The demonstrator will be composed of a copy of the TwinEBIS source, a LEBT, the Carbon-RFQ, and some further structure (studies presently ongoing for the choice of the accelerating structure following the RFQ). It has the purpose of validating the beam quality at the end of the low energy section, which is often the most critical part of hadron linacs, defining the beam characteristics that are then propagated along the whole accelerator. advice related to the mechanical dimensioning of the design.
V.B. and H.W.P. share the primary authorship. V.B. conceived general design parameters the beam dynamics design of the standard-vane RFQ. Trapezoidal design and beam matching over the inter-cavity gap are the result of the joint efforts of V.B. and H.W.P., being the part where beam dynamics and rf design are interlaced the most. H.W.P. developed the semi-analytic field description for the trapezoidal vanes, and performed rf design and dipole mode detuning of the RFQ cavities. A.G. and A.M.L. supervised the findings of this work. All authors discussed the results and helped shape the final manuscript.