Analysis and Mitigation of Pulse-Pile-Up Artifacts in Plasma Pulse-Height X-ray Spectra

: Pulse pile-up in pulse-height energy analyzers increases when the incident rate of pulses increases relative to the inverse of the dead time per pulse of the detection system. Changes in the observed energy distributions with incident rate and detector-electronics-formed pulse shape then occur. We focus on weak high energy tails in X-ray spectra, important for measurements on partially ionized, warm (50–500 eV average electron energy), pure hydrogen plasma. A ﬁrst-principles two-photon pulse-pile-up model is derived speciﬁc to trapezoidal-shaped pulses; quantitative agreement is found between the measurements and the model’s predictions. The model is then used to diagnose pulse-pile-up tail artifacts and mitigate them in relatively low count-rate spectra.


Introduction
Solid-state detectors operating in the pulse-height mode are used to measure energy distributions of incident radiation [1,2]. In these detectors, the amount of electrical charge released by the impact of a single photon is proportional to the energy of the photon. The energy resolution of these detectors is set by the timing and statistics of the generated and integrated charge, thermal noise, and the accuracy of the conversion of that charge to voltage [3]. In this paper, we will focus on energy analysis of X-rays emitted from plasmas. The method may also be applied to energy-resolving charged-particle detection.
Pulse-height X-ray detectors are used for applications where moderate resolution over a broad energy spectrum is more advantageous than high resolution in a narrow spectrum. The latter, for example, is obtainable with a crystal spectrometer [4]. The former is preferred for applications such as X-ray fluorescence spectroscopy of material samples [5] and electron temperature measurement via broad-spectrum Bremsstrahlung of warm or hot plasmas [6].
Experiments on the Princeton Field-Reversed-Configuration (PFRC-2) device explore nearly pure, ca. 99%, partially ionized, warm hydrogen plasmas [7]. For these, great interest lies in the tails of the X-ray spectrum. Small tails of high-energy electrons in the energy distribution (EED), even comprising less than 1% of the plasma density, can have large effects on resistivity, stability, and reaction rates of the plasma. Amptek X-123 Fast Silicon Drift Detector (SDD) pulse-height X-ray systems [5] have been used to detect and analyze X-rays emitted by electrons in PFRC-2 experiments. This paper focuses on spectral tails, a topic not encountered in the element-analysis application of SDDs, and represents an extended arena of their use.
Because the free charge generated in SDDs is ∼4.4 × 10 −20 C/eV of incident photon energy [8], the useful low energy limit of these detectors, based on resolution, is about 100 eV. These detectors are sensitive to lower-energy photons (VUV, UV, and visible), though these photons are not spectrally resolved.
For a high photon flux, more than one may arrive at the detector within the time that the free charge is integrated, the dead time per pulse, t d , the minimum time between two pulses at which they can be recognized by the electronics as distinct. As a result, the detector interprets near-coincident impacts of multiple photons as a single photon liberating charge equal to the sum of the liberated charge from the multiple impacts. This is termed pulse pile-up (PPU). Unraveling the true photon energy distribution when PPU occurs requires knowledge of the specific shape of the pulse and the peak detection processes.
As a result of PPU, the measured energy spectrum is corrupted in several ways. Firstly, PPU may produce false peaks in the distribution, located at the sum of the energies of two peaks. ("Real" peaks in the distribution correspond to elemental line radiation from an X-ray tube target, gamma radiation of radionuclides, or photon scattering mechanisms, e.g., Compton scattering.) Secondly, there will be a decrease in X-ray counts at low energies. Thirdly, the location of a peak may be shifted to higher energy if abundant low energy photons pile up with photons of the higher energy peak. Finally, PPU may add a tail to the distribution, which, in the case of two-photon pile-up, could reach up to twice the maximal photon energy in the experiment. PPU may also corrupt an already existing tail by giving a higher count rate in the tail region than the true count rate. It is of paramount interest to distinguish between tails that are artifacts of PPU and tails that have a physical origin.
Activating manufacturer-supplied software that reduces PPU-software termed "pileup rejection" (PUR)-proved ineffective at fully eliminating pile-up in many spectra in PFRC-2 experiments for reasons explained in Section 3. Thus, an analytical or algorithmic method was sought to analyze these spectra with the key objective to extract the electron energy distribution function (EEDF) from the X-ray energy distribution function (XEDF), primarily in the tail region.
The effect of PPU has been previously discussed by many authors. Datlowe analyzed the role of the shape of the pulse waveform and developed a method to calculate the effects efficiently [9], Guo et al. used a Monte-Carlo method, MCPUT, to correct the spectral distortion from PPU [10]. Taguchi et al. derived methods to correct the peak and tail pile-up effect for non-paralyzable detectors [11]. Wang et al. analyzed, for different pulse shapes, the effect of pulse pile-up on the spectrum for a double-sided silicon strip detector, accounting for the spatial distribution of photon interactions [12]. However, for digitized trapezoidal-shaped pulse-height detection systems, the effect of PPU on and the analytic mitigation of tail distortion in measured spectra have not previously been analyzed in detail.
This paper is a step towards understanding how PPU affects the tail region of spectra for detector-formed trapezoidal pulses. We focus on relatively low count rate (≤0.1/deadtime) spectra where primarily only two-photon pile-up needs to be considered. Extension of this work to multi-photon pile-up will be necessary to develop an analytical tool to diagnose and mitigate pile-up effects in the tail regions of higher count-rate spectra.

