Investigating infill density and pattern effects in additive manufacturing by characterizing metamaterials along the strain-gradient theory

Infill density used in additive manufacturing incorporates a structural response change in the structure. Infill pattern creates a microstructure that affects the mechanical performance as well. Whenever the length ratio of microstructure to geometry converges to one, metamaterials emerge and the strain-gradient theory is an adequate model to predict metamaterials response. All metamaterial parameters are determined by an asymptotic homogenization, and we investigate the effects of infill density and pattern on these parameters. In order to illuminate the role of infill characteristics on the strain-gradient parameters, an in-depth numerical investigation is presented for one, widely used case in three-dimensional (3D) printers, rectangular grid.


Introduction
The usage of additive manufacturing (AM) techniques in different industrial applications has recently gained remarkable momentum, trending in different fields like aerospace, automotive, medical, architecture, and construction. AM techniques fabricate three-dimensional (3D) designs prepared in a CAD software using a layer-wise approach, enabling to manufacture complex parts, which are challenging or even impossible to be realized by conventional manufacturing techniques such as CNC milling, turning, and casting. As many design constraints are eliminated, AM methods have revolutionized the perception of engineers and designers leveraging complexity, creativity, and multi-functionality. Therefore, with their inexorable progress and distinctive properties, AM techniques are currently preferred in many applications as primary fabrication technique [1][2][3][4] enabling to introduce new innovative design concepts [5][6][7][8][9][10][11].
One of the most significant advantages of AM is that lightweight and topologically optimized parts may be designed and fabricated per its layer-by-layer fabrication approach. In this way, less material is used while providing desired performance and a considerable reduction in waste. For this purpose, during the tool planning process, also referred to as ''slicing,'' the virtual model (i.e. CAD design) is divided into layers taking heed of infill pattern and infill ratio. Then, each layer is formed accordingly by following the generated tool path, and the part with desired internal structural pattern is fabricated. The infill pattern and infill ratio may vary depending on parts to be printed and expected mechanical performance. Therefore, as AM deals with internal structure without requiring any extra manufacturing steps or equipment, design and fabrication of mechanical metamaterials is emerging in basic research. Metamaterials exhibit tailored, ''exotic'' properties allowing to design multiscale approaches [12][13][14][15][16][17]. Therefore, in mechanical metamaterials such as auxetic [18,19] or pantographic [3] structures, the unique overall behavior is obtained by mechanical interaction of microconstituents composing the structure.
Ability of fabricating complex materials with new advanced manufacturing methods has also revealed the need for new mathematical models as the classical ones are not sufficient or practical [20][21][22][23][24][25]. Indeed, this is an ineluctable fact from a theoretical point of view in a more complex design and manufacturing environment. For this purpose, higher-gradient theories have been extensively developed and investigated in the literature. Briefly, higher-gradient theories assume that the deformation energy may also include higher gradients of displacement field as opposed to the classical theory [26]. Although such theoretical efforts have been made since 1950s [27][28][29][30][31][32][33], fabrication of metamaterials showing highergradient effects by AM has succeeded to ignite an applied research. Specifically, the recent studies on pantographic structures have epitomized the importance of higher-gradient theories, especially for numerical predictions of such a complex structure. In order to investigate the mechanical behavior of pantographic structures, various higher-gradient models have been proposed [34][35][36][37][38] and examined through experiments [39][40][41][42][43][44], considering different mechanical phenomena [45][46][47][48][49][50]. We refer interested readers to the previous works [51][52][53][54] on different aspects of higher-gradient modeling.
In this study, strain-gradient modeling of additively manufactured specimens is investigated considering different infill ratios and infill patterns. In order to elicit the strain-gradient model of an additively manufactured specimen, an asymptotic homogenization framework is utilized. The computational homogenization procedure, which is based on the balance of micro-and macro-energies, determines all the constitutive parameters emerging in the strain-gradient theory. Via the determined parameters, simulations based on the strain-gradient model are conducted to investigate the mechanical behavior of the specimen. In this study, we examine the effects of infill ratio and infill pattern on the strain-gradient model and its constitutive parameters. To this end, a specimen with grid infill pattern has been first investigated considering different infill ratios. Then, by keeping the infill ratio fixed, various infill patterns have been studied. The numerical study has been aimed to divulge how strain-gradient parameters and deformation energy related to the strain-gradient terms change due to infill ratio and infill pattern. As a result, insights have been unraveled for design and strain-gradient modeling of such materials.
The rest of the paper is as follows. In section 2, the asymptotic homogenization is presented identifying strain-gradient constitutive parameters in order to provide mathematical preliminaries for the subsequent numerical study. In section 3, the conducted numerical study is presented for the specimen under study. Then, the conclusions are drawn in section 4.

