Strain incompatibility as a source of residual stress in welding and additive manufacturing

The accumulation of residual stress during welding and additive manufacturing is an important effect that can significantly anticipate the workpiece failure. In this work we exploit the physical and analytical transparency of a 1.5D model to show that the deposition of thermally expanded material onto an elastic substrate leads to the accumulation of strain incompatibility. This field, which is the source of residual stress in the system, introduces memory of the construction history even in the absence of plastic deformations. The model is then applied to describe the onset and the progression of residual stresses during deposition, their evolution upon cooling, and the fundamental role played by the velocity of the moving heat source.

The accumulation of residual stress during welding and additive manufacturing is an important effect that can significantly anticipate the workpiece failure. In this work we exploit the physical and analytical transparency of a 1.5D model to show that the deposition of thermally expanded material onto an elastic substrate leads to the accumulation of strain incompatibility. This field, which is the source of residual stress in the system, introduces memory of the construction history even in the absence of plastic deformations. The model is then applied to describe the onset and the progression of residual stresses during deposition, their evolution upon cooling, and the fundamental role played by the velocity of the moving heat source.

I. INTRODUCTION
Many natural or technological processes where mass is continuously deposited on the boundary surface of a growing body exhibit a peculiar accumulation of residual stress, like in the growth of plants [1,2], in cell motility [3,4], in civil engineering [5,6], but also in planetary formation [7] and in crystallisation [8][9][10].
Welding and additive manufacturing fall in the general category of surface growth problems, since both technologies involve the surface deposition of thermally expanded material and result into the accumulation of longitudinal residual stress at the end of the process [11,12]. Experimental evidence suggests that the magnitude of residual stress generally increases upon cooling, potentially leading to the formation of cracks and to delamination, see Fig.1. Experiments also show that the velocity of the moving heat source plays an important role in the maximum residual stress at the end of deposition [13][14][15][16][17][18][19][20][21][22].
The source of residual stress in welding and additive manufacturing is "strain incompatibility": this field measures the local mismatch between stress-free configurations of adjacent layers and is the sole source of residual stress when the workpiece reattains a uniform temperature [23,24]. In this work we provide a model to describe how strain incompatibility is accumulated during the deposition of thermally expanded material, even in the absence of other inelastic effects (like plastic deformations or phase transformations). The resulting distribution of strain incompatibility depends on the whole thermal history of the workpiece, thus nailing the memory of the whole manufacturing process in the final distribution of residual stress [25].
Existing models for the accumulation of residual stress in welding and additive manufacturing are broadly plasticity-based: in this perspective, temperature gradients induce thermal stresses, which in turn lead to plastic deformations upon attainment of the material yield strength [26]; the resulting plastic deformations, if incompatible or inherent [24], are a source of residual FIG. 1. a) Failure of an additively manufactured part due to residual stress build-up, courtesy of [29]; b) experimental (whiskers) and computational (solid curve) modelling of longitudinal stress accumulation during additive manufacturing and c) numerical modelling of the evolution of the longitudinal residual stress upon cooling, courtesy of [30].
While certainly plasticity plays an important role (above all during solidification, when the stress increases significantly), there is a growing experimental evidence that immediately at the end of deposition, the residual stress can be significantly lower than the limit yield strength of the material, both for welding and for additive manufacturing [15,30,35,36]. Henceforth, it remains to explain, in the absence of plastic deformations, where does this initial distribution of residual stress originates from.
This perspective is further supported by the fact that in several problems of surface accretion, like in sand-pile growth [25] or in gravitational accretion [5,37], the final body has a distribution of residual stress that can not be explained in terms of plastic yielding, but rather in terms of strain incompatibility stored during the process [38][39][40], when the deposited material is fully in the elastic range.
To illustrate this idea in a minimal and mechanically transparent setting, in this work we exploit the simplicity of a toy "1.5D model". After identifying the mechanical source of residual stress in strain incompatibility, we describe how this field can be permanently stored during the deposition of thermally expanded material filaments. Strain incompatibility, which quantifies the strain mismatch between the deposited filaments and the underlying substrate, is "frozen" at the instant of deposition and does not evolve afterwards. Its value at a given point depends globally on the temperature profile on the bar, and for this reason strain incompatibility is a path-dependent field that depends, in particular, on the velocity of the moving heat source. Our model explains the peculiar shape of the longitudinal residual stress profile at the end of deposition, its evolution upon cooling, and the fundamental role played by the velocity of the moving heat source on the maximum value of the residual stress.
The manuscript is organised as follows. Strain incompatibility is firstly introduced in a purely mechanical setting in Sec.II. We then describe the deposition process in Sec.III, and we show how strain incompatibility can be determined analytically in the simple case where the elastic moduli are constant. We then address the case of temperature-dependent moduli, that can be approached numerically. In Sec.IV, after having introduced an approximated solution to the heat diffusion problem, we apply the model both in the simple case of constant moduli, and in the more realistic case of variable moduli, by highlighting the qualitative and quantitative overlaps with the existing experimental/computational estimates.

