1 Introduction

The accurate computation of the non-linear failure and deformation behavior of heterogeneous granular systems commonly requires a resolution of the complex mechanical interactions and deformation mechanisms at the particle scale, which can be adequately accounted for by using the discrete element method (DEM), see e.g., [1,2,3,4,5,6,7,8,9,10] and references therein. For practical granular systems composed of a vast number of particles, however, it is infeasible to simulate each particle as an individual discrete object, since this leads to DEM models with an enormously large number of degrees of freedom, and consequently, to impractical computation times. To circumvent this problem, advanced multi-scale frameworks have been developed, where the mechanical responses at the particle micro-scale and the structural macro-scale are hierarchically coupled in an computationally economical fashion. This is accomplished by simulating the macro-scale problem under consideration with the finite element method (FEM), whereby in every integration point the response to the corresponding deformation is calculated by means of a DEM model that accurately and efficiently represents the complex particle behavior at the micro-scale. Examples of coupled FEM–DEM approaches for granular materials can be found in [11,12,13,14,15], illustrating the use of various averaging theorems for relating force and displacement measures at the particle micro-scale to stress and strain measures at the structural macro-scale. Specific aspects that should deserve more attention in FEM–DEM homogenization methods, but often are neglected for reasons of simplicity, refer to (1) the Hill–Mandel micro-heterogeneity condition, which enforces consistency of energy at the micro- and macro-scales, (2) the effect of particle rotations in the formulation of micro-to-macro scale-transitions, and (3) a rigorous generalization of the multi-scale approach within the theory of large deformations.

The computational homogenization framework presented in [16] does include the three aspects mentioned above, and calculates the micro-scale response of a granular packing with a DEM model equipped with a frame of boundary particles at which the finite deformation following from the macro-scale is imposed. The formulation considers three types of micro-scale boundary conditions for the boundary particles, namely (1) homogeneous deformation and zero particle rotation (D), (2) periodic particle displacements and rotations (P), and (3) uniform particle force and free particle rotation (T), where the abbreviations (D), (P) and (T) are adopted from analogous, classical boundary conditions used in continuum homogenization theories, referring to the displacement, periodic and traction boundary conditions, respectively. The numerical implementation of the boundary conditions in [16] is done via a penalty method, where the violation of the boundary conditions is punished by increasing the total virtual work of the particle packing, through the introduction of additional forces and moments on the frame of boundary particles. Although the algorithm presented in [16] has been nicely generalized for the three types of boundary conditions in a mathematically elegant and transparent fashion, due to the nature of the penalty method the expression for the homogenized stress of the particle packing becomes explicitly dependent on the value of the penalty parameter, and thereby looses its physical interpretation. In addition, in DEM models the penalty parameter may be difficult to control and must be chosen sufficiently large in order for the penalty function to be effective, which may induce numerical instabilities [17, 18]. Another characteristic of the penalty method is that it requires the constraint equations to be satisfied “approximately” instead of “exactly”, whereby the accuracy of the approximation is determined by the magnitude of the penalty parameter. As a consequence, the limit case at which the boundary conditions are met exactly is not rigorously retrieved from the formulation, since the homogenized stress of the particle packing then vanishes, see expression (44) in [16].

In order to improve on the algorithmic drawbacks mentioned above, in the present communication an alternative numerical algorithm is proposed for the implementation of the homogenization framework presented in [16]. This algorithm is based on a servo-control methodology, using a feedback principle comparable to that of algorithms commonly applied within control theory of dynamic systems [19]. Accordingly, the displacements and rotations of the particles of the boundary frame are iteratively adapted from a gradually diminishing discrepancy between the measured and desired values of the micro-scale boundary condition. A strong point of this approach is that it is relatively simple to implement, and only affects the interface communicating information between the macro-scale FEM and micro-scale DEM models. In other words, it does not require internal modifications of the FEM and DEM source codes, so that the approach also can be combined with commercially available software for which the user typically has no access to the source code. In addition to its simplicity, the servo-control algorithm preserves the physical interpretation of the homogenized stress measure derived for the particle packing, and furnishes a realistic value for the stress in the limit case at which the micro-scale boundary condition is met exactly. It is noted that the algorithm only considers the (P) and (T) boundary conditions, since for a macro-scale problem discretized with a displacement-based FEM code, the (D) boundary condition can be implemented in a straightforward fashion, without the use of iterations.

Apart from providing servo-control algorithms for the individual (P) and (T) boundary conditions, a novel formulation for mixed (D)–(P)–(T) boundary conditions is derived, and subsequently cast into a numerical formalism. The formulation is proven to satisfy the Hill–Mandel micro-heterogeneity condition, and therefore is very useful for (1) a consistent derivation of macro-scale constitutive relations from standard material tests on particle aggregates subjected to any combination of (D)-, (P)- and/or (T)-type boundary conditions, and (2) the efficient computation of the homogenized response of large-scale particle aggregates characterized by a spatial periodicity in one or two directions, i.e., granular layers exposed to uniform (D) and/or (T) boundary conditions at their top and bottom surfaces. It will be demonstrated that the formulation allows to impose the (D) and (T) boundary conditions both at separate and identical parts of the layer boundary, where in the latter case the (D) and (T) contributions obviously need to be applied along different orthonormal directions.

Fig. 1
figure 1

a Two-dimensional particle aggregate of initial volume V and boundary \( \partial V \). Yellow and red colors refer to inner \( \mathcal {P}_p \) and boundary \( \mathcal {P}_q \) particles, respectively; b particle aggregate in the current configuration; c boundary forces \( \mathbf {a}_q\), boundary moments \( \mathbf {m}_q\), and particle contact forces \(\mathbf {f}_q^c\) acting on the boundary particles \( \mathcal {P}_q \); d particle contact forces \(\mathbf {f}_p^c \) acting on the inner particles \( \mathcal {P}_p\) (color figure online)

The performance of the servo-control algorithms developed for the various micro-scale boundary conditions is tested by using monodisperse and polydisperse frictional and cohesive packings composed of two-dimensional, circular particles and subjected to various loading paths. These examples illustrate the basic features of each of the boundary conditions in full detail. Despite the focus on two-dimensional particle systems, it should be mentioned that the extension of the present framework towards three-dimensional granular systems is trivial, and can be made without the introduction of additional prerequisites.

The paper is organized as follows. Section 2 presents a review of the numerical homogenization framework for particle aggregates, and outlines the formulations of the micro-scale (D), (P) and (T) boundary conditions proposed in [16]. Section 3 discusses the numerical implementation of the micro-scale boundary conditions, where for the (P) and (T) boundary conditions two different servo-control algorithms are presented, which include or not an initial prediction of the displacements of the boundary particles based on their positions calculated at the previous loading step. In Sect. 4 the performance of the numerical algorithms is tested on monodisperse and polydisperse frictional packings subjected to various loading paths. The numerical results clearly illustrate the characteristic differences in response for the three types of boundary conditions, and show their response convergence behavior under increasing sample size. Section 5 presents the formulation for the mixed boundary conditions, and provides the details of the servo-control algorithm and its numerical performance for the cases of infinite frictional and cohesive granular layers loaded by a vertical compressive stress, and subsequently subjected to a horizontal shear deformation. Some concluding remarks are provided in Sect.6.

In terms of notation, the cross product and dyadic product of two vectors are, respectively, designated as \(\mathbf {a} \times \mathbf {b} = e_{ijk} a_i b_j \mathbf {e}_k\) and \( \mathbf {a}\otimes \mathbf {b} = a_i b_j \mathbf {e}_i \otimes \mathbf {e}_j \), where \(e_{ijk}\) is the permutation symbol, \(\mathbf {e}_i\), \(\mathbf {e}_j\) and \(\mathbf {e}_k\) are unit vectors in a Cartesian vector basis, and Einstein’s summation convention is used on repeated tensor indices. The inner product between two vectors is given by \(\mathbf {a} \cdot \mathbf {b} =a_i b_i\), and between two second-order tensors by \( \mathbf {A}: \mathbf {B} = A_{ij} B_{ij}\). The action of a second-order tensor on a vector is indicated as \( \mathbf {A}\cdot \mathbf {b} = A_{ij} b_j \mathbf {e}_i \). The superscript T is used to indicate the transpose of a vector or a tensor. Further, \( \mathbf {I} =\delta _{ij} \mathbf {e}_i \otimes \mathbf {e}_j\) denotes the second-order identity tensor, with \(\delta _{ij}\) the Kronecker delta symbol.

Since the present study focuses on two-dimensional particle aggregates, throughout the paper the dimensions related to volume, area, stress and mass density are consistently presented in their reduced form as length\(^2\), length, force/length and mass/length\(^2\), respectively.

2 Micro–macro transitions for particle aggregates

2.1 Micro-scale geometry

The initial micro-scale granular system is characterized by a two-dimensional square domain of \( P+Q \) rigid particles, which are partitioned into P inner particles \( \mathcal {P}_p \), with \( p = 1, .., P \), and Q boundary particles \( \mathcal {P}_q \), with \( q = 1, .., Q \), colored in yellow and red in Fig. 1a, respectively. The boundary particles can be further split into corner particles \( \mathcal {P}_c \) with \( c = 1, .., 4 \) and the remaining edge particles \( \mathcal {P}_e \) with \( e = 1, .., E = Q - 4 \). The initial interior domain V comprises the inner particles with their center points as \( \mathbf {X}_p\in \mathcal {P}_p \) with \( p = 1, .., P \). The boundary \( \partial V \) is defined by the boundary particles, whose center points in the initial configuration are \( \mathbf {X}_q\in \mathcal {P}_q \) with \( q = 1, .., Q \). The macroscopic deformation of the granular micro-structure is imposed via the frame of boundary particles \( \mathcal {P}_q \), as a result of which the center points of the inner and boundary particles become located at \(\mathbf {x}_p\) and \(\mathbf {x}_q\), respectively, see Fig. 1b. In the current configuration, the boundary particles \(\mathcal {P}_q\) are subjected to boundary forces \(\mathbf {a}_q\), boundary moments \(\mathbf {m}_q\), and particle contact forces \(\mathbf {f}_q^c\), see Fig. 1c, while the inner particles \(\mathcal {P}_p\) are subjected to particle contact forces \(\mathbf {f}_p^c\), see Fig. 1d, with the superscript c denoting a contact with a neighbour particle.

The macroscopic response of a granular assembly is derived by transforming relevant principles used in first-order homogenization theories [20,21,22,23] from a continuous setting to a discrete setting. Accordingly, at the centroids of the boundary particles \(\mathcal {P}_q \) the finite area vectors \( \mathbf {A}_q\) and forces \( \mathbf {a}_q\) are derived from infinitesimal area vectors and forces, respectively,

$$\begin{aligned} \int _{\partial V} \varvec{N} ds \rightarrow \mathbf {A}_q\qquad \text {and}\qquad \int _{\partial V} {\mathbf {t}} \, ds \rightarrow \mathbf {a}_q\quad \text { for } q=1...,Q \, , \end{aligned}$$
(1)

