Modelling dynamic 3D heat transfer in laser material processing based on physics informed neural networks

. Machine learning algorithms make predictions by fitting highly parameterized nonlinear functions to massive amounts of data. Yet those models are not necessarily consistent with physical laws and offer limited interpretability. Extending machine learning models by introducing scientific knowledge in the optimization problem is known as physics-based and data-driven modelling. A promising development are physics informed neural networks (PINN) which ensure consistency to both physical laws and measured data. The aim of this research is to model the time-dependent temperature profile in bulk materials following the passage of a moving laser focus by a PINN. The results from the PINN agree essentially with finite element simulations, proving the suitability of the approach. New perspectives for applications in laser material processing arise when PINNs are integrated in monitoring systems or used for model predictive control.


Introduction
Data-driven machine learning (ML), in particular deep learning, is increasingly applied to analyse measurement data and to model a large variety of phenomena in the physical sciences [1] and technical applications.While it allows for a direct inclusion of empirical data, automatic feature extraction, and promises efficiency gains in modelling complex multi-physics situations, predictions based on purely data-based ML approaches struggle to guarantee consistency with elementary physical laws of nature.Therefore, new paradigms for integrating deterministic, physics-based modelling and data-driven learning techniques are desirable.A plethora of different approaches have emerged, ranging from learning effective input parameters for (e.g., multiscale) deterministic models, posterior correction of simulation results by supplementary data-based models (e.g., for degradation mechanisms), substitutional neural networks trained on synthetic (simulated) data, neural networks with specific, physics adopted topologies e.g., for Lagrangian or Hamiltonian dynamics, and many more.

Physics informed neural networks
A physics informed neural network (PINN) is a neural network which imposes the validity of governing equations as additional constraints on the loss function.It is capable of seamlessly integrating multimodal experimental data and, hence, to extrapolate between deterministic and empirical modelling.A PINN takes space and time coordinates as neural network inputs and exploits automatic differentiation.As it contains the governing equations it does not require any training data; however, available data can be used to facilitate training.Compared with the finite element method (FEM) it is particularly powerful in solving inverse or ill-posed problems.PINNs have been successfully applied to e.g., fluid dynamics [2], heat transfer [3] or fatigue modelling [4].This research prepares the way for using PINNS in laser material processing.

Time dependent heat transport equation
Dynamic heat conduction in bulk materials can be modelled by the time dependent heat conduction equation, a partial differential equation in space ‫ݔ(‬ ⃗) and time (t): Here ܿ describes the heat capacity, ߢ is the thermal conductivity, ߩ the density, ‫ݔ(ݑ‬ ⃗, ‫)ݐ‬ the temperature field and ܳ ‫ݔ(̇‬ ⃗, ‫)ݐ‬ the (moving) heat source.The temperature field is modelled within a finite cube.To its lower base a Dirichlet boundary condition (BC) was applied and set to 0. For the four lateral faces (F) the Neumann BC was The initial conditions (IC) were set to u = 0 for the whole domain.These conditions are motivated by the typical setup in the laser powder bed fusion process (PBF-LB/M).

Implementing PINN for dynamic heat transfer in laser material processing
PINNs have been implemented in a variety of frameworks [5,6].Here, a dynamic 3D implementation has been realized in the deep learning library PyTorch.

Heat source modelling and model parameters
For the heat source a Gaussian beam profile with a laser power ܲ =1 W and a velocity of 1 mm/s was used.The heat source is modelled by: The size of the laser spot ‫ݎ(‬ ௦௧ ) was 0.1 mm and the position of the laser focus ‫ݎ(‬ ௨௦ ) was a function of time.

Loss function
Constraints imposed by the time dependent heat equation, as well as by boundary and initial conditions have been included in the loss function with applied multipliers (߱): The governing partial differential equation (PDE) holds at any point in space and time.Hence, its validity should be imposed at any point of a numerical discretization lattice.However, to relieve the numerical effort, errors resulting from the governing equation are not calculated at all points of the lattice but stochastically sampled on a sufficiently dense subset of all lattice points (20% in each epoch).For the calculation 40,000 collocation points were used and sampled by the Latin-Hypercube method.Further details on modelling the losses will be presented in an extended version of the paper.

Training and model validation
The PINN is trained for 50,000 epochs.The decay of the contributing losses over the epochs can be seen in Fig. 1.
Fig. 1.Convergence of the 3 terms in the loss function.A decrease for the PDE loss can be seen at 5,000 epochs, followed by a smooth convergence of the loss.
The temperatures obtained from the PINN were compared with those from a corresponding FEM simulation, which has been performed in COMSOL Multiphysics environment, using the same parameters as for the PINN.

PINN-based modelling results
In Fig.To evaluate the calculations from the PINN, the results are compared to predictions from a FEM simulation, as shown in Fig. 3.The evaluation demonstrates agreement with FEM simulations.However, a deviation can be seen in front of the heat source, which is a result of lack of convergence and a known issue in physics-based modelling.The benefit of a PINN approach over finite element modelling becomes visible when additional sensor data is available to fit simulations to experiments or applications.Thus, PINNs can be considered a promising new tool for process monitoring and model predictive control in laser material processing, e.g. as part of a larger digital twin.Technical details on benchmarks and numerical implementations will be presented in an extended research article.
Fig. 2. 3D-temperature profile ‫ݔ(ݑ‬ ⃗, ‫)ݐ‬ at a given time during and after the passage of a laser focus through model material.

Fig. 3 .
Fig. 3. Comparison of a spatial temperature profile at a given point in time calculated using (i) a PINN (upper panel), (ii) a FEM simulation (middle panel) and (iii) the error measured by the absolute difference between both results (lower panel)