Negative ion beam space charge compensation by residual gas

The space charge of intense unbunched ion beams can be compensated by the ions created when the beam ionizes the residual gas, which creates a source of secondary particles inside the beam pipe. For negative ion beams, the effect of the beam electric field is to expel the electrons to the beam pipe walls, while the positive ions are trapped and start to be accumulated. In this paper, we report on experiments to study this space charge compensation (SCC) in a 45 keV H− unbunched beam in the CERN Linac4 low-energy beam transport. Beam size and emittance were measured for different gases injected into the beam region to control the degree and speed of the SCC. These results are compared with beam simulations that include the generation and tracking of secondary ions leading to a unique understanding of the transport of the ion beam in some specific cases.


I. INTRODUCTION
Beam space charge compensation (SCC) is crucial to overcome the transports limits of high intensity ion beams in the low-energy beam transport (LEBT) region of particle accelerators.
For negative ion beams, the SCC occurs when the positive secondary particles created by the ionization of the residual gas by the beam are trapped by the beam potential, leading to a decrease of the local charge density and therefore the electric field inside the beam.
The SCC characteristic time (τ) corresponds to the time required for the SCC process to reach a steady state and is inversely proportional to the residual gas pressure. During the time t < τ, SCC is not constant, which leads to a variation in the beam transport properties [1]. The degree to which the space charge is compensated in the steady state depends on the loss mechanism of the secondary particles from the beam potential well. CERN's Linac4 [2] has a beam pulse length comparable to τ, and therefore it is necessary to understand the beam dynamics during and after the SCC buildup to improve the matching to the next accelerator stages.
Measurements of negative ion beams show how the beam is not fully neutralized after the compensation time [3], and it is necessary to understand the neutralization level in the Linac4 LEBT to improve the matching of the next acceleration section.
This work presents the results of an extensive campaign of measurements and simulation of the H − beam at CERN's Linac4 installations, using a time-resolved slit and grid emittance meter [4] to measure the beam properties. The beam line contains externally applied electric and magnetic fields necessary to transport the beam from a source to a radio frequency quadrupole accelerator. In addition, there is the possibility to inject different gases into the transport region, to control the secondary ion generation.

II. SPACE CHARGE COMPENSATION OF A PULSED H − BEAM
The secondary ion production is determined by the residual gas density (n g ) and the cross section for residual gas ionization by primary ions [σðEÞ], which is a function of the primary ion kinetic energy E.
These parameters are combined to give the mean free path for a beam ion to produce a secondary [Eq. (1)] and divided by the beam velocity (v b ) to give the time required to have an equal density of primary ions to secondary ions (assuming none are lost) in Eq. (2), also known as the compensation time: For the Linac4 LEBT, the required time to accumulate sufficient secondary ions at the baseline pressure of 5 × 10 −7 mbar of H 2 is comparable to the 400 μs beam pulse length. When different gases are injected to compensate the beam, the compensation times are determined by the sum of all gases present, as given in Eq. (3), where n H 2 and n x are the residual gas densities of H 2 and other gas, respectively, and σ H 2 ðEÞ and σ x ðEÞ are the respective cross sections [5]: The SCC degree (η) is defined in Eq. (4) as the ratio of the potential in the center of the compensated beam (ϕ B ) to the equivalent potential created by an uncompensated beam following the same trajectory (ϕ NC ). Both ϕ B and ϕ NC can be calculated from simulations, whereas from measurements only ϕ B can be measured using the four grid analyzer technique [6]: The condition η < 1 is fulfilled below the critical pressure P m0 defined by the residual gas density n o [Eq. (5)] [3], where v i is the average secondary ion speed and r b is the beam radius. Above the critical pressure, overcompensation can occur (η ≥ 1) where the secondary ion density is higher than the beam density: When the SCC reaches a steady state, the loss rate for the secondary ions is equal to the production rate per unit volume ( _ n) [3], defined in Eq. (6), where n b is the beam density: For negative hydrogen beams, the electrons created by the ionization process do not contribute to the overall SCC, because they are quickly expelled to the walls by the beam potential (in approximately 1 × 10 −7 s [7] for a 1 V potential difference).
The effect of space charge compensation on the beam transport can be included into the cylindrically symmetric envelope equation [Eq. (7)]. For the beam outer radius r, with current I b , traveling in the z direction, in a focal channel where k 2 0 is the focal lens strength and ϵ 2 =r 3 is the beam emittance term, the space charge repulsion is determined by the perveance K 0 and is reduced by a factor 1 − f e ðtÞ due to space charge compensation: where the current I 0 is defined by 4πϵ 0 m b c 3 =q b with ϵ 0 the vacuum permittivity, m b the beam ion mass, q b the beam ion charge, and c the speed of light. The beam variation of SCC leads to a time dependence of the final envelope in the focal channel. We can estimate the beam properties in this regime by taking into account this time dependence with a linear fit to f e ðtÞ described in Eq. (9): where for t < τ Eq. (7) becomes leading to a solution of the beam radius that is dependent on time. It is possible to get good approximations using numerical solutions to Eq. (10); however, such a simple model neglects many important aspects, like the nonlinear distribution of the SCC within the beam region in both space and time and the final space charge compensation factor being an input to the model.

