Non-negative matrix factorization-aided phase unmixing and trace element quantification of STEM-EDXS data

Energy-dispersive X-ray spectroscopy


Introduction
A scanning transmission electron microscope (STEM) equipped with one or multiple silicon drift X-ray detector(s) (SDD) is a fast, robust and widely-used tool for the chemical analysis of materials from the microscale down to the nanoscale.With the spectrum imaging (SI) technique, an energy-dispersive X-ray spectrum is acquired at each scanned point, enabling chemical analysis for every spatial pixel in the SI dataset.Such a STEM-EDXS SI dataset allows a detailed chemical analysis of materials [1][2][3].However, when the sample is made of several phases that overlap within the thickness of the STEM specimen, the technique cannot directly deliver an individual quantification of each phase from relevant pixels, but only an average composition of a mixture of phases.This becomes problematic when the phases share some elements.For example, identifying chemically-similar multiphase nanoprecipitates in complex fission products remains difficult when characterizing irradiated nuclear fuels using STEM-EDXS [4].STEM-EDXS tomography might be an option for phase quantification in such scenarios.However, its application requires long acquisition times with high accumulated electron beam doses, and therefore is unsuitable for beam sensitive samples as studied here.Moreover, EDXS is prone to artifacts in the quantification when the geometry of the sample in the microscope changes (absorption, shadowing, effect of take-off angle), therefore EDXS tomography is best done on samples prepared as needles or tip-mounted lamellae.This is not always feasible for mechanical reasons, as is the case here, where the STEM lamella must be attached at many points on the supporting grid because of strong internal stresses in the starting material.
Another drawback of STEM-EDXS is the low X-ray counting statistics, in large part due to the small sample thickness, which is typically around or less than 100 nm, which in turn limits the interaction volume for Xray emission (as compared to analysis of bulk samples with a scanning electron microscope).This is a key factor limiting the precision of STEM-EDXS when quantifying minor elements, making trace element quantification very challenging.Theoretically, these quantification limitations could be reduced by using large electron probe currents and/or counting for a long time.However, such strategies increase the risk of beam damage, contamination, and specimen drift.Furthermore, if the material of interest is highly sensitive to electron dose, such as macromolecules and polymers [5,6], metal-organic frameworks [7,8], and low-dimensional materials [9,10], STEM-EDXS measurement would hardly attain sufficient signal-to-noise ratio (SNR) for accurate and precise quantification.
In the past decade, machine learning (ML) algorithms, such as principal component analysis (PCA) [11][12][13], independent component analysis (ICA) [14][15][16], and non-negative matrix factorization (NMF) [17][18][19], have been exploited for the analysis of various electron microscopy datasets.For instance, PCA is widely used for denoising.However, its bias can induce artefacts into the reconstructed dataset [20,21].In comparison, NMF is a promising method for separating different phases of a complex sample because it assumes a non-negativity for all the collected signals, which is a physically sound assumption.The returned results are then more easily interpretable [19].Nonetheless, the components extracted by NMF are not necessarily identical to the characteristics of the actual physical phases, hence the spectra cannot directly be used to quantify phases [17].Finally, the abundance maps may not equal the actual quantitative distributions of phases.This information, namely the physically sound spectra and abundance maps, is however what is needed for understanding the properties of the material, such as mechanical [22,23], transport [24,25] and magnetic [26,27].
To address these limitations of NMF, here we propose a new methodology that combines NMF with a priori knowledge of the sample.Using a test sample, this methodology is explained in Section 3.2, after presenting a "classical" STEM-EDXS analysis and its limitations in Section 3.1.Using our approach, we retrieve the physical EDX spectra of phases and their quantitative distribution maps in a sample where the constituent phases have significant spatial and spectral overlap.By making relevant statistical analyses, in Section 3.3 we show how the EDX peak signal intensities are significantly increased, allowing us to quantify trace elements having concentration levels as low as ~100 ppm.