Sample Spectra with PPU
To study this immitigable PPU and test models, several experiments were performed. First, X-ray emission was measured from a graphite-target X-ray tube with incident electron beams at various currents and fixed electron energy: E e = 5 keV for the cases presented here. Using a solid graphite target reduces poorly quantifiable VUV emission-attributed to hydrogen, carbon, nitrogen, and oxygen lines and low energy Bremsstrahlung in the PFRC-2 experiments to be described shortly-that generates PPU. Fortuitously, the truncated solidtarget Bremsstrahlung spectrum mimics the EEDF predicted by Hamiltonian simulations of some FRCs [13], providing a means to evaluate these codes. For these measurements, the SDD's PUR feature was disabled.
In these studies, and in many SDDs, trapezoidal pulses have equal rise and fall times, t r , and a short duration flat top, t f . Amptek X-123 SDDs define t d = t r + t f [5]. Figure 1 shows spectra measured using higher (750 nA) and lower (190 nA) X-ray-tube electron currents, corresponding to higher (65,000 counts per second, 65 kcps) and lower (14 kcps) X-ray count rates. (We use the terms count rate, CR, and µ interchangeably throughout the paper.). At lower count rate (blue), the spectrum has bright C, O, and Si K-α lines and solid-target Bremsstrahlung. The ratio of the 1740 eV Si peak (due to fluorescence from the SDD's C1 window) [5] to the signal at 5 keV is 10 4 . At higher count rate (red), the ratio has dropped to 1300, an indication of PPU. The PPU-generated (unphysical) tail above 5 keV has a near-exponential shape of slope twice that in the region 1400 < E < 4000 eV. Though µt d is low even for the high CR case, ca. 4 × 10 −2 , changes in the spectrum's unphysical tail, above 5 keV, are clear. (The solid angle of the SDD is small, hence negligible correlation of X-ray arrivals from a single electron impact on the graphite will occur.). The "predicted spectrum" (yellow) will be discussed in Section 7. Figure 1. X-ray spectra at two count rates, 14 kcps (blue) and 65 kcps (red), for a 5-keV electron beam impacting a carbon target. Noise was reduced using a 50-eV-wide weighted moving-average filter. The slow-channel dead time was 212 ns. For comparison, the predicted spectrum (yellow) was derived using the two-photon PPU model, to be described in Section 7.
Second, measurements were performed on X-ray emission from seed plasmas in the PFRC-2 filled with hydrogen (H 2 ) gas to a center-cell pressure 153 ± 4 µTorr. The magnetic field at the PFRC-2 center was 197 Gauss and 550 W forward power was applied by a capacitively coupled rf source. The SDD, located 41 cm from the PFRC-2 major axis, viewed the plasma through an 82-mm 2 -area aperture, 10.7 cm from the axis. µt d was changed by varying t d ; the count rate, µ, was kept constant at 9.54 kcps. We measured spectra with two different t r , 1.0 µs and 5.6 µs, and t f = 0.012 and 0.2 µs, respectively. As shown in Figure  2, the region between 650 eV and 1100 eV has a 50% rise in count rate at the higher µt d . For E > 1100 eV, the tail increased by a smaller percentage. The C, N, and O peaks shift to 17 eV higher energy while the CR from 200-510 eV falls 20%, see inset. All are indications of pile up.
Figures 1 and 2 support the claim that PPU compromises spectra. In the discussions thus far, the evidence for pile up in these spectra has been qualitative. In this paper, we present a two-photon PPU model of trapezoidal-shaped pulses that successfully explains the amplitude of the high-energy tail for low count-rate spectra. We provide an algorithmic/analytical way of deducing whether a tail is a complete artifact of PPU or the deformation of a true tail. Moreover, we provide an analytic means to recover true tails when PPU occurs. Figure 2. X-ray spectra from seed plasma in the PFRC-2 (H 2 fill-gas) formed by a continuous radiofrequency (rf) 550 W source. t r = 1.0 µs (blue) and 5.6 µs (red). From the least piled-up spectrum, t r = 1.0 µs, the true count rate µ = 9.54 kcps is obtained. The X-ray spectrum predicted with a two-photon model for t r = 5.6 µs is shown in yellow and described in Section 7. The inset shows a magnified view of the low energy region of the spectra to make clear the peak shift at high µt d .

Pulse Pile-Up Reduction Techniques
There are numerous ways to reduce PPU and its artifacts. One is to reduce the solid angle viewed by the detector. This decreases µ, hence the signal-to-noise ratio (S/N), necessitating longer data-taking time or creating larger uncertainty.
Another is to place a selective absorber to reduce the flux of X-rays in some regions of the spectrum [14]. This allows µ in the other regions of the spectrum, those of interest, to be unchanged while the total µ is decreased. This works well, though is complicated by edges in the absorber's transmission coefficient and the difficulty in finding and fabricating a thin absorber with the correct spectral features.
Other solutions are implemented via signal processing: (a) reducing the width of the shaped voltage pulse, a method that degrades the energy resolution; (b) rise-time discrimination of pulses; (c) tailoring the shape of the processed pulse, e.g., exponential, Gaussian, square, trapezoidal, or triangular, see Figure 3; and (d) comparing "fast" (10-200 ns) channel with "slow" (1-25 µs) channel pulse arrival times before vs. after pulse shaping, termed the fc-sc method. The limitations of these will be described shortly. In previous PFRC experiments [6,7,15], the X-ray flux was low; long-duration measurements were needed. Recent experiments have produced considerably higher X-ray fluxes, providing the possibility for more detailed spectral resolution.
In many circumstances, PPU can be mitigated by using PUR techniques. In the Amptek X-123 Fast SDD's fc-sc method-typical operational parameters are listed in Appendix Athe energy of a pulse is determined using a slow channel while the arrival time of a pulse is determined using a fast channel. If the fast channel measures two pulses within t d set for the slow channel, both pulses are rejected [5]. There are circumstances in which PUR is ineffective, as when the X-ray spectrum is quasi-Maxwellian. Then the tail inferred for the spectrum may be compromised by a much brighter low energy part of the true spectrum. Moreover, the small electrical charges created by low energy photons may not be recognized by the SDD as pulses. Several low-energy photons may arrive within the 10's of ns of the fast channel's pulse-pair resolving time. This contrasts with a common use of pulse-height energy detectors that concentrate on peaks whose heights are well above a low background. Under these circumstances, better mitigation techniques are required.

Determination of Photon Energy
A photon incident on the Amptek X-123 Fast SDD generates electrons in the conduction band with a number proportional to the photon's energy. That charge is integrated by the SDD's electronics, yielding a shaped voltage pulse whose height is used to measure the photon's energy.
An ideal detector, t d = 0, would register one X-ray photon of apparent energy E for every X-ray photon of true energy E i . When X-ray photons are incident upon an ideal detector at a spectral rate of f i (E i ) (counts/eV/second), an apparent spectral rate of In real detectors, t d is not 0 and pulses arriving within t d create amalgamate peaks. An X-ray photon incident at time t i with energy E i produces a voltage response of a specified shape V(t − t i , E i ) whose time-integrated value is proportional to E i . The voltage responses of several photons sum to a single voltage signal. Amptek SDDs use the maximum V of the summed signal, not its time-integral, to determine an X-ray's energy. If two or more pulses hit the detector with small arrival time difference, less than t d , it becomes impossible to resolve the pulses by detecting the maximum of V. The pulse processor records only a single pulse and assigns an increased height, hence wrong energy, to it. This creates a false count of photons with high energy and a reduction at low energy.
The X-123 SDD-specific description of how pulse processing works is: Every photon hitting the detector results in a trapezoidal shaped voltage with selected t r and t f . Pile up occurs for non-resolvable pulses whose time-dependent voltages are added to each other. The SDD pulse processor looks for peaks in the voltage signal by the following procedure: (1) If the voltage starts to rise, the PEAKH logic is set off and the logic starts to look for a peak. (2) When the voltage falls by a specified amount, the system recognizes a peak and takes it as a valid pulse. (3) The voltage at the peak is recorded as the energy of the pulse.

Modeling Pile Up for Uncorrelated Trapezoidal Pulses in the Two-Photon Approximation
Analytical results regarding pile up, in the contexts of non-paralyzable pulse detectors, have been derived by Taguchi et al. [11]. In this section, we are reviewing and re-deriving them to fit the technicalities and specifics of pulse-height silicon drift detectors which detect peaks and assign peak heights as pulse energies. These results will be used in section VII to construct our pile-up reduction algorithm.
For trapezoidal pulses, two pulses arriving with a time gap (∆t) exceeding t d have distinguishable peaks, hence are resolvable. Pile up only occurs if two pulses arrive with ∆t < t d . For ∆t > t d , the second pulse's amplitude is not offset by the first pulse as readily seen in Figure 4. (Intrinsic detector noise may be ignored, see Appendix B.). We assume no correlation exists between photon arrivals, i.e., the arrival-time probability distribution is uniformly distributed. The sum follows different patterns and formulae for the three cases: ∆t < t f , t f < ∆t < t d , and t d < ∆t. For t d < ∆t, the pulses are resolved and no PPU occurs.
In the peak detection modeling, two photons pile up if two sequential photons have ∆t less than t d and between the second and third photons ∆t is larger than t d . After detection of a pulse, the probability of not detecting another pulse within time t d is e −µt d , equivalent to the probability of no pulse pile up being e −µt d [16]. So the probability of detecting another pulse within time t d is 1 − e −µt d . Given that arrival time is assumed to be uncorrelated, the probability of two pulses piling up is thus e −µt d (1 − e −µt d ). We denote 1γ as a no pile-up event and 2γ as a two-photon pile-up event. For small µt d Small µt d can be considered the "overlap probability," an important dimensionless parameter for estimating the amount of pile up in a spectrum.
Accordingly, the approximate apparent count rate µ a is expressed in terms of the true count rate µ. Within the apparent count events, µ a p(1γ) and µ a p(2γ) are the number of events where only one and two photons have arrived within t d . We disregard pile-up events involving 3 or more photons. So there are, in total, µ a p(1γ) + 2µ a p(2γ) ≈ µ true photons. This gives The probability of detecting an energy E given two photons have piled up is p 2γ (E). So the ratio of apparent pulses with energy E where two photons have piled up is p(2γ)p 2γ (E). This number gets added to the fraction of counts with energy E where no pile up happened, which is p(1γ)p(E). We can then write the ratio of apparent pulses with energy E, or the apparent probability spectrum, p a (E) as p 2γ (E) needs to be expressed in terms of the energy of the first and second photons (E 1 , E 2 ), the shape of the trapezoid, t d , and p(E). The shape of a trapezoidal pulse, with t r = t f , can be expressed through three parameters: t r , t f , and the height of the trapezoid corresponding to an energy E. From Figure 4, we observe that the maximum value of the peak of the summed pulse is: We define a shape parameter, a ≡ t r /t d , termed the triangularity: a = 0 corresponds to a rectangular pulse while a = 1 corresponds to a triangular pulse.
Because ∆t is uniformly distributed from 0 to t d , the probability distribution of ∆t, p ∆t , follows dp ∆t /d(∆t) = 1/t d . For a uniformly distributed ∆t, the probability distribution of E, if the energies of two photons are given, (E 1 , E 2 ), is Equation (4) can be used to differentiate E with respect to ∆t and then inverted to arrive at |d(∆t)/dE| = t r / min(E 1 , E 2 ), see Figure 5. Using the Heaviside, θ(x), and Dirac delta, δ(x), functions, Equation (5) can be written as In Figure 6, for a = 0, p 2γ (E|E 1 , E 2 ) is a Dirac delta function at the sum of the incident photon energies. For a = 1, the function is uniform between E 1 and E 2 . For an intermediate a value, e.g., a = 0.5, both features are present.  To get the energy probability distribution given two photons of any possible energy, we need to multiply p 2γ (E|E 1 , E 2 ) with the probability that photons have energy E 1 and E 2 , which is p(E 1 )p(E 2 ), and then sum over all possible cases, which is the going to be a sum over all possible combinations of E 1 and E 2 . Hence, the general two-photon pile-up energy probability distribution function depends on the one-photon energy spectrum as follows: Integration of the first term using Equation (6) yields The integration limit of E 1 is from 0 to E because p(E 1 ) = 0 for E 1 < 0 as a photon's energy cannot be negative: In order to integrate the second term from Equation (6), notice that p( It is also true that the term we are integrating is symmetric with respect to E 1 and E 2 . Thus the integration may be performed in the region where E 1 ≥ E 2 and then the result is multiplied by 2. In the region

for a slab with constant E 1 and the integration becomes
Combining results from Equations (8) and (9) and multiplying them with necessary factors gives These results produce the effect of a trapezoidal voltage shape function on the energy spectrum when accounting for two-photon PPU. Thus, Equation (10), applied to Equation (3), and Equation (2) give all the information about the probability distribution p a (E) and total count rate µ a of the apparent spectrum in terms of the count rate µ, the probability distribution p(E) and the dead time t d of the original spectrum, in the two-photon approximation. This provides the necessary tools to analyze the pile up for trapezoidal-shaped voltage pulses in the two-photon approximation.

Ppu Examples Using the Two-Photon Uncorrelated Trapezoidal-Pulse Model
Our derived formula will be applied on both a narrow Gaussian and a truncated exponential spectra, the latter representative of EEDFs (and XEDFs) predicted for certain FRCs [13,15]. The overlap probability was taken to be µt d = 0.1. The effects of triangularity on the spectra are first presented.
The artificially piled-up plot of a monochromatic input spectrum (approximated by a narrow Gaussian function with FWHM = 0.0526 keV) is shown in Figure 7. For pulses with 0 < a < 1 there is the main peak, a secondary peak (at twice the energy of the monochromatic spectrum), and a constant region, roughly 1.1 < E < 1.9 keV, in between. For a = 1 pulses there is no twice-energy peak. For a = 0 pulses there is no constant region. The constant region has a height proportional to the triangularity. The constant region is present between channels 2600 and 4400 in the Amptek DppMCA spectrum measurements, see Figure 8 [17].  The piled-up plot of an exponential function (∝ e −E/E 0 , E 0 = 1 keV) truncated at 1 keV is shown in Figure 9. The pile-up tail differs by more than an order of magnitude for changing triangularity. This highlights the importance of taking pulse shape into account when modeling the PPU.

Experimental Validation of Pulse-Pile-Up Model in Two Photon Approximation
In this section the two-photon pile-up model is applied to the data collected from the graphite-target X-ray tube and 550-W rf-formed seed plasma and shows that PPU can quantitatively explain the increased-amplitude tails observed at higher CR or higher µt d .
In the carbon target data, the pulse has t r = 0.2 µs and t f = 0.012 µs, hence t d = 0.212 µs and a ≈ 0.943. The exact incidence rate of the nominal 65 kcps data is µ = 64.8 kcps. The overlap probability is µt d = 0.0137, satisfying the two-photon approximation. Given that the data with 14 kcps count rate has low µt d = 0.003, we begin by assuming that the 14 kcps data is free of pile up. We "piled up" the pile-up-less 14 kcps up using our model and compared it with the piled-up 65 kcps data. The piled-up plot for 14 kcps using our two-photon model for trapezoidally shaped pulses shows good quantitative agreement with the natural pileup from 65 kcps, see yellow curve, Figure 1. It displays an exponential shape from 5 keV to 8 keV. We conclude that most, if not all, of the tail is due to PPU. Comparison of the data and the model is summarized in Table 1. Table 1. Comparison of both models with measured data from graphite target X-ray tube. The tail is assumed to be the region beyond 5 keV. See Figure 1.

Spectra 14 kcps Spectrum Apparent 65 kcps Spectrum Predicted 65 kcps Spectrum
Percentage of area under Tail 0.0222% 0.0515% 0.0536% The two-photon model was then applied to the data from seed plasma in the PFRC filled with H 2 . In this case we assumed that the data with t r = 1.0 µs is without pile up. This data was then piled it up using the model to mimic the 5.6 µs data. The observed 5.6 µs data was compared with our calculated data in Figure 2 and Table 2. As readily seen, there is good agreement in the tail region, E > 1500 eV, and the region between 650 eV and 1000 eV where the probability doubled due to PPU. The tail is "real". Table 2. Comparison of both models with measured data from seed plasma in PFRC filled with H 2 with RMF turned off. Peaking time was 5.6 µs. The tail is assumed to be the region beyond 650 eV. The above examples show that the two-photon PPU model with uncorrelated trapezoidal pulses provides good agreement with the observed spectra for µt d ≤ 0.1 and is particularly useful in examining whether a tail is real or a partially an artifact.

Using the Two-Photon Model to Reduce Pulse Pile-Up Tails
In the previous section we saw that the two-photon model is valid for small µt d , an approximation used earlier when considering the 14-kcps count-rate data with 1µs peaking time. However, as seen in Figure 9, even a low but non-zero µt d can cause pile up in the tail region and of an amplitude that may be important to the physics. Below we describe a method to evaluate if a tail is explicable by pile up or contains a real component.
Measurement provides the apparent spectrum f a (E) which can be used to find the apparent count rate µ a = f a (E)dE and apparent probability distribution p a (E) = f a (E)/µ a . Firstly, reversing Equation (2) provides the real count rate, An iterative process then extracts p(E) from p a (E). The integration of p 2γ (E) goes from 0 up to E, i.e., photons with energy higher than the bin under inspection do not affect PPU in that bin. Using this information, Algorithm 1 was devised.

Algorithm 1: Pile-up Reduction Algorithm
Data: p a , ∆E, µ a , t d , a Result: p, The algorithm first examines a low energy bin, one that has little if any pile up. That bin is used to calculate pile up in the next bin and that pile up is then subtracted. The two bins are now pile-up removed and they are used to calculate and then remove pile up in the third bin; higher energy bins require including the contributions of all bins having lower energy. By following this procedure sequentially, moving to increasingly higher bins, pile up is iteratively removed from all bins by using the pile-up-less bins that come before it.
The algorithm is first applied on the carbon target data, to explore the improbable/unphysical result that a true tail exists beyond 5 keV. As can be seen in Figure 10, the pile-up-reduced carbon target spectra for 65 kcps data, obtained by applying Algorithm 1, has reduced the tail amplitude at 6 keV by 87%. This residual tail may be caused by three (and more) photon pile up that Algorithm 1 did not remove. Figure 10. Apparent 65 kcps (blue) graphite-target X-ray-tube spectra and pile-up-reduced spectra (red) extracted using the two-photon pile-up-reduction algorithm. Noise was reduced using 50-eVwide weighted moving-average filter. Negative values that could not be shown in logarithmic plot are seen in the linear scale inset.
To further examine this, the tail remaining in the pile-up-reduced 65 kcps data, i.e., above 5 keV, was removed altogether leaving a new spectrum. This tail-cut-off spectrum was then piled up for various count rates, see Figure 11. A key feature to notice is that the tail amplitudes for these simulated spectra are roughly proportional to the assumed µt d . Moreover, the predicted tail for 14 kcps and 65 kcps data is in good agreement with the observed tail. It is deduced that, as µt d → 0, the tail would disappear.
For the seed plasma spectrum, see Figure 12, the tail in the spectra (red) with 5.6 µs peaking time remains, as does the tail in the spectra (blue) with 1.0 µs. It is evident that the pile-up-removed spectrum collapses to the original spectrum-there is no µ-proportional decrease in the tail brightness. Hence we conclude that the seed-plasma tail to be of physical origin and not an artifact of pile up. Figure 11. Prediction of piled up spectra using tail cut off (> 5 keV) spectrum as the original spectrum. Figure 12. True pile-up-less X-ray spectra (with differing peaking times: 1.0 µs (blue) and 5.6 µs (red) from the seed plasma in PFRC filled with H 2 gas, extracted using the two-photon pile-up reduction algorithm.

Conclusions
This paper develops a two-photon model to describe changes in X-ray spectrum shapes caused by the pile-up of trapezoidal pulses in pulse-height energy spectrometers (detectors). The main focus is on the effects of PPU on the high energy continuum tail of X-ray spectra though this paper also explains changes in the low-energy region of the spectrum. The model quantifies whether measured high energy tails are artifacts of PPU or real. This research extends the standard use of pulse-height detectors to a new arena, one of critical importance to warm/hot hydrogen plasma experiments where even weak high-energy electron tails, extracted from X-ray spectra, are important. This paper quantitatively explains, for a monoenergetic X-ray source, the characteristics of a PPU-generated plateau region between the full energy and twice that energy, as a function of pulse triangularity. In the high energy part of the spectrum, the paper shows that the trapezoidal pulse shape chosen for the detector-amplifier's output plays an important role in the amplitude and shape of tails.
For spectra with µt d ≤ 0.1, the two-photon, trapezoidal, uncorrelated-pulse model accurately predicts the PPU-modified spectrum of carbon-target X-ray tube and H 2 seed plasma PFRC-2 data. An algorithm was developed to reduce pile up from these spectra and diagnose whether the tail regions are artifacts of PPU or have physical origins. The tail observed above the incident electron energy in the carbon-target X-ray tube spectrum was shown to be a PPU artifact.
The low energy part of the X-ray spectrum, below 200 eV-due to electronic and readout noise, and VUV photons-though far brighter than the higher energy tail, is not measured quantitatively in these experiments. Yet effects of "unresolved" low energy X-rays and noise, such as the shifting of peaks in the X-ray spectra and the brightness of this low energy photon flux, are shown in this paper and can be extracted by the two-photon model.  The intrinsic detector noise is due to several well-known phenomena including photon statistics, Fano noise and pre-amplifier noise, the latter likely due to Johnson noise. We have measured the noise spectrum with no plasma and with detector temperatures in the range 225 to 260 K and find it to be well-described by a Gaussian centered near E = 0 and with σ = 25 eV, hence of little significance to this study.