Hydrogenic fast-ion diagnostic using Balmer-alpha light

Hydrogenic fast-ion populations are common in toroidal magnetic fusion devices, especially in devices with neutral beam injection. As the fast ions orbit around the device and pass through a neutral beam, some fast ions neutralize and emit Balmer-alpha light. The intensity of this emission is weak compared with the signals from the injected neutrals, the warm (halo) neutrals and the cold edge neutrals, but, for a favourable viewing geometry, the emission is Doppler shifted away from these bright interfering signals. Signals from fast ions are detected in the DIII-D tokamak. When the electron density exceeds ∼7 × 1019 m−3, visible bremsstrahlung obscures the fast-ion signal. The intrinsic spatial resolution of the diagnostic is ∼5 cm for 40 keV amu−1 fast ions. The technique is well suited for diagnosis of fast-ion populations in devices with fast-ion energies (∼30 keV amu−1), minor radii (∼0.6 m) and plasma densities (⪅1020 m−3) that are similar to those of DIII-D.


Introduction
One of the most common forms of plasma heating in magnetic fusion devices is injection of hydrogenic neutral beams. The injected neutrals ionize in the plasma, then execute orbits in the confining magnetic field. As these ions gradually thermalize, they form a population of energetic ions in the plasma that is described by a distribution function f f (v, r). Hydrogenic fast-ion populations are also produced by ion cyclotron heating and by fusion reactions. A number of existing techniques [1] provide information about the fast-ion distribution function. Some fast ions undergo nuclear reactions: analysis of escaping neutrons, charged fusion products and gamma rays is one standard approach. Other fast ions neutralize in a charge-exchange reaction: analysis of the escaping neutrals is another standard technique. Inferences based on measurements of the pressure profile and of the stored energy are also widely employed. Collective scattering of microwaves off the fast-ion feature can also provide useful information [2].
Diagnosis of the fast-ion population is important because the fast ions are often a major source of energy, momentum and particles for the plasma. Moreover, the fast-ion pressure and driven current can have a significant impact on macroscopic stability properties. Although dilute populations of fast ions often behave classically, intense populations can drive instabilities that redistribute or expel the fast ions from the plasma [3]. This is often the case in experiments in the DIII-D tokamak, where anomalous fast-ion diffusion rates of approximately 0.3 m 2 s −1 are commonly inferred during neutral beam injection [4]. In DIII-D, it is difficult or expensive to detect diffusion at this level using the standard techniques [5].
Excited states of atomic hydrogen radiate the Lyman and Balmer series of spectral lines. The most familiar of these are the Lyman-alpha line, which is a transition from the n = 2 to n = 1 energy level, and the Balmer-alpha line, which is the 3 → 2 transition. Because Lyman alpha is in the ultraviolet, it is relatively difficult to measure, but the Balmer-alpha transition emits a visible photon, which is easily measured using standard lenses, spectrometers and cameras. Indeed, Balmer-alpha light from the plasma edge is measured on virtually all magnetic fusion devices as a monitor of plasma recycling and transport and to determine the relative abundances of different hydrogenic species [6]. The spatial profile of Balmer-alpha light from injected neutrals is used to measure the deposition of the neutral beams in the plasma [7,8]; the spectrum is used to detect magnetic [9] and electric fields [10,11] through Stark splitting, and fluctuations in the emission are related to fluctuations in the electron density [12]. Balmer-alpha light from the thermal ions that charge exchange with an injected beam provides information on the local ion temperature [13,14] and deuterium density [8,15]. In both astronomy and plasma physics Balmer-alpha radiation is also known as H α light or, in the case of deuterium atoms, D α .
Conceptually, the use of D α light to diagnose a fast deuterium population is similar to the diagnosis of fast helium populations using charge exchange recombination (CER) spectroscopy [16]. Fast helium populations during 3 He neutral beam injection were measured on JET [17,18]. Alpha particles produced in deuterium-tritium reactions were measured on the Tokamak Fusion Test Reactor (TFTR) [19,20].
For spectroscopic measurements of either fast helium ions or fast hydrogenic ions, avoiding the bright emission from other sources is a major challenge. There are several populations of hydrogenic neutrals in a typical tokamak plasma [21] (figure 1). At the plasma edge and pedestal region, there are enormous populations of relatively cold neutrals from the walls and divertor that are excited in the plasma periphery. These edge neutrals radiate brightly near the unshifted wavelength of the Balmer-alpha transition (at 656.1 nm for D α ). The penetration distance of edge neutrals into the bulk plasma is approximately the geometric mean of the mean free path for ionization and the mean free path for charge exchange, which is only a few centimetres in a typical tokamak.
Neutrals injected from neutral beam lines are the second major population. The velocities of these neutrals are determined by the accelerating grids of the neutral beam source. There are three discrete energies: the neutrals with the full acceleration voltage, neutrals with one-half of the acceleration voltage and neutrals with one-third of the acceleration voltage. The small divergence of the neutral beam source implies that both the direction of the velocity vector and the spatial extent of the injected neutrals are well defined. Because of their great velocity (2.8 × 10 6 m s −1 for an 80 keV deuteron), the Doppler shift of the D α emission can be as large as 6 nm. In addition to the Doppler shift, there is also Stark splitting of the line associated with both the motional v × B Stark effect and with plasma electric fields. This splitting accounts for the ∼1 nm spread of the three peaks in the full-energy D α line in figure 1.  The injected neutrals ionize through either electron-impact ionization with plasma electrons or through charge exchange with plasma ions. In a charge exchange event with a hydrogenic ion, the energetic injected neutral generates a neutral with the velocity of the thermal plasma. These warm neutrals can radiate promptly and they generally undergo several subsequent charge-exchange reactions before being ionized by electron impact. A warm, 'halo' neutral population forms around the injected beam. The velocity distribution of this population is approximately the local velocity distribution of the plasma ions. For an ion temperature of T i = 5 keV, the resulting Doppler shift of the D α line is approximately 1.5 nm.
Upon ionization, injected neutrals form a population of fast ions. These fast ions circulate around the torus on orbits that are determined by their velocity and the confining magnetic field. On a longer timescale, Coulomb collisions with the plasma cause gradual deceleration and spreading of the velocity distribution. An axisymmetric, supra-thermal distribution, f f , of fast ions is created that depends on four variables: the fast-ion energy, E, the projection of the velocity vector onto the magnetic field, v /v (also called the 'pitch'), and the radial and poloidal positions, r. When these fast ions orbit through an injected neutral beam, a small fraction of them undergo a charge-exchange reaction and become a hydrogen atom. The goal of this technique is to extract information about f f from the Balmer-alpha light emitted by these atoms.
The spectrum in figure 1 highlights the difficulties with a naive implementation of this concept. These data are from a fibre that views a neutral beam source tangentially in the midplane. Injected neutrals are travelling towards the fibre and so the radiation is blue-shifted. The bright contributions from edge and halo neutrals on the blue-shifted side of the central peak are also evident. For these plasma conditions, the fast-ion population is travelling primarily in the direction of the injected beam with a broad distribution of energies and velocities, and so a broad blue-shifted fast-ion 'line' that spans the entire abscissa is expected. This line is relatively weak, however. The fast-ion signal is proportional to the fast-ion density, n f , while the halo signal is proportional to the thermal plasma density, n i . As a crude estimate of the spectral intensity, dI/dλ, the ratio of the fast-ion signal to the halo signal This implies that the expected signal is smaller than typical backgrounds from bremsstrahlung and impurity radiation. Accurate background subtraction based on modulation of the injected neutral source is essential for the success of this concept. Even with accurate background subtraction, detection of a fast-ion signal is problematic for the geometry shown in figure 1.
Fortunately, there are more favourable geometries. Figure 2 illustrates the situation for a fibre located above the heating beam. Because the injected neutrals travel exclusively horizontally, this geometry eliminates their Doppler shift. In contrast, the fast ions gyrate vertically in the magnetic field due to the perpendicular component of their velocity. They travel down during half of their cyclotron orbit and up during the other half, and so a population of fast ions produces a spectrum with red-and blue-shifted wings. This effect is most pronounced for the idealized, monoenergetic distribution shown in figure 2, but the basic effect is present for more realistic distributions. With accurate background subtraction, the signal from fast ions is detectable.
This paper reports the first experimental measurements of D α light from a fastion population. Initial measurements have the expected spectral, temporal and density dependences (section 2). The prospects for future application of this technique are considered next (section 3). Conclusions and plans are summarized in section 4. A simulation code used to model the data and to assess the achievable spatial resolution is described in the appendix.