Sample synthesis and preparation
The material studied in this paper is a mineral assemblage synthesised in a laser-heated diamond anvil cell (LHDAC), a tool for reproducing the pressure and temperature conditions of Earth's deep interior in the laboratory.The starting material was a glass synthesised in an aerodynamic levitation laser furnace [28], with a pyrolitic composition that represents the average Earth's mantle composition in terms of major elements.Additionally, trace amounts of Nd, Sm, and U (0.3 wt.% for each) were added to the starting material.The nominal composition of the starting material, as measured by EDXS in a scanning electron microscope, is detailed in Table 1.
Using the LHDAC, the starting material was first compressed to 71 GPa, heated to ~4500 K and then held in a molten state for 2 min using double-sided laser-heating, followed by fast cooling to ~3900 K at a rate of around 90 K/s.The sample was next quenched by switching off the laser power (ramp down time ~10 μs), then slowly decompressed and unloaded from the diamond anvil cell.From this sample, a STEM specimen was prepared from the centre of the heated spot using the focused ion beam (FIB) lift-out technique with a Zeiss Auriga.

STEM-EDXS SI acquisition
The STEM imaging and EDXS measurements were performed on an FEI Tecnai Osiris microscope operated at 200 kV high tension, using an electron probe with a convergence semi-angle of ~12 mrad and nominal current of 750 pA.This microscope is equipped with four windowless Super-X SDD EDXS detectors and Esprit 1.9 acquisition software from Bruker.EDXS SI data, with a dimension of 512 × 512 pixels, were acquired using a pixel size of 1.7 nm and a pixel dwell time of 60 μs.With 46 frames, the total acquisition time amounted to 12 min for each SI map.The mapped area has an estimated average thickness of 117 nm and reaches a maximum of 156 nm.The EDXS acquisition parameters yield an average of ~160 counts per pixel.This ensures an appropriate SNR for characterizing the minor elements (i.e., Al Kα, Fe Kα, Ca Kα) without inducing severe electron beam damage of the specimen, which is prone to degradation (material loss) under excessive electron beam dose.

Conventional STEM-EDXS analysis
We first present a conventional STEM-EDXS analysis of the mineral assemblage.Fig. 1 shows its high-angle annular dark-field (HAADF) image, and the EDXS elemental maps of integrated peak counts.Through qualitative analysis of these elemental maps, we have identified three mineral phases, known to be the stable minerals in the lower mantle [29]: bridgmanite (MgSiO 3 with minor amounts of Fe, Al, and Ca, abbr.Brg), ferropericlase ((Mg, Fe) O, abbr.Fp), and Ca-perovskite (CaSiO 3 with minor amounts of Al, Nd, Sm, and U, abbr.CaPv).Three regions of interest (i.e., ROI_Brg, ROI_Fp, ROI_CaPv) are selected to study the three phases as indicated in Fig. 2(a); their pixel-integrated EDX spectra are displayed in Fig. 2

(b)-(d).
A fundamental question for geoscientists is assessing the interphase partitioning behavior of trace elements in Earth's mantle, such as Nd, Sm, Hf, Lu, U, since this evidences different chemical differentiation events in Earth's mantle [30,31].While CaPv is fractionally the minor phase, it is the predominant host for trace elements [32], as illustrated by the Nd Lα, Sm Lα, and U Mα peaks in the spectrum of ROI_CaPv (Fig. 2  (d)).Brg is also reported to host trace elements, albeit with a significantly reduced solubility [30].In Fig. 2(b), we inspect the X-ray signals of Nd Lα, Sm Lα, and U Mα, which were summed from a relatively large area of the matrix Brg (i.e., ROI_Brg).As depicted in the insets, the U Mα peak is hardly discernible, and the Nd Lα and Sm Lα peaks are too noisy to provide reliable elemental quantification.Meanwhile, we observe a signal of Mg Kα in the spectrum of ROI_CaPv (Fig. 2(d)).Since Mg only exists in small amounts in CaPv [33,34], this signal must come from Brg which is superimposed with the CaPv in the electron beam path.Similarly, we observe a Si Kα peak in the spectrum of ROI_Fp while Fp cannot contain any Si, indicating that Fp and Brg spatially overlap.After selecting more ROIs and inspecting their spectra, we also identified that the two precipitates overlap with each other as well as Brg in some areas.
Quantifying each relevant phase is essential for studying the interphase chemical partitioning behavior.Brg's chemical composition can be directly obtained from the ROI_Brg spectrum.However, precise quantification of trace elements such as Nd and Sm within Brg poses inherent challenges owing to their low concentrations and the beamsensitivity of Brg.These limit the attainment of a high signal-to-noise

