Introduction

Radium (Ra), with isotopes 223Ra, 224Ra, 226Ra, and 228 Ra, is a naturally occurring radioactive material (NORM) that results from the radioactive decay of 238U and 232Th1. 226Ra is the most relevant isotope explained by its half-life of 1600 years. Due to its strong affinity for barite (BaSO4), (Ba,Ra)SO4 solid solutions are commonly encountered as problematic scales in various subsurface energy-related applications2,3,4,5,6,7,8. For instance, wastewater from the extraction and production of conventional oil and gas9, hydraulic fracturing10 as well as geothermal brines11, contain radium. Besides its accumulation in uranium mill tailings12,13,14,15,16, 226Ra, will play a major role in the safety assessments for nuclear waste repositories17. Under certain repository configurations, Ba and Ra, generated from the decay of cesium (fission product) and uranium, respectively, may react with sulfate-rich pore water from the host rock, resulting in the formation of (Ba,Ra)SO4 solid solutions18,19. Determining the thermodynamic and kinetic parameters that describe the crystallization of (Ba,Ra)SO4 is therefore essential for optimizing waste water treatment, site remediation measures, or generating reliable predictions of hydrogeochemical processes in subsurface energy-related applications7,20.

In the past 10 years, there has been tremendous effort to investigate the thermodynamic properties and mixing behavior of (Ba,Ra)SO4 solid solutions over a wide range of temperatures (23 °C to 90 °C). The summary of these studies, combining batch experiments21,22,23, advanced analytical techniques e.g. time-of-flight secondary ion mass spectrometry (ToF–SIMS) or transmission electron microscopy (TEM)24,25,26 and thermodynamic modelling27,28 suggested that the (Ba,Ra)SO4 solid solution series is non ideal and is described by a regular mixing model with an interaction parameter of 2.5 ± 0.2 kJ mol−129,30. In the case of nuclear waste repositories, it is important to note that supersaturated solutions may exist metastably in the pore water of rock matrices in the subsurface. As a result, it is likely that parameters pertaining to nucleation and precipitation kinetics will play a major role in Ra migration through the repository near-field, making thermodynamic equilibrium calculations insufficient for a reliable prediction of 226Ra mobility18. Kinetics studies so far have focused on radium uptake into barite and recrystallization processes31,32,33 and for the determination of partition coefficients34. To the best of our knowledge, no studies have actually quantified the precipitation kinetics of (Bax,Ra1-x)SO4 as a function of solution supersaturation.

One possible explanation would be that conventional methods, e.g., batch crystallizers35, to study nucleation and precipitation kinetics would require a significant amount of radium. Experiments involving radium are difficult because of its high specific activity (3.7 × 1010 Bq g−1)—226Ra decays to form gaseous 222Rn and a series of other short-lived α-emitting isotopes36. Indeed, beside the classical work of Marie Curie (1911)37, Doerner and Hoskins (1925)38, Hahn (1926)39 and Goldschmidt (1940)40 on radium, in today’s research radium is usually used at trace concentrations (< 10–8 M), or barium is employed as a surrogate41.

Microfluidics-based screening and lab-on-a-chip, employed for decades in biotechnology, are now emerging as versatile tools in geosciences for studying fluid-rock interactions42,43,44. Microfluidics, or lab-on-a-chip, is an experiment that is conducted in a microreactor, monitored by time-lapse microscopy, and recently combined with in-operando spectroscopic or synchrontron techniques to monitor phase transformation45,46. Such systems can mimic the pore architecture of rocks and allow live monitoring of mineral nucleation, precipitation, and dissolution under well-controlled conditions (temperature and pressure). The methodology was successfully employed to investigate the nucleation of carbonates, sulfates and iron hydroxides in confinement47,48,49,50,51,52, mineral precipitation and dissolution processes53,54,55,56,57, or the complex interplay between crystallization and transport that leads to oscillatory zoning phenomena during solid solution precipitation20. It is used in radiopharmaceutics for the synthesis of radioactive position emission tomography (PET) tracers58,59,60. Microfluidics requires small quantities of fluid to conduct hundreds of experiments simultaneously. This technology has the potential to revolutionize radio-geochemistry by allowing researchers to work with high concentrations of radium or other radionuclides in solution at low radionuclide inventories. This would keep radiation doses below those of traditional batch experiments. However, the quantity of data resulting from these microfluidic experiments can be quite significant given the robust and high throughput nature of these setups. In addition, the results are mainly 2D optical images, which require significant time and human resources for evaluation, e.g., for the determination of crystal growth rates. To fully leverage the potential of these kinds of experiments, the evaluation processes along with several other bottlenecks must be removed by employing an artificial intelligence (AI) computer vision (CV) methodology in different steps of the workflow.