Initial data
As an initial test of the concept, the spectrometer of the DIII-D CER spectroscopy diagnostic [22] was shifted from its usual wavelength to the D α transition. The first test with a tangential view of the beam, shown in figure 1(b), highlighted the difficulties. After realizing the importance of exploiting the perpendicular gyromotion to avoid the bright interfering lines, an observation with the fibres at the 15˚midplane port was attempted. With this radial view (figure 1(a)), the injected neutrals are moving away from the detector, and so their D α emission is red-shifted. This view is nearly perpendicular to the magnetic field, and so the fast-ion gyromotion produces a large Doppler shift in both directions, as in figure 2. The CER diagnostic cannot span the entire spectral range of interest, and so the instrument was tuned to view the uncontaminated blue portion of the spectrum and to just miss the bright central line produced by the edge and halo neutrals.
A typical discharge for the experiments with the radial-view data is shown in figure 3. Several neutral beams inject into the discharge, but only one source injects neutrals in the sightline of the detector. This source injects steadily at the beginning of beam injection from 1.9 to 2.7 s, is off while other sources inject from 2.7 to 3.8 s, steadily injects again for the next 0.7 s and then is modulated by a square wave from 4.5 to 5.0 s. When the viewed source is off, other sources replace it, and so to a first approximation, the fast-ion distribution function is steady throughout the discharge. There are some changes in electron density (and other plasma parameters), however, and so the conditions are not perfectly constant. After an initial rise, the neutron rate, which is dominated by reactions between the fast ions and the thermal deuterons for these conditions, is nearly constant, and so the changes are modest. Figure 4(a) shows the spectrum at the onset of beam injection. During the first 30 ms of injection a broad feature appears between 652 and 654 nm in the spectrum (figure 4(b)). No feature appears below 650 nm, which corresponds to a larger Doppler shift than can be produced by an 81 keV atom. (The neutral beam injection energy is 81 keV.) The feature is fully formed in ∼40 ms; similarly, the neutron rate completes 75% of its initial rise after 40 ms, and then gradually increases for the next 40 ms.
In contrast, the behaviour is quite different when the viewed beam comes back on at 3.8 s ( figure 5). In this case, the fast-ion distribution function is already established because other beam sources have been injecting continuously. The signal immediately jumps up to its asymptotic value, as expected. The spectra predicted by the simulation code (figure 4(c)) are similar in shape to the observed spectra (figure 4(b)). The predicted shape increases rapidly with increasing wavelength because, for these plasma conditions, injected fast ions have large parallel velocities and can only obtain a substantial perpendicular velocity through pitch-angle scattering. The predicted temporal evolution agrees qualitatively with the data, but quantitatively the simulation predicts a more gradual increase in signal than observed. This discrepancy is probably caused by uncertainties in the experimental inputs to the simulation. The predicted increase in neutron emission (not shown) agrees well with the measured neutron rate.
The latter portion of the discharge, when the viewed beam is modulated, is particularly convenient for background subtraction and for a study of the electron density dependence of the signal. Figure 6 compares the spectra for a low-density (n e = 1.1 × 10 19 m −3 ) discharge and a high-density (n e = 10.3 × 10 19 m −3 ) discharge. Three features are evident. The wing of the line produced by halo (thermal) neutrals appears on the right side of the figure (near the unshifted line). The central ion temperature in these discharges is 3 keV, and so the expected Doppler broadening of this feature is ∼0.8 nm, in good agreement with the measurement. The signal between 652 and 654 nm is associated with gyrating fast ions. The minimum wavelength expected for 81 keV deuterons is ∼ 650 nm; in fact, since it is predominately the perpendicular component of the velocity that contributes to the blue-shift in this measurement,   wavelengths less than 651 nm should be rare. The third feature in the spectra is a broad featureless background associated with visible bremsstrahlung that increases rapidly with increasing electron density. As in the previous example, the observed fast-ion spectral shape is in good agreement with the shape predicted by the simulation code (figure 6(a)). The predicted reduction in the fast-ion feature in the high-density discharge is in qualitative agreement with the observation (figure 6(b)) but the predicted reduction is larger than observed (for reasons discussed later).  figure 3. One of the background slices during a 10 ms beam-off period is also shown. The spectra predicted by the simulation code are indicated by the * symbol; the same normalization is used for both cases. The random uncertainty in the simulation due to Monte Carlo statistics is approximately the size of the symbols. The integration windows for the 'fast-ion' and 'halo' data shown in figure 7 are also indicated.
The density dependence of these three features is shown in figure 7 in a sequence of discharges with the same beam modulation pattern, plasma current and beam power but with different values of electron density to check the identification of these features. (Only discharges with 10% density variations during the 500 ms of beam modulation are included.) The feature attributed to fast ions decreases rapidly with increasing density (figure 7(a)). The feature attributed to halo neutrals decreases less rapidly with increasing density than does the fast-ion feature but also decreases (figure 7(b)). In contrast, the background increases rapidly with density (figure 7(c)). Figure 7 compares the observations with analytical and empirical estimates of the expected dependences. Consider first the analytical estimates. The fast-ion feature, S f , should scale approximately as the product of the injected-neutral and fast-ion densities, S f ∝ n n n f . The density of injected neutrals, n n , decreases with increasing n e because the stopping power of the plasma increases with density. A simple analytical estimate based on the mean free path is where k is a constant. The density of fast ions, n f , depends on their deposition rate and on their slowing down time. Locally, the deposition rate is proportional to the product of the local density and the number of injected neutrals that reach that position, n e n n . The slowing down time is inversely proportional to n e ; also, for the parameters of these discharges, there is an additional modest reduction associated with the dependence of the slowing-down time on the electron temperature, which also generally decreases modestly with increasing density. Thus, the fast-ion density should decrease slightly faster than does n n .  figure 6. The triangles represent the signals from a fibre that intersects the modulated beam at 1.78 m; the diamonds represent data from 1.85 m. The analytical expressions (----) and empirical measurements (×) of (a) equation (1) and I dd I MSE /n e , (b) equation (2) and I MSE and (c) equation (3) and I VB are also shown.
Putting these factors together, the expected n e dependence of the fast-ion feature is roughly The halo feature, S h , should be proportional to the number of injected neutrals that ionize near the viewing volume. (There is an additional dependence on the lifetime of the daughter neutrals.) As a rough estimate, we assume that this is proportional to the local neutral density, For the background, if it is produced by visible bremsstrahlung, it should scale as These estimates are compared with the data in figure 7. The halo and background features agree well with these simple estimates, but the fast-ion feature decreases less rapidly than predicted. Empirical estimates based on independent measurements are also available. For an estimate of the injected neutral density, n n , the intensity of a channel of the motional Stark effect (MSE) diagnostic [23] that views the same spatial region is available. For the fast-ion density, n f , when the neutron rate is dominated by beam-plasma reactions, as it is here, the total number of fast ions in the plasma is approximately N f I dd /(n d σ v ), where I dd is the d-d neutron rate, n d is the deuterium density (assumed proportional to n e ) and σ v is the fusion reactivity.
Thus, the fast-ion signal should be approximately proportional to I dd I MSE /n e , where I MSE is the MSE amplitude. The halo feature should be proportional to I MSE . An independent diagnostic measures the visible bremsstrahlung emission I VB along a chord that passes through the centre of the plasma. These three empirical estimates are also compared with the data in figure 7. The visible bremsstrahlung measurement is in excellent agreement with the measured background, confirming its identification as bremsstrahlung. The halo feature is in fair agreement with the MSE measurement, but in light of the rather crude model, the agreement is satisfactory. The fast-ion feature does decay with density but the reduction is smaller than expected.
Reexamination of figure 6 reveals the cause of the discrepancy. The high-density data decay less rapidly than expected because the signal is contaminated by the background. In contrast to the low-density data ( figure 6(a)), the high-density spectrum is essentially flat between 650 and 654 nm. Evidently, the visible bremsstrahlung is slightly higher when the viewed beam is on than when the distant source is on, and so the background subtraction is imperfect, allowing a small fraction of the background to pollute the spectrum. For low densities, the net signal is larger than the background and the pollution is negligible. For high densities, the background is more than ten times larger than the net signal, and so small errors are significant. For these discharges and with this instrumentation, a true fast-ion signal is detectable for densities 7 × 10 19 m −3 .
To summarize this section, the spectral, temporal and density dependence of the signals confirms that light from fast ions has been detected in DIII-D.