Table 1
The nominal composition of the starting material with standard deviation.ratio (SNR) for trace elements despite integrating over a large ROI.Moreover, detecting U in Brg is nearly impossible due to its even lower concentration.
Regarding the composition of Fp and CaPv, they cannot be straightforwardly quantified from ROI_Fp and ROI_CaPv since both of them share many elements with Brg and always spatially overlap with Brg.Typically, petrologists follow a three-step procedure to obtain the compositions of precipitates in such overlapping scenarios.This approach relies on the unique element in each pair of precipitate-matrix: Si for the Fp-Brg pair and Mg for the CaPv-Brg pair.Once the compositions of Brg and the phase-mixture are characterized, the overlapping coefficient between each precipitate-matrix pair can be calculated.
Subsequently, the composition of the precipitate is attained by subtracting the proportion of Brg in the phase mixture.We used this approach to determine the compositions of the three phases from the EDX spectra of ROI_Brg, ROI_Fp, and ROI_CaPv using the Cliff-Lorimer ratio method.All the k-factors utilized for elemental quantification are derived from X-ray emission cross-sections generated using the state-ofthe-art calculations of the 'emtables' (Electron Microscopy Tables) library [35].The results are reported later in Table 2 and also Table S1 in the Supporting Information.Note that the errors reported Table 2 are calculated purely from Poisson statistics, as explained later in Section 3.3.In such an analysis, selecting appropriate ROIs for Fp, CaPv, and Brg is an exacting and tedious process, given the complicated overlap Fig. 1.HAADF image and EDXS elemental intensity maps of integrated peak counts of a mineral assemblage of the specimen.Each elemental map's intensity scale is self-referential, with a linear scaling from 0 fractional intensity for the pixel spectrum with the lowest integrated peak counts to a value of 1 for the pixel spectrum with the highest integrated counts.between these phases.On the one hand, large ROIs are desirable to achieve a sufficient SNR for precise elemental quantification.On the other hand, it is essential to avoid troublesome two-precipitate-overlapping areas (i.e., three-phase-overlapping areas) where no distinct element is available to differentiate the phases.
In order to tackle these limitations, we now develop an innovative methodology aimed at segmenting overlapped phases in a semiautomated fashion.This approach enables the generation of high SNR spectra, resulting in improved precision in phase quantification.Keeping to the same test sample, we demonstrate the effectiveness of this methodology with the detection and quantification of trace elements in the matrix Brg phase.