Asymptotic homogenization to identify strain-gradient parameters
We follow the asymptotic homogenization approach introduced [55], applied [56,57], and verified [58]. Continuum with a microstructure (microscale) is modeled as a metamaterial equivalent to a homogenized continuum (macroscale) with the smeared out microstructure. At the microscale, expressed in y, displacement, u m , strain, and stress may be different than its corresponding homogenized continuum at the macroscale, expressed in x. Between x and y, macro-to-microscale transformation is handled by a homothetic ratio, e. Technically, no scale separation is used, i.e., the same coordinate system is incorporated leading to a different material equation at micro-and macro-scales. By knowing one material model, we determine the parameters of the other material model. Herein, the approach is based on the given microscale with the material properties. Metamaterials' parameters at the macroscale are aimed for. At the microscale, we use linear elastic isotropic model with the known stiffness tensor, C m , the deformation energy density, e m , is modeled as a quadratic function: We use standard continuum mechanics formulation and understand Einstein's summation convention over repeated indices. Linearized displacement gradients, e m , create an objective energy formulation, they are given as, By using CASTIGLIANO's theorem: We obtain stress and the latter is called Hooke's law. Since the energy is quadratic, the material law is linear. We use small displacement approach for the homogenization process leading to metamaterials' parameters. Once the parameters are found, at the macroscale, geometric nonlinearities may be involved using a nonlinear strain measure [59,60]. At the macroscale, we model using the strain-gradient elasticity with the same type of (quadratic) stored energy density with the usual restrictions as objectivity and positive definiteness [61,62]. A comma notation denotes a partial derivative in x, which denotes the homogenized continuum. The same strain measure results in These additional metamaterial tensors, C M , G M , and D M , need to be determined. In the case of the repeating microstructure, we characterize only one unit cell or a representative volume element (RVE) built by unit cells. Using periodic boundary conditions on the RVE boundaries, we capture the complete response of the body. By varying additional parameters, it is possible to determine the correct variables that fulfill one axiom: the deformation energy within the RVE, O, is identical at micro-and macro-scales ð Displacements or stress may differ, but the energy is the same. This axiom is the starting point for the asymptotic homogenization. For the complete derivation of the governing equations, we refer to Abali and Barchiesi [55], and summarize the algorithm herein briefly. The core idea is to expand displacement field up to the second order, and then find out additional governing equations by coefficients comparison in this expansion in e 0 , e 1 , and e 2 . Three equations emerge and the first equation explains that the leading term with e 0 is equivalent to the displacement at the macroscale. Second equation delivers the newly introduced field u to be calculated by Once the field u is calculated, we obtain C M as follows: Third equation delivers c by calculating, By means of u and c, we obtain which is used to determine all strain-gradient parameters: We observe that C M , G M , and D M depend on e 0 , e 1 , and e 2 , respectively. Hence, stiffness tensor is constant for different homothetic ratios. The term G M vanishes in case of centro-symmetric microstructure, which is the case herein. However, we compute their values in order to make sure that the code is working as expected. Obviously, D M depends on e quadratically, this dependence on geometric characteristic length is known as the size effect in the literature.

