Modeling Phase Transformation for Residual Stress Study in Selective Laser Melting Processes by Finite Element/Matlab Integration

Selective laser melting (SLM) has been identified as a promising manufacturing technology for modern additive fabrication. However, this process results in powder sintering/melting during fabrication. Due to enormous thermo-mechanical mismatch, consequently, significant structural distortion and thermal stress would be expected.  Without carefully analyzing the stress and deformation during SLS, the final product could suffer from excessive distortion or strong residual stress. However, the thermo-mechanical properties of powder and sintered materials has significant difference and the phase transformation depends directly with processing parameters. Current finite element analysis usually needs to pre-assign the material properties and lacks the ability for performing effective material change during simulation. Without this capability, the achieved stress analysis results could be questionable due to incorrect constraints on structural deformation attributed to material Young’s modulus, for example. In this work, a rational flow for solving the above problem is proposed by integrating finite element package ABAQUS, Matlab, FORTRAN, and Python. The entire program is constructed as a Matlab code, where ABAQUS FE analysis is a major subroutine. In together with FORTRAN, it is responsible for obtaining the temperature and stress of each node/element. For each step, the Matlab main program makes judgement to determine if the material of elements should be changed from powder to sintered state based on the temperature distribution and other judgement criteria. These decisions are then used to re-compose the FE input files using Python and the new input files are then served as the FE simulation for the next step. By this approach, it is possible to adequately describe the phase change behavior and leads to a more reliable subsequent stress analysis for solving the residual stress and distortion problems commonly faced in SLS processes. Technically, this approach can also be applied to other ad hoc problems such as wafer polishing or wearing of mechanical probes.


Introduction
With the advance in modern digital manufacturing, additive manufacturing such as 3D printing becomes more important. Among all 3D printing technologies, selective laser melting (SLM), which is capable of producing metallic functional parts in a layer upon layer fashion directly from CAD data, has been recognized as a promising solution for producing highly quality and complicated metallic functional parts (1) . As shown in Figure 1, in a typical SLM system, a fine powder layer is placed on a substrate inside an inert chamber and is fully melted by a laser. After one layer is deposited, another layer will be placed and melted until a part is produced. By such an approach, complex structure can be built.
However, this process involves strong laser-material interaction and the resulted melting and re-solidification of metals, as well as the mismatching of thermo-mechanical properties of powder and substrate materials, could potentially generate very high thermal residual stresses. Consequently, considerable distortions and cracks of fabricated parts were observed and reported (2) . This problem must be eliminated or at least significantly reduced for quality control.
Analytical formulation on residual stress modeling in SLM process has been reported (3) . However, for counting the complexity, finite element (FE) simulation has been recognized as an effective tool for performing structural design, stress and deformation analysis, and failure identifications. During the past years, numerous studies have been investigated to predict temperature, stress, and deformation states in SLM process. However, an entire SLM fabrication involves complicated optical-thermal -mechanical interactions. To achieve a successful and accurate simulation, numerous parameters in materials, environmental and boundary conditions, and processing setups, must be precisely determined at the beginning. This is a difficult and nearly impossible task. As a result, FE simulations are usually used to find general trends and sensitivities of processing parameters.
At this moment, SLM temperature and stress analyses are the two major investigated issues in FE simulation. However, to the best of our knowledge, most FE simulation did not pay special attentions on the powder layer material variation before and after laser irradiation. Specifically, they just treat the powder layer as a special material. However, before laser melting, this material is a porous powder and the modulus, expansion coefficient, and conductivity are low (in comparison with those of buck materials). After melting and re-solidification, this material becomes much stiffer and the conductivity and density are also enhanced. This fact actually brings concern on the residual stress modeling using FEM. Taking a line scan case, schematically shown in Figure 2 as an illustration example. After the scan, the original powder materials are melted and then solidified. Due to the different thermo-mechanical properties between the solidified and the powder metals, certain level of residual stress would occur. In the scanning direction, the solidified metals are less room for change due to its solid attached on the substrate. On the other hand, for the direction orthogonal to the scanning direction, due to very low stiffness of the powder layer, the solidified structure is virtually no constraint forces. As a result, this can explain why the residual stress exhibit orient-dependent characteristics commonly observed in experimental studies. However, currently, virtually all residual stress modeling in SLM cannot reveal this fact due to assume the same mechanical properties between the powder and the solidified materials.
However, it is impossible to pre-assign the material type to the elements since the melting then solidified process is dependent on the processing and the analysis should have ability to change materials during simulation. Currently, due to the limitation of commercial FEM packages, it is difficult to realize the goal by solely using FEM packages. Without this feature, previous researches usually use the same mechanical properties for both powder and sintered structure. This implies that the current residual stress analysis could deviate the real scenarios significantly and a new approaches should be developed.
As addressed above, it is difficult and computational consuming in FE simulation for dealing the exact phase transformation analysis. However, without effectively describing this issue, the accuracy of the analyzed stress state could be questionable. In this work, as schematically shown in Figure 3, an approach by integration finite   element simulation and Python in a Matlab environment to effective change material properties of the powder layer based on laser heating condition is proposed. By this approach, the melting/re-solidification process can be effectively described for subsequent SLM stress analysis without high computational cost. Such an approach has been proposed by us in describing chemical mechanical planarization process elsewhere (4) . In this work, the concept and implementation would be clearly explained and validated, and followed by an example to compare with a benchmark problem for demonstrating the importance of this approach. The rest of this paper describes the technical issue in detail. In Section II, the proposed methodology and its detail flow is addressed. Section III provide detail technical procedure for implementation by using a specific SLM example. Analyses to show the difference and comparison between this and previous approaches is conducted in Section IV using a benchmark problem and a brief discussion would also highlight the advantage and characteristics of the proposed approach. The laser parametric study for discussing the size of phase change zone and the maximum surface Von Mises stress on the solidified zone would be presented in Section V for promoting this method. Finally, Section VI concludes this work.