Prospective applications
The successful detection of fast-ion signals motivates an investigation of the potential applications of the technique. What physical processes limit the spatial resolution? What features of the fast-ion distribution function can be deduced from the signal? Figure 8(a) illustrates the relevant atomic processes. The first reaction is the chargeexchange reaction with an injected or halo neutral that converts a fast ion into a neutral. After a fast neutral is created, its energy level can change. Many processes are involved: collisional excitation, deexcitation and ionization with electrons, deuterons and impurities, as well as radiative transitions. The transition of interest is the n = 3 → 2 radiative transition.
The intrinsic spatial resolution of this technique is determined by the mean free path of the fast ions following reneutralization. Note that the situation is different compared with CER spectroscopy of ions with Z > 1 [24]. An impurity ion that gains an electron remains charged and so it continues to orbit in the magnetic field. Ions can travel on curved paths from one neutral beam source into a sightline that views a different source [24] (the so-called plume effect). In contrast, a neutralized hydrogenic ion travels in a straight line until it is reionized or lost. Since fast neutrals from distant sources are unconfined, they tend to disperse rapidly. Figure 9 shows a simulation of the expected signal from a monoenergetic population of 80 keV amu −1 fast ions with a uniform velocity distribution in pitch that are randomly launched from one cell. The contours are displayed in the plane perpendicular to the injected neutral beam. The intensity from this localized source decreases rapidly with distance from the source. Three factors affect the spatial resolution. First, the emission from an isotropic source of unattenuated, steadily-radiating particles decreases as the square of the radius, r. The decrease with distance shown in figure 9 is faster than r −2 , however, because the radiating fast neutrals attenuate. The mean free path for reionization is comparable with the attenuation length for injected neutrals, i.e. ∼30 cm for a typical DIII-D plasma. A more important length is the mean free path associated with the lifetime of the n = 3 state, v f τ 3→2 6.1 cm. The actual mean free path in the plasma is shorter than this vacuum value because the effective lifetime of the n = 3 state is shortened by collisions. Consequently, the intrinsic spatial resolution is 5 cm. Some neutrals that are reexcited to the n = 3 state contribute a weak signal at the 0.1% level out to distances of 20-50 cm, however. Other simulations with a fast-ion density profile confirm that spatial structures are preserved on a 10 cm scale.
It should be noted that, from the standpoint of atomic physics, the Lyman-alpha transition is superior to the Balmer-alpha transition. The lifetime is shorter, and so v f τ 2→1 = 0.6 cm in vacuum. Moreover, the charge-exchange cross section from the ground state to the n = 2 state is much larger than to the n = 3 state, and so the line is brighter and uncertainties in the excited state fractions [25] have a smaller impact on the interpretation of the signal. The advantage of the Balmer-alpha transition is purely technical: although it is possible to design a high-throughput ultraviolet diagnostic [26], detection is simpler in the visible.
The relationship between the measured spectrum and the fast-ion distribution function is complicated by the energy dependence of the charge-exchange cross section. These effects have been the topic of extensive study within the context of CER spectroscopy (see, e.g. [27,28]). Ideally, an inversion algorithm would exist that relates the measured spectrum, dI/dλ, to the desired quantity, the fast-ion distribution function, f f (E, v /v); it would be particularly convenient if the signal was linearly proportional to the fast-ion density, but unfortunately, this Spectrum contour in the xy plane 40 45 50 55 60 x (cm) is generally not the case. Figure 10(a) shows the origin of the complexity. The neutralization rate is a strong function of the relative energy between the fast ion and the injected neutral, peaking at ∼27 keV amu −1 . This implies that certain velocities in the fast-ion distribution function are more likely to neutralize and contribute to the spectrum. The signal depends on two distinct pairs of velocities. The first pair is the relative speed between the injected neutral and the fast ion, v rel ( figure 8(b)), which determines the probability of neutralization. The second pair is the fast-ion velocity and the velocity vector of the emitted photon, since the component of the fast-ion velocity in the direction of observation, v f, , determines the Doppler shift of the photon ( figure 8(a)). The energy dependence of the charge-exchange cross section can distort the spectrum strongly, particularly if the sightline views parallel or antiparallel to the injected beam. Figure 10(b) compares the actual spectrum with the spectrum that would be produced if the neutralization rate was independent of energy. Fast ions travelling along the beam are preferentially selected, while fast ions travelling against the beam hardly appear in the spectrum because their relative energy is too high. In contrast, this effect has little impact on a vertical view ( figure 10(c)). In this case, the perpendicular component of the motion that determines the Doppler shift is generally perpendicular to the velocity vector of the injected neutrals, and so little distortion of the spectrum occurs.
Fast-ion distributions in contemporary devices are produced by neutral beam injection, by wave heating in the ion cyclotron range of frequencies (ICRF) and by fusion reactions. Consider first the fast-ion distribution produced by neutral beam injection from a positive-ion source. Because these sources rely on charge-exchange reactions to neutralize the beam, they typically operate at energies where the charge-exchange probability is large, i.e. E 50 keV amu −1 . Since the fast ions have similar energies, the neutralization probability is appreciable for most of the distribution function. This is illustrated in figure 11 for a simplified model of a typical application. (The model assumes that the magnetic field and the neutralizing beam are purely toroidal, so that the relative energy is E rel = E n + E − 2 √ E n Ev /v for all values of the gyroangle. Furthermore, only charge transfer to the n = 1 state is considered and contributions to the signal from half-energy, third-energy and halo neutrals are neglected.) Most fast ions in the distribution have a neutralization probability that is >25% of the highest probability. This implies that the technique is useful for measurements of the total fast-ion density, n f , and that different viewing angles provide valuable information about the details of the velocity distribution. Balmer-alpha spectroscopy is most useful for analysis of a distribution in this energy range.
The situation is quite different for neutral beam injection from a negative-ion source such as the one contemplated for ITER. In this case, the injection energy is much larger than the energy that maximizes the charge-exchange probability. To diagnose high-energy distribution functions, the neutral source must inject along the desired velocity component to reduce the relative velocity between the neutral and the fast ion. The neutralization probability is appreciable only for velocities close to this injected neutral velocity ( figure 12(a)). The measurement probes the portion of phase space near v n . The spectrum is nicely separated from interfering lines and the measurement is sensitive to anomalies in the interrogated portion of phase space ( figure 12(b)).
The technique could prove useful for measurement of fast-ion tails produced by ICRF or lower-hybrid heating. In many experiments, tail energies are in the optimal range of 50 keV amu −1 . For example, the acceleration of beam ions above the injection energy by high-harmonic ICRF heating produces an enhanced signal in the 'wings' of the D α spectrum ( figure 13). Even for high-energy proton distributions, as is common during hydrogen minority heating, some useful information is available. Figure 14 considers a highenergy, two-dimensional, perpendicular proton distribution that is characterized by a 'tail temperature' of O(100) keV amu −1 . In this case, it is desirable to inject the neutralizing beam in the perpendicular direction (either vertically from below as in figure 14 or radially from  . Approximate calculation of the spectral intensity, dI/dλ, for the fast-ion distribution that results from high-harmonic ICRF acceleration of the fast ions injected by a positive neutral beam for the geometry of figure 11. Typical DIII-D parameters for fourth harmonic ICRF acceleration of deuterium beam ions are assumed; the distortion of the beam slowing-down distribution is taken from the simple model of [44] for a case that doubles the neutron rate. outside the torus). The Balmer-alpha emission probes the portion of the distribution function with velocities close to v n , as in the case of high-energy negative neutral beam injection. The background from the injected neutrals is more difficult to avoid for this high-energy, perpendicular fast-ion distribution, but the Doppler shifts relative to these interfering lines are sufficient for a measurement ( figure 14(b)). dependences. With the current instrumentation, visible bremsstrahlung obscures the fast-ion signal for densities 7 × 10 19 m −3 . It is unlikely that this constitutes the ultimate density limit for this diagnostic concept. In the TFTR α CER spectroscopy experiments, high-throughput optics and clever background corrections enabled successful measurements of fast-ion signals with signal-to-background ratios of <1% [20]; in JET, helium signals that were a few per cent of the bremsstrahlung level were extracted from the data [28]. Nevertheless, it is clear that this diagnostic concept favours low densities: for fast ions produced by neutral beam injection, the signal-to-background ratio scales roughly as n −3 e . On DIII-D, a prototype system with three vertically-viewing spatial channels is under construction for the 2005 experimental campaign [29]. To accommodate the limited dynamic range of the detector, the prototype employs a mask that blocks the emission from the injected beam, as illustrated schematically in figure 2(b). Beam modulation is also planned to facilitate background subtraction. The mask and beam modulation should improve the signal-to-noise of the diagnostic, but these precautions may not be necessary. An alternative approach is to model the entire D α spectrum, as in [15]. The prototype diagnostic will measure the spatial profile of the fast-ion distribution produced by 80 keV deuterium beams. An intrinsic spatial resolution of 5 cm is anticipated. Initial experiments will focus on low-density discharges with weak MHD activity, where predictions with classical calculations of the fastion distribution function should be valid. The effect of high-harmonic ICRF heating on the spectrum will also be studied. If these comparisons are successful, measurements in discharges with fast-ion-driven Alfvén modes will be attempted.