Numerical implementation and results
All aforementioned governing equations are solved numerically by means of the finite element method (FEM). We use open-source packages known as FEniCS [63,64] and solve the governing equations by generating a weak form for each of them by following the standard variational formulation. We refer to Abali [65] for engineering applications and their implementation by means of FEniCS packages. Standard FEM properties are used, where the field functions are approximated by their discrete counterparts with a compact support. Technically, we span a finite dimensional Hilbertian Sobolev space for trial functions [66]. As known as the Galerkin approach, the same space is used for test functions as well. We emphasize that micro-and macro-scales are both expressed in the same coordinate system, which is an important benefit in the computational implementation. The computational domain is the RVE that is discretized by nodes and their connectivity by elements. This discretization procedure is handled by NetGen algorithms in Salome CAD software.
In two-dimensional (2D) case, for u from equation (7), we obtain three different weak forms and for c from equation (9), we obtain six different weak forms, by separately setting a, b, and c indices (no sum), we may write them all together, Trial functions, u and c, as well as their test functions, du and dc, are all approximated using standard Lagrange elements. We use continuous and linear form functions. Periodic boundary conditions are applied on all boundaries by mapping the solution at the corresponding surfaces. Simply stated, the solution is restricted in such a way that values of u and c are equal on corresponding surfaces. Therefore, the node positions have to match, which is established using projection method in meshing in Salome.
Since the weak form is linear, we solve them using a direct method, specifically, using Mumps solver from PETSc package [67]. A specimen of length L = 110 mm and height H = 22 mm as shown in Figure 1 has been selected to investigate in this study, where apparently the microstructure is of the same order of magnitude. Additional support has been added to the left and right sides of the grid structure with the purpose of applying boundary conditions to the grid structure equally distributed.
The specimen was first assumed to be designed with grid infill pattern and 40% infill ratio. RVE of the specimen is given in Figure 2, and the asymptotic homogenization procedure is applied to this RVE to extract strain-gradient constitutive parameters.
We consider this specimen as built by PLA, which is one often used filament type in fused deposition modeling (FDM)-based 3D printers. We utilize Young's modulus of PLA as E = 3500 MPa and Poisson's ratio as n = 0:3. For the ''voids,'' we use Young's modulus of 0:01 MPa.
Asymptotic homogenization results in C M , G M , and D M values, representing the same deformation energy for the metamaterial as a homogenized continuum as shown in Figure 3. Therefore, straingradient simulations are conducted on the homogenized continuum to predict the mechanical behavior of specimen under study.
In order to present the parameters, we use Voigt-like notation. Concretely, we use A, B indicating f11, 22, 12g and a, b denoting f111, 221, 121, 112, 222, 122g, such that we obtain and For the specific case of 40% infill ratio, parameters read as follows:  In order to conduct computational asymptotic homogenization procedure, discretization of the target RVE may play an important role, especially for D M ab . Therefore, global mesh size of RVE is identified by h-convergence, we emphasize the use of the FEM providing the monotonous convergence. In Appendix 1, the mesh convergence is shown for one of the cases considered in this study (see Figure 13).

Infill density variation
In the first part of the numerical study, the effect of infill density on second-gradient parameters has been investigated, varying infill density from 10% to 100% for the same type of infill pattern to be depicted in Figure 1. For a better visualization, how the infill density manipulates the microstructure, we demonstrate in Figure 4 four different infill ratios for the same RVE as used in the analysis.
With the aforementioned approach, all variations are calculated and we provide an insight in Figure  5, how the constitutive parameters, D M 11 , D M 33 , D M 12 , and D M 34 , vary with respect to infill ratio. These parameters are two on-diagonal and two off-diagonal terms in D M ab providing a general tendency. Obviously, all the presented parameters initially increase with increasing infill density, reaching their peak values around infill density of 80%. Then, parameters decrease and all vanish when the infill density is 100%. It is of importance to emphasize that D M parameters vanish in the case of homogeneous material of 100% infill (without any microstructure). Therefore, we obtain a non-monotonous dependency on the infill ratio. This property is indeed valuable since a tailored mechanism may be initiated using a varying microstructure with high and low parameters within the body.
We stress that D M parameters are relating strain-gradient terms' significance in the energy description. In other words, one may predict for on-diagonal terms a ''stiffness'' against corresponding straingradient value. For example, D M 11 provides normal strain gradient along the same axis as the normal strain. In a beam bending problem, we expect a linear increase in the normal strain and this takes some of the deformation leading to a stiffening effect in smaller beams. This so-called size effect is apparent depending on these values. Interestingly, we realize that one specific choice of infill ratio may trigger an increase in such effects.  In addition, energy due to strain-gradient parameters has been elucidated by conducting simulations with the determined constitutive parameters considering the specimen under shear and tensile tests. We refer to [59,60] for implementation details. For both cases, we divide the energy to a first-order and second-order term and compare them. Specifically, we use equation (4) and write that reads since G M = 0 effected by the centro-symmetric microstructure. In this way, we obtain a ratio, e M 2 =e M providing the role of second gradient term in the overall deformation. This ratio depends on the microstructure as well as on the loading scenario as provided in Figure 6 as functions of infill density, along with the change in constitutive parameter D M 22 . Furthermore, the effect of homothetic ratio, e, has been studied. The parameters D M depend directly on this value as apparent in equation (11). For e ! 0, the microstructure vanishes. For comprehending the effect of the homothetic ratio in a beam bending, the mechanical behavior of the specimen has been  simulated with e = 1 and e = 2. Both solutions are plotted in Figure 7 for 40% infill density, where a more dominant microstructure, e = 2 shows a higher stiffening effect than e = 1. From an engineering perspective, the homothetic ratio being equal to 1 means exactly the given RVE for 40% in Figure 2. In the case of homothetic ratio being equal to 2, it is scaled by 2, in other words, all dimensions are doubled. Infill density (infill ratio) is the same, yet the microstructure is greater so the effects are more dominant.