NMF decomposition and NMF-aided phase unmixing
Our segmentation method is based on NMF.The EDXS signal in each pixel of a STEM-EDXS SI dataset can be regarded as a linear combination of a number of individual phase spectra.Here, we assume that there is negligible effect of electron beam spreading that would introduce "crosstalk" of X-ray signal between neighboring pixels, thus preserving the linearity of the phase spectra.This we justify by recourse to the subnanometer probe size and experimental conditions (pixel size, sample thickness, convergence semi-angle) detailed in Section 2.2, together with the phase sizes in the sample that consistently exceed 20 nm.Under this assumption, unmixing the phases is defined as the problem of determining a) the individual spectrum of each phase and b) the abundance map, which indicates the local weighting of each phase spectrum.While matrix factorization [36] is a popular linear unmixing technique that matches the proposed assumption, its non-negative variant -NMFapplies a further non-negativity constraint that particularly suits EDXS data.The NMF is performed using the Hyperspy package [37].
First, PCA was applied to the dataset to evaluate the number of outputted components that must be specified in the NMF decomposition.According to the PCA scree plot (Fig. 3(a)), the first three components account for the majority of variances of the dataset, consistent with the EDXS analysis of Section 3.1.Therefore, we decompose the SI dataset into three components using NMF.Fig. 3(b)-(d) shows the resultant component spectra and corresponding abundance maps.All the spectra are normalized by their maximum peak intensity.Fig. 3(b) demonstrates that the three component spectra capture the main chemical features of the three phases.The spectrum of NMF#0 contains the major elements comprising Brg; the Si Kα and Ca Kα peaks disappear in the spectrum of NMF#1, consistent with Fp; and the Mg Kα peak is absent in the spectrum of NMF#2, compatible with CaPv.Moreover, Fig. 3(d) shows that the spatial distribution of NMF#0 is similar to that of the Brg matrix phase, while the spatial distributions of NMF#1 and NMF#2 resemble those of the Fp and CaPv precipitates, respectively.
Despite these similarities between NMF components and phase characteristics, a closer examination of the components' spectra reveals that they do not fully coincide with the actual spectra of the physical phases.This is unsurprising, given that we only impose a non-negativity constraint here.First, in Fig. 3(c), we see ditches approaching zero intensity around the Si Kα and Ca Kα energy range in the spectrum of NMF#1 and a ditch around the Mg Kα energy range in the spectrum of NMF#2.Similar ditches from NMF decomposition were observed previously [17].Physically, we understand that EDXS comprises a continuum X-ray spectrum (i.e., bremsstrahlung background) and characteristic X-ray peaks.However, without additional constraints, NMF decomposition fails to account for the bremsstrahlung background and returns zero when it assigns no element in a given energy range.We  further point out that the spectrum of NMF#0 fails to recover signals of trace elements such as Nd Lα and Sm Lα.Nevertheless, these elements are known to be present in the Brg, as was shown in the ROI_Brg spectrum in Fig. 2(b).Equally, elemental quantifications of the components' spectra done using the Cliff-Lorimer ratio method do not match with the compositions determined from the manually selected ROIs.While the NMF-derived component spectra show inaccuracies compared to the actual phase spectra, the spatial loading maps are similar to the true phase distributions, as inferred by comparison to the elemental maps in Fig. 1.Here, we exploit this resemblance for unmixing the phases spatially.As demonstrated in Fig. 4, we generate two binary masks, named mask#1 and mask#2, covering the two types of precipitate and derived from the abundance maps of NMF#1 and NMF#2, respectively.The union of the two masks covers all the precipitates.The complement of the union therefore results in a mask called mask#Brg (Fig. 4(e)), which covers all the available pure Brg areas.The intersection of mask#1 and mask#2 then represents the problematic threephase-overlapping areas.The remaining masks, mask#Fp+Brg and mask#CaPv+Brg (Fig. 4(f)-(g)), are respectively obtained by subtracting the three-phase-overlapping areas from mask#1 and mask#2.As a result, we create a pure Brg mask and two masks representing the mixtures of Fp+Brg and CaPv+Brg.It is impossible to spatially segment Fp or CaPv from Brg, since the latter is a matrix phase that is distributed almost everywhere.
Creating accurate mask#1 and mask#2 that cover all precipitates is a crucial step.For this purpose, we adapted a graph-based algorithm (GrabCut) [38] to perform the segmentation task.In comparison, traditional algorithms such as histogram thresholding [39], edge-based segmentation [40], and region-based methods such as watershed transform [41] not only require careful human supervision, they do not return a correct segmentation in our case, as our data do not always have a good background-to-foreground contrast ratio.In contrast, GrabCut views an image as a graph: every pixel is a vertex, and constraints between neighbouring pixels are considered as edges.Each edge is weighted by the computed affinity or similarity between two vertices.Pairs of vertices (pixels) within a subgraph have high affinity, while those from different subgraphs have low affinity.The partition of vertices into different subsets is therefore conducted by minimizing the cost of cutting edges [42,43].Each subgraph is then an image segment.The method does not solely utilize boundary or regional information but both to achieve optimal global segmentation.Moreover, it simply requires a user-specified rectangle drawn loosely around the object of interest as the input to perform an accurate segmentation.
By applying the mask#Brg, mask#Fp+Brg, and mask#CaPv+Brg generated by GrabCut to the original EDXS SI dataset, we respectively generate a map of pure Brg, a map of Fp+Brg mixture, and a map of CaPv+Brg mixture.From these, the full pixel-integrated spectrum of Brg is readily obtained in Fig. 5(a), and the spectra of the Fp+Brg mixture and CaPv+Brg mixture are displayed as dashed curves in Fig. 5(b)-(c).As mentioned earlier, the a priori knowledge that Brg is a silicate, while Fp is an oxide without Si, enables us to separate the spectrum of Fp from the spectrum of Fp+Brg mixture.To do this, we first normalise the spectrum of Brg and Fp+Brg mix by their Si Kα intensity, as shown by Brg_norm and Fp+Brg_norm in Fig. 5(b).Next, we obtain the spectrum of Fp by subtracting the contribution of Brg from the spectrum of Fp+Brg mixture.Then, because CaPv is a Ca-enriched silicate that tolerates little Mg in its crystal structure, an analogous routine is applied to extract the CaPv spectrum from that of the CaPv+Brg mixture, now based on normalisation by the Mg Kα intensity.
Having obtained the actual spectra of all three phases (Fig. 6(a)-(c)), we leverage them to identify their spatial abundances.Calculating the abundances of phases can be considered as a problem of linear spectral mixture analysis (LSMA) [44] with predefined endmembers.LSMA is often solved based on a least-squares criterion.To produce meaningful abundances of materials, we choose a fully constrained least squares LSMA (FCLS-LSMA) that imposes two constraints on the weights of endmembers in each pixel: the abundance sum-to-one constraint and the abundance nonnegativity constraint.Applying FCLS-LSMA pixel-by-pixel, the abundance maps of Brg, Fp, and CaPv are obtained; see Fig. 6(d)-(F).
In this section, we have presented a comprehensive demonstration of how our NMF-aided method effectively unmixes phase signals in STEM- EDXS data, allowing for the extraction of individual phase spectra and abundance maps.We demonstrated our methodology using a mineral assemblage containing many regions where two or more phases overlap, but also regions of pure matrix phase.The root cause of this microstructure is the precipitation of second phases during solidification, that is driven by poor solubility of certain elements in the matrix phase.Such Fig. 5.The normalised spectrum of (a) Brg (solid curve), (b) Brg (solid curve) and Fp+Brg mixture (dashed curve), and (c) Brg (solid curve) and CaPv+Brg mixture (dashed curve); the insets are the binary masks of Brg, Fp+Brg mixture, and CaPv+Brg mixture, respectively, from which the spectra are integrated.precipitationoccurring in liquid or solid stateand resulting microstructure of nanometric or micrometric second phases (defined by the segregation of certain element(s)) within a matrix phase, is common to many geological and materials samples, such as metal alloys.Inherently, such materials typically share the two characteristics required for the NMF-aided method: a sample having pure regions of at least one phase (matrix); and phases that do not share all the same elements (elemental segregation).Therefore, we believe that there is a wide scope for adapting our methodology to the analysis of such mineral or materials samples.