II. STRAIN INCOMPATIBILITY IN A "1.5D
MODEL" The minimal setting to describe the presence of residual stress is provided by a "1.5D model", describing an elastic 1D bar, laterally constrained by shear springs to a rigid foundation, see Fig.2. In the absence of external loading, by acting on the anchoring points of the shear springs on the rigid foundation it is possible to build up "strain incompatibility", which is the sole source of residual stress in the system. After introducing the concept of strain incompatibility in a purely mechanical 1.5D model, we will later show its genesis in the process of deposition, solidification and adhesion to an elastic substrate.
Consider an elastic rod of length L, which is connected to a rigid foundation through shear springs, as represented in Fig.2. Points in the bar are denoted by their referential coordinate x ∈ (0, L) and their displacement is denoted by u(x), so the strain is (x) = u ′ (x) (where ′ denotes differentiation with respect to x) and the stress is σ(x) = E( (x) − i (x)), with E the bar longitudinal elastic modulus. Here, and in very general terms, i (x) is a prescribed inelastic strain that could describe, for example, thermal expansion, plastic deformations or phase transformation strains [41,42].
The shear springs exert a force per unit length q(x) = G(ū(x) − u(x)) on the bar, where G may be given the meaning of a shear modulus and where the fieldū describes the placement of the anchoring point of the shear springs on the rigid foundation, as illustrated in the inset of Fig.2. As well as i , assume that such field can be externally controlled. Equilibrium of the bar under null end tractions results into the problem To further clarify the role of the inelastic strains ( i ,ū ′ ) in the accumulation of residual stress, it is convenient to eliminate u(x) in (1) so to obtain a stress-based formulation of equilibrium, In the expression above we have introduced the strain incompatibility η(x) = i (x)−ū ′ (x), that is the sole source of residual stress in the bar. In fact, the problem can be solved for a generic distribution of η and we obtain η e −βs ds .
If η = 0 there is no stress in the system, whereas if η ≠ 0, the resulting distribution of σ will be nontrivial. The field η here introduced may be seen as the 1.5D counterpart of the 3D tensorial strain incompatibility which is, also in that general context, the sole source of residual stress in the absence of external loading [38][39][40]. We note that the term incompatibility stems from the fact that η = 0 is implied by i =ū ′ , meaning that a non-trivial distribution of (ū ′ , i ), if compatible, does not produce stress in the system [23].
With reference to welding and additive manufacturing, while i may be given the meaning of a thermal expansion during the deposition of hot material, the fieldū ′ traduces the shear mismatch between the bar and the underlying layer. As we show in the next section, while i vanishes when the temperature of the bar is uniform and equal to the ambient temperature, the fieldū is "frozen" at the instant of deposition and it does not evolve afterward. Such field will persist at the end of manufacturing, producing residual stress without necessarily involving the onset of plastic deformations.
We finally remark that the 1.5D model directly introduced above is not derived from a parent 3D theory. For this reason, our model aims only at a qualitative description of the fundamental effects taking place during the deposition and solidification.