The aim of this work was to test the use of lab-on-a-chip experiments monitored by time-resolved microscopy in combination with Raman spectroscopy and the application of CV to investigate the crystal growth rate of (Ba,Ra)SO4 solid solutions. Reacting solutions were injected into a microfluidic mixer to precipitate (Ba,Ra)SO4, where radium is beyond the trace. The experiments were carefully designed to precipitate Ba0.5Ra0.5SO4 under various saturation conditions. The 3D Raman tomographs of the single crystals suggested that the \(\left\{210\right\}\) face grew twice as fast as the {001} face, a common behavior for barite61,62,63. A computer vision pipeline was developed to identify crystal habits and track crystal growth from 2D optical images. Our algorithm also included the evaluation of the Ba0.5Ra0.5SO4 crystals in 3D to extract the volume and surface area of single crystals with time. These enabled the determination of the crystal growth rate of Ba0.5Ra0.5SO4, which follows a second order reaction, similar to barite, with a kinetic constant equal to (1.23 ± 0.09) × 10–10 mol m−2 s−1. The lesson learned from this study marks the first building block towards an automated radio-geochemical lab-on-chip.

Results and discussion

Evaluation of the solution chemistry and stoichiometric saturation function

The laminar mixing reactor (Fig. 1a) was used to foster the crystallization of (Ba,Ra)SO4. Three experiments denoted A, B and C, were conducted using consistent concentrations of barium chloride (BaCl2) and radium bromide (RaBr2) but with varying concentrations of sodium sulfate (Na2SO4, 0.75 mM, 1 mM, and 1.5 mM respectively). The fluxes and concentrations of the reacting solutes in the microfluidic channel were calculated using COMSOL Multiphysics64 (see details in supplementary note 1). This allowed the evaluation of solute species concentrations at every point in space and time in the microfluidic channel. By coupling this information with geochemical speciation calculations using GEMS65, the corresponding saturation indices with respect to the solid solution series were determined. The injection of Na2SO4 and a mixed solution of RaBr2 and BaCl2 at a flow rate of 1 µL min−1 induces a fluid velocity of about 4 × 10–3 m s−1 (Fig. 1b). The Reynolds number defined by the ratio of inertial forces to viscous forces is 3.75, indicating a laminar flow whereby the reacting fluids flow in parallel (Fig. 1c–e), without turbulence, and the only mixing that occurs is the result of the diffusion of molecules across the interface (green region of the microfluidic channel in Fig. 1c–e) between the reacting fluids66. The concentrations of the reacting solutes for the experiment with 1.5 mM Na2SO4 across lines 1–3 (Fig. 1b) are plotted in Fig. 2a, b. A concentration gradient develops along the x-axis of the reactor, leading to a widening of the mixing zone as the fluids flows toward the outlet. This is evident in Fig. 2a, where a non-zero sulfate concentration is observed across lines 2 and 3 in contrast to line 1.

Figure 1
figure 1

Evaluation of the solution chemistry in the microfluidic reactor for experiment C. (a) Design of microfluidic reactor with two inlets where reacting solutions are injected and an outlet. (b) Simulated velocity magnitude in the microfluidic reactor with lines 1, 2 and 3 where the solution chemistry is numerically sampled. The line x = 0.25 mm marks the middle of the reactor (c) sulfate (d) barium and (e) radium concentrations in the microfluidic reactor at steady state for experiment C.