Enhancing trace element SNR: improving elemental quantification and detection limits
In Section 3.1, we showed how noisy the Nd and Sm signals of the spectrum integrated over the pixels of ROI_Brg spectrum are, and that the U signal is undetected.As shown with the blue spectrum in Fig. 7(c), by instead integrating over all the pixels covered by the masked pure Brg areas (Fig. 7(b)), the U Mα peak becomes visible, and the Nd Lα peak and Sm Lα peak are smoother and more distinguishable from the background.This enhancement allows us to include U in the spectral quantification of Brg via the Cliff-Lorimer ratio method presented in the compositional Table 2, and also improves the quantification of Nd and Sm.Errors given in Table 2 are calculated based on the assumption that the number of X-rays detected follows Poisson statistics, hence the error is given by atomic fraction × 1/ ̅̅̅̅̅̅ N p √ where N p is the number of counts in a fitted peak.Table 2 shows how X-rays integrated from the larger area of Mask_1 have reduced Poisson errors compared to those from the limited zone of Brg_ROI.We further discuss this reduction in Poisson error for improved trace element quantification later in this section.It is noted that other EDXS quantification errors such as X-ray absorption, errors in cross-sections, and possible spectrum fitting errors are not accounted for in Table 2.
We now delve deeper into the statistical basis of the quantification improvement, starting with the influence of the number of integrated pixels on Brg spectra.In Fig. 7(a), we show three Brg ROIs of varying size (small, medium and large) for generating Brg spectra of different SNRs.The respective trace element peaks are shown in Fig. 7(c), along with the spectrum from their summation (Brg ROI_Sum).This comparison demonstrates a significant enhancement in SNRs for trace element peaks with increasing spectral counts due to a larger number of summed pixels.
Given this result, we now further leverage our NMF-aided phase unmixing method by applying it to two other maps (Fig. 8(a), (c)) located in neighbouring areas.This process generates more Brg maps, as seen in Fig. 8(b), (d).Subsequently, in Fig. 8(e), the U signal from the three masked areas are summed to give the brown spectrum "Brg_Mask_Sum".By making this spectral integration over a large number of pixels, it is seen that there is now a sufficient SNR to clearly differentiate the U Mβ peak from the background.
To evaluate this improvement quantitatively, in Table 3, we list the SNRs of U Mα, Nd Lα, and Sm Lα calculated for each Brg ROI, together with their corresponding integrated number of pixels.Here, the net elemental signal (S) is defined as the area of the peak above the background, and the noise (N) is taken as the standard deviation (σ) of the background on either side of the actual or expected peak [45].The SNR is then given by SNR = S/N = S/σ.By comparing the signals of Brg ROI_S with those of Brg Mask_1, we observe that the SNRs of Nd Lα and Sm Lα improve by a factor of 10.2 and 8.3, respectively.Further, the SNR of U Mα increases by a factor of 5.5 from the signal of Brg ROI_L to that of Brg Mask_Sum.Fig. 9 demonstrates that the SNRs of trace elements approximately follow a square root relationship with the number of summed pixels, as expected from Poisson statistics.Phenomenologically, the SNRs of trace elements should approach around 10.0 to distinguish their signals from the background.For instance, the SNR of Nd Lα increases from 3.9 in Brg ROI_S (see the orange spectrum in Fig. 7 (c)) to 9.8 in Brg ROI_M (see the green spectrum in Fig. 7(c)), enabling the emergence of the Nd Lα peak from the background.Similarly, the SNR of Sm Lα increases from 7.1 in Brg ROI_S to 12.9 in Brg ROI_M, resulting in a more discernible Sm Lα peak.Furthermore, the SNR of U Mα jumps from 2.2 in Brg ROI_L (see purple spectrum in Fig. 7(c)) to 9.7 in Brg Mask_1 (see the blue spectrum in Fig. 7(c)), effectively differentiating the U Mα peak from the background.
Improving the SNRs of trace element signals reduces two aspects of uncertainties in elemental quantification.Primarily, we achieve a better spectrum fitting with reduced fitting errors.Fig. 10(a)-(c) illustrate the spectral fitting of U Mα of Brg ROI_L, Brg Mask_1, and Brg Mask_Sum.The fitting uses Gaussian models for X-ray peaks and assumes a Poissonian error variance.The reduced chi-squared (χ 2 red ) is a general method for assessing the goodness of a fit.If a model is fitted to data and the resulting χ 2 red is larger than one, it is considered a "bad" fit; whereas if χ 2 red < 1, it is considered an overfit.The "best" fitting is the one whose value of χ 2 red is closest to one.The χ 2 red of Brg ROI_L is 1.24, and the value improves to 0.95 when integrating over the areas of Brg Mask_1.Furthermore, the χ 2 red of Brg Mask_Sum is 0.97 which is the closest to one, indicating a satisfactory fitting.Considering the emission and detection of a characteristic X-ray as statistically independent events, The proposed NMF-aided phase quantification not only reduces the quantification uncertainties in trace elements, but also extends the limit of detection (LOD) in STEM-EDXS.Here, we illustrate this improvement by examining the spectra of Fp.The LOD, as defined by American Chemical Society [46,47], is the lowest concentration of an analyte that can be determined to be statistically distinct from a blank.In other words, the LOD is equal to the concentration of an analyte whose SNR equals three.To assess the LOD improvement, we normalize the spectra of Fp obtained from ROI_Fp, map 1, and the three maps by their maximal intensities.Fig. 11 presents their energy range of 4.8 keV to 6.0 keV, covering the Nd Lα and Sm Lα energy range.As expected, no elemental signals are detected in the Fp spectra since neither Nd nor Sm can be incorporated into the crystal structure of Fp [32].Notably, the spectrum of Fp obtained through NMF-aided phase unmixing exhibits a significant reduction in noise level.To quantify the LOD improvement, we take the concentration of Mg as a reference, and use the Cliff-Lorimer ratio method to convert the LOD of Sm from units of counts to units of concentration.Consequently, the LOD of Sm in Fp (if Sm were present in Fp) decreases from 176 ppm to 106 ppm going from ROI_Fp to the map 1 Fp mask.Furthermore, when we obtain the Fp spectrum by applying NMF-aided method to the three maps, the LOD of Sm in Fp further decreases to 65 ppm.