III. GENESIS OF INCOMPATIBILITY DURING DEPOSITION
We now describe the process of accretion of a 1.5D bar through lateral deposition of mass on its "growth end". We introduce an evolving reference configuration R t = {x ∈ (0, ψ(t))}, where t represents a time-like parameter and where ψ(t) denotes the evolution of the referential growth end. We further denote by D 0 (t) =ψ(t) the referential velocity of the growth end, where the dot denotes differentiation with respect to t. By assuming that the referential mass density 0 is uniform, the rate of deposited mass is µ = D 0 0 . Since ψ(t) is an increasing function, we can define its inverse ϑ = ψ −1 so that t = ϑ(x) gives the instant when a material point x is located on the growth end.
To simplify the analysis we assume that heat diffusion is uncoupled from the equilibrium, so we assume that the temperature profile T (x, t) in the bar is always known during the process. In the subsequent applications of the theory, we will adopt temperature profiles typically suggested in literature to model the process of welding and additive manufacturing.
During the deposition of hot material, a referential fibre dx will be deposited in a thermally expanded length where α is the coefficient of thermal expansion and ∆T (x, t) = T (x, t) − T amb , where T amb is a reference ambient temperature. Due to thermal expansion and to the build-up of elastic stress, points of the bar can undergo a time-dependent displacement u(x, t), which is assumed small together with the strain (x, t) = u ′ (x, t). The current placement of the growth end is given by ξ(t) = ψ(t)+u(ψ(t), t), so that the actual velocity of the growth end is D(t) =ξ(t) = D 0 (t) +u(ψ(t), t) + D 0 (t) (ψ(t), t). By assuming that ≪ 1 and thatu ≪ D 0 , the current and referential velocities D and D 0 may be confused for all practical purposes. We finally introduce the displace- 3. Schematic representation of the reference (above) and current (below) configurations of the bar in two instants t1 and t2 > t1. The springs connecting the bar to the foundation, denoted in red in the current configurations, are un-sheared at deposition. The scheme also illustrates the role of the field u in defining the current placement of the growth-end. ment of the growth end at the deposition instant, which is a main player in our model. Note that by making use of the function To impose equilibrium at each stage of accretion, further assumptions are required on the mechanical state of the system. The first assumption is that the longitudinal elastic modulus E and the shear modulus G are known functions of temperature; concerning their ratio, since in 3D elasticity it results that G E = 1 (2(1 + ν)) where ν is the Poisson coefficient, and since for a wide class of materials ν is essentially independent on temperature [18,22,43], we here assume that β 2 = G E is constant. We assume, as well, that the thermal expansion coefficient α does not depend on temperature [18,22,43].
To describe the deposition and contextual adhesion to the substrate, we assume that new "drops" of material are continuously deposited in a close-to-melted state, in a traction-free state (σ(ψ(t), t) = 0). As soon as temperature decreases below the deposition temperature T dep , we assume that the material instantaneously adheres to the foundation. This means that the anchoring point of shear springs on the rigid foundation coincides with the current placement of the growth end ξ(t) = ψ(t) +ū(ψ(t)), so that the resulting shear force is q(x, t) = G(T (x, t))(ū(x)−u(x, t)). Due to the definition ofū(x), this means that the shear force between the substrate and the bar is zero at deposition (q(ψ(t), t) = 0).
To sum up, equilibrium of the growing bar can be imposed, by slight modification of (1), as The structure of this problem is similar to the purely mechanical theory of 1.5D surface growth proposed in [39]. Since temperature is prescribed during the process, the main unknown in the problem is represented by the functionū ′ (x) which, as described by (2), is the sole source of residual stress at the end of deposition, when the bar is at ambient temperature.
To solve this problem we compute the field u(x, t) as a function of the yet unknown fieldū(x), and we thus impose the consistency conditionū(x) = u(x, ϑ(x)), leading to an integral equation forū ′ (x), see [39] for a similar analysis. An analytically simpler, and physically more transparent, incremental formulation of this problem is discussed in the next section.
We remark that the assumption that strain incompatibilityū ′ is "frozen" at the instant of deposition and does not evolve afterwards may always be relaxed to permit, for example, the description of delamination effects or the onset of plastic deformations during deposition. The analysis of these effects are left for future studies.

