1 Introduction

Additive manufacturing (AM) offers great opportunities in product design and manufacturing, and thus received considerable attention in research and industry over the past years. Especially, computational simulation of AM processes helps to gain a deeper understanding of involved process physics. In this spirit, this work proposes a general modeling framework for solving coupled microfluid-powder dynamics problems involving thermo-capillary flow and reversible phase transitions. This modeling framework is especially suitable to examine complex physical phenomena in AM processes such as binder jetting (BJT), material jetting (MJT), directed energy deposition (DED), and powder bed fusion (PBF). In the following, a brief overview of these AM processes is given. Within this scope, two characteristic physical phenomena are identified which play a crucial role, coupled microfluid-powder dynamics (relevant for BJT, PBF, and DED) and thermo-hydrodynamics along with phase transitions in the form of melting and solidification (relevant for PBF, DED, and MJT), as illustrated in Fig. 1.

Fig. 1
figure 1

Overview of the considered AM processes with classification of two characteristic physical phenomena

In BJT, liquid binder droplets (\(\sim {80}\,\upmu \hbox {m}\) diameter) are deposited from a print head onto a previously spread powder layer to bind powder particles together, forming the cross-section of the desired part. Subsequently, a new powder layer is spread (similarly to PBF processes) and the droplet deposition is repeated. The resulting so-called green part is solely held together by adhesive bonds between the cured binder and the powder and requires post-processing to increase mechanical strength, e.g., sintering in case of metals or ceramics [1,2,3]. Besides challenges in powder handling and spreading as well as post-processing of the part, there is need for a more detailed understanding of the coupled microfluid-powder dynamics during droplet impact in binder jetting, which may significantly affect the packing structure of the powder bed after droplet impact and, eventually, the quality of the final part [2, 3]. In MJT no additional binder material is required. Instead, the design material, e.g., metal, is processed in liquid state and deposited from a print head. The ejected melt droplets solidify on top of previously deposited material and, thus, layer-by-layer create the final part [1]. Critical aspects of the process are, e.g., the degree of droplet–substrate adhesion, the phenomenon of droplet–droplet coalescence, as well as the rate of cooling and solidification [4]. In DED a focused heat source (laser or electron beam) is used to melt a continuous stream of feedstock material (powder or wire), again to build a part layer-by-layer. A common type of DED process is laser powder deposition (LPD), where a moving deposition head combines the laser heat source and the powder delivery. Through one or more nozzles the deposition head creates a stream of powder particles that is focused at the laser interaction zone. Depending on the processing conditions, the powder either melts during flight or when entering the melt pool below the laser. The shape of the final part is defined by a complex three-dimensional relative motion between substrate and deposition head, which is achieved by moving either the deposition head, or the substrate, or a combination of both [1]. A comprehensive overview of DED is given, e.g., in [5,6,7]. In PBF processes, such as selective laser melting (SLM) or electron beam melting (EBM), complex structural components are created by selectively melting and fusing thin layers of metal powder in a layer-by-layer fashion [8,9,10]. These processes are driven by temperature-dependent surface tension, wetting, and capillary forces, which crucially affect the shape of the melt pool [9, 11, 12] and the surface topology of the solidified track. Typically, the peak temperatures in PBF, but also in DED, exceeds the boiling temperature of the liquid metal. Thus, strong evaporation occurs under typical PBF process conditions, giving rise for evaporation-induced recoil pressure, which is the origin for the characteristic keyhole-shaped depression of the melt pool surface, as well as dynamic vapor and gas flows in the build chamber. From experiments it is well-known that the evaporation-induced reoil pressure and vapor/gas flow can lead to powder particle ejection and entrainment within a domain that exceeds the dimensions of the melt pool by far [13,14,15,16,17].

Altogether, the aforementioned AM processes open up great opportunities in product design and manufacturing. However, many of the underlying physical phenomena as well as their influence on process stability and part quality are still insufficiently understood. In particular, this involves the microfluidic behavior of liquid binder or molten metal, especially when considering the coupling with powder dynamics and/or temperature-induced phase transition phenomena. Physics-based modeling and predictive simulation has the potential to gain a better understanding of the governing process physics and the optimal processing conditions to improve, e.g., processing hardware, strategies, and materials, and to mitigate process instabilities and the creation of defects [18].

Recent modeling approaches of BJT processes have focused on the microfluid dynamics of liquid binder droplets infiltrating the powder bed, e.g., to determine equilibrium saturations [19], or to predict droplet impact and penetration dynamics [20, 21]. In the field of MJT, several modeling approaches, e.g., based on the finite difference method, the finite volume method, or the finite element method, have been proposed [4, 22, 23] to study the thermo-hydrodynamics of droplet impact and solidification. An extensive review of computational models for the simulation of DED processes, which include analytical, numerical, and hybrid models for the powder stream, melt pool dynamics, or part scale response, is provided in [7, 24]. Moreover, computational fluid dynamics models have been proposed that consider the interaction of (discrete) powder particles with the melt pool [25, 26]. Most computational modeling approaches have been proposed for PBF. Existing models are based, among others, on finite element [27,28,29,30], finite difference [31], finite volume [32, 33], Lattice Boltzmann [12, 34], or meshfree [35,36,37,38,39,40,41,42] discretizations, and typically consider free-surface flow with temperature-dependent surface tension, evaporation-induced recoil pressure and heat loss as well as a Gaussian laser heat source as main driving forces.

Despite the variety of models for these different AM processes, none of the aforementioned approaches explicitly considers coupled microfluid-powder dynamics in combination with thermo-capillary flow and phase transitions. For example, existing modeling approaches for BJT or PBF typically assume the powder particles as spatially fixed while focusing on (thermo-)capillary flow. In contrast, some DED modeling approaches account for mobile powder particles, however, these are rather described as discrete point masses and not as three-dimensional continua with distributed temperature field and continuous phase transitions.

To help close this gap, the present work proposes a general smoothed particle hydrodynamics (SPH) modeling framework for coupled microfluid-powder dynamics in AM involving thermo-capillary two-phase flow and reversible solid-liquid phase transitions, i.e., melting and solidification. Thereby, it relies on methodologies proposed in two recent publications of the authors [40, 43]. In particular, a liquid and a gas phase are considered, which are governed by temperature-dependent surface tension and wetting effects and interact with a solid phase. The latter is assumed to consist of a substrate and mobile powder particles, each modeled as an arbitrarily-shaped mobile rigid body, that are evolved in time individually. For the scenario of laser–metal interactions, the effect of rapid evaporation is incorporated through additional mechanical and thermal interface fluxes. As novel contribution of this work, a regularization of the interface forces is proposed, which allows for smooth force evolutions during phase transitions to increase the robustness of the computational scheme.

To the best of the authors’ knowledge, the proposed modeling framework is the first of its kind simultaneously considering coupled microfluid-powder dynamics along with the aforementioned thermo-capillary phase transition phenomena, and, thus, it is expected to become a valuable tool for detailed simulation-based studies of AM processes. To this end, the generality and robustness of the computational modeling framework is demonstrated by several application-motivated examples representing the specific AM processes binder jetting, material jetting, directed energy deposition, and powder bed fusion. Among others, it is shown how the dynamic impact of droplets in binder jetting or the evaporation-induced recoil pressure in powder bed fusion leads to powder motion, distortion of the powder packing structure, and particle ejection.

The remainder of this work is organized as follows: The governing equations for a coupled microfluid-powder dynamics problem involving thermo-capillary flow and phase transitions are outlined. Next, the computational modeling approach using SPH is presented. Finally, several numerical examples in three dimensions are considered with a focus on the specific AM processes binder jetting, material jetting, directed energy deposition, and powder bed fusion.

2 Governing equations

Within the scope of this work, two-phase flow problems of a liquid phase (with domain \(\Omega ^{l}\)) and a gas phase (with domain \(\Omega ^{g}\)) are considered that interact with a solid phase (with domain \(\Omega ^{s}\)). The solid phase is assumed to consist of a substrate and several arbitrarily-shaped, undeformable but mobile rigid bodies, that are evolved in time individually and allowed to get into mechanical contact with each other. Optionally, thermal conduction subject to all phases and reversible phase transitions between the solid and the liquid phase is considered. Accordingly, the overall domain splits to \(\Omega = \Omega ^{l} \cup \Omega ^{g} \cup \Omega ^{s}\) and the two-phase fluid domain is given as \(\Omega ^{f} = \Omega ^{l} \cup \Omega ^{g}\). When considering thermal conduction and phase transitions additionally the combined domain \(\Omega ^{h} = \Omega ^{l} \cup \Omega ^{s}\) is introduced. In the remainder of this work, the superscripts used to denote the domains of the phases are also used to distinguish between quantities related to these phases. Besides, a double or triple of these superscripts denote quantities related to the interface between two phases respectively the triple line between three phases. In the context of metal AM modeling, the solid phase and the gas phase correspond to the solid metal and the atmospheric gas in the build chamber of an AM device. Furthermore, depending on the considered AM process, the liquid phase either corresponds to the molten metal or the liquid binder. In the following, the governing equations for the general formulation are delineated on the basis of the authors’ previous work [40, 43, 44].

2.1 Fluid phases

The liquid and gas phase are governed by the instationary and anisothermal Navier–Stokes equations in the domain \(\Omega ^{f}\), which consist of the continuity equation and the momentum equation in convective form

$$\begin{aligned}&\frac{\mathrm{d}\rho }{\mathrm{d}t} = -\rho \varvec{\nabla }\;{\varvec{\cdot }}\;{\mathbf {u}} {\quad }\text {in}\quad \Omega ^{f} \, , \end{aligned}$$
(1)
$$\begin{aligned}&\frac{\mathrm{d}\mathbf {u}}{\mathrm{d}t} = \frac{1}{\rho } \left( -\varvec{\nabla }{p} + \mathbf {f}_{\nu } + \tilde{\mathbf {f}}^{lg}_{s} + \tilde{\mathbf {f}}^{slg}_{w} + \tilde{\mathbf {f}}^{lg}_{v} \right) + \mathbf {b} {\quad }\text {in}\quad \Omega ^{f} \, , \end{aligned}$$
(2)