with \( \mathbf {N} \) the vector pointing in the outward normal direction of the boundary \(\partial V\) of the initial particle volume V, \( \mathbf {t} \) being the boundary traction, and ds indicating an infinitesimal part of the boundary surface. Various expressions for \(\mathbf {A}_q\) have been presented in the literature, see e.g., [24, 25]. In the present communication the initial area vector is computed by accounting for the different radii of the boundary particles:

$$\begin{aligned} \mathbf {A}_q= & {} \frac{{R}_q}{{R}_q + {R}_{q-1}}({\mathbf {X}_q-\mathbf {X}_{q-1}})\times {\mathbf {e}_3} \nonumber \\&\quad +\,\frac{{R}_q}{{R}_q+ {R}_{q+1}} ({\mathbf {X}_{q+1}-\mathbf {X}_{q}})\times {\varvec{e}_3} \, , \end{aligned}$$
(2)

where \(R_{q+1}\), \(R_{q}\) and \(R_{q-1}\) are the radii of adjacent boundary particles \(q+1\), q and \(q-1\), respectively. Further, \(\varvec{e}_3\) represents the unit vector in the out-of-plane direction of the two-dimensional particle structure, see also Fig. 1a. Note that in (2) the boundary particles must be numbered in the anti-clockwise direction in order to obtain an area vector pointing in the outward normal direction of the boundary.

It is remarked that the formulation of the proposed homogenization scheme in principle is independent of the chosen shape of the micro-scale particle system, see also [16]; however, a slightly different implementation strategy may be required when considering non-rectangular particle systems.

2.2 Micro-scale governing equations

2.2.1 Equilibrium conditions

In the absence of body forces, the mechanical equilibrium of a granular micro-structure can be formulated in terms of the boundary forces \( \mathbf {a}_q\) and moments \( \mathbf {m}_q\) acting on the boundary particles \( \mathcal {P}_q \):

$$\begin{aligned} \sum _{q=1}^{Q} \mathbf {a}_q= \varvec{0} \qquad \text {and}\qquad \sum _{q=1}^{Q} (\mathbf {x}_q\times \mathbf {a}_q+ \mathbf {m}_q) = \varvec{0} \quad \text { for } q=1...,Q , \end{aligned}$$
(3)

with \( \mathbf {x}_q\) the current position vector of the boundary particles. The boundary forces \(\mathbf {a}_q\) and moments \(\mathbf {m}_q\) thus drive the overall, macroscopic deformation of the granular system via the frame of boundary particles.

Note that, besides global equilibrium (3), local equilibrium conditions may be formulated for each of the inner particles \( \mathcal {P}_p \), which interact through contact forces \( \mathbf {f}_p^c \) at discrete contact points \( \mathbf {x}_p^c \) on the particle surfaces:

$$\begin{aligned} \sum _{c=1}^{N^c_p} \mathbf {f}_p^c = \varvec{0} \qquad \text {and}\qquad \sum _{c=1}^{N^c_p} (\mathbf {x}_p^c -\mathbf {x}_p) \times \mathbf {f}_p^c = \varvec{0}\quad \text { for } p=1...,P, \end{aligned}$$
(4)

with the superscript c referring to a particle contact, \( {N^c_p} \) being the number of contact forces related to particle p and \( \mathbf {x}_p\) is the current position vector of the inner particle. Analogous conditions may be written for the boundary particles \( \mathcal {P}_q \), for which discrete contact forces \( \mathbf {f}_q^c \) act at contact points \( \mathbf {x}_q^c \) on the particle surfaces. The frame of boundary particles is driven by boundary forces \( \mathbf {a}_q\) and boundary moments \( \mathbf {m}_q\),

$$\begin{aligned}&\sum _{c=1}^{N^c_q} \mathbf {f}_q^c = - \mathbf {a}_q\qquad \text {and}\nonumber \\&\quad \sum _{q=1}^{N^c_q} (\mathbf {x}_q^c -\mathbf {x}_q)\times \mathbf {f}_q^c = -\mathbf {m}_q\quad \text { for } q=1...,Q \, ,\nonumber \\ \end{aligned}$$
(5)

where \( {N^c_q} \) is the number of contact forces for particle q. Note that the combination of expressions (4) and (5) is in correspondence with relation (3).

2.2.2 Particle contact laws

In order to solve the micro-scale problem, the constitutive response of the granular assembly needs to be defined through a relation between the contact forces \( \mathbf {f}_{i}^c \) (or contact moments \(\mathbf {m}_{i}^c \)), with \( i= 1, ...,P+Q \), and the corresponding contact displacements \(\Delta \mathbf {u}_i^c\) (or contact rotations \(\Delta \varvec{\theta }_i^c\)). For the sake of clarity, in the following the superscript c and subscript i will be dropped. Two types of particle contact interactions will be considered, which are referred to as frictional contact and cohesive contact.

In accordance with [1], in the frictional contact law the normal particle contact force \(f_{n}\) is proportional to the normal overlap \(\Delta u_{n}\) between two particles in contact via a multiplication by the normal contact stiffness \(k_{n}\). The tangential particle contact force \(f_{s}\) is proportional to the relative tangential displacement \(\Delta u_{s}\) at the particle contact via a multiplication by the tangential contact stiffness \(k_{s}\), up to a limit value at which frictional sliding starts, as defined by the normal force multiplied by the friction coefficient \( \mu \). The contact law is thus expressed as