A. Incremental formulation: constant moduli
The general problem discussed above can be conveniently recast in an incremental form, that we first discuss under the simplifying assumption E, G and α are constant. In this case, the problem admits a fully analytical solution, that provides a good qualitative description of the main effects observed in literature. We later focus on the case where the elastic moduli depend on temperature.
An incremental formulation of problems involving surface growth was originally proposed by [37,44] in the context of gravitational accretion, and by [45] in the context of water freezing. Later developments based on the seminal work of [46] paved the way to general formulations of the theory of surface growth, both in the linear [38] and in the nonlinear [40] setting. The current formulation is inspired by [39], where a purely mechanical theory of a growing 1.5D bar was presented.
The incremental formulation of (5) relies upon on the possibility to recast the displacement and the stress in the bar, at an arbitrary instant t ≥ ϑ(x) after deposition, as where we recall that σ(x, ϑ(x)) = 0 and u(x, ϑ(x)) ≡ u(x). Thus, the equilibrium equation (5) 1 can be recast as For x = ψ(t), the equation above delivers an incremental boundary conditionσ(ψ(t), t) = 0. Since (8) holds for all t ≥ ϑ(x), by localisation we obtain the incremental equilibrium equationσ ′ (x, t) − Gu(x, t) = 0. Together with time differentiation of (5) 2,3,6 we thus obtain the incremental formulation of the equilibrium problem (5), The advantage of (9) with respect to (5) is that the incremental displacementu(x, t) does not depend on the yet unknown fieldū ′ (x), whereasū ′ (x) appears explicitly in the problem (5). Furthermore, at least in the special case when the elastic moduli are constant, the incremental solutionu can be determined analytically.
Once the fieldu is known, the resulting distribution ofū ′ (x) can be obtained by recalling thatū ′ (x) = (x, ϑ(x)) + ϑ ′ (x)u(x, ϑ(x)). By using this identity together with the condition σ(x, ϑ(x)) = 0, we finally obtainū This expression shows that the incompatibility resulting from deposition and adhesion to an elastic substrate is made of two counterparts: a local, uniform contribution, that is controlled by the deposition temperature; and a non-local contribution, that depends on the incremental displacement of the growth-end and, henceforth, on the deformation of the whole bar. Due to the non-local term, deposition protocols that share the same deposition temperature, but that differ in terms of spatial distribution of temperature, will ultimately result into different distributions of residual stress. In this sense, the strain incompatibility permanently accumulated through u ′ holds the memory of the construction history [25], a path-dependence effect already highlighted in the context of purely mechanical surface growth [38][39][40]. Under the assumption of constant velocity, ϑ(x) = V x, the solutionu to the incremental problem can be found analytically and then, through (10), we finally obtain, for a generic distribution of temperature in the bar, This expression, which is our main finding, shows explicitly how the fieldū ′ (x) depends on the whole previous thermal history T (z ≤ x, s ≤ ϑ(x)) in the bar. The resulting distribution ofū ′ (x) can be used to compute the evolution of stress during deposition, by using the analytical expression (3) together with η(x, t) = α∆T (x, t) −ū ′ (x).
To compute the residual stress in the bar at end of accretion, when the bar is uniformly at the ambient temperature, we can use (3) with η(x) = −ū ′ (x).

B. Incremental formulation: temperature dependent moduli
The assumption of constant moduli discussed above leads to an underestimate of the stress accumulation during the deposition. For this reason, we now briefly discuss how the incremental approach discussed above can be modified to account for temperature dependence of the moduli. In this case, the incremental equilibrium equation (5) 1,4 rewrites aṡ The resulting incremental formulation of the equilibrium problem with temperature dependent moduli is depend on the previous history of deformation. In this case the incremental solutionu cannot be determined analytically and the problem can be approached by a finite difference formulation. The resulting incompatibility can be computed, once again, by using (10).

IV. APPLICATIONS
The model can now be applied to reproduce some important features observed in numerical and experimental studies on welding and additive manufacturing. We separately present the fully analytical results in the case of constant moduli, and the numerical results relative to non-constant moduli.

A. Temperature distribution during deposition
To account for the velocity of the moving heat source we embrace the approximated Rosenthal solution to the heat diffusion problem [47], frequently adopted in the modeling of welding and additive manufacturing [48]. Such solution is here modified to avoid temperature singularities at deposition. By assuming that the velocity V of the moving heat source is constant and equal to the deposition velocity D 0 , so that ψ(t) = V t, we take where the tuning parameter a is proportional to the specific heat flux of the source, and where w = a 2 V (T dep − T amb ) 2 . The resulting dependence of temperature on velocity, qualitatively reported in Fig.4, shows that higher velocities of the moving heat source result into higher temperature of the whole bar. This confirms the physical expectation that if the heat source moves faster, there is less time for heat transfer to take place with the surrounding material.