with density \(\rho\), pressure p, and velocity \(\mathbf {u}\). Contributions from viscous forces \(\mathbf {f}_{\nu }\), surface tension forces \(\tilde{\mathbf {f}}^{lg}_{s}\), wetting forces \(\tilde{\mathbf {f}}^{slg}_{w}\), and evaporation-induced recoil pressure forces \(\tilde{\mathbf {f}}^{lg}_{v}\), each per unit volume, as well as body forces \(\mathbf {b}\) per unit mass, can be identified. These contributions are in general dependent on the temperature T. For (incompressible) Newtonian fluids the viscous forces as defined above read \(\mathbf {f}_{\nu } = \eta \nabla ^{2}{\mathbf {u}}\) with dynamic viscosity \(\eta = \rho \nu\) and kinematic viscosity \(\nu\). The remaining contributions to the momentum equation are introduced below. Following a weakly compressible approach, density \(\rho\) and pressure p are linked via the equation of state

$$\begin{aligned} p\left( \rho \right) = c^{2} \left( \rho - \rho _{0}\right) {\quad }\text {in}\quad \Omega ^{f} \, , \end{aligned}$$
(3)

with reference density \(\rho _{0}\) and artificial speed of sound c. Accordingly, the reference pressure can be identified as \(p_{0} = \rho _{0} c^{2}\). Within this work, the Navier–Stokes equations (1) and (2) are subject to the following initial and boundary conditions

$$\begin{aligned}&\rho = \rho _{0} \quad \text {and}\quad \mathbf {u} = \mathbf {u}_{0} {\quad }\text {in}\quad \Omega ^{f} \quad \text {at}\quad t = 0 \, , \end{aligned}$$
(4)
$$\begin{aligned}&\mathbf {u} = \hat{{\mathbf {u}}} \quad \text {on}\quad \Gamma ^{f} \, , \end{aligned}$$
(5)

with initial density \(\rho _{0}\), initial velocity \(\mathbf {u}_{0}\), and boundary velocity \(\hat{{\mathbf {u}}}\) on the domain boundary \(\Gamma ^{f} = \partial \Omega ^{f} \setminus \Gamma ^{fs}\). Besides, kinematic and dynamic coupling conditions are defined on the fluid–solid interface \(\Gamma ^{fs}\) as

$$\begin{aligned} \mathbf {u} = \mathbf {u}^{fs} \quad \text {and}\quad \mathbf {t} = \mathbf {t}^{fs} \quad \text {on}\quad \Gamma ^{fs} \, , \end{aligned}$$
(6)

with interface velocity \(\mathbf {u}^{fs}\) and traction \(\mathbf {t}^{fs}\).

2.1.1 Surface tension and wetting forces

Following the continuum surface force (CSF) approach [45], surface tension and wetting effects are considered as volumetric forces distributed across an interfacial volume of finite width instead of additional boundary conditions at the liquid–gas interface and the solid–liquid–gas triple line. The distributed surface tension forces on the liquid–gas interface consist of the following two contributions in interface normal and tangential direction

$$\begin{aligned} \tilde{\mathbf {f}}^{lg}_{s} = \alpha \kappa \mathbf {n}^{lg} \delta ^{lg} + \left( \mathbf {I} - \mathbf {n}^{lg} \otimes \mathbf {n}^{lg} \right) \varvec{\nabla }{\alpha } \delta ^{lg} \, , \end{aligned}$$
(7)

with the surface tension coefficient \(\alpha\), the interface curvature \(\kappa = \varvec{\nabla }\;{\varvec{\cdot }}\;\mathbf {n}^{lg}\), and the liquid-gas interface normal \(\mathbf {n}^{lg}\) as well as the surface delta function \(\delta ^{lg}\) between liquid and gas phase. The surface delta function \(\delta ^{lg}\) is employed to distribute surface tension forces across interface domains of finite thickness. It is non-zero only on these interface domains and its integral is normalized to one. A purely linear temperature-dependent surface tension coefficient, i.e., \(\varvec{\nabla }{\alpha } = \alpha '\left( T\right) \varvec{\nabla }{T}\) with \(\alpha '\left( T\right) = {\mathrm{d}\alpha \left( T\right) }/\mathrm{d}{T}\), is considered according to

$$\begin{aligned} \alpha \left( T\right) = \alpha _{0} + \alpha '_{0} \left( T - T_{\alpha _{0}}\right) , \end{aligned}$$
(8)