III. EXPERIMENTAL SETUP
Beam measurements were performed at the Linac4 source test stand, where the H − beam was provided by a 2 MHz rf ion source enhanced with cesium to improve the negative ion surface production. It delivered a 35 mA H − beam at 45 keV, with 600 μs beam pulses spaced by 1.2 s [8].
The transport system ( Fig. 1) used for the experiments consists of a multistage 45 kV extraction system, one solenoid with a nominal focusing strength of 9 T 2 mm and total length of 304 mm, and horizontal and vertical trajectory correction magnets. Beam properties are measured using a Faraday cup for beam current, grid profile measurement for beam sizes, and a slit-grid emittance meter [4] for the beam phase space. The beam signals from these instruments are sampled with a resolution of 6 μs , allowing the measurements of intensity and phase space to be made as a function of time.
The emittance meter slit is grounded to suppress the secondary electrons generated when the beam hits the slit, forcing the secondary electrons to come back immediately to the slit and not disturb the beam.
The gas injection into the ion source, necessary to generate the plasma, leads to a H 2 baseline pressure of 5 × 10 −7 mbar in the LEBT. The LEBT gas density can be independently adjusted with a continuous gas injection system, which also allows a different type of gas to be injected for space charge compensation.
The gas injection into the ion source is pulsed, and, as the beam is produced quickly after this injection, the gas has not propagated to the LEBT, so the residual baseline pressure in the LEBT is actually formed by the gas left from the previous pulse.
Three gases were injected into the LEBT in separate tests: krypton, nitrogen (N 2 ), and hydrogen (H 2 ). H 2 is the same gas used in the source, N 2 is safe and easy to pump, and Kr is a noble gas with a high mass and ionization cross section compared to H 2 [5], which has been preferred for space charge compensation in other laboratories [9]. The injection of these gases generates a residual gas mixture of H 2 plus the injected gas.
The low vacuum conductivity between the LEBT and source means that only a negligible fraction of the injected gas reaches the ion source and hence should not affect its properties; however, the long term performance of the cesium-enhanced source with these added gases is still to be investigated.