Conclusion
In this study, we present an NMF-aided method for phase analysis that successfully unmixes phases with substantial spatial and spectra overlap, while increasing the sensitivity and precision of STEM-EDXS quantification.We have applied the method to analyse a beam sensitive mineral assemblage that is experimentally synthesised to represent of Earth's lower mantle (i.e., Brg, Fp, and CaPv).Despite having many elements in common and experiencing significant spatial overlap, the physical phase spectra and phase abundance maps are obtained using the proposed approach.Furthermore, we reveal and quantify trace elements such as Nd, Sm, and U in Brg.STEM-EDXS spectrum imaging  combined with the proposed method should be suitable for analysing a wide variety of materials that have complex volumetric phase relationships, restricted SNR and beam sensitivity, or vital trace constituents.Moreover, we believe that the presented strategy can also be straightforwardly adapted to other spectroscopic techniques, in particular STEM electron energy-loss spectroscopy.

Declaration of competing interest
The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.

Fig. 2 .
Fig. 2. ROIs of Brg, Fp, and CaPv are selected and indicated in (a), and their corresponding EDX spectra are presented in (b), (c), and (d), respectively.The two insets of (b) show the X-ray signals of U Mα, Nd Lα and Sm Lα in the ROI_Brg.The inset of (d) shows the X-ray signals of U Mα in the ROI CaPv.