Infill pattern variation
In the second part of the numerical study, the effect of infill pattern on the strain-gradient constitutive parameters has been investigated. To this end, infill pattern has been changed while keeping infill density fixed as ratio 80%. In order to control the form of voids, the following generalized ellipsoid equation [68]: has been used, where s is the exponent, which controls the convexity of the generated shape, and r is the positive real number. Non-convex shapes are generated by values s\1 while block-like shapes are generated by values s . 2. Using different values of s, different patterns have been generated, and corresponding r values providing the same infill density have been computed. In Table 1, corresponding r values are listed for the considered s values in this study. The eight different void shapes used in this part are presented in Figure 8. As seen from generated shapes, grid infill pattern is obtained for higher values of exponent s. For each pattern, we applied the asymptotic homogenization procedure and investigated how constitutive parameters (C M AB and D M ab ) change due to infill pattern. In Figure 9, constitutive parameters, namely, C M 11 , C M 12 , and C M 33 , are presented as functions of s. Roughly speaking, we observe that they remain the same without a clear trend in altering. This fact is justified since the infill density, equivalently the porosity of the material has been kept constant. The stiffness is not dependent on the microstructure, as in equation (11), it is independent of the homothetic ratio, e. Yet there is slight variation in the values, specifically the terms C M 11 and C M 12 tend to increase with increasing s values up to around s = 2 and then slightly decrease for values s . 2. We stress that the  microstructure is introducing some level of anisotropic properties that vanish as s = 2 is reached (see Figure 8). In Figure 10, the constitutive parameters D M ab are given as functions of s. Here, the terms D M 11 , D M 45 , and D M 55 decrease initially with increasing s values, reaching a minimum value at s = 2 (circular void shape). Then, they tend to increase rather moderately with increasing s values. This observation may be explained by the anisotropic to isotropic and then again to anisotropic change. However, a similar trend is observed for the terms D M 22 and D M 44 , having minima at s = 3. Hence, it is challenging to find a definite answer how the microstructure shape is altering the response. Moreover, other terms (i.e., D M 16 , D M 26 , D M 33 , and D M 35 ) increase with increasing s values. Based on the extended Voigt notation, D 22 and D 44 matrix elements represent the variation in the orthogonal direction to normal strain. The fact that these two elements of constitutive parameter are similar, results from the orthotropic nature of the macro structure Clearly, it is possible to manipulate the macroscopic response, yet the steering mechanism is counter-intuitive. In a design, we have to rely to computation models to find an optimum topology.  In addition, energy due to strain-gradient terms has been calculated for each infill pattern, deforming the specimen under a shear force as before. In Table 2, energy percentages are given for each s value considered in the analysis. Considering the change in energy values, it is seen that the stationary point is around s = 3 just like in the variation of D 22 and D 44 parameters. Therefore, at least, we may claim that these values have a major effect on the strain-gradient energy.
Moreover, the mechanical behavior of the specimen designed with three different s values, namely, 0:8, 1:5, and 3, has been studied, deforming the specimen in a shear test (Figure 11). The s values have  been chosen to emphasize the transition from convexity to concavity, considering the geometry of microstructure. According to the bending behavior of each specimen, it may be observed that an increase in concavity of the microstructure positively affects the stiffness of the structure.

Conclusion
Strain-gradient modeling in additively manufactured metamaterials is key for an effective modeling of mechanical response. We focus on different infill characteristics and their relevance in constitutive parameters. In order to identify strain-gradient constitutive parameters, an asymptotic homogenization procedure has been adopted and applied through RVE of each considered infill density and pattern. In the first part of the numerical study, for grid infill pattern, the effect of infill density on the constitutive parameters has been analyzed. Then, in the next part, the effect of infill pattern has been investigated, designing different void shapes parametrized by the exponent term of the adopted generalized ellipsoid equation.
Such studies shed light on the possibilities how to alter the macroscale mechanical response by varying microstructure properties like shape and porosity. We emphasize that the analysis has been carried out by envisioning that a varying infill density and pattern is possible with nowadays manufacturing possibilities. We give a visionary example in Figure 12 cartooning a semi-gradual change in s parameters. By developing adequate optimization algorithms for such problems, we may claim that it is apparent why we need to determine a priori the strain-gradient parameters.

Funding
The author(s) received no financial support for the research, authorship, and/or publication of this article.