IV. SIMULATIONS
The simple model for beam transport with space charge compensation presented in Sec. II cannot reproduce or predict with great accuracy the beam measurement results due to the missing effects of a strongly nonuniform beam and the simple linear compensation model (whereby the space charge electric field is reduced by a constant fraction in the radial direction called the net current model). To further improve the accuracy, we choose the code Ion Beam Simulator (IBSimu) [10], which is a suite of calculation libraries for low-energy particle tracking in electric and magnetic fields with space charge, is valid for unbunched beams, and has already been used to simulate the extraction system of the ion source [11].
For high space charge beams simulations, IBSimu calculates the potential distribution by solving the Laplace equation (∇ 2 ϕ ¼ 0) on a mesh including the boundary conditions given by biased electrodes and the beam pipe. Charged particles are tracked through this potential field, as well as any magnetic field, and their space charge used to find the potential distribution by solving the Poisson equation. The starting conditions for the primary charged particles can be taken from a preceding simulation. This process is repeated iteratively until the result converges to a self-consistent solution.
For the Linac4 LEBT solenoid magnetic field, the code OPERA-3D from Vector Fields [12] was used to generate the field map and imported into IBSimu, where the field map is set to zero once the magnetic flux density is less than 0.7 mT.
The IBSimu results for the full space charge regime have been cross-checked with the code Travel [13] for the Linac4 LEBT (which tracks bunches of particles through electric and magnetic fields and includes the space charge interaction between the particles).
The interaction between the beam and the secondary ions ( Fig. 2) created by the beam collision with the background gas along the trajectories of the beam is added to the model via their additional space charge contribution (we call this model the beam plasma model).
Starting from the solution of the full intensity net current model, we calculate the SCC effect in four steps.
1. Track the beam through the electric and magnetic fields from the last potential solution, and the space charge density distribution ρ b is calculated.
2. Use a Monte Carlo generator to create the secondary ions along the trajectories of the primary beam randomly but taking into account the mean free path of the beam with the residual gas. The mean free path calculation includes both residual H 2 and the injected gas.
3. Track the secondaries through the electric and magnetic field of the last solution for the time Δt track and 4. Create a new electric potential by solving ∇ 2 ϕ ¼ −ðρ s þ ρ b Þ=ϵ 0 and return to step 1 until the total beam pulsed length has been simulated by the number of iterations times the secondary tracking time.
A constant density of the gas inside the beam pipe has been considered, any scattering and stripping of the beam has been neglected, and the initial energy of the secondary ions (less than 1 eV) is given in a random direction for the ions.
Because there are no ionization cross section data available for H − with residual gases, we use instead the ionization cross section for H þ with residual gases [5].
Multiple time steps must be considered for the simulation, and they are listed below from the shortest to longest time. Charged particle tracking through a constant magnetic and electric field distribution is handled internally by IBSimu, where the shortest equivalent time step is dominated by the cyclotron frequency inside a magnetic field, which is approximately 10 −7 s for slow H 2 ions in the LEBT maximum integrated solenoid magnetic field strength(24 T 2 mm), or to maintain an accurate response to the spatial variation of the fields by evaluating them approximately once per mesh (10 −10 s for the H − primary ions).
If the charged particles are trapped, their tracking is stopped after a time limit is reached. This time limit Δt ite ¼ 1 μs is chosen to be shorter than the shortest compensation time for all the cases studied in this work. This also means the electromagnetic field distribution is considered to be constant over this time scale. Iterations of the space charge calculation are then continued until a steady state is reached or until the beam pulse length is reached (500 μs).
After some tests, it was found that, as long as Δt ite is below 10 μs, the solutions converged to a steady solution.
In a typical simulation we use 7 × 10 4 beam particles, the number of secondary ions tracked can reach 3 × 10 6 , and a cubic mesh size of 0.5 mm was used.

V. TRANSPORT SYSTEM WITH SCC
Full beam transport simulations with secondary particles show that significant emittance growth can already be attributed to the nonuniform space charge compensation in a simple drift space [7]. In the following example, a 35 mA H − Gaussian beam of σ ¼ 12 mm (1 rms) at 45 keV with 0.2 mm mrad normalized rms emittance, in a 0.7 m drift space, is transported through a region with a residual gas pressure of 2 × 10 −6 mbar H 2 . The boundary conditions are ϕðz ¼ 0Þ ¼ þ100 V (simulating the beam emerging from an ion extraction region), ϕðz ¼ 0.7 mÞ ¼ 0, and the beam pipe ϕðr ¼ 0.05 mÞ ¼ 0. Figure 3 shows the beam and the secondary ion distributions, when the SCC has reached a steady state; the secondary ions follow the beam Gaussian distribution except in the regions close to the boundaries.
The time evolution of the normalized emittance value and beam size at the end of the drift (Fig. 4) shows a dramatic variation during the SCC buildup, which finally converges to a steady value. If we compare the emittance value in the steady state with the emittance at the start of the drift, the emittance growth is 30%, and, by using the standard method of net current SCC where η ¼ 80% gives us the closest results between simulation and measurements in the LEBT measurements, the emittance growth is less than 1%. Figure 5 shows a clear difference in the two phase spaces due to the nonlinearity of the space charge created by the secondary ions.
Adding the solenoid magnetic field generates an emittance growth of 50% using secondary particles and 10% with the net current space charge method. To explain the differences between the two methods of simulation of the SCC on the beam transport, it is necessary to understand the behavior of the secondary ions.

A. Secondary ion dynamics
Secondary ions are created with an initial energy that is negligible in comparison to the potential at the center of the beam ϕ B at t ¼ 0 (i.e., E i ≪ qϕ B ). SCC simulations show how the beam potential initially captures the ions at a constant rate (Fig. 6) during the SCC buildup, until a saturation level is reached and the steady state is achieved. This linear accumulation of secondaries during the first 50 μs agrees with the hypothesis that τ ≫ electron lifetime and only positive ions will stay in the system. To know how this linear evolution takes place, it is necessary to understand the secondary ion dynamics, and the analysis will be divided into two components.