B. Predictions in the case of constant moduli
While in realistic applications of welding and additive manufacturing the elastic moduli have a strong variation with temperature, we can still show that under the simplifying assumption of constant elastic moduli our theory gives good qualitative agreement with the experimental observations. The advantage is, in this case, that the solution is fully analytical. At this point, by adopting the temperature profile (15), we can introduce the dimensionless stress in the bar where E = E amb is the homogeneous reference longitudinal modulus. Note thatσ depends on the list of parameters β, α, a, (T dep − T amb ), V . The resulting stress profile immediately at the end of deposition, its modification during cooling and the influence of velocity on the maximum residual stress are given FIG. 5. Trends of the elastic moduli with temperature for two materials: IN718 (used in AM) data from [30] and DP600 (used in welding) data from [51,52] .
by the fully analytical expressions (3),(11) together with the temperature profile (15). The results, represented in Fig.6, show that during deposition the stress is nonsymmetric with respect to the bar midpoint, and that the stress increases as deposition advances, see Fig.6 a . At the end of deposition, the temperature decreases while the strain incompatibility is frozen at its deposition value (11). As a result, the stress in the bar increases significantly upon cooling, as illustrated in Fig.6 b . Finally, the maximum residual stress in the bar is an increasing function of the velocity of the moving heat source, see Fig.6 c . As discussed later on, all these trends are recovered in the case of variable elastic moduli, and are in reasonable qualitative agreement with the available experimental and computational observations.

C. Predictions in the case of temperature dependent moduli
In most materials used in welding and additive manufacturing, both the longitudinal and the shear elastic moduli are decreasing functions of temperature, whereas their ratio (which is a function of the Poisson coefficient), is essentially constant over a wide range of temperatures, see Fig.5 [18,22,43]. To account for the reduction with temperature we here assume that E(T ) = E amb (1−r(T −T amb )), where E amb is the value of the longitudinal modulus at the ambient temperature and where r is a tuning parameter. Concerning the shear modulus, we assume that G(T ) = β 2 E(T ) where, in analogy with the 3D theory, β is constant.
The only parameter that can not be extracted from available data at the 3D level is β: a consistent 3D→1.5D derivation of β is still possible by using methods of dimension reduction [49], but this task is out of the scopes of our work; for this reason, we here treat it as a tuning parameter. More in detail, after obtaining from literature the value of the material/process parameters α, a, (T dep − T amb ), E amb , r, V , we tune β on the maximum value of the dimensionless stressσ. We then keep β fixed when changing other process parameters, such as velocity or temperature profile. Note that with temperature dependent moduli there are no closed form solutions, so the approach described in Sec.III B must be adopted.
In our first application, we deal with the stress profile at the end of deposition and we compare our results with the numerical and experimental results of [30,50]. By extracting the temperature profile from [30], we have tuned the model parameter β to achieve the same maximum value of the dimensionless stressσ, see Fig.7. Our resulting profile for the longitudinal stress is in good qualitative agreement with the experimental measurements, when temperature in the workpiece is uniformly equal to the ambient temperature.
A second application describes the evolution of the stress profile upon cooling. In this case, we first tune the temperature profile at the end of deposition and during cooling on the numerical solution to the heat diffusion problem given in [30] (see Fig.8). We then deduce the distribution of stress in the bar as described in Sec.III B. Upon cooling, the stress in the bar increases and tends to become symmetric, both according to the numerical predictions of [30] (see Fig.9 a ) and according to our model (see Fig.9 b ). Note that numerical predictions of [30] show, upon cooling, a flat region due to the attainment of the yield stress, and a clear hardening effect which makes the model quite more elaborate than the present simple, but transparent one. Since we neglect plasticity effects in our model, we cannot expect a quantitative agreement with the numerical predictions of [30], but we would like to point out that the "origin" of residual stresses, even in the model of [30], remains mostly elastic: as Fig.9 a shows, immediately at the end of deposition (red curve) the stress is mostly below the yield stress for the given temperature. In our perspective, this initial distribution of residual stress is due to the accumulation of strain incompatibility. Then, during cooling, larger plasticity effects appear in the system.
To attempt a qualitative comparison of our findings with the ones of [30], we have used third order polynomials to extrapolate elastic stress profiles in this work. Based on the values of the yield stressesσ II y andσ III y for the green and the blue curves of Fig.9 a , respectively, we have computed the 4 coefficients of the third-order polynomialσ ela by imposing that the extrapolated elastic stress profile (dotted curves) has same values and slopes of the numerical profiles in the two points where the yield stress is attained. The comparison of our results with the ones of [30] shows a reasonably good estimate of the stress increments during the cooling process. We finally focus on the effect of velocity on the maximum residual stress. This effect was experimentally studied by [15] in the case of laser welding of dual phase steel for a constant heat input per unit length. In this case, experiments show that the maximum residual stress at the end of welding is lower than the material yielding  [50], from which we have extracted V = 4mm/s, L = 40mm, T amb = 300K, T dep = 1600K and a = 1056.8K √ s, E amb = 165GPa, r = 5.14 ⋅ 10 −4 K −1 and α = 1.43 ⋅ 10 −5 K −1 . The blue curve is the numerical estimate of [30], whereas the green curve is the residual stress profile according to our own model, with β = 0.0305 mm −1 .
stress, supporting our perspective that residual stresses can have a non-plastic origin. By extracting from [15] the model parameters and by tuning β on a reference value of the dimensionless stress, our results, illustrated in Fig.10, show that higher velocity results into higher maximum stress in the bar: this result is consistent with the experimental findings of [15], further supporting the capacity of our model to describe a plethora of effects, even in the absence of plastic deformations.