$$\begin{aligned} f_{n} = k_{n} \Delta u_{n} \text { and } f_{s} = {\left\{ \begin{array}{ll} k_{s} \Delta u_{s}&{} \text { if } f_{s} < \mu f_{n} \, , \\ \mu f_{n} &{}\text {otherwise}. \end{array}\right. } \end{aligned}$$
(6)

For the cohesive contact law, two particles in contact are assumed to be initially bonded according to the constitutive model presented in [26, 27], which proposes a linear relation between the force (or moment) and the corresponding relative displacement (or rotation) at the particle contact:

$$\begin{aligned} f_{n}^b = k_{n}^b \Delta u_{n} \text { and } f_{s}^b = k_{s}^b \Delta u_{s} \text { and } m^{b}_{\theta } = k^{b}_{\theta } \Delta \theta ^b \, , \end{aligned}$$
(7)

where the superscript b refers to “bond”. In specific, the relative displacements between two particles in the normal and tangential directions of the contact, \( \Delta u_{n} \) and \( \Delta u_{s} \), are, respectively, related to the normal and tangential bond forces \( f_{n}^b \) and \(f_{s}^b\) through a multiplication by the bond stiffnesses \( k_{n}^b \) and \( k_{s}^b \), respectively. Similarly, the relative angular rotation \(\Delta \theta ^b\) is related to the contact moment \(m_{\theta }^{b}\) through a multiplication by the bond bending stiffness \(k^{b}_{\theta }\). The bond between two particles is considered as broken when the following failure criterion is met:

$$\begin{aligned} \frac{ f_{n}^b }{{f}_{n}^{b,u} } + \frac{ | f_{s}^b |}{{f}_{s}^{b,u} } + \frac{ | m_{\theta }^{b} |}{{m}_{\theta }^{b,u} } = 1 \, , \end{aligned}$$
(8)

where \({f}_{n}^{b,u}\) is the (ultimate) tensile strength, \({f}_{s}^{b,u}\) is the shear strength and \({m}_{\theta }^{b,u}\) is the bending strength. After breakage of the contact the particle interaction is described by the frictional contact law presented in expression (6).

2.2.3 Dynamic relaxation

The equilibrium conditions described by Eqs. (3)–(5) are solved by applying a dynamic relaxation method, in which the kinetic energy activated by the applied deformation is dissipated to arrive at the equilibrium state. For each particle i, where \( i = 1, .., P+Q \), a vector of generalized coordinates is defined as \( \mathbf {d}_i = \left[ \mathbf {x}_i, \ \varvec{\theta }_i\cdot \mathbf {e}_3 \right] ^T \), which includes the particle center location \(\mathbf {x}_i\) and rotation \(\varvec{\theta }_i\). In addition, a generalized force vector is introduced, \( \mathbf {p}_i = \left[ \mathbf {f}_i, \ \mathbf {m}_i\cdot \mathbf {e}_3 \right] ^T \), which contains the forces and moments acting on the particle. Accordingly, the generalized equation of motion of particle i can be expressed as

$$\begin{aligned} \mathbf {M}_i \ddot{\mathbf {d}}_i = (\mathbf {p}_r + \mathbf {p}_d )_i\quad \text { for } i=1...,P+Q \, , \end{aligned}$$
(9)

where the mass matrix \( \mathbf {M}_i =\mathbf { \mathrm {diag} } \left[ M_i, I_i \right] \) includes the particle mass \(M_i \) and particle mass moment of inertia \( I_i = 1/2~M_i R_i^2 \), with \( R_i \) the particle radius. The term \( \ddot{\mathbf {d}}_i \) represents the generalized acceleration vector, with a superimposed dot indicating a derivative with respect to time. The vector \( \mathbf {p}_r \) is the generalized force vector composed of the resultant force \( \mathbf {f}_r \) and moment \(\mathbf {m}_r\) acting on particle i, and \( \mathbf {p}_d = \left[ \mathbf {f}_d, \ \mathbf {m}_d\cdot \mathbf {e}_3 \right] ^T\) is the vector containing the resulting particle force and moment following from the artificial dissipation applied in the simulations to improve the convergence rate towards the equilibrium state. Following [28], the artificial dissipative force \(\varvec{f}_d\) and moment \(\varvec{m}_d\) are here defined as

$$\begin{aligned} \mathbf {f}_d=-\alpha |\mathbf {f}_r| \, \text {sign}(\dot{\mathbf {x}}_i) \text { and } \mathbf {m}_d=-\beta |\mathbf {m}_r| \, \text {sign}(\dot{\varvec{\theta }}_i), \end{aligned}$$
(10)

where \(\alpha \) and \(\beta \) are damping values related to (signum functions of) the particle translational velocity \( \dot{\mathbf {x}}_i \) and rotational velocity \( \dot{\varvec{\theta }}_i \), respectively. Further, |.| refers to the absolute values of the components of the corresponding vector.

The time integration of the governing equations is performed by applying an explicit, first-order finite difference scheme, which, for each time step \(t_{h+1}\), with the time increment given by \( \Delta t = t_{h+1} - t_{h} \), allows for an explicit update of the particle acceleration, velocity and displacement, see [29] for more details. The dynamic relaxation process is considered to be converged towards the equilibrium state when the ratio between the kinetic energy \(E_k\) of the inner particles in the aggregate and their potential energy \(E_p\) is lower than a prescribed tolerance [30], i.e.,

$$\begin{aligned} E_k/E_p \le \mathrm {tol}_{E}, \end{aligned}$$
(11)

in accordance with the following definitions

$$\begin{aligned} E_k= & {} \sum _{i=1}^{P} \frac{1}{2}\dot{\mathbf {d}}_i^T \mathbf {M}_i \dot{\mathbf {d}}_i \qquad \mathrm {and} \nonumber \\ E_p= & {} \sum _{c=1}^{N^c} \frac{1}{2} \left( k_{n} \, (\Delta u^c_{n})^2 + k_{s} \, (\Delta u^c_{s})^2 \right) \, , \end{aligned}$$
(12)

where \(\Delta u^c_{n}\) and \(\Delta u^c_{s}\) are the relative displacements in the normal and tangential direction of particle contact c and \(N^c\) is the total number of particle contacts. Note that for the cohesive contact law given by Eqs. (7) and (8) the potential energy in (12) needs to be extended with the rotational term \(k_{\theta } ( \Delta \theta ^c)^2/2\).

Obviously, for deriving the solution of a boundary value problem, the equation of motion (9) and the constitutive response of the particles (6) and (7) should be complemented by the appropriate boundary conditions. As mentioned in the introduction, the numerical implementation of the micro-scale boundary conditions is based on the formulation presented in [16], and the main equations are summarized in Sect. 2.3 for the sake of clarity.

2.3 Micro-scale kinematics and boundary conditions

Consider a rigid particle i within a granular assembly. The current location \(\mathbf {x}\) of an arbitrary material point, located within the initial particle volume at \(\mathbf {X}\), is defined through the non-linear deformation map \(\mathbf {x} = \varvec{\psi }_i (\mathbf {X})\), with \( \varvec{\psi }_i \) as

$$\begin{aligned} \varvec{\psi }_i(\mathbf {X}) =\mathbf {x}_i+\mathbf {Q}_i\cdot (\mathbf {X} - \mathbf {X}_i)\quad \text { for } i=1..., P+Q, \end{aligned}$$
(13)

where \( \mathbf {x}_i\) and \(\mathbf {X}_i\) are the current and original positions of the center of particle i, and \( \mathbf {Q}_i\) is the second-order particle transformation tensor. For plane problems defined with respect to the orthonormal tensor basis \(\{ \mathbf {e}_k \otimes \mathbf {e}_l \}^2_{k,l=1,2}\), the transformation tensor of particle i can be expressed as \( \mathbf {Q}_i= \mathrm {cos} \, \theta _i \mathbf {e}_1\otimes \mathbf {e}_1 - \mathrm {sin} \, \theta _i \mathbf {e}_1\otimes \mathbf {e}_2 + \mathrm {sin} \, \theta _i \mathbf {e}_2\otimes \mathbf {e}_1 + \mathrm {cos} \, \theta _i \mathbf {e}_2\otimes \mathbf {e}_2 \), with \(\theta _i\) the magnitude of the particle center rotation \(\varvec{\theta }_i= \theta _i \varvec{e}_3\), where \(\varvec{e}_3\) is the unit vector normal to the plane. In addition, the current position of the particle center \( \mathbf {x}_i\) can be expressed as the sum of a contribution affine to the macroscopic deformation gradient \(\varvec{\bar{F}}\) and a local, micro-scale fluctuation \( \mathbf {w}_i\):

$$\begin{aligned} \mathbf {x}_i=\varvec{\bar{F}}\cdot \mathbf {X}_i+ \mathbf {w}_i\quad \text { for } i=1...,P+Q. \end{aligned}$$
(14)

In homogenization schemes for continuous media, the macro-to-micro scale transition is enforced by requiring the macro-scale deformation gradient to be equal to the volume average of the micro-scale deformation gradient. In a discrete setting, this is equivalent to the condition

$$\begin{aligned} \varvec{\bar{F}}= \frac{1}{V} \sum _{q=1}^{Q} \mathbf {x}_q\otimes \varvec{A}_q. \end{aligned}$$
(15)

Relation (15) can be derived by transforming the volume average of the macro-scale deformation into a surface integral

$$\begin{aligned} \varvec{\bar{F}}= \frac{1}{V} \int _{V} \varvec{F} dv = \frac{1}{V} \int _{V} \nabla \varvec{x} dv = \frac{1}{V} \int _{\partial V} \varvec{x} \otimes \varvec{N} ds \, , \end{aligned}$$
(16)

with \( \mathbf {N} \) the vector normal to the outer boundary of the original particle volume, and subsequently performing the transition from a continuous to a discrete setting with the aid of (1)\(_1\).

Equation (15) needs to be satisfied by applying specific boundary conditions to the boundary particles of the granular micro-structure. For continuous media, this goal is typically accomplished by applying one of the three classical types of boundary conditions, namely (1) a homogeneous deformation, also known as the displacement boundary condition and thus abbreviated as (D), (2) periodic displacements (P), and (3) a uniform traction (T), see, e.g., [21,22,23]. For discrete particle structures, however, additional conditions need to be imposed on the rotations or moments of the boundary particles. Correspondingly, along the lines of [16], the three boundary conditions mentioned above are extended as (1) homogeneous deformation and zero rotation (D), (2) periodic displacement and periodic rotation (P), and (3) uniform force and free rotation (T), of which the formulations are presented below. The abbreviations (D), (P) and (T), although typically used in continuum homogenization theories, are maintained here for reasons of consistency. In addition to the three classical boundary conditions, a novel combination of these boundary conditions has been derived, which will be referred to as “mixed boundary conditions”. The corresponding formulation is proven to satisfy the consistency of energy between the microscopic and macroscopic scales of observation, known as the Hill–Mandel micro-heterogeneity condition, and the details are provided in Sect. 5.

2.3.1 Homogeneous deformation and zero rotation (D)

In accordance with this boundary condition, all the boundary particles \( \mathcal {P}_q \) are prescribed to have zero micro-scale displacement fluctuations and zero rotations:

$$\begin{aligned} \mathbf {x}_q=\varvec{\bar{F}}\cdot \varvec{X}_q \text { and } \mathbf {Q}_q=\varvec{I}\,\text { on}\, \partial V \, , \end{aligned}$$
(17)

where the first expression follows from (14) with the displacement fluctuations as \(\mathbf {w}_q=\mathbf {0}\). Due to the second condition in (17) the boundary moments do not vanish, i.e.,

$$\begin{aligned} \mathbf {m}_q\ne \varvec{0}\,\text { on}\, \partial V. \end{aligned}$$
(18)

The homogeneous deformation and zero rotation boundary condition is expected to result in a relatively stiff macroscopic response of the particle aggregate.

2.3.2 Periodic displacement and periodic rotation (P)

For this boundary condition, both the displacements and rotations of the boundary particles \( \mathcal {P}_q \) are related by periodicity requirements:

$$\begin{aligned} \mathbf {x}_q^{+}-\mathbf {x}_q^{-}=\varvec{\bar{F}}\cdot (\mathbf {X}_q^{+}-\mathbf {X}_q^{-}) \text { and } \mathbf {Q}_q^{+}-\mathbf {Q}_q^{-}=\varvec{0} \,\text { on} \, \partial V \, , \end{aligned}$$
(19)

where the superscripts \(^+\) and \(^-\) refer to corresponding particles on opposite boundaries of the granular assembly. From the viewpoint of equilibrium, the forces and moments on opposite boundaries need to be anti-periodic, thus satisfying the relations

$$\begin{aligned} \mathbf {a}_q^{+}+\mathbf {a}_q^{-}=\varvec{0} \text { and } \mathbf {m}_q^{+}+\mathbf {m}_q^{-}=\varvec{0} \,\text { on}\, \partial V. \end{aligned}$$
(20)

2.3.3 Uniform force and free rotation (T)

The boundary forces \( \mathbf {a}_q\) of the boundary particles \( \mathcal {P}_q \) are here determined from the product of the macroscopic first Piola-Kirchhoff stress \( \varvec{\bar{P}}\) and the discrete area vectors \( \mathbf {A}_q\) introduced in Eq. (1)\(_1\):

$$\begin{aligned} \mathbf {a}_q=\varvec{\bar{P}} \cdot \varvec{A}_q \, \text { on}\, \partial V. \end{aligned}$$
(21)

In addition, no constraint is applied to the boundary rotations, so that the boundary moments vanish:

$$\begin{aligned} \mathbf {m}_q= \varvec{0}\, \text { on} \, \partial V. \end{aligned}$$
(22)

The uniform force and free rotation boundary condition is expected to provide a relatively soft macroscopic response of the particle aggregate.

2.4 Macro-scale stress and Hill–Mandel condition

The first Piola-Kirchhoff stress at the macro scale is defined in terms of the boundary forces \( \mathbf {a}_q\) acting on the particle aggregate:

$$\begin{aligned} \varvec{\bar{P}}=\frac{1}{V}\sum _{q=1}^{Q} {\mathbf {a}_q}\otimes {\varvec{X}_q}. \end{aligned}$$
(23)

The Hill–Mandel micro-heterogeneity condition expresses the equality between the volume average of the virtual work applied at the boundaries of the micro-structure and the virtual work of a macroscopic material point [31]. For a discrete particle system this condition specifies into

$$\begin{aligned} \varvec{\bar{P}}:\delta \varvec{\bar{F}}= \frac{1}{V} \sum _{q=1}^{Q} \mathbf {a}_q\cdot \delta {\mathbf {x}_q}. \end{aligned}$$
(24)

The macroscopic stress \( \varvec{\bar{P}}\) given by (23) must satisfy the energy consistency between the two scales. Accordingly, considering definition (15), the following identity holds

$$\begin{aligned} \varvec{\bar{P}}:\delta \varvec{\bar{F}}= \varvec{\bar{P}}:\frac{1}{V} \sum _{q=1}^{Q} \delta \mathbf {x}_q\otimes \mathbf {A}_q= \frac{1}{V} \sum _{q=1}^{Q} \left( \varvec{\bar{P}}\cdot \mathbf {A}_q\right) \cdot \delta \mathbf {x}_q. \end{aligned}$$
(25)

Alternatively, by making use of the definition of the macro-scale stress (23), the inner product \( \varvec{\bar{P}}:\delta \varvec{\bar{F}}\) can be expanded as

$$\begin{aligned} \varvec{\bar{P}}:\delta \varvec{\bar{F}}= \frac{1}{V} \sum _{q=1}^{Q} \mathbf {a}_q\otimes \mathbf {X}_q:\delta \varvec{\bar{F}}= \frac{1}{V} \sum _{q=1}^{Q} \mathbf {a}_q\cdot \left( \delta \varvec{\bar{F}}\cdot \mathbf {X}_q\right) . \end{aligned}$$
(26)

Subsequently, reformulating Eq. (24) as

$$\begin{aligned} \frac{1}{V} \sum _{q=1}^{Q} \mathbf {a}_q\cdot \delta \mathbf {x}_q- \varvec{\bar{P}}:\delta \varvec{\bar{F}}- \varvec{\bar{P}}:\delta \varvec{\bar{F}}+ \varvec{\bar{P}}:\delta \varvec{\bar{F}}= 0 \, , \end{aligned}$$
(27)

substituting Eqs. (25) and (26), and keeping in mind that

$$\begin{aligned} \varvec{\bar{P}}:\delta \varvec{\bar{F}}= & {} \varvec{\bar{P}}:\left( \delta \varvec{\bar{F}}\cdot \frac{1}{V} \sum _{q=1}^{Q} \mathbf {X}_q\otimes \mathbf {A}_q\right) \nonumber \\= & {} \varvec{\bar{P}}: \left( \frac{1}{V} \sum _{q=1}^Q \delta \varvec{\bar{F}}\cdot \mathbf {X}_q\otimes \mathbf {A}_q\right) \nonumber \\= & {} \frac{1}{V} \sum _{q=1}^{Q} (\varvec{\bar{P}}\cdot \mathbf {A}_q)\cdot (\delta \varvec{\bar{F}}\cdot \mathbf {X}_q), \end{aligned}$$
(28)

leads to

$$\begin{aligned} \frac{1}{V} \sum _{q=1}^{Q} { \left( \mathbf {a}_q- \varvec{\bar{P}}\cdot \mathbf {A}_q\right) \cdot \left( \delta \mathbf {x}_q- \delta \varvec{\bar{F}}\cdot \mathbf {X}_q\right) } = 0. \end{aligned}$$
(29)

Invoking the micro-scale displacement fluctuations in accordance with relation (14) turns expression (29) finally into

$$\begin{aligned} \frac{1}{V} \sum _{q=1}^{Q} \left( \mathbf {a}_q- \varvec{\bar{P}}\cdot \mathbf {A}_q\right) \cdot \delta \mathbf {w}_q= 0. \end{aligned}$$
(30)

Note that the recast form (30) of the Hill–Mandel condition is satisfied for all three types of boundary conditions introduced above: For the (D) boundary condition, the combination of Eqs. (14) and (17) results in \( \delta \mathbf {w}_q= \varvec{0} \). For the (P) boundary condition, the periodicity of the micro-fluctuations of the boundary displacements \( \mathbf {w}_q^+ = \mathbf {w}_q^- \) and the anti-periodicity of the boundary forces \( \mathbf {a}_q^{+}= - \mathbf {a}_q^{-}\), following from Eqs. (19) and (20), respectively, make that their products in expression (30) vanish for opposite boundaries. For the (T) boundary condition, relation (21) leads to \(\mathbf {a}_q- \varvec{\bar{P}}\cdot \mathbf {A}_q= \mathbf 0 \).

It should be mentioned that the Hill–Mandel condition elaborated above only accounts for the influence of contact forces acting on inner particles, and does not include the effect of contact moments. This is consistent with the assumption of a standard (Boltzmann) continuum at the macro scale, which contains displacement degrees of freedom but does not consider rotations. This assumption is satisfied for the frictional contact law, in which the contact moments are absent, see expression (6). For the cohesive contact law, the contact moments contribute both to the elastic behavior and the strength criterion, see expressions (7) and (8), respectively. The extension of a contact law with a contact moment contribution formally introduces a couple stress in the macroscopic response of the particle aggregate, which is energetically conjugated to the gradient of the overall rotation, see e.g., [32,33,34,35,36,37]. These higher-order stress and deformation measures correspond to higher-order natural and essential boundary data [37], which are known to be difficult to measure in experiments, and commonly are (substantially) lower in magnitude than the classical boundary data. For these reasons, and from the fact that the cohesive contact law defined by Eqs. (7) and (8) is used only for one example discussed at the end of this communication, see Sect. 5.3, an extension of the Hill–Mandel condition with the effect of a contact moments is omitted here, but may be considered as a topic for future research. Correspondingly, for the cohesive contact law a consistency in energy between the micro- and macro- scales of a particle aggregate can only be warranted in an approximate fashion.

In Sects. 4 and 5, the results of the DEM analyses will be presented in terms of components of the macro-scale Cauchy stress tensor \(\varvec{\bar{\sigma }}\). This stress measure can be derived from the first Piola-Kirchhoff stress \(\varvec{\bar{P}}\) computed through (23) by using the common transformation rule:

$$\begin{aligned} \varvec{\bar{\sigma }} = \frac{1}{\mathrm {det} \left( \varvec{\bar{F}}\right) } \varvec{\bar{P}}\cdot \varvec{\bar{F}}^T. \end{aligned}$$
(31)

3 Numerical implementation of micro-scale boundary conditions

The micro-scale boundary conditions outlined above were implemented by using the open-source discrete element code ESyS-Particle [38, 39]. The numerical algorithms developed for this purpose are described below.

3.1 Homogeneous deformation and zero rotation (D)

The homogeneous deformation and zero rotation boundary condition (D) given by Eq. (17) can be implemented straightforwardly by imposing this condition in an incremental fashion on the boundary particles \( \mathcal {P}_q \). After moving the boundary particles in accordance with the incremental update of the deformation \(\varvec{\bar{F}}\), dynamic relaxation is applied to reach the equilibrium state of the particle aggregate, during which the displacements imposed on the boundary particles remain fixed. The particle configuration corresponding to the equilibrium state is stored, and the next deformation increment is applied. This process is repeated until the total number of deformation increments \(i_{tot}\) is reached. The details of the algorithm are summarized in Table 1.

Table 1 Algorithm for the (D) boundary condition

3.2 Periodic displacement/periodic rotation (P) and uniform force/free rotation (T)

The periodic displacement and periodic rotation boundary condition (P) and the uniform force and free rotation boundary condition (T) were numerically implemented by means of a servo-control algorithm, which uses a feedback principle similar to that of algorithms commonly applied within control theory of dynamic systems [19]. More specifically, the algorithms iteratively correct the boundary particle displacements and rotations from a gradually diminishing discrepancy between the measured and the required values of the boundary condition.

For the periodic displacement and periodic rotation boundary condition (P), the boundary forces and boundary moments should satisfy the anti-periodicity conditions presented in Eq. (20). Accordingly, the corresponding residuals for the edge particles are

$$\begin{aligned}&\Delta \mathbf {a}_e = \mathbf {a}_e^{+}+\mathbf {a}_e^{-}, \quad \nonumber \\&\quad \Delta {m}_e = (\mathbf {m}_e^{+} + \mathbf {m}_e^{-})\cdot \mathbf {e}_3 \quad \text { for }\quad e=1...,E/2. \end{aligned}$$
(32)

Multiplying the residuals by corresponding gain parameters \( g^p_a \) and \(g^p_m\) results into the following displacement and rotation corrections for the edge particles:

$$\begin{aligned}&\Delta \mathbf {u}_e^{+} = \Delta \mathbf {u}_e^{-} =g^p_a \Delta \mathbf {a}_e ,\quad \nonumber \\&\quad \Delta {\theta }_e^{+} = \Delta {\theta }_e^{-} =g^p_m\Delta {m}_e \quad \text { for }\quad e=1...,E/2 \, , \end{aligned}$$
(33)

which are added to the particle locations and rotations from the previous iteration. Note that the four corner particles straightforwardly follow the macroscopic deformation \(\varvec{\bar{F}}\), by prescribing their displacements in accordance with Eq. (17). Hence, for these particles no displacement correction is needed. The rotations of the four corner particles will be updated similarly to (33), using the corrections

$$\begin{aligned} \Delta {\theta }_c^{+} = \Delta {\theta }_c^{-} =g^p_m\Delta {m}_c \quad \text { with}\quad \Delta {m}_c = \sum _{c=1}^4 \varvec{m}_c \cdot \varvec{e}_3. \end{aligned}$$
(34)

For the uniform force/free rotation boundary condition (T), the boundary forces ensue from the applied macroscopic stress through expression (21). However, since the solution procedure is deformation-driven, the constraint given by (21) cannot be enforced directly on the micro-scale particle structure. Correspondingly, an additional condition that depends explicitly on the macroscopic deformation \( \varvec{\bar{F}}\) should be used. This condition is given by expression (15), which represents the weak counterpart of expression (21), see also [16]. Hence, the two corresponding residuals are formulated as

$$\begin{aligned} \Delta \mathbf {a}_q= & {} \varvec{\bar{P}}\cdot \mathbf {A}_q- \mathbf {a}_q, \quad \nonumber \\ \Delta \varvec{\bar{F}}_q= & {} \sum _{r=1}^{Q} \left[ V \varvec{\bar{F}}\cdot \mathbf {A}_q- (\mathbf {A}_q\cdot \mathbf {A}_r)~\mathbf {x}_r\right] \quad \text { for } q=1...,Q .\nonumber \\ \end{aligned}$$
(35)

The correction for the displacement of the boundary particles is derived by multiplying the force and deformation residuals in (35) by the gain parameters \( g^{t}_a \) and \( g^{t}_F \), respectively, leading to

$$\begin{aligned} \Delta \mathbf {u}_q = g^{t}_a \Delta \mathbf {a}_q+ g^{t}_F \Delta \varvec{\bar{F}}_q \quad \text {for}\quad q=1...,Q. \end{aligned}$$
(36)

When performing numerical simulations, the specific values of the gain parameters \( g^p_a, \, g^p_m, \, g^{t}_a, \, g^{t}_F \) need to be fine-tuned from accuracy and stability considerations of preliminary numerical benchmark tests.

Table 2 Algorithm for the (P) and (T) boundary conditions with initial displacement prediction
Table 3 Algorithm for the (P) and (T) boundary conditions without initial displacement prediction

The corrections for the displacement and rotation of the boundary particles were implemented by means of two different algorithms, which consider or not an initial prediction of the position of the boundary particles based on their positions calculated at the previous loading step. These algorithms are therefore given the labels “with initial displacement prediction” and “without initial displacement prediction”. The algorithms are discussed below, and their effect on the computational results will be investigated in Sect. 4. The specific parts of the algorithms that refer to the periodic displacement and periodic rotation boundary condition will be denoted by the symbol (P), while the symbol (T) indicates the uniform force and free rotation boundary condition. Finally, the residuals defined in expressions (32) and (35), which relate to the particle force, particle moment and macroscopic deformation gradient, are evaluated at each iteration by subjecting their dimensionless form to a convergence check. The dimensionless forms are obtained through, respectively, a normalization by the following parameters:

$$\begin{aligned} \tilde{a}_k=\frac{{M_k}{R_k}}{{{\Delta t}}^2}, \qquad \tilde{m}_k=\frac{{M_k}{R_k^2}}{{{\Delta t}}^2}, \qquad \tilde{F}_k = R_k^3 \, , \end{aligned}$$
(37)

with \( k = c, e, q \) referring to corner, edge, and boundary particles, respectively. In (37), \( M_k \) is the mass of particle k, \( R_k \) is its radius and \( \Delta t \) is the time increment used in the dynamic relaxation procedure.

3.2.1 Algorithm with initial displacement prediction

The macroscopic deformation is imposed in \(i_{tot}\) steps on the boundary particles \( \mathcal {P}_q \) via the incrementally updated deformation gradient \(\varvec{\bar{F}}\). In correspondence with the algorithm presented in Table 2, in the initialization step, \(i = 0\), the boundary particles are moved in accordance with a homogeneous deformation, and for the periodic boundary also a zero rotation, similar to Eq. (17). Subsequently, the granular assembly is dynamically relaxed to the equilibrium state, keeping the translational and, for the periodic boundary, rotational degrees of freedom of the boundary particles fixed. The iterative loop is entered, and the actual values of the forces and moments of the boundary particles are recorded. For the (P) boundary condition, the corrections for obtaining periodic particle translations and rotations at the boundary are calculated for the corner and edge particles separately, in accordance with relations (32)–(34). For the (T) boundary condition, the boundary moments vanish and the displacement corrections are computed via (35)–(36). The residuals are computed and compared with prescribed tolerances. For the (P) boundary condition, the residual is based on boundary forces and moments. For the (T) boundary condition, two residuals are calculated, which are based on the boundary forces and on the imposed macroscopic deformation. If the norm of the residual(s) is(are) smaller than the tolerance(s) (referred to as \( \epsilon _a \) for the force criterion and \( \epsilon _F \) for the deformation criterion), the iterative loop is terminated and the next loading step is applied. If the convergence criterion is not satisfied, the corrections are computed again and the residual is iteratively re-examined, until convergence is reached.

After the initialization step is concluded, the responses for subsequent increments, \( 1 \le i \le i_{tot}\), are calculated, see Table 2. For the (P) boundary condition, the corner nodes are moved by straightforwardly imposing the updated macro-scale deformation in accordance with relation (17). For the edge particles, their current position is determined from a prediction based on the particle position in the previous loading step \(i-1\). More specifically, this prediction is a function of the position a particle would have in case of a homogeneous deformation [using the displacement boundary condition (17)], plus the difference, multiplied by an inheritance factor \(n_f\), between the final particle position at the previous increment and the position the particle would have at the previous increment under a homogeneous deformation. The inheritance factor lies between 0 and 1, and its optimal value (in terms of computational efficiency) depends on the loading conditions applied and the characteristics of the particle assembly. For the (T) boundary condition, the prediction occurs in an analogous fashion and is applied to all the boundary particles. After the boundary particles are translated in accordance with the predicted values of their positions, the granular assembly is dynamically relaxed to its equilibrium state. Subsequently, the iterative loop is entered, which invokes the previously described correction procedure of the displacements and rotations, in correspondence with the servo-control methodology.

3.2.2 Algorithm without initial displacement prediction

Similar to the algorithm with initial displacement prediction, for the algorithm without initial displacement prediction the macroscopic deformation is imposed in \(i_{tot}\) steps to the boundary particles \( \mathcal {P}_q \). However, as pointed out in Table 3, all increments are now treated in the same fashion. The boundary particles are initially moved in accordance with the updated homogeneous macroscopic deformation \(\varvec{\bar{F}}\), similar to expression (17), after which the particle assembly is dynamically relaxed to its equilibrium state. The iterative loop is started, in which the corrections for the displacement and rotation of the boundary particles are calculated based on the servo-control methodology. For the (P) boundary condition, the boundary is partitioned into corner and edge particles, whereby relations (32)–(34) are applied. For the (T) boundary condition, Eqs. (35)–(36) are employed. Subsequently, the particle system is relaxed to the equilibrium state, and the current values of the boundary forces and moments are recorded and used to compute the residuals. If the norms of the residuals are smaller than the corresponding tolerances adopted, the iterative loop is terminated and the next loading step is applied. It can be confirmed that the algorithm without displacement prediction can be obtained as a limit case of the algorithm with initial displacement prediction by setting the inheritance factor equal to zero, \(n_f=0\), whereby the algorithmic structure provided in Table 2 reduces to the more compact and simpler algorithmic structure presented in Table 3.

4 Computational results for regular and irregular packings

The algorithms proposed above for the implementation of the micro-scale boundary conditions are tested on a series of DEM simulations on regular, monodisperse and irregular, polydisperse particle packings.

4.1 Regular monodisperse packing

In this section the responses of three different regular, monodisperse particle packings are considered, which consist of circular particles of radius \(R = 1.02\) mm, where the centroids of two particles in contact initially are at a distance of 2.0 mm. The initial volumes of the packings are \( V = \left[ 64, 324, 784\right] \) mm\( ^2 \), which are calculated from the locations of the centroids of the four corner particles. The number of particles of the three packings are equal to \( n_p = \left[ 25, 100, 225 \right] \). The particle volume fraction related to initial volume occupied by the inner particles is \( \mathfrak {v} = 0.785\). The corresponding coordination number, which reflects the average number of contacts of the inner particles, equals 4.

Table 4 Physical and algorithmic model parameters
Fig. 2
figure 2

Combined biaxial compression-true shear deformation: normalized macroscopic Cauchy stresses \( -{\tilde{\sigma }}_{11} \) and \( -{\tilde{\sigma }}_{12} \) versus the shear deformation \( -\bar{F}_{12} \) for a periodic displacement/periodic rotation boundary condition (P) and b uniform force/free rotation boundary condition (T). The responses relate to a regular monodisperse packing of 25 particles, and were computed by the algorithms with (solid line) and without (dot-dashed line) initial displacement predictions

The particles obey a frictional contact law, in correspondence with relation (6). Assuming relatively soft particles, the normal and tangential stiffnesses are chosen as \( k_{n} = 10^4 \) N/m and \( k_{s} = 2\times 10 ^3\) N/m, and the friction coefficient equals \( \mu = 0.4 \). The density of the particles is \( \rho = 2\times 10^3 \) kg/m\(^2\). The translational and rotational damping factors used in the dynamic relaxation procedure are \( \alpha = \beta = 0.7 \). The packings are subjected to a combined biaxial compression-true shear deformation

$$\begin{aligned} \varvec{\bar{F}}=\mathbf {I} + \bar{F}_{11} \, \varvec{e}_1 \otimes \varvec{e}_1 + \bar{F}_{12} \, \varvec{e}_1 \otimes \varvec{e}_2 + \bar{F}_{21} \, \varvec{e}_2 \otimes \varvec{e}_1 + \bar{F}_{22} \, \varvec{e}_2 \otimes \varvec{e}_2 \, , \end{aligned}$$
(38)

with \(\bar{F}_{11}=\bar{F}_{22}=-0.03\) and \(\bar{F}_{12}=\bar{F}_{21}=-0.3\), which is applied in \(i_{tot}=300\) loading steps. For reaching the equilibrium state at each loading step, the particle system is subjected to dynamic relaxation steps of constant time increments \( \Delta t = 10^{-6} \)s. The gain parameters (in dimensionless form) used for the correct application of the boundary conditions are: for (P) \( g_a^p M / \Delta t^2 = 1 \cdot 10^2 \) and \( g_m^p M R^2 / \Delta t^2 = 2 \times 10^2 \); for (T) \( g^t_a M / \Delta t^2 = 1 \times 10^2\) and \( g^t_F R^2 = 2 \times 10^{-5} \), with \(M= \rho \pi R^2\) representing the mass of the particles. The force and deformation tolerances are taken as \( \epsilon _a =10^{-6}\) and \(\epsilon _F =10^{-2} \), respectively. For the dynamic relaxation process, a value of \(10^{-3}\) is adopted for \(\mathrm {tol}_{E}\), whereby Eq. (11) must be minimally satisfied for a pre-defined, continuous period of \(20 \Delta t\), in order to ensure a rigorous dynamic relaxation to the equilibrium state. An overview of the model parameters is given in Table 4.

Fig. 3
figure 3

Combined biaxial compression-true shear deformation: deformed configurations of a regular packing of 25 particles with (P) boundary conditions evaluated at three different deformation states: a \(\bar{F}_{12} = -0.01\), b \(\bar{F}_{12} = -0.113 \), c \(\bar{F}_{12} =-0.28 \). The particle configurations were computed with the algorithms with (top) and without (bottom) initial displacement prediction. The red lines indicate the normal contact force network of the particles (color figure online)

Fig. 4
figure 4

Combined biaxial compression-true shear deformation: a normalized homogenized Cauchy stress \(- {\tilde{\sigma }}_{11} \) and b average particle overlap \(\Delta \bar{u}_n\) versus the shear deformation \( -\bar{F}_{12} \) for the three types of boundary conditions (D), (P) and (T)

4.1.1 Responses for algorithms with and without initial displacement prediction

In order to investigate the performance of the two algorithms presented in Tables 2 and 3, the packing of 25 particles is considered first. The stress responses under the combined biaxial compression-true shear loading were computed with Eq. (31), and plotted as a function of the applied macroscopic shear deformation \( \bar{F}_{12}\). Figure 2a, b show the results for the algorithms with (solid line) and without (dot-dashed line) an initial displacement prediction for the (P) and (T) boundary conditions, respectively. The normal and shear components of the Cauchy stress are normalized as \( {\tilde{\sigma }}_{11} = {\bar{\sigma }}_{11}R/k_n \) and \( {\tilde{\sigma }}_{12} = {\bar{\sigma }}_{12}R/k_n \), respectively, where \({\bar{\sigma }}_{11}\) and \({\bar{\sigma }}_{12}\) are the macroscopic normal and shear Cauchy stresses of the particle aggregate. For the periodic boundary conditions (P), Fig. 3 illustrates the packing structures at specific macroscopic shear deformations \( \bar{F}_{12} = -0.01 \) (a), \( \bar{F}_{12} = -0.113 \) (b), and \( \bar{F}_{12} = -0.28 \) (c). The red lines plotted in the deformed particle aggregates indicate the network of normal contact forces between the particles.

For the algorithm with initial displacement prediction, the local minimum of the normal stress \( {\tilde{\sigma }}_{11} \) near \( \bar{F}_{12} = -0.113 \), as shown in Fig. 2a for the periodic boundary conditions (P), can be ascribed to a joint localized sliding of all the boundary particles, see Fig. 3b, top. This localization mechanism does not arise for the algorithm without initial displacement prediction, which furnishes a shear response that is much more homogeneous, see Fig. 3b, bottom. It may be therefore concluded that the response of the packings is rather sensitive to bifurcations in the equilibrium path followed, which here become evident due to the relatively low number of particles present in the packing. Under continuing deformation towards \(\bar{F}_{12} = -0.28\), the inner particles of the aggregate also develop substantial sliding, such that for both algorithms the particle structure gradually reaches its densest packing structure, at which the deformation as well as the normal contact force network become strongly homogeneous. Both for the normal and shear stress components the responses computed by the two algorithms at this stage have coalesced, and steadily grow under further increasing deformation.

A similar trend can be observed for the normal and shear stress responses of the particle aggregates with the (T) boundary condition, see Fig. 2b. The discrepancies in the responses computed by the two algorithms appears to be less than for the (P) boundary condition.

In the simulations discussed above the two proposed algorithms have demonstrated a comparable numerical efficiency and robustness. Additional analyses not presented here nevertheless have illustrated that the performance of the algorithm with initial displacement prediction may be computationally more efficient for a well-calibrated choice of the inheritance parameter. However, if the value of the inheritance factor becomes relatively large, convergence problems may arise. Hence, for reasons of simplicity and numerical robustness, the forthcoming DEM results were computed with the algorithm without initial displacement prediction.

Fig. 5
figure 5

Combined biaxial compression-true shear deformation: normalized macroscopic Cauchy stress \(- {\tilde{\sigma }}_{11} \) versus the shear deformation \( -\bar{F}_{12} \) for three different sample sizes of 25, 100 and 225 particles, for the a (D) boundary condition, b (P) boundary condition, and c (T) boundary condition

4.1.2 Responses for the (D), (P) and (T) boundary conditions

The influence of the choice of the boundary condition on the overall packing response is illustrated in Fig. 4a. The (normalized) normal stress \( {\tilde{\sigma }}_{11} \) is shown as a function of the applied shear deformation \( \bar{F}_{12} \) for the displacement/zero rotation boundary condition (D) with a solid line, for the periodic displacement/periodic rotation boundary condition (P) with a dot-dashed line, and for the uniform force/free rotation boundary condition (T) with a dashed line. The stress response computed for the (P) boundary condition is bounded by the stiffer and softer responses measured for the (D) and (T) boundary conditions, respectively, a result that is in agreement with the numerical studies performed in [16]. It may be observed that the initial stress value corresponding to the (T) boundary condition is somewhat smaller than the value computed for the other two boundary conditions. This is, because after the sample preparation procedure was finished, the boundary forces generated by a 4\(\%\) particle overlap do not exactly satisfy Eq. (21), and therefore in the first loading increment are slightly relaxed by the algorithm in order to meet this condition.

Consider the average normalized particle overlap \(\Delta \bar{u}_n\), defined as

$$\begin{aligned} \Delta \bar{u}_n = \frac{1}{N^c}\sum _{c=1}^{N^c}\frac{\Delta u_n^c}{\bar{R}^c} \, , \end{aligned}$$
(39)

where \(N^c\) is total number of particle contacts, \(\bar{R}^c\) is the average radius at contact c and \(\Delta {u}_n^c\) is the particle overlap at contact c. Figure 4b depicts \(\Delta \bar{u}_n\) as a function of the applied shear deformation \( - \bar{F}_{12} \). Observe that the trend for the average particle overlap is similar to that for the macroscopic normal stress in Fig. 4a. This can be explained as follows: The macroscopic stress is represented by the volume average of all contact forces generated within the granular micro-structure. Since the assumed normal contact stiffness is considerably larger than the shear contact stiffness, \( k_n>> k_s\), see Table 4, the normal contact forces \(f_n^c\), which are proportional to contact overlaps \(\Delta u^c_n\), see expression (6), provide the main contribution to the macroscopic stress response.

4.1.3 Responses for different sample sizes

The effect of the sample size on the macroscopic stress response is considered by plotting the computational results for packings composed of 25, 100 and 225 particles for the (D), (P) and (T) boundary conditions in Fig. 5a–c, respectively. Generally, for a larger sample the normal stress \(\tilde{\sigma }_{11}\) decreases. The (D) and (P) boundary conditions show a close resemblance in the responses for 100 and 225 particles, from which it may be concluded that for a sample of about 225 particles the stress response has more or less converged. Conversely, for the (T) boundary condition the stress for a sample of 225 particles shows a substantial relative drop in value up to a deformation of \(\bar{F}_{12} \approx 0.20\). This softening behavior appears to be governed by strongly localized deformations emerging at the boundaries of the particle system, a phenomenon that also has been reported for continuum homogenization methods equipped with this relatively soft boundary condition, see [40].

Fig. 6
figure 6

Characteristics of the five different irregular polydisperse packings studied: a initial packings generated by a collision-driven molecular dynamics code [41], b geometrically periodic packings with the number of particles equal to \( n_{p} = \left[ 37, 120, 228, 444, 650 \right] \), and c the rose diagrams (color figure online)

4.2 Irregular polydisperse packing

The irregular polydisperse packings analyzed in this section are composed of circular particles, with the particle radii arbitrarily taken from a uniform size distribution with polydispersity \(R_{max}/R_{min} = 2\), where \(R_{min} = 0.67\) mm. A collision-driven molecular dynamics code described in [41] is used to randomly generate irregular packings with the initial number of particles equal to \( n_{p}^0 = \left[ 25, 100, 200, 400, 600 \right] \), as shown in Fig. 6a. Subsequently, these packings are reconstructed into geometrically periodic packings by copying each of the boundary particles intersecting with the edges of the square particle volume to corresponding positions at the opposite boundaries. This results into the packing geometries shown in Fig. 6b, with the final particle numbers as \( n_{p} = \left[ 37, 120, 228, 444, 650 \right] \). The initial volumes of the particle aggregates are equal to \( V = \left[ 100, 400, 818, 1462, 2156 \right] \) mm\( ^2 \), respectively. The rose diagrams of the particle assemblies are sketched in Fig. 6c, clearly indicating that the packings become more isotropic when the particle number increases. The particle volume fraction of the packings varies in the range \( \mathfrak {v}\in [0.833, 0.850] \), where the smallest and highest values correspond to the packings with the smallest and highest number of particles, respectively. The corresponding coordination numbers lie in between 2.97 and 3.47.

Fig. 7
figure 7

Simple shear deformation: normalized homogenized Cauchy stresses versus the shear deformation \({\bar{F}}_{12}\) for packings of 228 particles, subjected to the boundary conditions (D), (P) and (T). a Stress component \({\tilde{\sigma }}_{11}\), b stress component \({\tilde{\sigma }}_{22}\)

Fig. 8
figure 8

Simple shear deformation: deformed configurations of an irregular packing of 228 particles evaluated at four different deformation states. a \(\bar{F}_{12} = 0.05\), b \(\bar{F}_{12} = 0.1 \), c \(\bar{F}_{12} = 0.3\), and d \({\bar{F}}_{12} = 0.5\), for the (D), (P) and (T) boundary conditions. The red lines indicate the normal contact force network of the particles (color figure online)

The particle packings are subjected to a simple shear macroscopic deformation

$$\begin{aligned} \varvec{\bar{F}}=\mathbf {I} + \bar{F}_{12} \, \varvec{e}_1 \otimes \varvec{e}_2 \, , \end{aligned}$$
(40)

with \(\bar{F}_{12}=0.5\), which is applied in \(i_{tot}=100\) loading steps. A step size variation study not presented here has shown that this loading step is sufficiently small for reaching a converged, pre-peak response of the micro-structural particle assembly, irrespective of the type of boundary condition applied. However, after passage of the peak load localization may occur, during which the macroscopic stress response softens; due to the appearance of numerous bifurcations the equilibrium path to be followed then becomes sensitive to small physical and numerical perturbations of the particle system, such as round-off errors in the numerical scheme. Accordingly, different load step sizes may trigger different equilibrium paths and therefore can induce differences in the post-peak response computed. For the irregular packings the same physical and algorithmic parameters are used as for the regular packings, see Table 4, except for the tolerance \( \epsilon _F =10^{-1} \) and the two gain values for the (T) boundary condition, which here relate to \( g^t_a M_i/ \Delta t^2= 5 \) and \( g^t_F R_i^2 = 2\times 10^{-6} \), with \(M_i= \rho \pi R_i^2\) being the mass of particle i and \(R_i\) its radius. Note that for an irregular polydisperse packing the specific gain values depend on the characteristics of the actual particle i.

4.2.1 Responses for the (D), (P) and (T) boundary conditions

The response of a packing with 228 particles is considered first. The normalized macroscopic stresses \( {\tilde{\sigma }}_{11} = {\bar{\sigma }}_{11}\bar{R}/k_n \) and \( {\tilde{\sigma }}_{22} = {\bar{\sigma }}_{22}\bar{R}/k_n \), with the average radius as \( \bar{R} = \sum _{i=1}^{P+Q} R_i/(P+Q) \), are shown in Fig. 7 as a function of the applied macroscopic shear deformation \( \bar{F}_{12}\). The solid, dot-dashed and dashed lines refer to the (D), (P) and (T) boundary conditions, respectively. Since for the packing of 228 particles the particle structure is rather isotropic, see Fig. 6c, it can be confirmed that the responses for the two normal stresses \(\tilde{\sigma }_{11}\) and \(\tilde{\sigma }_{22}\) indeed are similar. As for the regular monodisperse packing, the (D) and (T) boundary conditions provide the upper (stiffest) and lower (softest) bounds for the particle system response, and thereby encapsulate the response calculated for the (P) boundary condition. Although not depicted here, the responses for the normalized shear stress \(\tilde{\sigma }_{12}=\bar{\sigma }_{12}\bar{R}/k_n\) under the (D), (P) and (T) boundary conditions follow similar trends as observed for the normal stresses \(\tilde{\sigma }_{11}\) and \(\tilde{\sigma }_{22}\), with the magnitude of the shear stress being about one third of that of the normal stresses.

Fig. 9
figure 9

Simple shear deformation: a average normalized particle overlap \(\Delta \bar{u}_n\) and b average particle rotation \(\bar{\theta }\) versus the shear deformation \( \bar{F}_{12} \) for a packing of 228 particles subjected to the (D), (P) and (T) boundary conditions

Figure 8 shows the deformed structure of the granular aggregates for the three types of boundary conditions at four different deformation levels, namely (a) \({\bar{F}}_{12} = 0.05\), (b) \({\bar{F}}_{12} = 0.1\), (c) \({\bar{F}}_{12} = 0.3\) and (d) \({\bar{F}}_{12} = 0.5\). The local distribution of particles develops differently for the three boundary conditions, leading to differences in the network of normal contact forces represented by the red lines: The (D) and (T) boundary condition experience the highest and lowest contact forces, respectively, as indicated by the relatively thick and thin red lines. Obviously, this is in correspondence with the largest and smallest stress levels for the (D) and (T) boundary conditions, as depicted in Fig. 7.

Figure 9 illustrates the average normalized particle overlap \( \Delta \bar{u}_n \), defined by relation (39), and the average particle rotation

$$\begin{aligned} \bar{\theta } = \frac{\sum _{i=1}^{P+Q} | {\theta }_i |}{P+Q} \, , \end{aligned}$$
(41)

both as a function of the applied macroscopic shear deformation \( \bar{F}_{12} \). As for the regular monodisperse packings, the average normalized particle overlap is the largest for the (D) boundary condition and the smallest for the (T) boundary condition, and shows a similar evolution as observed for the normal stresses, see Fig. 7. As expected, the average rotation shows the opposite trend, being the largest for the soft (T) boundary condition and the smallest for the stiff (D) boundary condition.

4.2.2 Convergence behavior of macroscopic response under increasing sample size

The convergence behavior of the apparent macroscopic response of the particle aggregate towards its effective response under increasing sample size is studied by subjecting the five micro-structures depicted in Fig. 6b to a simple shear deformation given by (40). In convergence studies, this type of loading condition occasionally is characterized as “critical”, because of a relatively slow convergence behavior towards a representative volume element (RVE). The convergence behavior is evaluated here by means of the \(L_2\)-norm of the normalized, homogenized Cauchy stress tensor \(\tilde{\varvec{\sigma }}\), integrated along the entire deformation path

$$\begin{aligned} \Vert {\tilde{\sigma }}\Vert _{L_{2}} = { \Bigg ( \sum _{ij = 11,22,12,21} \int _{\bar{F}_{12} = 0}^{\bar{F}_{12} = 0.5} { { {\tilde{\sigma }}_{ij}} }^2 \mathrm {d}{\bar{F}_{12}} \Bigg )} ^ {1/2}. \end{aligned}$$
(42)

Figure 10 illustrates the stress norm \( \Vert {\tilde{\sigma }}\Vert _{L_{2}} \) as a function of the sample size, expressed in terms of the number of particles. It can be observed that for the stiff (D) and soft (T) boundary conditions the stress norm, respectively, decreases and increases with increasing sample size, while for the periodic (P) boundary condition it remains approximately constant. These trends are typical for a change in apparent properties under increasing sample size, see e.g., [21]. However, to define the minimal RVE the curves for the (D) (P) and (T) boundary conditions must coincide [31], which indeed is not the case for the largest sample of 650 particles. As already indicated above, the minimum size of RVE depends on the type of loading condition applied, which is known to be relatively large under a macroscopic shear deformation. From the approximately constant stress value observed in Fig. 10 for the (P) boundary condition, it may be expected that the stress response of the RVE will be close to \( \Vert {\tilde{\sigma }}\Vert _{L_{2}} \approx 0.011\). Hence, in multi-scale simulations on granular materials the computational costs can be kept manageable by adopting the (P) boundary condition for a relatively small (and thus not rigorously “representative”) micro-structural sample. Its effective response in fact is comparable to that of the minimal RVE, which thus is typically characterized by a much larger size.

Fig. 10
figure 10

Stress norm \( \Vert {\tilde{\sigma }}\Vert _{L_{2}}\) versus particle number for irregular polydisperse particle packings subjected to (D), (P) and (T) boundary conditions, in accordance with a macroscopic simple shear deformation \(\bar{F}_{12}\)

5 Mixed boundary conditions

In this section the formulation and numerical implementation of mixed (D)–(P)–(T) boundary conditions is presented. Despite that the classical boundary conditions accurately represent the response of granular assemblies for the specific conditions under which they apply, for simulating more generally the effect of a macroscopic deformation on the particle micro-structure and to accurately represent the loading conditions in particular experimental set-ups, a combination of the classical boundary conditions may be needed. The homogenization framework proposed here satisfies the Hill–Mandel micro-heterogeneity condition, and thus can be used for (1) a consistent derivation of macro-scale constitutive relations from standard material tests on micro-scale particle aggregates subjected to any combination of (D)-, (P)- and/or (T)-type boundary conditions, and (2) the efficient computation of the homogenized response of large-scale particle aggregates characterized by a spatial periodicity in one or two directions, i.e., granular layers exposed to uniform (D) and/or (T) boundary conditions at their top and bottom surfaces. To the best of the authors’ knowledge, the formulation presented is novel in the field of granular materials.

5.1 Formulation

For the formulation of the mixed boundary conditions, the basic particle configuration sketched in Fig. 1 is considered, with the boundary being split up into the top part \( \partial V_t\), the bottom part \( \partial V_b\), the left part \( \partial V_l\) and the right part \( \partial V_r\). It is emphasized that the main concepts of the mixed formulation are general, and can be applied to arbitrary boundary value problems. The concepts are elaborated here for the specific case of an infinite horizontal layer of particles loaded by a constant vertical pressure, \(\bar{P}_{22}=\bar{P}_{22}^*\), and subsequently subjected to a shear deformation \(\bar{F}_{12}\) in horizontal direction. The reason for choosing this boundary value problem is that it includes all the three (D), (P) and (T) boundary conditions discussed previously, with their combinations entering the formulation both at separate and identical parts of the layer boundary. This allows for highlighting the characteristics of the mixed formulation in full detail. Accordingly, the macroscopic deformation of the particle aggregate is imposed via a combined (D)–(T) condition

$$\begin{aligned} x_{q,1} = \bar{F}_{12}X_{q,2} + X_{q,1} \text { and } a_{q,2} = \bar{P}_{21}{A}_{q,1}+\bar{P}_{22}^*{A}_{q,2} \, , \end{aligned}$$
(43)

in which the macroscopic shear stress \(\bar{P}_{21}\) is measured from the response of the particle assembly. Note that (43)\(_1\) implicitly accounts for the condition

$$\begin{aligned} \bar{F}_{11} \, = \, 1 . \end{aligned}$$
(44)

Furthermore, the first contribution in the right-hand side of (43)\(_2\) typically is relatively small, since most particles q at the top boundary \(\partial V_t\) are characterized by \(A_{q,1}<< A_{q,2}\), with \(A_{q,1}\) vanishing for the specific case of an ideally horizontal boundary composed of identical particles. Since the shear deformation \(\bar{F}_{12}\) is imposed after the application of the vertical stress \(\bar{P}_{22}^*\), in (43)\(_1\) the reference positions \(\varvec{X}_q\) of the boundary particles relate to the particle configuration obtained after the vertical stress has been applied. In summary, the boundary conditions for the particle aggregate are specified as follows:

  • For the particles that are part of the bottom boundary, \( q \in \partial V_b \), the homogeneous deformation and zero rotation boundary condition (D) is applied in accordance with expression (17). The vertical boundary displacements are constrained to construct a rigid support for the layer, and the horizontal boundary displacements follow the shear deformation given by expression (43)\(_1\).

  • For the particles that are part of the left and right boundaries, \( q \in \partial V_l\cup \partial V_r\), the periodic displacement and periodic rotation boundary condition (P) is applied, as given by expression (19). This boundary condition reflects the horizontal confinement of the particles within the infinite layer.

  • For the particles that are part of the top boundary, \( q \in \partial V_t \), free rotations are assumed, in correspondence with the (T) boundary condition.Footnote 1 For the description of the particle displacements, the boundary is split up along the two orthonormal directions \(\mathbf {e}_1\) and \(\mathbf {e}_2\) indicated in Fig. 1. Along the \( \mathbf {e}_1 \)-direction, the (D) boundary condition (43)\(_1\) is applied to simulate the horizontal macroscopic shear deformation. Along the \( \mathbf {e}_2 \)-direction, a constant macroscopic pressure \( \bar{P}_{22}^*\) is imposed via the (T) boundary condition (43)\(_2\), for which the corresponding components of the macroscopic deformation gradient, \(\bar{F}_{21}\) and \(\bar{F}_{22}\), in accordance with the general form (15), turn into

    $$\begin{aligned} \bar{F}_{21}= \frac{1}{V}\sum _{q=1}^{Q} x_{q,2} A_{q,1} \text { and } \bar{F}_{22}= \frac{1}{V}\sum _{q=1}^{Q} x_{q,2} A_{q,2}. \end{aligned}$$
    (45)

    Note that the two deformation components above should be considered as a computational result obtained by prescribing the stress component \( \bar{P}_{22}^*\).

The macroscopic deformation gradient \(\bar{\varvec{F}}\), which is followed by the four corner nodes of the sample, now is fully specified through its “(D)-type components” provided by (43)\(_1\) and (44), and its “(T)-type components” given by (45)\(_{1,2}\). The corresponding macroscopic Piola-Kirchhoff stress tensor is defined by (23). For the adopted mixed-boundary conditions it will now be demonstrated that this stress definition satisfies the recast Hill–Mandel condition given by expression (30), i.e., the energy consistency between the macro- and micro scales. Accordingly, relation (30) is first split up with respect to the different boundary parts considered above, i.e.,

$$\begin{aligned}&\sum _{q\in \partial V_b} \left( \mathbf {a}_q- \varvec{\bar{P}}\cdot \mathbf {A}_q\right) \cdot \delta \mathbf {w}_q+ \sum _{q\in \partial V_l\cup \partial V_r} \left( \mathbf {a}_q- \varvec{\bar{P}}\cdot \mathbf {A}_q\right) \cdot \delta \mathbf {w}_q\nonumber \\&\qquad + \sum _{q\in \partial V_t} \left( \mathbf {a}_q- \varvec{\bar{P}}\cdot \mathbf {A}_q\right) \cdot \delta \mathbf {w}_q= 0. \end{aligned}$$
(46)

For the bottom boundary \( \partial V_b \), boundary condition (D) holds, which, by comparing Eqs. (17) and (14), lets the micro-fluctuations of the displacements vanish, \( \mathbf {w}_q= \varvec{0} \). Hence, the first term in (46) is equal to zero. At the left and right boundaries \(q \in \partial V_l\cup \partial V_r\), the (P) boundary condition is imposed, for which the micro-fluctuations of the displacements are periodic, \( \mathbf {w}_q^l = \mathbf {w}_q^r \), see (14) and (19). Together with the anti-periodicity of the boundary forces \( \mathbf {a}_q^{l}+\mathbf {a}_q^{r}=\varvec{0} \), see (20), the second term in (46) vanishes. Finally, for the top boundary \( \partial V_t \), the last term in (46) may be further developed as

$$\begin{aligned}&\sum _{q \in \partial V_t } \left[ \left( a_{q,1} - \bar{P}_{1j} A_{q,j} \right) \delta w_{q,1} + \left( a_{q,2} - \bar{P}_{2j} A_{q,j} \right) \delta w_{q,2} \right] \nonumber \\&\quad = {0} . \end{aligned}$$
(47)

Along the \( \mathbf {e}_1 \)-direction, the micro-fluctuations of the boundary particle displacements vanish, \( w_{q,1} = 0 \), in correspondence with Eq. (43)\(_1\), by which the first term in (47) becomes zero. Along the \( \mathbf {e}_2\)-direction, the boundary forces are uniform, \( a_{q,2} - \bar{P}_{2j} A_{q,j} = 0 \), see Eq. (43)\(_2\), so that the second term in (47) becomes zero. With this result, the Hill–Mandel condition (46) is proven to be satisfied for the mixed boundary conditions.

5.2 Numerical implementation

The numerical algorithm for the implementation of the mixed boundary conditions is outlined in Table 5, and is based on a combination of the algorithms presented in Sect. 3 for the (D), (P) and (T) boundary conditions, without an initial displacement prediction.

During stage 1 of the loading process, the vertical compressive stress \(\bar{P}_{22}=\bar{P}_{22}^{*}\) is applied to the particle aggregate in a stepwise fashion,Footnote 2 using a total of \(i_{vs}\) loading increments, with the subscript vs designating “vertical stress”. After initiating the displacement and rotation boundary conditions at the top \(\partial V_t\) and bottom \(\partial V_b\) boundaries, the vertical stress is incrementally updated and subsequently used to compute the displacement and rotation corrections at the left and right boundaries with expressions (32)–(33), and the displacement correction at the top boundary boundary with

$$\begin{aligned} \Delta {u}_{q,2} = g^{t}_a \Delta a_{q,2} \text { with } \Delta a_{q,2} = a_{q,2} - \bar{P}_{21}{A}_{q,1}- \bar{P}_{22}^*{A}_{q,2}. \end{aligned}$$
(48)

The expression above is derived from (43)\(_2\), whereby during the incremental application of the vertical stress \(\bar{P}_{22}^{*}\) the value of \(\bar{P}_{21}\) is prescribed as zero, in order to avoid the initial development of a shear stress. After the particle aggregate has reached its equilibrium state under dynamic relaxation, the boundary forces and moments of the particles at the top, left and right boundaries are recorded and employed to compute the corresponding residuals. When all residuals are lower than the prescribed values of the corresponding tolerances, the iterative loop is stopped and the next vertical stress increment is applied. Otherwise, the iterative loop is entered again, until a converged solution is found. After the application of \(i_{vs}\) increments the vertical stress has reached the desired value, and stage 1 of the loading process has completed.

Table 5 Algorithm for the application of the mixed boundary conditions

During stage 2 of the loading process, the horizontal shear deformation \(\bar{F}_{12}\) is imposed on the particles at the top \(\partial V_t\) and bottom \(\partial V_b\) boundaries of the granular assembly, by displacing these in a stepwise manner using \(i_{tot}-i_{vs}\) increments. The rotations of the particles at the top boundary are free, and the vertical displacement and rotation of the particles at the bottom boundary are fully constrained. In a similar way as explained above for stage 1, the boundary forces and moments in the relaxed equilibrium state are used to compute the displacement and rotation corrections at the periodic left and right boundaries \(\partial V_l\) and \(\partial V_r\), and at the top boundary boundary \(\partial V_t\). However, the only difference is that in (48) the shear stress \(\bar{P}_{21}\) here is not prescribed as zero, but is calculated from the homogenized response of the particle assembly using Eq. (23). After the dynamic relaxation procedure has completed, the residuals are computed in the same way as during stage 1, and compared against the corresponding tolerances. The iterative process is terminated when the convergence criterion is satisfied, after which the shear deformation is incremented and the response to the next loading step is computed. This procedure is continued until all loading increments \(i_{tot}\) are applied.

Table 6 Physical and algorithmic model parameters for the simulations with mixed boundary conditions

5.3 Computational results

The performance of the algorithm used for the implementation of the mixed boundary conditions is demonstrated by means of two DEM simulations of an irregular polydisperse packing of 449 particles, with the particle radii taken randomly from a uniform size distribution with polydispersity \(R_{max}/R_{min}=\) 1.5, where the minimum radius equals \(R_{min}\)= 0.8 mm. The initial particle volume is \(V=1517\) mm\(^2\), with the particle volume fraction of the packing being equal to \(\mathfrak {v}=0.849\), and the average particle coordination number as 3.55. The two simulations consider different particle contact laws, namely the frictional contact law and the cohesive contact law described in Sect. 2.2.2. Assuming relatively hard particles, the normal and tangential contact stiffnesses for the frictional contact law are set as \( k_{n} = 10^5 \) N/mm and \( k_{s} = 4\times 10 ^4\) N/mm, respectively, and the friction coefficient equals \( \mu = 0.6 \). The normal contact stiffness \(k_n^b\) and the tangential contact stiffness \(k_s^b\) for the cohesive contact interaction are assumed to be equal to those of the frictional contact law, and the bending contact stiffness is taken as \( k_{\theta }^b = 2\times 10 ^4 \) Nmm. The normal, shear and bending strengths have the values \( {f}_{n}^{b,u} = 300 \) N, \({f}_{s}^{b,u}= 60 \) N and \( m_{\theta }^{b,u} = 200 \) Nmm, respectively. The density of the particles is \( \rho = 10 \times 10^3 \) kg/m\( ^2 \). The macroscopic vertical (compressive) stress is \( \bar{P}_{22}^*= -1.05 \times 10^6\) N/m, which is applied in \(i_{vs}=6\) increments. The total macroscopic shear deformation equals \( \bar{F}_{12} = 0.2 \), which is imposed on the particle aggregate in \(i_{tot}-i_{vs} = 100\) increments. The translational and rotational damping factors used in the dynamic relaxation procedure are \( \alpha = \beta = 0.7 \), and the time increment equals \( \Delta t = 10^{-5} \) s. The dimensionless values of the gain parameters are \( g_a^t M_i/\Delta t^2 = g_a^p M_i/\Delta t^2 = 3\times 10^4 \) and \(g_m^p M_i R_i^2/\Delta t^2=6 \times 10^4\), and the corresponding tolerances are equal to \(\epsilon _a^t = \epsilon _a^p = \epsilon _m^p =2 \times 10^{-10}\). The above model parameters are summarized in Table 6.

Fig. 11
figure 11

Macroscopic response of an infinite granular layer subjected to a vertical compressive stress \(\bar{P}_{22}=\bar{P}_{22}^{*}\) and a horizontal shear deformation \(\bar{F}_{12}\). a Stress ratio \(\bar{\sigma }_{12} / \bar{\sigma }_{22}\), b relative volumetric change \(\text{ det }(\bar{\varvec{F}})\), and c average particle rotation \(\bar{\theta }\), all plotted versus the applied shear deformation \(\bar{F}_{12}\) for cohesive (dot-dashed line) and frictional (solid line) packings

Fig. 12
figure 12

Deformed configurations of a packing with 449 particles corresponding to a \({\bar{F}}_{12} = 0.002\), b \({\bar{F}}_{12} = 0.05\), c \({\bar{F}}_{12} = 0.1\) and d \({\bar{F}}_{12} = 0.15\), for cohesive (top) and frictional (bottom) particle contact interactions. The networks of cohesive and frictional forces acting between particles are indicated by the red and blue lines, respectively (color figure online)

Figure 11 shows the macroscopic response of the particle aggregates as a function of the applied shear deformation \(\bar{F}_{12}\), with the dot-dashed and solid lines referring to packings with cohesive and frictional particle contact interactions, respectively. In Fig. 11a the stress ratio \(\bar{\sigma }_{12}/\bar{\sigma }_{22}\) is depicted, while Fig. 11b illustrates the relative volumetric change \(\text{ det }( \bar{\varvec{F}})\) (using the packing obtained after the application of the vertical stress as the reference state), and Fig. 11c sketches the average particle rotation \(\bar{\theta }\), in accordance with expression (41). Furthermore, in Fig. 12 the particle configurations of the cohesive and frictional packings are plotted at four different deformation levels, namely (a) \( \bar{F}_{12} = 0.002 \), (b) \( \bar{F}_{12} = 0.05 \), (c) \( \bar{F}_{12} = 0.1 \) and (d) \( \bar{F}_{12} = 0.015 \). Here, the red lines between the particles represent cohesive contact forces, while the blue lines indicate frictional contact forces. It can be observed from Fig. 11a that up to a deformation \( \bar{F}_{12} = 0.02 \) the cohesive and frictional packings show a similar response, whereby the stress increases approximately proportionally with deformation. Upon continuing deformation, in the frictional packing a large number of contacting particles meets the failure criterion (6) and starts to slide, such that the stress ratio \(\bar{\sigma }_{12}/\bar{\sigma }_{22}\) reaches a maximum at \(\bar{F}_{12} \approx 0.06\). The maximal stress ratio is accompanied by a volumetric increase of the particle structure, commonly referred to as “dilation”, see Fig. 11b. After passing the peak value, the stress ratio for the frictional packing slightly drops in magnitude, which is caused by a substantial rolling of particles. The effect of particle rolling can be clearly observed from Fig. 11c, where at the onset of shear deformation the increase in average particle rotation only is mild, but steadily grows towards a more or less constant value at \(\bar{F}_{12}=0.07\) for the frictional packing and at \(\bar{F}_{12}=0.12\) for the cohesive packing. Note from Fig. 11c that the initial value of the average particle rotation is due to the application of the vertical stress \(\bar{P}_{22}^*\), and for the frictional packing appears to be somewhat larger than for the cohesive packing. For the cohesive packing the maximal value of the stress ratio \(\bar{\sigma }_{12}/\bar{\sigma }_{22}\) is about 1.5 times larger than for the frictional packing, and is reached at \(\bar{F}_{12}\approx 0.07\), see Fig. 11a. At this stage a significant number of particle bonds are broken, in correspondence with the failure criterion (8). With continuing deformation, the broken particle bonds of the cohesive packing become frictional, as indicated by the thick blue lines in Fig. 12c, whereby the stress ratio \(\bar{\sigma }_{12}/\bar{\sigma }_{22}\) of the packing drops to a level comparable to that of the frictional packing, see Fig. 11a. Observe from Fig. 12c, d that for the cohesive packing the frictional contacts indicated by the blue lines are established only along local force chains in the particle structure, whereby the rest of the contacts remain cohesive, as indicated by the red lines. This implies that the overall deformation of the packing near the end of the loading process becomes governed by a localized failure zone, which indeed is associated to a strong softening behavior in the stress response, see Fig. 11a. Towards a shear deformation of \(\bar{F}_{12}=0.20\), both the stress ratio \(\bar{\sigma }_{12}/\bar{\sigma }_{22}\) and the relative volumetric change \(\text{ det } (\bar{\varvec{F}})\) of the frictional and cohesive packings become approximately constant, characterizing the occurrence of a so-called “critical state”. For the frictional packing the overall residual strength at the critical state is \(\bar{\sigma }_{12}/\bar{\sigma }_{22} \approx 0.28\). This value is only about half of the value of 0.6 adopted for the local particle contact friction \(\mu \), which can be explained from the fact that at the end of the deformation process the dilating particle structure, instead of sliding, is predominated by a relatively easy rolling of particles, see [7] for a more detailed discussion on this aspect. For the same reason, the eventual, large amount of particle rolling generated in the cohesive packing, see Fig. 11c, leads to a final residual strength that is lower than for the frictional packing, see Fig. 11a.

As a final note, it is mentioned that the contact moments in the cohesive packing determine about 10\(\%\) of the total potential energy. This contribution implicitly contributes to the stress ratio \(\bar{\sigma }_{12}/\bar{\sigma }_{22}\) depicted in Fig. 11a by means of moment equilibrium at the particle level. More specifically, for each particle the corresponding contact moments are balanced by the product of the contact shear forces and the particle radius, whereby contact shear forces contribute to the effective Cauchy stress in accordance with expressions (23) and (31).

6 Conclusions

Novel numerical algorithms have been presented for the implementation of three types of classical boundary conditions for a particle aggregate. The micro-scale boundary conditions are formulated within the discrete element method using large deformation theory, and, along the lines of [16], are imposed on a frame of boundary particles of the particle packing, in accordance with (1) a homogeneous deformation and zero particle rotation (D), (2) a periodic particle displacement and rotation (P), and (3) a uniform particle force and free particle rotation (T). The algorithms can be straightforwardly combined with commercial discrete element codes, thereby enabling the determination of the solution of boundary-value problems at the micro-scale only, or at multiple scales via a micro-to-macro coupling with a finite element model. The performance of the algorithms has been tested by means of discrete element method simulations on regular monodisperse packings and irregular polydisperse packings composed of frictional particles, which were subjected to various loading paths. The simulations provide responses with the typical stiff and soft bounds for the (D) and (T) boundary conditions, respectively, and illustrate for the (P) boundary condition a relatively fast convergence of the apparent macroscopic properties under an increasing packing size. Finally, a homogenization framework has been presented for the formulation of mixed (D)–(P)–(T) boundary conditions that satisfy the Hill–Mandel micro-heterogeneity condition on energy consistency at the micro- and macro-scales of the granular system. The numerical algorithm for mixed boundary conditions has been developed and tested for the case of an infinite layer subjected to a vertical compressive stress and a horizontal shear deformation, whereby the response computed for a layer of cohesive particles is compared against that for a layer of frictional particles. The results illustrate that the failure response for both contact laws is characterized by the development of a dilated particle structure, which at large deformation gradually turns into a critical state with an approximately constant residual strength and specific volume. The application of the present algorithms for multi-scale FEM–DEM analyses on granular systems with a large number of particles, and their extension towards a dynamics homogenization framework, are topics for future studies.