Fig. 3 .
Fig. 3. (a) The scree plot of PCA decomposition; (b) the three component spectra of NMF decomposition; and (c) their respective zoomed-in spectral features; (d) the abundance maps of NMF decomposition.

Fig. 4 .
Fig. 4. (a)-(b) Abundance maps of the second and third NMF components; (c)-(d) binary masks generated from (a) and (b), respectively; the binary mask of (e) Brg, (f) the mixture of Fp and Brg, (g) the mixture of CaPv and Brg.

H
. Chen et al.

Fig. 9 .Fig. 10 .
Fig. 9.The SNRs of Nd Lα, Sm Lα, and U Mα and their square root fit with the numbers of summed Brg pixels.The cluster of data points on the left corresponds to the individual ROIs as well as to their sum, the cluster in the middle corresponds to the three masked regions, and the data point on the right side corresponds to the sum of the masks.

Fig. 11 .
Fig. 11.A comparison of the noise levels of Fp spectra obtained from ROI_Fp, the Fp mask of map 1, and the Fp masks of all three relevant maps.

Table 2
Compositions and their associated Poisson errors of Brg obtained from ROI_Brg and Mask_1.The errors are calculated as described in Section 3.3

Table 3
The SNRs of trace elements in Brg when integrating over different numbers of pixels.