V. CONCLUSIONS
In this work we have presented a simple mechanical model that describes the process of deposition and adhe-  [30] immediately at the end of deposition (red), during cooling (green) and towards the end of cooling (blue). (b) (red) our calibration of the modified Rosenthal solution (15) based on the numerical temperature profile at the end of cooling, for V = 15mm/s, L = 14mm, T amb = 300K, T dep = 960K, that gives a = 235.9 Ks 1 2 ; (green) polynomial interpolation of the corresponding curve in (a); (blue) the uniform ambient temperature in the bar.
sion of thermally expanded filaments to an elastic substrate, and we have applied our model to reproduce some trends observed in numerical and experimental studies on welding and additive manufacturing. Despite of its intrinsic limitations, our 1.5D model correctly predicts several effects observed both in experimental and computational studies, such as the residual stress pattern immediately after deposition, its evolution upon cooling, and the role played by the velocity of the moving heat source on the maximum value of the residual stress. Noteworthy, our model does not require the introduction of plastic deformations. While on the one hand plasticity effects can be certainly included, our main task was to show that the inelastic source of residual stress during the deposition of thermally expanded material is represented by strain incompatibility. The relevance of this  [30] with E amb = 166GPa. The three stress profiles refer to the three temperature profiles reported in Fig.8a and are relative to the end of deposition (red), cooling (green) and ambient temperature (blue). Hereσ α y with α =I,II,III are the yield stresses at various temperatures and the dotted curves are 3 rd order extrapolations of the elastic stress in the plastically deformed zone. (b) Dimensionless stressσ from our model, relative to the temperature profiles reported in Fig.8 b . The value β = 0.49mm −1 was calibrated to achieve the same maximum stressσ * at the end of deposition in our model and in the numerical simulations. for the maximum residual stress versus velocity. Here L = 150mm, T amb = 300K, T dep = 1600K, a = 236.7Ks 1 2 , α = 1.82 ⋅ 10 −5 K −1 , E amb = 210GPa, r = 6.124 ⋅ 10 −4 K −1 . The value of β = 0.0067 mm −1 was tuned to match the marked value of dimensionless stress, relative to V = 80mm/s. field was recently discussed for all processes of surface deposition of mass [38][39][40], above all in the "inverse engineering" perspective to embed a required distribution of residual stress through suitable deposition protocols. Future extensions of the idea proposed in this work will require a fully coupled 3D thermo-elastic formulation of the theory, thus paving the way for the possibility to "design residual stress patterns" through layered deposition of mass: an exciting perspective for a future generation of 3D printers, capable to embed information not only in the form of elastic properties [55], but also in the form of prestress [53,54].