B. Radial dynamics
The grounded beam pipe and the negative beam potential trap the ions in the system. The ions must fulfil the condition E i > q½ϕ B ðrÞ − ϕ B ðRÞ to reach the vacuum pipe at radius R. For t ≪ τ, only some ions created in the beam edges are able to escape, whereas the ions created at the radius r that do not fulfil this condition will oscillate around the beam center until the SCC reduces the potential sufficiently to allow the ions to escape radially.
During the SCC buildup, the beam potential distribution leads to the highest secondary ion concentration at the beam center, meaning the space charge is not compensated uniformly across the beam volume in this period. Figure 7 shows the sum of the beam and secondary ion space charge at a time during the buildup of SCC; this hollow density is the cause of the emittance growth in the first 60 μs in Fig. 4.
Once the secondary ions reduce the potential sufficiently (and therefore the electric field), ions oscillate around the beam center at an increased amplitude, spreading the secondary ion density across more of the beam (Fig. 8). Because of their lower velocity at the edges of the beam, the secondary ions increase their contribution to the compensation charge density, and the total space charge can become inverted in this region (this does not create a positive potential, because the total space charge is still negative). This creates a nonlinear electric field that can increase the emittance of the transported beam during the steady state, in comparison to the net current model where the space charge map is smooth.

C. Longitudinal dynamic and ion losses
Studies that take into account only the radial dynamics of the SCC [7] (equivalent to assuming a constant longitudinal potential) show that the secondary ions will fully suppress the beam space charge and the final potential in the steady state will be almost equal to the initial energy of newly ionized secondary ions. The results of our simulations show how the space charge and the beam potential at t > τ still differ from zero in large part of the beam volume, as seen in Figs. 9 and 10(d).
In the simple test case, ions are trapped in the longitudinal direction by the potential formed by the beam and Once the number of secondary particles in the system suppresses a large fraction of the beam space charge, local variations in the density of secondary ions can lead to plasmalike waves that can propagate in the longitudinal direction. Secondary ions that move at the same phase velocity as the wave can gain sufficient energy to leave the beam potential and reach the grounded plate at the end of the beam line (either the emittance meter input plate or the radiofrequency quadrupole input flange) and be lost. This effect is more pronounced longitudinally in comparison to the radial coordinates due to the longer distance over which the electric field of the wave can act. In the pressure regime p < p mo , the voltage amplitude of this plasma oscillation wave is of several volts [14] and leads to longitudinal losses that prevent the system from reaching a full degree of space charge compensation. In terms of the number of secondary ions, the longitudinal losses will limit the final number of ions that the system can trap once _ n production ¼ _ n losses (Fig. 11).
When the solenoid field map is included in the simulations, the magnetic field reduces the radial movement of the secondary ions, and the solenoid fringe field acts like a mirror magnet in the longitudinal direction, reflecting some secondary ions, but there is no appreciable difference in the final number of secondary ions accumulated after the SCC buildup.

A. Input beam Linac4 and full space charge solution
During measurements at the Linac4 test stand, the source and extraction system delivered a 35 mA H − beam into the LEBT. The extraction of the beam from the source was simulated with IBSimu, and the results served as the input distribution for these SCC simulations. Although performed with the same code, the two regions are not coupled into one single simulation due to the smaller mesh size required in the source extraction calculation (IBSimu uses a fixed size, cubic mesh). The beam handover takes place in a plane inside the Linac4 source extraction system where the electric potential (13000 V) suppresses the SCC by rapid removal of secondary particles.
The handover beam parameters are given in Table I and the X − Y profile in Fig. 12; the asymmetry in the vertical plane arise from the stage where the electrons are dumped using a magnetic field inside the extraction system. It has been found to be crucial to have an accurate beam input distribution to be able to correctly interpret beam measurements and compare the SCC degree. Figure 13 shows the key features of the simulation region. The total length considered is 1.39 m with the emittance meter slit at z ¼ 1.39 m and a beam pipe radius of 0.05 m, and the solenoid field map covers the first 0.57 m in z. The beam density is plotted in this transport region for a 35 mA beam without space charge compensation included, where the solenoid focuses the H − beam enough to prevent beam losses.