Figure 2
figure 2

Evaluation of the solution chemistry and supersaturation function Ωst along the mixing zone. (a) The concentration of solutes across line 1–3 (c.f. Figure 1) for experiment C with (b) a change in the y-axis for a better visualization of Ba(aq) and Ra(aq (c) The comparison of the Ωst for experiment A, B and C along line 1 at x = 0.25 mm with the red stars indicating the thermodynamically most stable solid solution composition based on the aqueous solution chemistry.

The solutes react according to Eq. (1) to form (Ba,Ra)SO4 solid solutions along the mixing zones.

$${x{\text{Ba}}}_{\left(aq\right)}^{2+}+\left(1-x\right){{\text{Ra}}}_{\left(aq\right)}^{2+}+{{\text{SO}}}_{4(aq)}^{2-}\leftrightarrow {{\text{Ba}}}_{x}{{\text{Ra}}}_{(1-x)}{{\text{SO}}}_{4(s)}$$
(1)

The stoichiometric supersaturation function \({\Omega }_{st}\) for the solid solutions was computed for the entire compositional range from XBa = 0 to XBa = 1 using the equation below67:

$${\Omega }_{st}({X}_{{\text{Ba}}})=\frac{{({a}_{{{\text{Ba}}}^{2+}})}^{{X}_{{\text{Ba}}}}{({a}_{{{\text{Ra}}}^{2+}})}^{{X}_{{\text{Ra}}}}({a}_{{{{\text{SO}}}_{4}}^{2-}})}{{\left({K}_{{{\text{BaSO}}}_{4}}{\gamma }_{{{\text{BaSO}}}_{4}}{X}_{{\text{Ba}}}\right)}^{{X}_{{\text{Ba}}}}.{\left({K}_{{{\text{RaSO}}}_{4}}{\gamma }_{{{\text{RaSO}}}_{4}}{X}_{{\text{Ra}}}\right)}^{{X}_{{\text{Ra}}}}}$$
(2)

where \({a}_{{{\text{Ba}}}^{2+}}\), \({a}_{{{\text{Ra}}}^{2+}}\) and \({a}_{{{{\text{SO}}}_{4}}^{2-}}\) represent the free ion activities in the aqueous solution considering the extended Debye–Huckel ionic strength activity model; \({K}_{{{\text{BaSO}}}_{4}}\) and \({K}_{{{\text{RaSO}}}_{4}}\), the solubility products of the end-members BaSO4 and RaSO4 equal to 10–9.97 mol2 L−1 and 10–10.26 mol2 L−1 respectively at 298.15 K (cf. Klinkenberg et al. 25); and \({X}_{{\text{Ba}}}\) and \({X}_{{\text{Ra}}}\), the molar fractions of BaSO4 and RaSO4 in the solid. \({\gamma }_{{{\text{BaSO}}}_{4}}\) and \({\gamma }_{{{\text{RaSO}}}_{4}}\) are the activity coefficients of the end-members in the solid solution based on the Thompson-Waldbaum model and assuming a regular mixing model with a Margules interaction parameter, w, of 2479 J mol−1(cf. Vinograd et al. 29). Any solid solution with a stoichiometric supersaturation \({\Omega }_{st}\) > 1 can potentially precipitate while those with a \({\Omega }_{st}\) < 1 will dissolve.

The stoichiometric supersaturation function for all three experiments (line 1, x = 0.25 mm) is depicted in Fig. 2c. The maxima of the Ωst at 0.4 < XBa < 0.5 give the thermodynamically most stable solid solution for each experiment. The variation in concentration across the reactor results in variation in the Ωst. The evaluation Ωst in the regions, where crystals were observed and monitored, is provided in supplementary note 2.

Crystallization of (Ba,Ra)SO4 solid solutions

The ingress of the mixed barium chloride/radium bromide solution and sodium sulfate solution into the microfluidic reactor triggered the crystallization of (Ba,Ra)SO4, resulting in the formation of euhedral-shaped crystals (Fig. 3). Nucleation started during the seeding procedure at the interface of the mixing solution and the crystallites grew continuously, forming a trail of crystals in the middle of the microfluidic channel (0.245 mm < x < 0.255 mm). Fewer crystals of sizes 4.9 ± 0.1 µm were observed for experiment A with 0.75 mM Na2SO4, while larger crystals merging after 2–3 h were observed for the experiments with higher concentrations of Na2SO4. Crystal habits were clearly distinguishable, including flattened tabular (Fig. 3d i), orthorhombic bipyramidal (Fig. 3d ii), and pseudo-rhombohedral crystals (Fig. 3d iii), with the latter being the predominant crystal habit observed in all three experiments.

Figure 3
figure 3

Micrographs of (Ba,Ra)SO4 crystals that precipitated in the microfluidic reactor. Sample micrographs from (a) experiment A (0.75 mM Na2SO4) (b) experiment B (1 mM Na2SO4) and (c) experiment C (1.5 mM Na2SO4) with (d) the three identified crystals habits that were observed in these experiments. The figures in (d) were created using Onshape68.

Determination of solid solution composition

The Raman spectra for at least fifteen crystals from each experiment were collected to determine the solid solution composition. Figure 4a shows one spectrum as a typical example. In addition, the Raman spectra of synthetic BaSO4 (99.99% from Chempur), SrSO4 (99.99% from Chempur), and PMMA (reactor material) were collected. These measurements served as standards for the evaluation of our experimental data. The free sulfate ions (SO4–2) have characteristic ν1 and ν3 bands corresponding to the symmetric and the anti-symmetric stretching modes, respectively, and ν2 and ν4 bands corresponding to the bending vibrations. The intense ν1(SO4) bands for BaSO4 and SrSO4 are located at 988 cm−1 and 1001 cm−1, respectively. No Raman data for RaSO4 or (Ba,Ra)SO4 from literature were available for comparison necessitating further calculations to access this information. The Raman spectra of pure RaSO4, BaSO4 and SrSO4 were determined using DFT calculations, of which a detailed analysis is given in supplementary note 4. Based on these calculations the position of the ν1(SO4) band would shift by −12 cm−1 for RaSO4 and + 11 cm−1 for SrSO4 with respect to that of BaSO4. Given that the shift of the ν1(SO4) for SrSO4 is consistent with experimental measurements (Δν =  + 12 cm−1) it can be expected that the ν1 (SO4) position in the Raman spectrum of RaSO4 is located at ν1 = 977 cm−1. According to Vegard’s law, the lattice parameters are correlated to the composition of the solid solution. Lattice parameters (more specifically distance between atom) and composition (more specifically mass of the atom) affect the vibrational frequencies. For the case of solid solution, an increase in one end-member composition usually leads to a continuous change in both the band position and band widths69. This means that the linear interpolation of the positions (cm−1) of the ν1(SO4) band maxima is a function of the mole fraction XBa in (Ba,Ra)SO4. This was verified experimentally for the case (Ba,Sr)SO4 solid solutions despite their non-ideal mixing behavior (c.f. supplementary note in Poonoosamy et al20). The measured ν1(SO4) frequency of all analyzed crystals is distinct, intermediate between those of pure BaSO4 and RaSO4, and broadened, indicating without any doubt the presence of (Ba,Sr)SO4 solid solutions. The ν1(SO4) band observed at 984 ± 1 cm−1 corresponds to a stoichiometric composition of (Ba0.5Ra0.5)SO4 (~ 0.5 × (977 + 989) = 983 cm−1).

Figure 4
figure 4

Raman spectroscopic analysis of (Ba,Ra)SO4 crystals. (a) Raman spectra of a typical crystal that precipitated in the microfluidic reactor and standard spectra of commercial BaSO4 and SrSO4 and the microfluidic reactor vessel; (b) an example of a pseudo rhombohedral crystal of (Ba,Ra)SO4 on which further Raman measurements were done to reconstruct its (c) 3D geometry.

Stacked 2D Raman images of single pseudo-rhombohedral-shaped crystals (Fig. 4b) were collected to construct their 3D structures (Fig. 4c). Such crystals were observed to grow faster in the xy direction than in the z direction, e.g., a rhombohedral crystal (Fig. 4c) of 15 ± 1 µm along its diagonal would be around 5 ± 3 µm in depth. These observations suggest that the crystals grow twice as fast along the \(\left\{210\right\}\) surfaces (causing growth in the xy direction) than on the {001} surface (causing growth in the z direction). This observation is frequently reported also for pure barite 61,62.

Computer vision pipeline for the determination of the crystal growth rate

A CV methodology was developed to detect (Ba,Ra)SO4 crystals, identify their habits and determine their crystal volume and surface area. We focused our analysis on the pseudo-rhombohedral crystals, the most abundant crystal habit observed. For each experiment, 30 crystals were analyzed. A semi-automated Python tool (supplementary note 3) is employed for the selective analysis of flat crystals from 2D optical microscopy images. The optical microscopy images were pre-processed, which included several steps such as filtering, thresholding, and contour detection, as shown in Fig. 5a, to identify the pseudo-rhombohedral-shaped crystals. To determine volume and consequently the molar amounts of precipitates from 2D images, 3D models based on crystal drawings (Fig. 3d) were integrated into our CV pipeline. The python library Trimesh70 (version 3.2.0) was used for 3D modeling of single crystals and accurate volume determination. Surface area calculations were similarly evaluated. Geometrical filters were employed to match 2D shapes of crystals (green line in Fig. 5b) to 3D mathematical shapes (blue line in Fig. 5b) in order to track the 2D surface and volume of the growing crystals with time. A convolutional neural network (CNN) was also developed to identify crystals with a categorized habit. However, due to the currently insufficient amount of data for training, CNN was not able to identify accurately the habits when the crystals were tilted i.e., the crystals were not flat from a 2D perspective.

Figure 5
figure 5

CV pipeline for the identification of crystal habits and determination of crystal growth rates. (a) The pre-processing steps for identifying pseudo-rhombohedral crystals (b) Tracking the growth of single crystals with time, with the green line capturing the rhomboidal shapes and the blue line approximating the pseudo-rhombohedral 3D crystal habit.

The volume of single crystals was used to calculate the molar amounts (n [mol]) of (Ba0.5Ra0.5)SO4 that precipitated assuming the molar volume of (Ba0.5Ra0.5)SO4 to be proportional to the mole fractions of the end members (c.f. Vinograd et al.30) with a value of 53.7 cm3 mol−1. The rate of precipitation at a given time (t), (Rt [mol−1 m2 s−1] normalized to the surface area (At [m2]) was determined using Eq. 353:

$${R}_{t}=\frac{{n}_{t+1}-{n}_{t}}{\Delta t\times {A}_{t}}$$
(3)

where Δt is the time lapse between captured images.

An average rate of precipitation for each crystal was calculated for experiments A-C and reported in the histograms given in Fig. 6. The mean crystal growth rate for each experiment and associated standard deviations were calculated and are given in Fig. 6.

Figure 6
figure 6

Evaluation of crystal growth rate. Average precipitation rate (Rt) of single crystals for (a) experiment A, (b) experiment B and (c) experiment C. (d) Graph of crystal growth rate R as a function of supersaturation ratio with respect to Ba0.5Ra0.5SO4. The error associated with the crystal growth rate in (d) is the standard error associated with the sampling distribution in (ac). The variations in \({\Omega }_{st({{\text{Ba}}}_{0.5}{{\text{Ra}}}_{0.5}{{\text{SO}}}_{4})}\) in the monitored region were included as the uncertainty on \({\Omega }_{st}\) but was insignificant enough to be visible on the graph.

Determination of the kinetic constant for Ba0.5Ra0.5SO4

The kinetic constant for the crystal growth of B0.5Ra0.5SO4 was calculated based on the measured crystal growth rates from the optical microscopy images. The crystal growth rate normalized to the surface area (R [mol m−2 s−1]) for the precipitated Ba0.5Ra0.5SO4 was assumed to follow a second order reaction like that reported for barite (BaSO4). The kinetic constant, k, can be calculated using the relationship:

$${R}_{({{\text{Ba}}}_{0.5}{{\text{Ra}}}_{0.5}{{\text{SO}}}_{4})}=k({1-{\Omega }_{st({{\text{Ba}}}_{0.5}{{\text{Ra}}}_{0.5}{{\text{SO}}}_{4})})}^{2}$$
(7)

where \({\Omega }_{st({{\text{Ba}}}_{0.5}{{\text{Ra}}}_{0.5}{{\text{SO}}}_{4})}\) is the supersaturation ratio with respect to Ba0.5Ra0.5SO4 solid solution (indicated by red stars in Fig. 2c). It is important to note that the variation of \({\Omega }_{st}\) in the regions where crystals were observed and monitored (0.225 mm < x < 0.275 mm and −14 mm < y < −5 mm) is negligeable on the final evaluation of the results (c.f. Supplementary note 2).

The rate of crystal growth \({R}_{({{\text{Ba}}}_{0.5}{{\text{Ra}}}_{0.5}{{\text{SO}}}_{4})}\) was plotted against \({\Omega }_{st({{\text{Ba}}}_{0.5}{{\text{Ra}}}_{0.5}{{\text{SO}}}_{4})}\) in Fig. 6d, and consequently, k was calculated as the slope of the linear equation, yielding (1.23 ± 0.09) × 10–10 mol m−2 s−1. The error associated with the rate is based on the least squares method, which minimizes the sum of the squares of the differences between the observed and predicted values.

Our results were compared with the experimental data provided by Hedström et al.71 (see supplementary note S5 for detailed analysis). Based on these experiments, the precipitation rate of (Ba,Ra)SO4 normalized to a specific surface area was estimated to be 2.3 × 10−8 mol m−2 s−1. The calculated rate of precipitation associated with the experimental conditions of Hedstroem et al.71 using Eq. 7, is 3.2 × 10−8 mol m−2 s−1. These findings demonstrate a significant consistency between our calculated precipitation rate and the experimental data provided by Hedstroem et al.71. The crystal growth rate of pure barite is reported as (1.5 ± 0.2) × 10–11 mol m2 s−1 in literature62. This is one order of magnitude lower than one of the synthesized Ra-bearing barite in our experiments indicating that the use of default barium growth rate kinetics to describe the (Ra, Ba)SO4 solid solution system in the subsurface or groundwater remediation analyses might lead to an overestimation of aqueous radium in solution. By changing the Ba/Ra ratio in the experiments, the radium content in the crystals can be varied. It still needs to be determined whether the kinetic rate of precipitation of (BaxRa1-x)SO4 scales with the Ra content; this will be further investigated in future studies.

Conclusion

In this work we developed a microfluidic experiment combined with a computer vision tool to determine the kinetic rate of precipitation of (BaxRa1-x)SO4 where radium is present beyond trace amounts—an achievement previously deemed unfeasible. The determined crystal growth rate can be further applied in geochemical calculations for optimizing wastewater treatment and in reactive transport code for a more realistic assessment of radium mobility in the environment for energy extraction or remediation purposes. The unique capabilities of microfluidics in radiochemistry, particularly the ability to conduct multiple experiments in parallel with minimal radionuclide inventories, underscore the potential of this methodology. The developed computer vision tool further enhances experimental throughput, providing robust statistical insights. This methodology will be further developed to conduct experiments at higher temperatures and derive the activation energies. Future work will focus on converting the processing routine from the use-case specific Jupyter notebooks (c.f. code availability) into a python package for generic application. Moreover, we will concentrate on developing a fully automated methodology by implementing CNN into the pipeline.

Experimental/methods

Chemicals used

A stock solution with 0.0375 mM of 226Ra was prepared from RaBr2 (salt, purchased from section Physik Univ. München, Technologisches Labor, München, Germany and manufactured by VG. Khlopin Radium Institute, St Peterburg, Russia in 2003). The Ra activity in solution, from which the concentration is calculated, was quantified via Gamma spectrometry using a N2 cooled high purity germanium detector (HPGe, Canberra ɣ-analyst) considering the 186 keV gamma line of 226Ra. 10 µL of a 30 mM BaCl2 solution (prepared from BaCl2·2H2O salt > 99% index no. 056-004-00-8 sigma Aldrich), was pipetted in the 5 mL of the Radium solution yielding a mixed solution of 0.061 mM of BaCl2 and 0.0375 mM RaBr2. Solution of 0.75 mM, 1 mM and 1.5 mM of Na2SO4 were prepared from Na2SO4 salt (> 99% Cas no. 7757–82-6).

Experimental setup

The experimental setup consisted of a microfluidic mixer (Fig. 1) that is connected to syringe pumps (PHD ULTRA™ Syringe Pumps, Havard Apparatus, Massachusetts, United States) and monitored by time-lapse optical microscopy using an inverted Microscope Eclipse Ti2 (NIKON, Tokyo) equipped with a motorized stage and with a 40X objective (CFI Plan Apochromat, NA 0.95, Nikon, Tokyo). The microfluidic mixer made out of polymethylmethacrylate (PMMA), with dimensions shown in Fig. 1, consists of two inlets and one outlet. The two inlets (1 and 2) were each connected to 500 µL glass syringes, dispensing the mixed solution of BaCl2 and RaBr2 and Na2SO4, respectively (Fig. 1). The outlet was linked to an effluent vessel. A PMMA reactor was chosen over the classically used polydimethylsiloxane (PDMS) because it is gas-tight, making it safer for handling radionuclides. The inlets and outlets (mini luer) were connected with tubings (Tygon AAD04103, ID 0.51 mm, OD 1.53 mm, Saint-Gobain Performance Plastics, Akron, OH, USA) via mini luer connectors (chipshop GmbH, Jena, Germany). The microfluidic reactor was initially filled with deionized water, followed by the injection of the reacting solutions at 1 µL min−1 for 15 min. The syringe pump was stopped for 15 min to enable nucleation in the microfluidic channel (seeding step). After these 15 min, the pump was switched on again and reacting solutions were injected at 1 µL min−1 and monitored by optical microscopy for 3 h. Three experiments were conducted with varying concentrations of Na2SO4 of 0.75 mM, 1 mM and 1.5 mM and were labeled A, B and C, respectively. The experiment was conducted at ambient temperature (21 °C) and pressure. Micrographs of 439 µm × 439 µm were collected using a high-resolution camera from Zyla (sCMOS, Andor, Belfast) in DIC mode over 11 to 15 areas of the 10 mm monitored region (Fig. 1) at regular intervals of 5 min.

Transport in microfluidic mixer

The flow field in the microfluidic mixer was simulated with computational fluid dynamics using the software COMSOL Multiphysics 6.0 (COMSOL AB, Stockholm, Sweden see supplementary note 1). The initial saturation ratio with respect to the complete solid solution series was calculated following the steps described in Poonoosamy et al.72. This process involved an initial evaluation of the flow and concentration fields using COMSOL Multiphysics. Subsequently, the geochemical calculations of aqueous speciation were performed using GEMS selektor65. The resulting activities of aqueous species from the geochemical solver are used for the computation of the supersaturation ratio function given in Eq. 2.

Raman measurements

Raman measurements and 3D tomographs were conducted using a Witec alpha300 Ri Inverted Confocal Raman Microscope with a Nikon 100 × oil immersion objective, having a numerical aperture (NA) of 1.4, a working distance of 0.13 mm, and a cover glass correction. The instrument is equipped with a 70 mW Nd:YAG laser (λ = 532 nm) and a thermoelectrically cooled charge-coupled device (CCD). The laser power was set to 20 mW and a grating with 1800 grooves per mm was chosen. With this setup, the spectral resolution was 2 cm−1. The theoretical, diffraction-limited lateral and axial resolutions of the Raman measurements at the sample surface were ~ 464 nm and ~ 629 µm considering Eqs. (3) and (4) in Everall73, and the refraction index of the immersion medium (n = 1.55). Raman spectra of at least 15 crystals per experiment were collected with a measuring time of 20 s in the wavenumber range from 300 cm−1 to 1400 cm−1. In addition, stacked Raman images of single crystals were collected with a 500 nm step size in the x and y direction over a depth of 10 μm with a 1 µm step size. Raman intensities were recorded for 0.1 s in the wavenumber range from 300 cm−1 to 1400 cm−1. These images were used to reconstruct the 3D geometry of the single crystals, enabling the determination of their volume. Raman image stacks were visualized with the ImageJ 3D Viewer (version 4.0.2).

DFT calculation

The synthetic Raman spectra of BaSO4, RaSO4 and SrSO4 compounds were computed with the plane-wave Quantum-ESPRESSO package74, using density functional perturbation theory. We applied the norm-conserving pseudopotentials, the kinetic energy cutoff of 200 Ry and the LDA (for Raman intensities) and PBEsol (for vibrational frequencies) exchange–correlation functionals75. The compounds were modeled with four formula units supercells that contained 24 atoms and 2 × 2 × 2 Monkhorst–Pack k-point grid for Brillouin zone76 sampling. Details of these calculations and analyses are given in supplementary note 2.

Computer vison pipeline

The development of the CV methodology for (Ba,Ra)SO4 crystal analysis involved some carefully designed steps that allowed us to extract physical details and growth rates from 2D optical microscopy images. This included a semi-automated image-processing Python methodology that allows for bordering of selected regions of interest from the available TIFF input images. This is essential as it ensures the exclusion of crystals that are not flat from a 2D perspective. Analyzing non-flat crystals can potentially result in inaccurately identifying an enlarged perimeter, leading to inaccurate calculations of volumes and precipitation rates. It is important to mention that the selection process is conducted on the final image of each experiment to ensure the capture of the necessary coordinates. These coordinates are then saved and utilized by the CV tool to trace the growth of crystals throughout the entire duration of the experiment.

The first step of the main CV code, the pre-processing step, employs various Python libraries such as OpenCV77 (version 4.6.0.66) for image processing, Pandas78 (version 1.3.3) for data manipulation, and Matplotlib79 (version 3.4.3) for graphical representation. This step involves applying bilateral filtering80,81 to reduce noise around the border of the crystal while preserving edges, adaptive thresholding82,83 to segment the crystals from their background, and contour detection84 to identify the crystal shapes. The contours are then filtered further to exclude small artifacts and nested contours in order to ensure that only the valid crystal shape is considered. Geometrical filters are then applied to detect the 2D shape and match it with its corresponding 3D morphology. For example, detected rhomboidal shapes are matched with pseudo-rhombohedral 3D morphologies.

Following the image pre-processing step, crystallographic 3D morphological models were drawn using the CAD software onshape68, and were designed based on drawings from the (Atlas der Krystallformen) textbook85. These 3D models are then integrated into the proposed CV tool to calculate the volume of the crystals being analyzed. As for the growth rate of the unseen dimension from the 2D perspective, the depth is determined based on the relevant available research work and experimentally determined 3D structures. For example, for the pseudo-rhombohedral morphology, the growth rate of the {210} surface is approximately twice as fast as that of the {001} surface61,62. In the main code, the 3D modeling is utilized using the Trimesh library70 (version 3.2.0), with the volume of the crystal being calculated based on the scaled dimensions derived from the two-dimensional analysis. The scaling is done in a way that ensures the proportions are accurately maintained, and that the volumes are calculated by scaling a 3D mesh model to accurately match the rate of growth of the visible dimensions of the crystal that were observed by the CV tool during the experiment. It is also important to mention that the maximum depth was manually set to be 10 µm as it is the actual depth of the experimental microfluidic chambers. This methodology allowed us to predict the depth of the observed crystals accurately according to the representation of the crystal’s 3D morphology. Additionally, it was possible to calculate the surface area of the scaled mesh, providing additional data needed for the calculation of the precipitation rate. The precipitation rate is calculated using Eq. 3. The surface area is estimated by updating its value for each time interval.