Conclusion
The prospects for application in other magnetic fusion devices are good. The technique is best suited for devices with densities less than 10 20 m −3 and fast-ion populations with energies of the order of 30 keV amu −1 , as is common for positive neutral beam injection. Diagnosis of high-energy fast-ion populations in devices such as ITER is more challenging [30] but appears feasible.

Appendix. Simulation code
The simulation code begins with a steady state calculation of the beam and halo neutral distributions in real space, velocity space and energy levels. Since the neutral beam source is modulated, only reactions with injected neutrals and halo neutrals are relevant. (Theoretically, the halo neutral distribution forms on a timescale that is much shorter than the typical 10 ms duration of the modulated beam pulse. Any changes in edge neutrals during a beam pulse are ignored.) Then, with this fixed background, a Monte Carlo calculation follows the spatial trajectories, energy level transitions and radiated spectra of the neutralized fast ions.
There are many possible principle quantum numbers, n, and angular momentum states, l, available to the neutrals. The strong fine-structure mixing allows the assumption that the population of each quantum state may be grouped as a single population based on the principle quantum number [31]. The required cross sections and reactivities are available in the literature and in the Atomic Data and Analysis Structure (ADAS) compilation [32,33]. Cross sections for the charge-exchange reactions between fast ions and neutrals in states n = 1-4 are given in ADAS [32]. (States with n > 4 are neglected in our calculations because these energy levels are sparsely populated and the cross sections seem uncertain.) Hydrogenic rates are evaluated using the relative velocity between the fast ion and the neutral, |v f − v n |, where v f is the fast-ion velocity at the instant of neutralization ( figure 8(b)). Since the electron distribution function is Maxwellian and the electron thermal speed is much greater than the fastest neutrals, it is expedient to work directly with the reactivities σ v for electron collisions with neutrals. Expressions for electron-impact ionization as a function of the electron temperature, T e , and the energy level, n, appear in [34]. Formulae for electron excitation from one energy level to another are found in [35]. A simplification is also possible for collisions with carbon. (Carbon is the principal impurity species in DIII-D.) In this case, the neutral speed is much greater than the carbon speed and so the reactivity depends only on the fast-ion speed, v f . Impurity cross sections are listed in equations (13)-(16) of [36]. Neutral collisions with hydrogenic ions are more demanding computationally. For these collisions, the speeds of the ions are often comparable with the neutral speed, and so it is necessary to average the reactivity over the ion distribution function, which is assumed to be a drifted Maxwellian with temperature T i and rotation velocity v rot . Equations (9) and (10) of [36] give the cross section for proton excitation and impact ionization from the ground state, while [37] contains cross sections for excitation from higher states. Combining the three species, a typical collisional excitation rate coefficient (for excitation from the ground state to the n = 2 state) is Q 12 = n e σ v coll,e 12 + n d σ v coll,d 12 + n C σ coll,C 21 v n , where n e , n d and n C are the electron, deuteron and carbon densities. For all species, deexcitation rates are derived from the principle of detailed balance, i.e. σ v u→l = (n 2 l /n 2 u ) σ v l→u , where u and l represent the upper and lower quantum numbers, respectively. The radiative transition rates are given by the Einstein coefficients.
The structure of the simulation code is outlined in figure 15. Because neutrals travel in straight lines, a Cartesian grid is employed and is a great simplification relative to flux coordinates. There are several subroutines that are used both in the initial calculation of the beam neutral and halo neutral distributions and in the main fast-ion loop. One subroutine finds the neutralization rate to various quantum states for an ion that charge exchanges with a neutral in state n. A second basic subroutine calculates the track of a neutral through the Cartesian grid, returning the length of the track in each 'cell'. A third subroutine solves the time-dependent collisional-radiative equations [25] for the neutral density in each state, given initial state populations, the rates for collisional excitation and deexcitation and the radiative transition rates. A fourth subroutine calculates the Stark [38] and Doppler shifts of emitted photons, given the local electric and magnetic fields and the velocities of the neutral and the photon. (The detector is assumed to measure all emitted polarizations.) The geometry of the injected beam, the position of the detector and the magnetic and electric fields calculated by the EFIT equilibrium code [39] are input to the code. Profiles of electron density and temperature, ion temperature and rotation, and carbon density as a function of flux surface are also given. The fast-ion distribution function, f f , as a function of E, v /v and r, is specified using, for example, an analytical model, a Fokker-Planck calculation [40] or a numerically produced distribution from the TRANSP [41] code. For the simulations shown in section 2, the radial profile of f f is from TRANSP and the local velocity distribution is from the transient (figure 4) or steady state (figure 6) Fokker-Planck formulae of [40].
The code begins with a set of initial calculations. First a regular Cartesian mesh is established along the centreline of the injected beam. Then the plasma parameters and electric and magnetic fields are mapped from flux coordinates onto this mesh. Next, all atomic rates that do not depend on the neutral velocity are computed, such as the collisional ionization of neutrals by electrons. The direction of the velocity vector from each cell to the collection optics is also calculated. All these quantities are stored in a large structure.
The next step is to calculate the neutral populations that will eventually charge exchange with the beam ions. Using the known beam geometry and divergence, the collisional-radiative  equations for the injected neutrals are solved. The densities and velocities of the full, half and third neutrals (each as a function of energy level n) are added to the structure that describes each cell. Charge-exchange events for the injected neutrals are the source of halo neutrals. A Monte Carlo procedure calculates halo diffusion. If a charge-exchange event happens in a cell, the particle is restarted with a new random velocity based on the local ion temperature and rotation. The neutral is followed until it ionizes. The energy occupation levels are approximated by the steady state collisional-radiative balance. At the completion of the halo calculation, the halo densities (as a function of n) are stored for each cell. After all these preliminaries, the program enters the main loop, which is a weighted Monte Carlo routine. The product of the fast-ion density, n f , and the sum of injected neutral and halo neutral densities, n n , has already been calculated as a function of position. This estimate of the probability of a reaction (which neglects the computationally intensive dependence of the reaction rate on the relative velocity) is used to determine how many fast neutrals to launch from each cell. The initial position of the fast neutral within the cell is selected randomly. The initial velocity is found using a Monte Carlo rejection test in the two dimensions that describe the velocity distribution (energy and pitch), the gyroangle is randomly generated and the velocity vector is transformed into Cartesian coordinates. With the velocity now specified, the actual reaction rate of the fast ion with each of the neutral populations can be computed; the sum of these rates is the weight of this particular fast neutral. (In fact, each individual fast neutral represents the set of possible n states of neutrals along the selected trajectory.) The trajectory of the fast neutral through the cells is computed next. As the fast neutral travels through each cell, the time-dependent collisional-radiative balance between states is computed, including the number of D α photons that are emitted. The spectrum of the emitted photons is also computed. Finally, the properly weighted spectrum is added to the accumulated spectra in each cell.
The output of the main program is the spectra from each cell. To simulate a signal from an actual instrument, a model of the optical collection efficiency is used to sum the spectra from each of the cells.
Several benchmarks of the code were performed. Results in Mandl's thesis [42] checked several lower-level routines. To test the collisional-radiative model, the attenuation of the injected neutral beam was compared with an independent calculation [43]. The spectral calculation and the weighted Monte Carlo scheme were verified as follows. As part of our initial investigation of the feasibility of this concept, a simplified model of the expected spectra was developed that ignores atomic physics and assumes that the magnetic field is purely toroidal. (Figure 2 shows a result calculated by this code.) To test our full simulation code, we replaced the magnetic field with a toroidal field and modified the cross sections to be independent of velocity. The resulting spectra were consistent with the output of the simple model.