Methodology
The generic SLM FE simulation is schematically shown in Figure 3. In this section, the proposed methodology and its corresponding implementation is detailed described. The entire flow is shown in Figure 4. To emulate the SLM process, a substrate with proper boundary conditions is created. On the other hand, the powder layers must also be created at this moment. With certain element birth/death actions, these powder layers can be temporally hided and then activated to mimic the process condition. A Gaussian surface heat source is then used to modeling the laser irradiation. Using Rosenthal's approach with Gaussian distribution as ( (1) where qmax, , and v are maximum applied laser power, energy absorption coefficient, and scanning speed, respectively. x and t are the scan location and timing. This model has been widely used in related laser processing such as laser peeling (6) . For finite element simulation, it is possible to choose either sequential analysis or coupled analysis. In sequential analysis, a heat transfer analysis is performed to obtain the node temperature history. These data are then input for the subsequent static stress/deformation analysis. On the other hand, it is also possible to choosing coupled element to perform temperature-displacement coupling analysis directly.
Up to now, the procedure is common. However, in certain conditions, the powder layers turn to be melted and re-solidification. The mechanical properties of original powder and solidified buck materials are extremely different. As a result, after laser irradiation, the material of the corresponding powder layer elements should be changed if the node temperatures of elements exceed melting temperature. However, this action involves modification of input files and it cannot be automatically updated using FE simulation code itself.
In order to fulfill the task automatically, a Matlab main program is built. This program contains two major subroutines. The first one is the FE simulation. The other is a Python code for extracting FE simulation results for re-building the associated FE input file for the subsequent FE simulation step. The main program also responsible to judge if any portions of a powder layer is melted and the material of the corresponding elements should be changed and to rebuild the input file for the next step as follow. In summary, under such a Matlab environment, the above mention issues can be executed automatically. Notice that the proposed computational architecture is proposed for demonstrating the feasibility and it may not be optimized for computational efficiency at this moment.

Model Construction and Validation
In this section, a step by step illustration is performed to illustrate the realization of the above-proposed scheme. Consider a SLM process with a single laser scan back and forth. For simplicity, this problem can reasonably be reduced to a 2D structure with a laser scanning on the top surface as schematically shown in Figure 5a. The plane strain finite element model is firstly created. This model contains a steel substrate (material A) and n-layers of steel powders (material B). By model change, except the first one, the rest layers are inactivated. The laser scans from left to right, due to generated heat, the power layer melted and solidified. The simulation results are extracted by Python and the corresponding material of each element are changed if the temperature exceeds the melting point. Figure 5b, c and d shows the temperature, stress, and material profile at a given instance. It can be seen that the power layer and some substrate structures are melted and solidified to material C. After finishing a scan, the second powder layer is active and the process is repeated again till the n th layer has been deposited and sintered. Since the thermo-mechanical properties of materials A, B, and C are different (this is especially true for material Bof powder steel), it is expected that the resulted temperature and stress distributions could have substantial differences in comparison with those predicted by traditional fixed material models.