where \(\alpha _{0}\) is the surface tension coefficient at reference temperature \(T_{\alpha _{0}}\) and \(\alpha '_{0} < 0\) is the surface tension gradient coefficient. To avoid negative values of the surface tension coefficient in the regime of high temperatures, additionally the limiting condition \(\alpha \left( T\right) > \alpha _{\min }\) is enforced. Moreover, the wetting forces acting on the solid–liquid–gas triple line are given by

$$\begin{aligned} \tilde{\mathbf {f}}^{slg}_{w} = \alpha \left( \cos {\theta } - \cos {\theta _{0}} \right) \mathbf {t}^{sf} \delta ^{lg} \delta ^{sf} \, , \end{aligned}$$
(9)

with the equilibrium wetting angle \(\theta _{0}\) and the current wetting angle \(\theta\) defined via \(\cos {\theta } = \mathbf {n}^{lg} \cdot \mathbf {n}^{sf}\), as well as the solid-fluid interface normal \(\mathbf {n}^{sf}\) and tangent \(\mathbf {t}^{sf}\), and the surface delta function \(\delta ^{sf}\) between solid and fluid phase.

2.1.2 Evaporation-induced recoil pressure forces

In PBF and DED processes, the high peak temperatures at typical process conditions give rise to considerable evaporation effects. Herein, a phenomenological model for the evaporation-induced recoil pressure forces based on [46] is employed

$$\begin{aligned}&\tilde{\mathbf {f}}^{lg}_{v} = -p_{v}\left( T\right) \mathbf {n}^{lg} \delta ^{lg} \quad \text {with} \nonumber \\&p_{v}\left( T\right) = C_{P} \exp \left[ - C_{T} \left( \frac{1}{T} - \frac{1}{T_{v}} \right) \right] , \end{aligned}$$
(10)

where the constants \(C_{P} = 0.54 p_{a}\) as well as \(C_{T} = \bar{h}_{v}/R\) contain the atmospheric pressure \(p_{a}\), the molar latent heat of evaporation \(\bar{h}_{v}\), and the molar gas constant R. With typical parameter values for liquid metals [13, 38] at an ambient pressure of \(p_{a} = 10^{5} \hbox {Nm}^{-2}\), these constants take on values of \(C_{P} = 5.4 \times 10^{4} \hbox {Nm}^{-2}\) and \(C_{T} \approx 5.0 \times 10^{4}\hbox {K}\). Moreover, \(T_{v}\) is the boiling temperature of the liquid phase.

2.2 Solid phase

The solid phase is assumed to consist of a substrate and several arbitrarily-shaped, undeformable but mobile rigid bodies \(k\) that are each represented by a sub-domain \(\Omega ^{s}_{k}\) of the solid domain and embedded in the fluid domain \(\Omega ^{f}\). The motion of an individual rigid body k is described by the balance of linear and angular momentum

$$\begin{aligned}&m_{k} \frac{\mathrm{d}{\mathbf {r}_{k}}}{\mathrm{d}t^2} = \mathbf {f}^{fs}_{k} + \sum _{\hat{k}} \mathbf {f}^{ss}_{k,\hat{k}} + m_{k} \mathbf {b}_{k} \quad \text {for}\quad \Omega ^{s}_{k} \, , \end{aligned}$$
(11)
$$\begin{aligned}&\mathbf {I}_{k} \frac{\mathrm{d}{\boldsymbol {\omega } }_{k}}{\mathrm{d}t} = \mathbf {m}^{fs}_{k} + \sum _{\hat{k}} \mathbf {m}^{ss}_{k,\hat{k}} \quad \text {for}\quad \Omega ^{s}_{k} \, , \end{aligned}$$
(12)

with mass \(m_{k}\) and mass moment of inertia \(\mathbf {I}_{k}\) with respect to the center of mass position \(\mathbf {r}_{k}\) and the angular velocity \(\boldsymbol {\omega }_{k}\). The velocity can be expressed as \(\mathbf {u}_{k} = {\mathrm{d}\mathbf {r}_{k}}/{\mathrm{d} {t}}\). Coupling contributions from interaction with the fluid phase at the fluid–solid interface \(\Gamma ^{fs}_{k}\) of rigid body k are described by the resultant coupling forces \(\mathbf {f}^{fs}_{k}\) and torques \(\mathbf {m}^{fs}_{k}\). Besides, contributions from mechanical contact of rigid body k with the substrate or neighboring rigid bodies \(\hat{k}\) are described by the resultant contact forces \(\mathbf {f}^{ss}_{k,\hat{k}}\) and torques \(\mathbf {m}^{ss}_{k,\hat{k}}\) at the solid–solid interface \(\Gamma ^{ss}_{k, \hat{k}}\). Finally, the body force \(\mathbf {b}_{k}\) given per unit mass is contributing to the balance of linear momentum. Within this work, the balance of linear and angular momentum (11) and (12) of a rigid body k are subject to the following initial conditions

$$\begin{aligned} \mathbf {u}_{k} = \mathbf {u}_{k,0} \quad \text {and}\quad \boldsymbol {\omega }_{k} = \boldsymbol {\omega }_{k,0} \quad \text {for}\quad \Omega ^{s}_{k} \quad \text {at}\quad t = 0, \end{aligned}$$
(13)

with initial velocity \(\mathbf {u}_{k,0}\) and initial angular velocity \(\boldsymbol {\omega }_{k,0}\). This modeling approach allows to evolve each rigid body in time individually. For more details refer to the authors’ previous work [43].

2.3 Thermal conduction

The fluid and the solid phases are subject to thermal conduction that is governed by the following energy equation as

$$\begin{aligned} c_{p} \frac{\mathrm{d}T}{\mathrm{d}t} = \frac{1}{\rho } \left( -\varvec{\nabla }\;{\varvec{\cdot }}\;{\mathbf {q}} + \tilde{s}^{hg}_{l} + \tilde{s}^{lg}_{v} \right) {\quad }\text {in}\quad \Omega , \end{aligned}$$
(14)

with temperature T and specific heat capacity \(c_{p}\). The heat flux is defined as \(\mathbf {q} = -k \varvec{\nabla }{T}\) according to Fourier’s law with thermal conductivity k. Within this work, the energy equation (14) is subject to the following initial and boundary conditions

$$\begin{aligned}&T = T_{0} {\quad }\text {in}\quad \Omega \quad \text {at}\quad t = 0 , \end{aligned}$$
(15)
$$\begin{aligned}&T = {\hat{T}} \quad \text {on}\quad \Gamma , \end{aligned}$$
(16)

with initial temperature \(T_{0}\) and boundary temperature \(\hat{T}\) on the domain boundary \(\Gamma = \partial \Omega\).

Remark 1

Note that thermal convection is hidden in the total time derivative \({\mathrm{d}T}/{\mathrm{d}t}\) of the energy equation (14) written Lagrangian description.

Besides, heat fluxes stemming from the laser beam heat source \(\tilde{s}^{hg}_{l}\) and from evaporation-induced heat losses \(\tilde{s}^{lg}_{v}\), each per unit volume, are considered. The former is given by

$$\begin{aligned}&\tilde{s}^{hg}_{l} = \zeta _{l} \langle -\mathbf {n}^{hg} \cdot \mathbf {e}_{l}\rangle s^{hg}_{l}\left( \mathbf {x}\right) \delta ^{hg} \quad \text {with} \nonumber \\&s^{hg}_{l}\left( \mathbf {x}\right) = s^{hg}_{l0} \exp \left[ -2 \left( \frac{\Vert \mathbf {x}-\mathbf {x}_{0}\Vert }{r_w} \right) ^{2} \right] , \end{aligned}$$
(17)

where \(\zeta _{l}\) is the laser energy absorptivity and \(\mathbf {e}_{l}\) is the unit vector representing the laser beam direction. The interface between the combined liquid and solid phase and the gas phase is described by the interface normal \(\mathbf {n}^{hg}\) as well as the surface delta function \(\delta ^{hg}\). The Macauley bracket \(\langle \cdot \rangle\) returns the value of its argument if the argument is positive and zero otherwise. The irradiance \(s^{hg}_{l}\left( \mathbf {x}\right)\) describes the incident laser power per unit area at position \(\mathbf {x}\) as a function of the laser beam center position \(\mathbf {x}_{0}\) and has the form of a Gaussian distribution with the peak value \(s^{hg}_{l0}\) and the standard deviation \(\sigma = r_{w}/2\). The quantity \(d_{w} = 2 r_{w}\) is a frequently used measure for the effective laser beam diameter. With a given total laser power \(P_{l}\) the peak value follows from normalization as \(s^{hg}_{l0} = 2 P_{l}/\pi r_{w}^{2}\). Eventually, following the same phenomenological model as for the recoil pressure forces (10), the evaporation-induced heat loss reads

$$\begin{aligned}&\tilde{s}^{lg}_{v} = s^{lg}_{v} \delta ^{lg} \quad \text {with}\quad s^{lg}_{v} = - \dot{m}^{lg}_{v} \left( h_{v} + h\left( T\right) \right), \,\nonumber \\& \dot{m}^{lg}_{v} = 0.82 c_{s} p_{v}\left( T\right) \sqrt{\frac{C_{M}}{T}} , \quad h\left( T\right) = \int \limits _{T_{h,0}}^T c_{p} {\mathrm{d}{\bar{T}}} , \end{aligned}$$
(18)

where the enthalpy rate per unit area \(s^{lg}_{v}\) results from the vapor mass flow per unit area \(\dot{{m}}^{lg}_{v}\) and the sum of the specific enthalpy h(T) and the latent heat of evaporation \(h_{v}\), both per unit mass. Moreover, \(T_{h,0}\) is a reference temperature of the specific enthalpy and the constant \(C_{M} = M/(2\pi R)\) contains the molar mass M and the molar gas constant R. Finally, \(p_{v}\left( T\right)\) is the recoil pressure defined in (10) and \(c_{s}\) the so-called sticking constant which takes on a value close to one for metals [13, 38].

3 Spatial discretization via smoothed particle hydrodynamics

For the spatial discretization of the governing equations the method of SPH is used. The SPH formulation applied herein combines two of the authors’ approaches recently proposed in the literature: First, a weakly compressible SPH formulation modeling multiphase fluid flow for thermo-capillary phase transition problems [40]. Second, a fully resolved SPH formulation for fluid–solid and contact interaction problems including thermo-mechanical coupling and reversible phase transitions [43]. Accordingly, this section gives a brief overview of the combined SPH formulation based on [40, 43, 44] and proposes additional methodological novelties needed to model a host of complex multiphysics problems in the field of metal AM in an accurate and robust manner. The proposed modeling framework is implemented in the in-house parallel multiphysics research code BACI (Bavarian Advanced Computational Initiative) [47] using the Message Passing Interface (MPI) for distributed-memory parallel programming.

Remark 2

The domain \(\Omega\) is initially discretized by particles located on a regular grid with spacing \(\Delta {}x\). A particle that falls into the fluid domain \(\Omega ^{f}\) is assigned to the fluid phase, while a particle that falls into the solid domain \(\Omega ^{s}_{k}\) of a rigid body k is assigned to the latter. It follows, that each rigid body is fully resolved being spatially discretized as clusters of particles. The mass of a particle is assigned using its reference density \(\rho _{0}\) and its effective volume \(\left( \Delta {}x\right) ^{d}\) (given in d-dimensional space). To introduce a short notation, a quantity f evaluated for particle i at position \(\mathbf {r}_{i}\) is written as \(f_{i} = f\left( \mathbf {r}_{i}\right)\). Besides, \(W_{ij} = W\left( r_{ij}, h\right)\) denotes the smoothing kernel W evaluated for particle i at position \(\mathbf {r}_{i}\) with neighboring particle j at position \(\mathbf {r}_{j}\), where \(r_{ij} = \Vert \mathbf {r}_{i} - \mathbf {r}_{j}\Vert\) is the absolute distance between particles i and j, and h is the smoothing length. Similarly, the derivative of the smoothing kernel W with respect to the absolute distance \(r_{ij}\) is denoted by \(\partial W/\partial r_{ij} = \partial W\left( r_{ij}, h\right)/\partial {r_{ij}}\). The initial particle spacing \(\Delta {}x\) is set equal to the smoothing length h. Besides, a quintic spline smoothing kernel \(W\left( r, h\right)\) [48] with smoothing length h and support radius \(r_{c} = 3 h\) is applied.

3.1 Discretization of phase interfaces

The representation of different phase interfaces is crucial for the evaluation of mechanical interface forces or thermal interface heat fluxes. To this end, a density-weighted color field function and its gradient are defined based on [49, 50] as

$$\begin{aligned}&c_{i} = \frac{1}{V_{i}} \sum _{j} \chi _{j} \left( V_{i}^{2}+V_{j}^{2}\right) \frac{\rho _{i}}{\rho _{i}+\rho _{j}} W_{ij} \quad \text {and} \nonumber \\&\varvec{\nabla }{c}_{i} = \frac{1}{V_{i}} \sum _{j} \chi _{j} \left( V_{i}^{2}+V_{j}^{2}\right) \frac{\rho _{i}}{\rho _{i}+\rho _{j}} \frac{\partial W}{\partial r_{ij}} \mathbf {e}_{ij} , \end{aligned}$$
(19)

evaluated for particles i and j belonging to different phases. In addition to [49, 50], an optional scaling factor \(\chi _{j}\) is introduced, that is by default set to one unless stated otherwise. Based on the definition of the color field gradient (19) the surface delta function and the interface normal of particle i read

$$\begin{aligned} \delta _{i} = \Vert \varvec{\nabla }{c}_{i}\Vert \quad \text {and}\quad \mathbf {n}_{i} = {\left\{ \begin{array}{ll} \varvec{\nabla }{c}_{i}/ \Vert \varvec{\nabla }{c}_{i}\Vert &{} \quad \text {if}\quad \Vert \varvec{\nabla }{c}_{i}\Vert > \epsilon , \\ \mathbf {0} &{} \quad \text {otherwise.}\quad \end{array}\right. } \end{aligned}$$
(20)

This procedure leads to an outward-pointing interface normal \(\mathbf {n}_{i}\) with respect to the phase of particle i. The tolerance \(\epsilon \ll 1\) is applied to avoid erroneous interface normals for particles far away from the interface. Note that the metrics (19)–(20) are, by definition, exclusively used to represent the interface between two phases and not the triple line between three phases.

Remark 3

In case of high density ratios between two phases the definition of \(\delta _{i}\) according to (19) and (20) ensures that the majority of a flux contribution, i.e., of mechanical interface forces or thermal heat fluxes, distributed over the interface via \(\delta _{i}\) acts on the phase associated with the higher density.

3.2 Phase transitions and treatment of resultant discontinuities

Reflecting the Lagrangian nature of SPH, each particle carries its phase information. Accordingly, the discretized energy equation (41) is evaluated for each particle with phase-specific parameters. Furthermore, particles undergo phase transitions solid \(\leftrightarrow\) liquid when exceeding or falling below the melt temperature \(T_{\text {m}}\). Due to this procedure, discontinuities in time occur that originate from abruptly changing contributions to the discretized momentum equation (22) after particles change phase from solid to liquid or vice versa from one time step to the next. Without additional treatment, these discontinuities may cause instabilities in the numerical time integration scheme as such schemes typically require at least \(C^{0}\) continuity of the integrand. Note that the primary driving forces of thermo-capillary phase transition problems are typically surface tension and wetting forces, while viscous and gravity forces can be considered as secondary effects [9]. Hence, the discontinuities as described above shall be avoided by employing a regularization procedure focusing on relevant terms of these primary driving forces. To this end, a linear transition function (21) is introduced to scale the respective contributions of particles close to the melt temperature \(T_{\text {m}}\) with the goal to smoothen out these discontinuities. In the subsequent sections the described regularization strategy is applied to relevant terms of the momentum equation.

Remark 4

The linear transition function \(f\left[ x, x_{1}, x_{2}\right]\) and the complementary linear transition function \(\bar{f}\left[ x, x_{1}, x_{2}\right] = 1-f\left[ x, x_{1}, x_{2}\right]\) with arbitrary arguments x, \(x_{1} < x_{2}\) are defined as

$$\begin{aligned}&f\left[ x, x_{1}, x_{2}\right] = {\left\{ \begin{array}{ll} 1 &{} \quad \text {if}\quad x> x_{2} , \\ \frac{x-x_{1}}{x_{2}-x_{1}} &{} \quad \text {if}\quad x_{2} \ge x \ge x_{1} , \\ 0 &{} \quad \text {if}\quad x< x_{1} , \end{array}\right. } \quad \text {and}\quad \nonumber \\& \bar{f}\left[ x, x_{1}, x_{2}\right] = {\left\{ \begin{array}{ll} 0 &{} \quad \text {if}\quad x > x_{2} , \\ \frac{x_{2}-x}{x_{2}-x_{1}} &{} \quad \text {if}\quad x_{2} \ge x \ge x_{1}, \\ 1 &{} \quad \text {if}\quad x < x_{1} . \end{array}\right. } \end{aligned}$$
(21)

Remark 5

The vapor phase is not modeled explicitly herein such that phase transitions liquid \(\leftrightarrow\) vapor are considered implicitly in terms of evaporation-induced recoil pressure forces (10) and heat losses (18). Note that the latent heat of melting could be considered in a straightforward manner as well by employing, e.g., an apparent capacity scheme relying on an increased heat capacity \(c_{p}\) within a finite temperature interval [51]. For the sake of simplicity, temperature-independent parameter values are considered herein except for the temperature-dependent surface tension coefficient.

3.3 Modeling microfluidic flow via weakly compressible SPH

The density of a particle i with mass \(m_{i}\) is determined via summation \(\rho _{i} = m_{i} \sum _{j} W_{ij}\) of the respective smoothing kernel contributions of all neighboring particles j resulting in exact conservation of mass. Hence, the actual volume of a particle i is computed as \(V_{i} = m_{i}/\rho _{i}\) and the pressure \(p_{i}\) follows directly from evaluation of the discrete version of the equation of state (3) for particle i. The discretized momentum equation to evaluate the total acceleration \(\mathbf {a}_{i} = {\mathrm{d}\mathbf {u}_{i}}/{\mathrm{d} t}\) of a particle i can be formulated as

$$\begin{aligned} \mathbf {a}_{i} = \frac{1}{m_{i}} \left( \mathbf {F}_{p,i} + \mathbf {F}_{\nu ,i} + \mathbf {F}_{s,i} + \mathbf {F}_{v,i} + \mathbf {F}_{d,i} + \mathbf {F}_{b,i}\right) + \mathbf {b}_{i} \, . \end{aligned}$$
(22)

The pressure forces \(\mathbf {F}_{p,i}\), viscous forces \(\mathbf {F}_{\nu ,i}\), surface tension forces \(\mathbf {F}_{s,i}\) as well as evaporation-induced recoil pressure forces \(\mathbf {F}_{v,i}\) acting on particle i result from summation of all interaction contributions with neighboring particles j. Optionally, additional viscous dissipation forces \(\mathbf {F}_{d,i}\) are applied at the liquid–gas and solid–fluid interface, and, barrier forces \(\mathbf {F}_{b,i}\) are acting in rare scenarios of impermissibly close particles only to retain reasonable particle distributions. No-slip boundary conditions are modeled using a boundary particle formulation proposed in [52] resulting in contributions to the acceleration of a particle i located close to such a boundary. For a particle r of a rigid body k these acceleration contributions are denotes as \(\mathbf {a}_{ir}\) and used for the evaluation of the resultant forces and torques acting on that rigid body. In the following, the force contributions in the momentum equation above including regularization procedures to avoid discontinuities stemming from phase transitions solid \(\leftrightarrow\) liquid are discussed.

3.3.1 Pressure and viscous forces

As in the authors’ previous works [40, 43, 44], the pressure and viscous forces are discretized following a formulation proposed in [52, 53] as

$$\begin{aligned}\mathbf {F}_{p,i} + \mathbf {F}_{\nu ,i} = \sum _{j} \left( V_{i}^{2}+V_{j}^{2}\right) &\left( - \frac{\rho _{j}p_{i}+\rho _{i}p_{j}}{\rho _{i} + \rho _{j}} \frac{\partial W}{\partial r_{ij}} \mathbf {e}_{ij} \right. \nonumber \\&\quad \left. + \frac{2\eta _{i}\eta _{j}}{\eta _{i}+\eta _{j}} \frac{\mathbf {u}_{ij}}{r_{ij}} \frac{\partial W}{\partial r_{ij}} \right) \, , \end{aligned}$$
(23)

with unit vector \(\mathbf {e}_{ij} = \left( \mathbf {r}_{i} - \mathbf {r}_{j}\right) /r_{ij}\) and relative velocity \(\mathbf {u}_{ij} = \mathbf {u}_{i}-\mathbf {u}_{j}\). In addition, the transport-velocity formulation [53], which utilizes a constant background pressure \(p_{b}\) to suppress the problem of tensile instability is employed herein.

3.3.2 Surface tension forces

The surface tension forces consist of an interface normal curvature-proportional contribution and an interface tangential Marangoni contribution due to surface tension gradients. Accordingly, the surface tension forces are given as

$$\begin{aligned} \mathbf {F}_{s,i} = f\left[ T_{i}, T_{\text {m}}, T_{\text {m}} + \Delta {}T_{s}\right] \left( - V_{i} \alpha _{i} \kappa _{i} \varvec{\nabla }{c}_{i}^{lg} + V_{i} \alpha _{i}' \delta ^{lg}_{i} \varvec{\nabla }_{t} {T}_{i} \right) , \end{aligned}$$
(24)

with the curvature

$$\begin{aligned} \kappa _{i} = - \frac{ \sum _{j} f\left[ T_{j}, T_{\text {m}}, T_{\text {m}} + \Delta {}T_{s}\right] \cdot V_{j} \left( \mathbf {n}^{lg}_{i}-\mathbf {n}^{lg}_{j}\right) \frac{\partial W}{\partial r_{ij}} \mathbf {e}_{ij} }{ \sum _{j} f\left[ T_{j}, T_{\text {m}}, T_{\text {m}} + \Delta {}T_{s}\right] \cdot V_{j} W_{ij} } \end{aligned}$$
(25)

based on a formulation proposed in [54]. Here, \(\varvec{\nabla }_{t} {T}_{i}\) represents the projection of the temperature gradient into the interface tangential plane following

$$\begin{aligned}&\varvec{\nabla }_{t} {T}_{i} = \left( \mathbf {I} - \mathbf {n}^{lg}_{i} \otimes \mathbf {n}^{lg}_{i} \right) \varvec{\nabla }{T}_{i} \quad \text {with} \nonumber \\ &\varvec{\nabla }{T}_{i} = \sum _{j} V_{j} (T_{j} - T_{i}) \frac{\partial W}{\partial r_{ij}} \mathbf {e}_{ij} . \end{aligned}$$
(26)

The surface tension forces (24) are computed for particles i and j of the liquid and gas phase. To avoid discontinuities stemming from phase transitions solid \(\leftrightarrow\) liquid (as outlined above), the surface tensions forces (24) are regularized within a small temperature interval \(\Delta {}T_{s}\) above the melt temperature \(T_{\text {m}}\) utilizing the linear transition function (21). Likewise, the contributions from neighboring particles j to the curvature (25) are regularized. Note that in the evaluation of the temperature gradient (26) particles of all phases, i.e., solid, liquid, and gas, are considered. For this reason, the temperature gradient will not suffer from these discontinuities.

3.3.3 Wetting phenomena

Following a strategy proposed in [50], the wetting forces (9) are not discretized and evaluated directly. Instead, the desired equilibrium wetting angle \(\theta _{0}\) is enforced prescribing the interface normal between the liquid and gas phase in the triple line region. To begin with, the standard interface normal between liquid and gas phase is evaluated following (19) and (20) and denoted as \(\bar{\mathbf {n}}^{lg}_{i}\) in the following. In a next step, a distance measure and an interface normal for a particle i of the fluid phase with respect to particles j of the solid phase are defined. Thereto, the color field function \(c_{i}^{sf}\) as well as its gradient \(\varvec{\nabla }{c}_{i}^{sf}\) at the solid-fluid interface are defined based on (19) with the scaling factor \(\chi _{j} = \bar{f}\left[ T_{j}, T_{\text {m}} - \Delta {}T_{s}, T_{\text {m}}\right]\). The additional factor ensures that for a particle i the color field function and also its gradient do not change abruptly when particles j are subject to phase transitions solid \(\leftrightarrow\) liquid. The corresponding interface normal \(\mathbf {n}_{i}^{sf}\) is defined based on (20). The interface normal to be prescribed in the triple line region between the liquid and gas phase is determined on the basis of the equilibrium wetting angle \(\theta _{0}\) according to

$$\begin{aligned} \hat{\mathbf {n}}^{lg}_{i} = \mathbf {t}^{sf}_{i} \sin {\theta _{0}} - \mathbf {n}_{i}^{sf} \cos {\theta _{0}} , \end{aligned}$$
(27)

where the interface tangent \(\mathbf {t}^{sf}_{i}\) is given by

$$\begin{aligned}&\mathbf {t}^{sf}_{i} = {\left\{ \begin{array}{ll} \tilde{\mathbf {t}}^{sf}_{i}/\Vert \tilde{\mathbf {t}}^{sf}_{i}\Vert &{} \quad \text {if}\quad \Vert \tilde{\mathbf {t}}^{sf}_{i}\Vert > \epsilon , \\ \mathbf {0} &{} \quad \text {otherwise,}\quad \end{array}\right. } \quad \text {with}\quad \nonumber \\&\tilde{\mathbf {t}}^{sf}_{i} = \bar{\mathbf {n}}^{lg}_{i} - \left( \bar{\mathbf {n}}^{lg}_{i} \cdot \mathbf {n}^{sf}_{i}\right) \mathbf {n}^{sf}_{i}. \end{aligned}$$
(28)

The denominator above can only become zero when the interface normals \(\bar{\mathbf {n}}^{lg}_{i}\) and \(\mathbf {n}^{sf}_{i}\) are parallel or anti-parallel, which only happens for very rare configurations, e.g., perfect wetting, or a liquid bubble close to a solid wall with a very thin gas film in between. To have a smooth transition of the liquid-gas interface normal \(\mathbf {n}^{lg}_{i}\) from the triple line region with prescribed interface normal \(\hat{\mathbf {n}}^{lg}_{i}\) to the interior domain with standard interface normal \(\bar{\mathbf {n}}^{lg}_{i}\), the following correction scheme in analogy to [50] is employed:

$$\begin{aligned}&\mathbf {n}^{lg}_{i} = {\left\{ \begin{array}{ll} \tilde{\mathbf {n}}^{lg}_{i} /\Vert \tilde{\mathbf {n}}^{lg}_{i}\Vert &{} \quad \text {if}\quad \Vert \tilde{\mathbf {n}}^{lg}_{i}\Vert > \epsilon , \\ \mathbf {0} &{} \quad \text {otherwise,}\quad \end{array}\right. } \quad \text {with} \nonumber \\&\tilde{\mathbf {n}}^{lg}_{i} = f\left[ {c}_{i}^{sf}, c_{1}, c_{2}\right] \cdot \hat{\mathbf {n}}^{lg}_{i} + \bar{f}\left[ {c}_{i}^{sf}, c_{1}, c_{2}\right] \cdot \bar{\mathbf {n}}^{lg}_{i} \end{aligned}$$
(29)

As long as the norms of \(\hat{\mathbf {n}}^{lg}_{i}\) and \(\bar{\mathbf {n}}^{lg}_{i}\) are equal to unity, the denominator can only be zero if the two vectors are anti-parallel, which is very unlikely for configurations sufficiently close to the equilibrium wetting angle \(\theta _{0}\). Note that the correction parameters \(c_{1} = 0.0\) and \(c_{2} = 0.2\) were found to be reasonable.

3.3.4 Recoil pressure forces

The discrete version of the evaporation-induced recoil pressure forces (10) based on a phenomenological model [46] is given by

$$\begin{aligned} \mathbf {F}_{v,i} = - V_{i} p_{v,i} \mathbf {n}_{i}^{lg} \delta _{i}^{lg}, \end{aligned}$$
(30)

where \(p_{v,i}\) is the recoil pressure according to (10) evaluated for particle i.

3.3.5 Viscous dissipation forces

As proposed in [40], viscous dissipation forces are employed selectively at the liquid–gas and solid–fluid interface to avoid oscillations originating from the primary force contributions at the liquid–gas interface and from the phase transitions solid \(\leftrightarrow\) liquid. The discrete version of the viscous dissipation forces is based on a stabilization term denoted as artificial viscosity [55] and is given as

$$\begin{aligned} \mathbf {F}_{d,i} = - m_{i} \alpha _{i} \sum _{j} m_{j} \frac{ h \bar{c}_{ij}}{\bar{\rho }_{ij}} \frac{\mathbf {u}_{ij} \cdot \mathbf {r}_{ij}}{( r_{ij}^{2} + \epsilon h^{2} )} \frac{\partial W}{\partial r_{ij}} , \end{aligned}$$
(31)

with the inter-particle averaged speed of sound \(\bar{c}_{ij} = (c_{i}+c_{j})/2\) and density \(\bar{\rho }_{ij} = (\rho _{i}+\rho _{j})/2\). Here, the constant \(\epsilon \ll 1\) is applied to ensure a non-zero denominator. The artificial viscosity factor is split into two contributions \(\alpha _{i} = \alpha ^{lg}_{i}+\alpha ^{sf}_{i}\). The first one is given as

$$\begin{aligned} \alpha ^{lg}_{i} = \alpha ^{lg}_{0} h \delta ^{lg}_{i} \end{aligned}$$
(32)

and is acting only on the liquid–gas interface. It has been demonstrated in [40], that this contribution (if \(\alpha ^{lg}_{0}\) is chosen in a reasonable range) effectively reduces spurious interface flows known to occur in CSF formulations [45, 50] without introducing additional dissipation of physically relevant flow characteristics in the interior fluid domain. The second contribution of the artificial viscosity factor is defined as

$$\begin{aligned} \alpha ^{sf}_{i} = \alpha ^{sf}_{0} \bar{f}\left[ T_{i}, T_{\text {m}}, T_{\text {m}} + \Delta {}T_{d}\right] . \end{aligned}$$
(33)

Accordingly, this contribution only acts on particles of the fluid phase with temperatures within a small temperature interval \(\Delta {}T_{d}\) above the melt temperature \(T_{\text {m}}\) and thus effectively damps potential instabilities arising from phase transitions solid \(\leftrightarrow\) liquid (as outlined above). Both contributions to the artificial viscosity factor can also be interpreted from a physical point of view as a non-conservative surface tension formulation with interface viscosity [56] and a physical model for the gradual phase transition of alloys between liquidus and solidus temperature.

3.3.6 Barrier forces

In order to retain reasonable particle distributions and to circumvent instabilities (originating from violations of the partition of unity of the smoothing kernel), especially in the triple line region during phase transitions, additional elastic and viscous barrier forces are introduced. These barrier forces only act in rare scenarios where particles are impermissibly close to each other and thus have no significant effect on the physical flow characteristics of the problem. The barrier forces are defined according to

$$\begin{aligned}&\mathbf {F}_{b,i} = \sum _{j} \left( k_{b} g_{ij} + d_{b} {|}g_{ij}{|} \dot{g}_{ij} \right) \mathbf {e}_{ij} \quad \text {with}\quad \nonumber \\& g_{ij} = {\left\{ \begin{array}{ll} r_{b}-r_{ij} &{} \quad \text {if}\quad r_{ij}< r_{b} , \\ 0 &{} \quad \text {otherwise,}\quad \end{array}\right. }\nonumber \\&\dot{g}_{ij} = {\left\{ \begin{array}{ll} - \mathbf {e}_{ij} \cdot \mathbf {u}_{ij} &{} \quad \text {if}\quad r_{ij} < r_{b} , \\ 0 &{} \quad \text {otherwise,}\quad \end{array}\right. } \end{aligned}$$
(34)

with stiffness constant \(k_{b}\), damping constant \(d_{b}\), and interaction distance \(r_{b} < h\).

3.4 Modeling the motion of rigid bodies discretized by particles

As proposed in the authors’ previous work [43], the rigid bodies making up the solid phase are fully resolved, that is spatially discretized as clusters of particles. These particles are fixed relative to a rigid body frame, i.e., there is no relative motion among particles constituting a rigid body. Consequently, the particles of a rigid body are not evolved in time individually, but instead follow the motion of the rigid body. This approach offers several advantages: First, advanced boundary particle methods, e.g., based on the extrapolation of fluid quantities to the solid phase [48, 52, 57], to accurately model momentum exchange at the fluid–solid interface, can be utilized. Second, thermal conduction in the solid and the fluid phase can be modeled, e.g., based on [58], without the need for sophisticated coupling formulations at the fluid–solid interface. Finally, phase transitions solid \(\leftrightarrow\) liquid can be evaluated in a straightforward manner for each involved particle separately. In the following, the modeling approach as proposed in [43] is briefly recapitulated.

3.4.1 Evaluation of mass-related quantities of rigid bodies

The mass \(m_{k}\) and the center of mass position \(\mathbf {r}_{k}\) of a rigid body k are computed as

$$\begin{aligned} m_{k} = \sum _{r} m_{r} \quad \text {and}\quad \mathbf {r}_{k} = \frac{\sum _{r} m_{r} \mathbf {r}_{r}}{\sum _{r} m_{r}} , \end{aligned}$$
(35)

with mass \(m_{r}\) and position \(\mathbf {r}_{r}\) of all particles r affiliated to a rigid body k. Accordingly, the mass moment of inertia \(\mathbf {I}_{k}\) of a rigid body k follows component-wise (in index notation) as

$$\begin{aligned}I_{k,ij} = &\sum _{r} \left[ I_{r} \, \delta _{ij} + \left[ \sum _{q} \left( r_{k,q} - r_{r,q} \right) ^{2} \delta _{ij} \right. \right. \nonumber \\&\quad \left. \left. - \left( r_{k,i} - r_{r,i} \right) \left( r_{k,j} - r_{r,j} \right) \vphantom{\sum _{r}} \right] m_{r} \right] \end{aligned}$$
(36)

with mass moment of inertia \(I_{r}= 0.4 m_{r} \root 3 \of {0.75/\pi } \Delta {}x\) of particles r [43] and Kronecker delta \(\delta _{ij}\). Each time a rigid body k is subject to phase transitions, i.e., gains or loses particles r, the mass \(m_{k}\), center of mass position \(\mathbf {r}_{k}\), and mass moment of inertia \(\mathbf {I}_{k}\) are updated. In addition, the velocity \(\mathbf {u}_{k}\) is updated based on quantities prior to phase transitions indicated by index \(\left( \cdot \right) ^{\prime }\) as

$$\begin{aligned} \mathbf {u}_{k} = \mathbf {u}_{k}^{\prime } + \boldsymbol {\omega }_{k} \times \left( \mathbf {r}_{k} - \mathbf {r}_{k}^{\prime }\right) \end{aligned}$$
(37)

following rigid body motion with (unchanged) angular velocity \(\boldsymbol {\omega }_{k}\).

3.4.2 Evaluation of resultant forces and torques acting on rigid bodies

First of all, the combined coupling and contact forces acting on a particle r of a rigid body k are given as \(\mathbf {f}_{r} = \sum _{i} \mathbf {f}_{ri} + \sum _{\hat{k}} \sum _{\hat{r}} \mathbf {f}_{r\hat{r}}\) with coupling forces \(\mathbf {f}_{ri} = - m_{i} \mathbf {a}_{ir}\) stemming from interaction with particles i of the fluid phase (while considering conservation of linear momentum), and contact forces \(\mathbf {f}_{r\hat{r}}\) stemming from interaction with particles \(\hat{r}\) of contacting rigid bodies \(\hat{k}\) as defined below. Accordingly, the resultant forces \(\mathbf {f}_{k}\) and torques \(\mathbf {m}_{k}\) acting on a rigid body k are computed as

$$\begin{aligned} \mathbf {f}_{k} = \sum _{r} \mathbf {f}_{r} \quad \text {and}\quad \mathbf {m}_{k} = \sum _{r} \mathbf {r}_{rk} \times \mathbf {f}_{r} \end{aligned}$$
(38)

with the relative positions \(\mathbf {r}_{rk} = \mathbf {r}_{r} - \mathbf {r}_{k}\) and the resultant forces \(\mathbf {f}_{r}\) of all particles r of the rigid body.

3.4.3 Contact evaluation between neighboring rigid bodies

Mechanical contact between neighboring rigid bodies k and \(\hat{k}\) is modeled based on a contact normal force law that is acting between pairs of neighboring particles r and \(\hat{r}\) of the contacting rigid bodies. Accordingly, the contact force acting on a particle r of rigid body k due to contact with a particle \(\hat{r}\) of neighboring rigid body \(\hat{k}\) is given as

$$\begin{aligned} \mathbf {f}_{r\hat{r}} = {\left\{ \begin{array}{ll} \left( k_{c} g_{r\hat{r}} + d_{c} \dot{g}_{r\hat{r}} \right) \, \mathbf {e}_{r\hat{r}} &{} \quad \text {if}\quad \left( k_{c} g_{r\hat{r}} + d_{c} \dot{g}_{r\hat{r}} \right) > 0 , \\ 0 &{} \quad \text {otherwise,}\quad \end{array}\right. } \end{aligned}$$
(39)

where

$$\begin{aligned}&g_{r\hat{r}} = {\left\{ \begin{array}{ll} \Delta {}x-r_{r\hat{r}} &{} \quad \text {if}\quad r_{r\hat{r}}< \Delta {}x , \\ 0 &{} \quad \text {otherwise,}\quad \end{array}\right. }\nonumber \\&\dot{g}_{r\hat{r}} = {\left\{ \begin{array}{ll} - \mathbf {e}_{r\hat{r}} \cdot \mathbf {u}_{r\hat{r}} &{} \quad \text {if}\quad r_{r\hat{r}} < \Delta {}x , \\ 0 &{} \quad \text {otherwise,}\quad \end{array}\right. } \end{aligned}$$
(40)

with unit vector \(\mathbf {e}_{r\hat{r}} = \left( \mathbf {r}_{r} - \mathbf {r}_{\hat{r}}\right) /r_{r\hat{r}}\), relative velocity \(\mathbf {u}_{r\hat{r}} = \mathbf {u}_{r}-\mathbf {u}_{\hat{r}}\), stiffness constant \(k_{c}\), and damping constant \(d_{c}\). This approach ensures that only repulsive forces between pairs of neighboring particles are considered.

3.5 Modeling thermal conduction

The conductive term in the energy equation (14) is discretized using a formulation from [58], that is especially suitable for problems involving a discontinuity of the thermal conductivity k across phase interfaces. Accordingly, the discretized form of the energy equation reads

$$\begin{aligned} c_{p,i} \frac{\mathrm{d}T_{i}}{\mathrm{d}t} = \frac{1}{\rho _{i}} \left( \sum _{j} V_{j} \frac{4k_{i}k_{j}}{k_{i}+k_{j}} \frac{T_{j}-T_{i}}{r_{ij}} \frac{\partial W}{\partial r_{ij}} + \tilde{s}^{hg}_{l,i} + \tilde{s}^{lg}_{v,i}\right) . \end{aligned}$$
(41)

The discrete versions of the laser beam source term \(\tilde{s}^{hg}_{l,i}\) and the evaporation-induced heat loss term \(\tilde{s}^{lg}_{v,i}\) result directly from evaluating (17) and (18) for the discrete particle i.

3.6 Time integration scheme

The discretized governing equations are integrated in time applying explicit time integration schemes. For the sake of brevity, these schemes are not further delineated herein referring to [40, 43, 44] instead. Several restrictions on the time step size \(\Delta {}t\) are required to maintain stability of the applied time integration schemes, which are the Courant–Friedrichs–Lewy (CFL) condition, the viscous condition, the body force condition, the surface tension condition, the contact condition, and the conductivity-condition [48, 49, 53, 59, 60]

$$\begin{aligned}\Delta {}t \le \min &\left\{ 0.25 \frac{h}{c+\Vert \mathbf {u}_{max}\Vert }, \quad 0.125\frac{h^{2}}{\nu }, \right. \nonumber \\&\left. \quad 0.25 \sqrt{\frac{h}{\Vert \mathbf {b}_{max}\Vert }}, \quad 0.25 \sqrt{\frac{\rho h^3}{2 \pi \alpha }},\right. \nonumber \\&\left. \quad 0.22 \sqrt{\frac{m}{k_{b/c}}}, \quad 0.1 \frac{\rho c_{p} h^{2}}{k} \right\} , \end{aligned}$$
(42)

with maximum fluid velocity \(\mathbf {u}_{\max }\) and maximum body force \(\mathbf {b}_{\max }\). The contact condition with the mass m of involved particles is relevant for barrier forces with stiffness constant \(k_{b}\) as well as for solid contact forces with stiffness constant \(k_{c}\) [43]. In both cases also the damping constants \(d_{b}\) and \(d_{c}\) should be limited (here based on a trial and error approach) to avoid time integration instabilities.

4 Numerical examples

In the following, the versatility and robustness of the proposed computational modeling framework is demonstrated examining several numerical examples in three dimension. The focus is set on showcasing the models general capability to capture the physical phenomena that are characteristic for AM processes such as BJT, MJT, DED, and PBF. Accordingly, representative material parameters are selected, while, for the sake of simplicity, detailed process conditions are not entirely met but replicated in an idealized way. All simulations are performed on an in-house cluster consisting of up to 16 nodes with \(2 \times 12\) cores each (Intel Xeon E5-2680 v3 Haswell, 2.5 GHz, 64 GB RAM). To give an impression about the required computational effort of each simulation, the number of cores, the number of SPH particles per core, and the mean wall-clock time per time step are given along with the total number of SPH particles used for discretization of the domain.

4.1 Representative configuration for the numerical simulation of additive manufacturing processes

This section gives a representative configuration for the numerical examples in the context of the considered AM processes, that is, unless explicitly stated otherwise, applied in the subsequent examples. As in the authors’ previous work [40], representative material parameters close to stainless steel at the melt temperature \(T_{\text {m}} = {1700}\, \hbox {K}\) are selected based on [13, 27]. To provide an overview, the material parameters for molten and solid metal applied herein are given in Tables 1 and 2, while the material parameters for atmospheric gas are given in Table 3. To keep the computational effort at a feasible level considering the time step restrictions (42), the density and viscosity of atmospheric gas are selected based on the ratios \(\rho _{0}^{l}/\rho _{0}^{g} = 100\) and \(\eta ^{l}/\eta ^{g} = 10\) with respect to the material parameters of molten metal. This procedure was motivated and justified in the authors’ previous work [40]. In the case of BJT examples, the material parameters as given in Table 4 are applied for liquid binder. The initial powder bed as used for the BJT and PBF examples is obtained in a pre-processing step based on a cohesive powder model [61, 62] using the discrete element method (DEM) and a log-normal type size distribution for the powder particles with diameters between \({16}\,\upmu \hbox {m}\) and \({32}\,\upmu \hbox {m}\). All phases are initially at rest with the temperature 500 K. On all boundaries no-slip conditions are applied and the temperature 500 K is prescribed. A gravitational acceleration of magnitude \({9.81}\,{\text{m s}}^{-2}\) is acting in downward direction set as body force per unit mass of all involved phases. A standard discretization strategy with initial particle spacing \(\Delta {}x = {1.\overline{6}}\,\upmu \hbox {m}\) and time step size \(\Delta {}t = 1.0 \times 10^{-6}\,\hbox {ms}\) is applied as given in Table 5. For all fluid phases, the reference pressure of the weakly compressible model is set to \(p_{0}= 1.0 \times 10^{7} \,\hbox {Pa}\) and the background pressure of the transport-velocity formulation [53] to \(p_{b} = 5 p_{0}\). Barrier forces are evaluated with interaction distance \(r_{b} = {0.8\overline{3}}\,\upmu \hbox {m}\) and the stiffness and damping constants \(k_{b} = {1.0}\,\hbox {kg s}^{-2}\) and \(d_{b} = {1.0}\,\hbox {kg m}^{-1}\,\hbox {s}^{-1}\). The stiffness and damping constants applied for contact evaluation of rigid bodies are set to \(k_{c} = {1.0}\,\hbox {kg s}^{-2}\) and \(d_{c} = {1.0} \times 10^{-4}\,\hbox {kg s}^{-1}\). The domain boundaries are modeled as rigid walls using a boundary particle formulation following [52]. In a post-processing step the obtained particle-based results are visualized applying an SPH approximation as in the authors’ previous work [40, 43, 44].

4.2 Binder jetting

This example aims to demonstrate the general applicability of the proposed modeling framework in the context of BJT processes examining the impact of a liquid binder droplet on a powder bed. For that purpose, coupled microfluid-powder dynamics are considered while thermal effects and phase transitions are irrelevant. Note that curing of the liquid binder to form the so-called green part is not considered herein. Consider a domain with dimension \({320}\,\upmu \hbox {m} \times {320}\,\upmu \hbox {m} \times {200}\,\upmu \hbox {m}\) (\(4.5\times10^{6}\) SPH particles, 192 cores, \( 23.3 \times 10^{3}\) SPH particles per core, \({1.15}\,\hbox {s}\) mean wall-clock time per time step). The lower part of the domain is occupied by a substrate of thickness \({20}\,\upmu \hbox {m}\). A powder bed consisting of a total of 500 individual powder particles with diameters between \({16}\,\upmu \hbox {m}\) and \({32}\,\upmu \hbox {m}\) is resting on the substrate. A spherical binder droplet with diameter \({80}\,\upmu \hbox {m}\) is placed centrally above the powder bed. The center of the droplet is a distance of \({100}\,\upmu \hbox {m}\) above the substrate. The remainder of the domain is filled with atmospheric gas and surrounded by rigid walls. The binder droplet is initialized with a velocity pointing in downward direction such that it is approaching the powder bed and the substrate. In the following, three variants with different values for this velocity are considered, namely, \({1}\,\hbox {m s}^{-1}\), \({10}\,\hbox {m s}^{-1}\) and \({50}\, \hbox {m s}^{-1}\). Note, that the impact velocity in the real process depends on the nozzle exit velocity of the binder droplet and the falling height.

To begin with, a time series of the results until \(t = {0.1}\,\hbox {ms}\) obtained with initial velocity \({1}\,\hbox {m s}^{-1}\) of the liquid binder droplet are given in Figs. 2 and 3 (see Supplementary Videos 1 and 2). The liquid binder droplet gradually penetrates into the powder bed. Slight powder dynamics can be observed as metal powder particles are gently pushed outwards by the liquid binder. The liquid binder remains in a compact shape enclosing solely few metal powder particles in the center. At \(t = {0.1}\,\hbox {ms}\) a downward movement of the binder towards the substrate is still visible.

Fig. 2
figure 2

Sectional view of BJT example with initial velocity \({1}\, \hbox {m s}^{-1}\) of the liquid binder droplet: time series illustrating the impact of the liquid binder droplet on the powder bed

Fig. 3
figure 3

Overall view of BJT example with initial velocity \({1}\,\hbox {m s}^{-1}\) of the liquid binder droplet: time series illustrating the impact of the liquid binder droplet on the powder bed

In a next step, the initial velocity of the liquid binder droplet is increased to \({10}\,\hbox {m s}^{-1}\). The obtained results are given in Figs. 4 and 5 (see Supplementary Videos 3 and 4) until \(t = {0.05} \, \hbox {ms}\). Due to its higher initial velocity, the liquid binder droplet is subject to oscillations upon impact with the powder bed. Besides, more pronounced powder dynamics are observed, i.e., the powder packing beneath the droplet is significantly compressed, and the liquid binder droplet is spread across a slightly larger area on the powder bed with less penetration depth as compared to the previous variant. At \(t = {0.05}\,\hbox {ms}\) a slight downward movement of the binder towards the substrate is still visible.

To enhance these effects, in the third variant the initial velocity of the liquid binder droplet is set to \({50}\,\hbox {m s}^{-1}\). The obtained results are given in Figs. 6 and 7 (see Supplementary Videos 5 and 6). The liquid binder droplet splashes into the powder bed, evoking highly dynamic motion of the metal powder particles. Besides, wetting of the liquid binder on the surface of individual powder particles can be observed. At the same time, spatters of liquid binder are ejected that subsequently adhere on the rigid walls surrounding the domain. The high impact velocity has the effect, that the packing density and uniformity of the powder bed is strongly disturbed and that the liquid binder is spread across a large area on the powder bed.

In sum, the results of these three variants demonstrate, that the microfluid dynamics of high-velocity binder droplets and their interaction with mobile powder particles can be captured by the proposed modeling framework in a robust manner. The replicated physical phenomena are typical for BJT processes [3, 63], and, consequently, the proposed modeling framework can be recommended as a useful tool for detailed studies of these processes.

Fig. 4
figure 4

Sectional view of BJT example with initial velocity \({10}\, \hbox {m s}^{-1}\) of the liquid binder droplet: time series illustrating the impact of the liquid binder droplet on the powder bed

Fig. 5
figure 5

Overall view of BJT example with initial velocity \({10}\,\hbox {m s}^{-1}\) of the liquid binder droplet: time series illustrating the impact of the liquid binder droplet on the powder bed

Fig. 6
figure 6

Sectional view of BJT example with initial velocity \({50}\,\hbox {m s}^{-1}\) of the liquid binder droplet: time series illustrating the impact of the liquid binder droplet on the powder bed

Fig. 7
figure 7

Overall view of BJT example with initial velocity \({50}\,\hbox {m s}^{-1}\) of the liquid binder droplet: time series illustrating the impact of the liquid binder droplet on the powder bed

4.3 Material jetting

In the next example, the behavior of molten metal droplets that are ejected on a substrate is examined. The setup is close to potential application scenarios in MJT processes. A domain with dimension \({160}\,\upmu \hbox {m} \times {160}\,\upmu \hbox {m} \times {260}\,\upmu \hbox {m}\) (\({1.7 \times 10^{6}}\) SPH particles, 48 cores, \({35.1 \times 10^{3}}\) SPH particles per core, \({3.05}\,\hbox {s}\) mean wall-clock time per time step) is given. The lower part of the domain is occupied by a substrate of thickness \({20}\,\upmu \hbox {m}\). First, a spherical molten metal droplet with diameter \({50}\,\upmu \hbox {m}\) is placed centrally above the substrate with a distance of \({40}\,\upmu \hbox {m}\) with respect to the center of the drop. The remainder of the domain is filled with atmospheric gas and surrounded by rigid walls. The molten metal droplet is initialized with the temperature \({2500}\,\hbox {K}\) and the velocity \({1.6}\,\hbox {m s}^{-1}\) pointing in downward direction such that it is approaching the substrate.

Fig. 8
figure 8

Sectional view of MJT example with one molten metal droplet and initial temperature \({500}\,\hbox {K}\) of the substrate: time series illustrating the impact of the molten metal droplet on the substrate and the solidification process with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({2500}\,\hbox {K}\) (red)

Fig. 9
figure 9

Overall view of MJT example with one molten metal droplet and initial temperature \({500}\,\hbox {K}\) of the substrate: time series illustrating the impact of the molten metal droplet on the substrate and the solidification process with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({2500}\,\hbox {K}\) (red)

Fig. 10
figure 10

Sectional view of MJT example with one molten metal droplet and initial temperature \({1500}\,\hbox {K}\) of the substrate: time series illustrating the impact of the molten metal droplet on the substrate and the solidification process with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({2500}\,\hbox {K}\) (red)

Fig. 11
figure 11

Overall view of MJT example with one molten metal droplet and initial temperature \({1500}\,\hbox {K}\) of the substrate: time series illustrating the impact of the molten metal droplet on the substrate and the solidification process with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({2500}\,\hbox {K}\) (red)

A time series of the results obtained for a single molten metal droplet is given in Figs. 8 and 9 (see Supplementary Videos 7 and 8). Typical surface tension-driven oscillations of the droplet can be observed caused by the impact with the substrate. The molten metal immediately solidifies when it comes into contact with the substrate that itself does not exhibit noticeable melting. In practice, this behavior could suggest insufficient metallurgical bonding to the substrate, as the thermal energy of the droplet does not suffice to produce a notable remelting depth in the substrate [4, 64].

For the next variant, the initial temperature of the substrate is set to \({1500}\,\hbox {K}\) to examine its influence on the resulting melt pool shape. The results obtained for this variant are illustrated in Figs. 10 and 11 (see Supplementary Videos 9 and 10). A maximum melt pool depth of approximately \({16}\,\upmu \hbox {m}\) is observed at \(t = {0.075} \, \hbox {ms}\), that can be explained with the higher initial temperature of the substrate compared to the previous variant. Accordingly, the oscillations of the droplet are less pronounced while the droplet itself is spread across a larger area on the substrate. As a result, the final solidified geometry is flatter than for the previous variant and a better bonding to the substrate can be expected due to the increased remelting depth.

In a next step, the example is extended to consider a total of two respectively three molten metal droplets. The droplets are each placed a distance of \({40}\,\upmu \hbox {m}\) and \({200}\,\upmu \hbox {m}\) respectively \({40}\,\upmu \hbox {m}\), \({120}\,\upmu \hbox {m}\), and \({200}\,\upmu \hbox {m}\) above the substrate. The lateral distance between the droplets is set to \({25}\,\upmu \hbox {m}\). That is, the projection of the initial position of the droplets onto the substrate constitutes a line when considering two droplets, and an equilateral triangle when considering three droplets. The initial temperature of the substrate is set again to the standard value \({500}\, \hbox {K}\), while the initial temperature of the molten metal droplets remains at \({2500}\,\hbox {K}\). The obtained results for both variants are given in Figs. 12 and 13 (see Supplementary Videos 11 and 12). For the two droplet variant, the first droplet solidifies in the same fashion as in the single droplet variant. When the droplet is almost completely solidified the second droplet comes into contact with the first one and shortly after with the substrate. Through contact with the second droplet, the interface of the first droplet partially remelts. Due to contact with the substrate and the first droplet the second droplet solidifies slightly faster than observed for a single droplet. In the variant with three droplets, the second droplet hits the first droplet earlier such that less than half of the first droplet is solidified. The liquid and partially liquid droplets coalesce during the descend of the second droplet forming one large liquid phase. Due to the motion of the second droplet, the liquid exhibits large oscillations which are increased when the third droplet coalesces with the liquid phase. This oscillation leads to large scale ripples on the surface of the droplets during solidification. With respect to the practical realization of the process, the three droplet variant represents a case where the solidification time interval between successive droplet impacts is too short, leading to droplet–droplet coalescence, and in turn to increased surface roughness of the final part.

Fig. 12
figure 12

Overall view of MJT example with two molten metal droplets and initial temperature \({500}\,\hbox {K}\) of the substrate: time series illustrating the impact of the molten metal droplet on the substrate and the solidification process with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({2500}\,\hbox {K}\) (red)

Fig. 13
figure 13

Overall view of MJT example with three molten metal droplets and initial temperature \({500}\,\hbox {K}\) of the substrate: time series illustrating the impact of the molten metal droplet on the substrate and the solidification process with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({2500}\,\hbox {K}\) (red)

Altogether, the results of the four variants show the coalescence and dynamic solidification behavior of one or more molten metal droplets on a substrate, constituting typical effects of MJT processes. Above that, the modeling framework is able to capture the interplay of surface oscillations and rapid solidification leading to ripples on the interface as also observed in experiments.

4.4 Directed energy deposition

The setup of this example is motivated by a DED process, or more specifically an LPD process. Hence, consider a domain with dimension \({260}\,\upmu \hbox {m} \times {260}\,\upmu \hbox {m} \times {240}\,\upmu \hbox {m}\) (\({3.9 \times 10^{6}}\) SPH particles, 192 cores, \({20.5 \times 10^{3}}\) SPH particles per core, \({1.49}\,\hbox {s}\) mean wall-clock time per time step). The lower part of the domain is occupied by a substrate of thickness \({20}\,\upmu \hbox {m}\). A total of five individual powder particles each with diameter \({16}\,\upmu \hbox {m}\) are aligned on an axis with inclination angle of \(45\) degree through the center of the substrate, simulating the powder stream. Initially, the centers of the individual powder particles are at a distance of \({40}\,\upmu \hbox {m}\), \({60}\,\upmu \hbox {m}\), \({80}\,\upmu \hbox {m}\), \({100}\,\upmu \hbox {m}\), and \({120}\,\upmu \hbox {m}\) above the substrate. The remainder of the domain is filled with atmospheric gas and surrounded by rigid walls. The powder particles are all initialized with the velocity \({10}\,\hbox {m s}^{-1}\) towards the center of the substrate. A laser beam with total power \(P_{l} = {312}\,\hbox {W}\) and effective diameter \(d_{w} = {140}\,\upmu \hbox {m}\) is acting in downward direction at the center of the domain. The laser melts the substrate and to some extend also the injected powder. Two variants are considered in the following: First, the laser remains continuously switched on. Second, the laser is switched off after \(t = {0.012}\,\hbox {ms}\) to study solidification.

In the first variant (see Fig. 14 and Supplementary Video 13) a melt pool starts to form due to heating by the laser. As the first powder particle comes in the vicinity of the laser beam at \(t\approx {0.004}\,\hbox {ms}\), the top of the powder particle slowly starts to melt, but enters the melt pool still in solid form at \(t\approx {0.006}\,\hbox {ms}\). Though, a deflection of the powder particle can be observed as it hits the solid substrate at the bottom of the melt pool which is still shallow at the beginning. Soon thereafter, at \(t\approx {0.007}\,\hbox {ms}\), the second powder particle collides with the first one. When the third powder particle hits the second and immerses in its liquid phase (\(t\approx {0.009}\,\hbox {ms}\)), the first powder particle is almost fully liquefied. At \(t\approx {0.012}\,\hbox {ms}\) the melt pool grew large enough such that solid powder particles can immerse in the melt pool. Accordingly, the powder particles melt through heat conduction from the surrounding melt pool as typical for LPD. During the simulation the melt pool increases in size to a final diameter of approximately \({130}\,\upmu \hbox {m}\) at \(t\approx {0.018}\, \hbox {ms}\). Note that partially molten powder particles are deflected from their straight trajectory by recoil pressure forces which emerges when the peak temperature on the surface exceeds the boiling temperature. Hence, the powder particles do not hit the melt pool in its center. For the practical realization, this evaporation-induced deflection can be taken into account by adapting the orientation of the powder stream.

Fig. 14
figure 14

Overall view of DED example with laser continuously switched on: time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red)

Fig. 15
figure 15

Overall view of DED example with laser switched off at \(t = {0.012}\,\hbox {ms}\): time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red)

In the second variant the laser is switched off at \(t = {0.012}\,\hbox {ms}\) such that the same observations as in the previous example can be made until \(t = {0.012}\,\hbox {ms}\) (see Fig. 14). Fig. 15 shows the solidification process (see Supplementary Video 14). As soon as the laser is switched off the melt pool rapidly cools down and gradually solidifies. The powder particle coming into contact with the melt pool at the time of the switch-off only partially melts and rapidly solidifies such that the last powder particle bounces off and is deflected, finally flying above the substrate at \(t\approx {0.026}\,\hbox {ms}\).

With five powder particles only a small part of a realistic LPD process is considered in this example. Still, both variants allow to study in detail the interaction of mobile powder particles with the laser heat source, the molten metal, and other powder particles, thus capturing important aspects of LPD. Therefore, the proposed modeling framework is deemed suitable to model this process.

4.5 Powder bed fusion

This example examines an SLM process, a variant of PBF, utilizing a laser beam as local heat source. That is, consider a domain with dimension \({320}\,\upmu \hbox {m} \times {320}\,\upmu \hbox {m} \times {240}\,\upmu \hbox {m}\) (\(5.9 \times 10^{6}\) SPH particles, 96 cores, \(61.3 \times 10^{3}\) SPH particles per core, \({3.81}\,\hbox {s}\) mean wall-clock time per time step). The lower part of the domain is occupied by a substrate of thickness \({80}\,\upmu \hbox {m}\). A powder bed consisting of a total of 500 individual powder particles with diameters between \({16}\,\upmu \hbox {m}\) and \({32}\,\upmu \hbox {m}\) is resting on the substrate. The remainder of the domain is filled with atmospheric gas and surrounded by rigid walls. A spatially fixed laser beam with total power \(P_{l} = {312}\, \hbox {W}\) and effective diameter \(d_{w} = {140}\,\upmu \hbox {m}\) is acting in downward direction in the center of the domain melting the powder and the substrate until \(t = {0.1}\,\hbox {ms}\). Subsequently, the laser is switched off to allow for solidification until \(t = {0.25} \,\hbox {ms}\). In this example, the time step size is set to \(\Delta {}t = {0.5 \times 10^{-6}}\, \hbox {ms}\).

A time series of the obtained results is given in Figs. 16 and 17 (see Supplementary Videos 15 and 16). The laser beam locally melts the granular metal powder such that under the effect of surface tension a melt pool with smooth surface is formed. When the peak temperature in the melt pool center exceeds the boiling temperature, recoil pressure forces induce the formation of a deep keyhole-shaped depression of the melt pool. In particular, recoil pressure-induced waves can be observed, which propagate from the top to the bottom of the keyhole while increasing in their magnitude. These wave patterns are well-known for laser–metal interactions in the high power regime, and their instable growth behavior can be traced back to the strong mutual coupling of local keyhole surface curvature, laser energy absorption and recoil pressure [65]. Due to the recoil pressure forces (and thereby induced gas flow), powder particles are dynamically ejected from the edge of the melt pool. Some of the ejected powder particles are partially molten and resolidify in the atmospheric gas. Boundary effects are visible as some of the ejected powder particles bounce off the rigid walls (not visualized) surrounding the domain. After the laser is switched off at \(t = {0.1}\,\hbox {ms}\), the bottom of the melt pool solidifies very quickly, i.e., faster than the surface tension can smoothen out the melt pool depression, leaving a deep indentation. The larger portion of the molten metal at the top of the melt pool cools down slower while constricting under the action of surface tension to form a pore.

Fig. 16
figure 16

Sectional view of point melting PBF example: time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red)

Fig. 17
figure 17

Overall view of point melting PBF example: time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red)

In a next step, the domain is extended by a factor of three in longitudinal direction to examine the case of line melting. Hence, the dimension of the domain covers \({960}\,\upmu \hbox {m} \times {320}\,\upmu \hbox {m} \times {240}\,\upmu \hbox {m}\) (\(17.3 \times 10^{6}\) SPH particles, 384 cores, \(45.0 \times 10^{3}\) SPH particles per core, \({3.76}\, \hbox {s}\) mean wall-clock time per time step) and the powder bed is constituted by a total of 1500 individual powder particles. The laser beam is switched on at a distance of \({160}\,\upmu \hbox {m}\) from one end of the domain and remains at rest until \(t = {0.05}\, \hbox {ms}\). Then the laser beam starts moving with the constant velocity \({2}\, {\hbox {m s}}^{-1}\) in longitudinal direction towards the other end of the domain, crossing a total distance of \({640}\,\upmu \hbox {m}\), until it stops at \(t = {0.37}\,\hbox {ms}\). At the same time, the laser is switched off to allow for solidification. Figures 18 and 19 (see Supplementary Videos 17 and 18) show a time series of the obtained results. In the initial phase, similar observations as for the point melting variant can be made. As soon as the laser starts its longitudinal movement, the propagating melt front compresses and pushes ahead the powder feedstock in front of the laser. Due to this effect, which has to the best of the authors’ knowledge not been observed in previous studies, the initial packing structure of powder material ahead of the laser beam is strongly distorted before melting takes place. In addition, recoil pressure forces (and thereby induced gas flow) lead to dynamic particle ejections and instable wave patterns across the front melt pool wall (where temperatures are highest) as already observed in the point melting case above. Eventually, a continuous melt track lags behind the laser and gradually starts to solidify, leaving a small island of molten metal behind. After the laser is switched off, the thin film of melt directly beneath the laser beam center cools down very quickly, leaving back a surface indentation after solidification.

Fig. 18
figure 18

Sectional view of line melting PBF example: time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red)

Fig. 19
figure 19

Overall view of line melting PBF example: time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red)

Finally, Fig. 20 gives a detail view of the line melting PBF example illustrating the non-molten and resolidified portion of the material. At the initial position of the laser, both the melt pool depth and the surface height of the solidified material are largest. In contrast, at the final laser position, the melt pool depth is smallest and, due to the remaining surface indentation after laser shut-off, the surface profile of the solidified track even lies below the initial height of the substrate. All together, the surface profile along the entire melt track is very wavy, which can be attributed to surface tension effects (e.g., Plateau–Rayleigh instabilities) and dynamic fluctuations of the melt pool shape due to coupled melt-powder-recoil pressure interactions.

Fig. 20
figure 20

Detail view of line melting PBF example: time series illustrating the powder dynamics and the melt pool shape with temperature field ranging from \({1700}\,\hbox {K}\) (blue) to \({3400}\,\hbox {K}\) (red) and sectional planes with non-molten material (black), resolidified material (blue), and surface of initial substrate (red)

Altogether, both variants of this example, i.e., point and line melting, demonstrate that the proposed modeling framework can robustly capture highly dynamic laser-melt-powder interactions while resolving important physical phenomena such as recoil pressure-induced wave patterns on the keyhole walls with a high detail. Finally, it shall be noted, that currently no frictional contact forces between powder particles are considered, and that the vapor jet and thereby induced gas flow are not explicitly modeled. These aspects will be in the focus of the authors’ future research work. However, even when considering these additional effects, the general mechanisms observed in the studies above are expected to be still valid. Moreover, the general suitability of the proposed modeling framework for complex PBF processes is shown such that it can be recommended for further detailed studies.

5 Conclusion and outlook

In this work, a general SPH modeling framework for coupled microfluid-powder dynamics problems involving thermo-capillary flow and reversible phase transitions was presented. Herein, parallel implementation aspects were not discussed. However, in the authors’ previous work [43], a concept for the parallelization of the computational framework for fluid–solid and contact interaction problems was proposed and verified on the basis of an extensive scalability study. This framework enabled large-scale simulations such as the powder bed fusion line melting example, which was discretized by approximately \(17.3 \times 10^{6}\) SPH particles and \(5 \times 10^{5}\) time steps. Note that the implementation of such a parallel computational framework is far from trivial but indispensable when examining three-dimensional application-motivated examples that are of practical relevance.

The proposed modeling framework is suitable for the simulation of complex AM processes such as binder jetting (BJT), material jetting (MJT), directed energy deposition (DED), and powder bed fusion (PBF). To this end, the generality and robustness of the proposed computational modeling framework were demonstrated by examining several three-dimensional application-motivated examples. The obtained numerical results showcase the model’s general ability to capture relevant physical phenomena such as coupled microfluid-powder dynamics and thermo-hydrodynamics involving surface tension and wetting effects as well as reversible phase transitions. In particular, the following key characteristics of the considered AM processes were observed:

  • The dynamic impact of binder droplets in BJT evokes significant distortions of the powder packing structure, which can extend to droplet splashing and powder particle ejection in case of high droplet impact velocities.

  • Based on the preheating temperature of the substrate and the timing of successive droplets in MJT, aspects such as remelting depth or the occurrence of droplet coalescence and surface ripples can be controlled.

  • Early laser shut-off, or equivalently insufficient laser powers, in DED can lead to inclusions of partially molten powder particles.

  • As consequence of the evaporation-induced recoil pressure forces in PBF, powder particles are dynamically ejected and the powder feedstock is pushed ahead by the propagating melt pool.

In summary, it can be stated that the proposed modeling framework has the ability to accurately model important physical phenomena of a host of complex AM processes, and thus can be expected to become a valuable tool for detailed studies in this field. Most of these effects could only be represented due to the coupled microfluid-powder dynamics, considered in combination with thermo-capillary flow and phase transitions for the first time in the proposed modeling framework. This modeling framework could also be used to model aspects of other AM processes than the ones considered, e.g., material extrusion or vat photopolymerization.

The authors’ future research in this field will mainly focus on the processes PBF and BJT, in particular on the aspect of powder particle ejection and powder bed distortion due to coupled microfluid-powder dynamics. To experimentally validate the predicted degree of powder bed distortion, optical surface imaging techniques as well as a novel high-resolution X-ray device [66], both developed by the authors’ collaborators at MIT, will be employed. In addition, in situ monitoring of the melt pool surface temperature in PBF will be enabled by a novel midwave infrared (MWIR) imaging technique [67], also developed by the authors’ collaborators at MIT. This approach provides high-resolution temperature fields and allows to resolve spatter ejection from the melt pool by capturing thermal emissions. Apart from model validation, such experimental data will help to identify unknown or uncertain model parameters based on inverse analysis.