B. Beam dynamics in the steady state t > τ
The results of the emittance measurements at the time t > τ at the emittance meter position for different injected gas types and pressures using an integrated solenoid field strength of 9 T 2 mm will be compared to the simulations of the SCC using the secondary ions. The emittances have been calculated by integrating the signals over a time period of 200 μs, starting 300 μs after the first observed beam from the source and using the 0.4% threshold from the FIG. 11. A number of macro secondary ions captured in the system for different gas pressures. maximum recorded signal, where all the signals below the threshold are set to zero. The measurements show a constant emittance for different pressures and types of residual gas within an error of 5% from the phase space measurements. However, simulations show an emittance reduction as the pressure is increased (see Fig. 14). When increasing the pressure that approaches the 100% SCC case using Kr and N 2 , instead of H 2 , this emittance reduction is the product of the more uniform SCC with nitrogen and Kr, thanks to the lower secondary ion speed compared to H 2 .
The agreement between the phase space of the simulation and experiment can be seen by the unusual features that can be created in the beam phase space in some cases. By increasing the H 2 pressure to 1 × 10 −6 mbar above the baseline, we can see the appearance of two distinct components in the transverse phase space when the beam is strongly focused (Fig. 15).
Simulation shows how this second component only appears in the H 2 steady state case because of the nonuniform SCC along the LEBT coupled to the beam waist before the emittance meter. N 2 and Kr do not show this effect, because their larger ion masses help to create a more constant radial and longitudinal SCC distribution.
By increasing the pressure or using a Kr or nitrogen to compensate the gas, this second component in the phase space is less distinct (Fig. 16).
The values for simulated and measured beam sizes as a function of pressure [15] and gas type is shown in Fig. 17. These show good agreement for each pressure and type of gas, where the beam size depends of the type of gas and pressure; for pressures below 5 × 10 −6 mbar, Kr and nitrogen lead to a smaller beam size than hydrogen due to a higher degree of compensation reached with less pressure.
For Kr and nitrogen, the beam size no longer varies for pressures above 2 × 10 −6 mbar; for H 2 , variation continues up to 1 × 10 −5 mbar.
Comparing the results with the net current SCC method simulations, the dotted lines show that all the recorded beam sizes are between the net current SCC at 80% and 100%.
The beam size recorded in the emittance meter is associated with the compensation degree ηðzÞ achieved along the line in Fig. 18, which shows that η is approximated 70% for the H 2 baseline pressure, and for 1.1 × 10 −5 mbar H 2 the average compensation degree is 90%, while for Kr it is only necessary to inject 2.2 × 10 −6 mbar to reach nearly full compensation.

C. Beam dynamics in t < τ
The beam parameters vary considerably during the space charge buildup to a steady state. Measurements of the beam sizes and simulations at the emittance meter position (Fig. 19) show how for the baseline pressure it takes more than 200 μs to the beam size to reach the steady state. Increasing the pressure reduces the time required to reach the steady state and the value of the final beam size reported in Fig. 17.
The simulations show a fair agreement of the beam size as a function of time during this regime (Fig. 19), even when the rise of the beam current from the source and some uncertainties in the stabilization of the extraction system electrodes voltages were not taken into account.

D. Stabilization time
One of the main goals of the campaign of measurements was also to investigate when the SCC stabilizes quickly with respect to the beam pulse, to limit losses in the beam pulse head. An estimate of the compensation time is taken by fitting an exponential function to the beam size recorded at the emittance meter as a function of time from Fig. 19 and defining the stabilization time as τ decay through σðtÞ ¼ σ 0 e ð−t=τ decay Þ , where the compensation time τ ≈ 2 · τ decay .
Our desired stabilization time is 25 μs, so that full stable conditions are found after approximately 50 μs. Using this method, we compare the pressures required to achieve a stabilization time τ decay ¼ 25 μs, as a function of the different gases. A comparison of this measured stabilization time for different gases and pressures is shown in Fig. 20.

VII. CONCLUSIONS
Measurements and simulations have been made of the transport of a 35 mA H − ion beam at 45 keV during and after the space charge compensation buildup, by the injection of three different gases as the source of secondary ions.
The simulations reproduce very well the beam size measured with the emittance meter, as well as many fine details of the phase space, which do not appear in the net current model.
Below a critical pressure depending on the gas type (10 −5 mbar for H 2 ), the final compensation degree and therefore the beam size after the SCC buildup show a pressure dependence.
The simulations results and Ref. [14] suggest that full space charge compensation is not reached at lower pressures due to plasmalike waves that accelerate the secondary ions, creating a secondary ion escape mechanism from the beam potential confinement.
Simulations predict a reduction in emittance for higher gas injection, whereas the measurements show no significant improvement in the emittance, and the effect of the gas type is limited to its ionization cross section to enhance the secondary ion production with lower pressures in the beam line.
In the case of simulations, there is an emittance reduction for Kr and N 2 that converge to the 0 beam current case. This emittance reduction arises from the more homogeneous SCC created for the slower ion speed of Kr and N 2 in comparison to H 2 .