Analysis Results
Finally, a 2D case study based on the geometry and working conditions from (7) is presented here. By comparing the analysis results with that from this benchmark problem for demonstrating the importance of the proposed scheme. The domain mesh and associated boundary conditions are shown in Figure 6 and the material properties of the steel substrate (A), steel powder(B), and sintering bulk steel (C), are listed in Table I. The substrate is fixed at the bottom surface while the four boundaries are assumed to have heat convections with surroundings. Conversely, the benchmark problem assumed no material change and the buck material properties are used through the entire simulation.
Next, the FE model is constructed. The mesh and thermal and displacement boundary conditions are then shown in Figure 6. It is a 2D plane strain model containing 22626 quadratic elements and 68457 nodes. The laser scans from left to right and the powder layers are added 3 times. After sintering, the structure is cooled to room temperature and the bottom supports are released for observing the final warpage. The temperature distribution, residual stress, and final warpage (after releasing the bottom fixed boundary) are shown in Figure 7 after 3 scans. For the purpose of comparison, the analysis results based on the assumption of (7) is also presented. A typical temperature distributions during scan shown in Figure 6a exhibit no major difference and this is reasonable since the thermo-properties of both cases has no significant difference. On the other hand, the residual stress after cooling to room temperature is shown  in Figure 7b, where the orange portion indicate the von Mises stress between 200 to 223 MPa. One can see the situations are very different. Finally, the warpage level also shows slight difference from 14.9 to 15.5m (see Figure  7c).

Laser Parametric Studies
After validation, it is possible to use the proposed integrated SLM FE model to perform parametric studies for promoting the proposed method. To demonstrate the advantage of the method, two quantities, namely the size of the melting/solidifying zone, and the representative residual stress of the SLM structure, are served as the measures in the following parametric studies. First, the model would be analyzed by different laser power and laser scanning speed for evaluating their influence on the size of the melting/solidifying zone, as shown in Figure 8, by comparing to the nominal laser parameters (i.e., laser irradiation power of 300 W and a scanning speed of 50 mm/s), the melting/solidifying zone would be increased with larger laser power input (shown in Figure 8 with a laser power from 300 W to 500 W) , and is reduced with increased scanning speed (shown in Figure 8 with a scanning speed from 50 mm/s to 130 mm/s). In addition, it is also found that the influence of laser power input is more profound than that by scanning speed for (a) Typical temperature contour during scan.     determining the zone size. This could be one useful analysis results for further optimizing the SLM process. Second, the residual stress of the SLM process always comes from the constraint of the shrinking force during cooling, thus, at this part, the maximum surface Von Mises stress would be analyzed by different laser parameters, laser power from 300 W to 500 W and scanning speed from 50 mm/s to 130 mm/s, and with/without phase transformation analysis, moreover, the surface maximum stress is always in the melted/solidified region. In the Figure 9, it is obviously that the stress increases with the larger laser power and decreases with the faster scanning speed for the none-phase transformation analysis, therefore, it is guaranteed that the residual stress tendency with the none-phase transformation analysis could be affected by the temperature gradient different during laser scanning. However, with the phase transformation analysis, the residual stress changes a little because the strength of the solidified bulk material is much more stronger than the powder material, thus, only if the temperature gradient difference is getting much larger, the shrinking force would be enough to show the trends of the surface maximum Von Mises stress.

Discussion and Conclusion
SLM process has been identified as a promising add-on technology in modern manufacturing. However, the process involves significant phase transformation due to melting/solidification. Consequently, considerable residual stress and distortions are observed in work pieces. Analyses are need to improve the design. However, the current finite element analysis lacks the ability for performing effective material change (from powder to bulk) during simulation. Without this capability, the achieved stress analysis results could be questionable. In this work, by integration of finite element package with Python under a Matlab environment with element birth/death technique, a new finite element analysis scheme for emulating SLM process is proposed. This approach can emulate the net change of materials from powder form to bulk form with different thermo-mechanical properties. Consequently, the residual stress and the subsequently induced workpiece distortion could be better estimated. In this paper, based on a benchmark problem (7) , the predicted temperatures, residual stresses, and distortions based on the traditional approach and this method are compared. It is found that their residual stress and distortion analysis results are quite different due to the material sintering from powder into bulk state. This demonstration also reveals the importance of this key function to the workpiece distortion prediction and subsequent process optimization of SLM process. In the future, more dedicated consideration and modeling will be included for better prediction. The computation efficiency would be further optimized. Nevertheless, the simulation results provided by this work has clearly indicate the importance and potential of the proposed scheme. Taiwan.