^{1}

^{*}

^{1}

In this research, we have improved a relaxation method for triangular meshes intended for finite element fluid simulations which contain discrete element particles. The triangle edges are treated as springs which relax their lengths towards a “better” force equilibrium where the triangles are closer to equilateral shape. The actual kernel is an improved zero order integrator which is able to follow reconfigurations of the particles faster than earlier methods. The improved relaxation allows larger timesteps in the flow simulation and leads to more stable, faster mesh reconfigurations for fast moving particles in the flow. Additionally, this demonstrates how integrators of the same order zero can nevertheless have different convergence speeds towards equilibrium

Systems of particles in fluids exhibit a wide range of phenomena like sedimentation, erosion, liquefaction as well as landslides, which go far beyond the rheology of homogeneous fluids. For the corresponding simulations, carelessness in the implementation of the boundary conditions of the particles introduces noise and inaccuracies in the interaction computation between particles and fluid and may annihilate the validity of a simulation method altogether. As the most reliable approach to take into account both the non-sphericity of granular particles, as well as the geometry of the pore space between those particles, we have devised a two-dimensional simulation that combines a discrete element method (DEM) of polygonal granular particles [

Unfortunately, the relaxation method we had used previously [

In this article, we want to modify the integrator so that it is still of zeroth-order but adapts faster to the reconfiguration of the particle positions to speed up the relaxation, increase the size of the timestep and avoid any oscillations in the mesh for small triangles.

Simulations of particles in fluids usually require a variety of regions with different mesh sizes which must be joined together (see

mesh shapes should be avoided, as they would lead to bad conditioning of the underlying system of equations. To improve the efficiency of the simulation, it is advisable to introduce graded meshes: In regions of interest, the size of the mesh elements needs to be kept small e.g. around the particles or where high gradients of the flow fields (pressure, velocity) need to be resolved with sufficient accuracy. On the other hand, many setups feature large buffer regions stretching towards the boundaries. Large mesh elements are sufficient there, because far away from the region of interest the gradients in the velocity and pressure fields are much smaller. When we then treat the meshes as springs acting between grid points, we can obtain close to equilateral triangles with a suitable force model: The equilibrium configuration can be obtained by calculating the spring forces based on the current positions of the mesh points and “integrating” them with a zero-order algorithm which will return the positions of the mesh points in the force equilibrium. As we will show here, an adept selection of this zero-order integrator leads to noticeable improvements in the relaxation behaviour. For the discussion of the topic, we will restrict ourselves to the two-dimensional case, but the situation in three dimensions is analogous.

The forces of a fluid acting on a particle are obtained from the boundary integral, in two dimensions along the outline Γ , as

F Drag = ∫ Γ { − p δ i j + η ( ( ∇ u ) + ( ∇ u ) T ) } ⋅ n ^ d l (1)

from the pressure p (form drag), as well as from the velocity field u and the viscosity η (friction drag). In turn, the force of the particle acting on the fluid is exerted as a boundary condition of the fluid domain. This means that any simulation approach that requires a physical fluid solid interaction becomes invalid when the length of the boundary is discretized via an uncontrolled approximation. For structured square grids, this is indeed the case and it may come as a surprise that mesh refinement does not remedy this issue. As

When we consider not only a single particle, but the very complicated pore space between sedimenting (or sedimented) particles, it is clear that a triangulation is able to give a much better approximation than a decomposition into squares. In particular, for Equation (1), square grids will always result only in zero-order approximations, while for polygonal particles; triangular grids can represent the outline exactly, without any need for approximation.

For a given setup of mesh points (from the outlines of the particles, as well as existing stencil points in the fluid space) we can always create a space filling triangular mesh via Delaunay triangulation. More precisely, it is a so-called “constrained” Delaunay triangulation, which may violate the property that no points are contained in the circumcircle of any triangle, which is the condition for Delaunay triangulations in the strict sense. Nevertheless, the arbitrary particle positions (we assume polygonal particles throughout the paper) result in arbitrary positions of the grid points and in turn to mesh triangles with arbitrary angles. This has to be taken into account, as the quality of the mesh has to be maintained so that FEM-triangles do not contain angles above 135 degrees [

The relaxation method in ref. [

r n + 1 = 2 r n − r n − 1 + ι 2 a n (2)

with the “virtual” relaxation timestep ι . We use Greek ι (iota), which looks like the symbol of the physical timestep τ with something missing, to express that ι is deficient in physical meaning and only a (dimensionless/virtual) iteration parameter. The acceleration a n is obtained from the spring force, as deviation from the equilibrium length and can therefore be positive (under compression) or negative (under tension). From Equation (2) we obtain

r n + 1 = r n + r n − r n − 1 + ι 2 a n , (3)

= r n + ι r n − r n − 1 ι ︸ v n + ι 2 a n . (4)

In [

r n + 1 = r n + ι 2 a n . (5)

Accordingly, the remaining algorithm had an accuracy of order zero, which for the solution of Newton’s equation of motion converges to the force-equilibrium. For grids with roughly uniform grid size, the convergence of this method is very satisfying. Nevertheless, for a grid with short and long edges, or for large spring constants k, convergence issues arise in the form of grid oscillations (between corner nodes of the same triangles, or neighbouring triangles) and in the form of mesh elements getting squeezed by larger neighbouring elements. As a remedy, in [

a n , g s = k ⋅ ∑ i sgn ( A n , i − A n ) ⋅ | ( A n , i − A n ) | (6)

which uniformly wants to grow all edges of an element if its area A n is smaller than that of its neighbours A n , i or shrink them if its area is larger instead. Grid oscillations, however, require a substantial reduction in the number of relaxation timesteps ι per physical timestep τ to be suppressed. Otherwise, they are pesky at least because they require a reduction of the physical timestep τ within the adaptive timestep control (see Section 4.2). In the worst case, they are disastrous, as the oscillations considerably change the triangle sizes from one physical timestep to the next, which leads to locking of the FEM due to oscillatory noise in the solution [

When we consider the zero-order approximation in Equation (5) above as one extreme of Equation (4), while dropping the acceleration term would lead to

r n + 1 = r n + ι r n − r n − 1 ι ︸ v n . (7)

This does not contain the spring forces at all and would be quite useless on its own. Now we can look for a “better” algorithm in the convex hull of both Equation (5) and Equation (7) with a partitioning

r n + 1 = r n + ι p v n + ι 2 ( 1 − p ) a n , (8)

= r n + p ( r n − r n − 1 ) + ι 2 ( 1 − p ) a n , (9)

which for a partition factor 0 < p < 1 would still be of order zero and thus preserve the convergence.

The effects of the relaxation from Equation (9) can be visualized by implementing a one-dimensional linear chain that starts out with random segment lengths and then relaxes the configuration towards equal distances between nodes. The average segment length we use is r n − r n − 1 = 1 . Partitioning values for 0.8 ≤ p ≤ 0.9 show very good stability while the results still converge relatively fast: For values of p > 0.9 , the convergence speed is slowed down (up to p = 1 , where the position of the mesh nodes does not change at all). In case of p = 0 , Equation (9) becomes identical to Equation (5) (our old algorithm), which we will use for comparison.

F i j = k ( x j − x i ) (10)

between the nodes, while the first and last node ( i = 1 and i = 20 ) were fixed. The relaxation timestep is an arbitrary (within the limits of convergence), dimensionless constant and taken as ι = 0.1 . For partitioning values of p = 0 (old algorithm) and p = 0.8 , we can see clear differences for k = 50 : The old algorithm shows oscillations that subside only slowly, while the new algorithm

ensures a smooth convergence towards the equilibrium points. With p = 0 as in Equation (5), the oscillations around the equilibrium position will occur for k ≤ 30 or even lower values in case of too large ι (or too large changes of r n ). In the language of numerical analysis, this would correspond to an ι which is larger than the stability radius of the integrator. The new algorithm Equation (9) with p = 0.8 properly locates the equilibrium positions without these issues. This more stable “advection” towards the equilibrium position occurs because the “velocity part” and the “acceleration part” compensate each other in case of larger ι , while with the old algorithm Equation (5) the points would oscillate around their equilibrium positions in such a case. The new relaxation with p = 0.8 , shows no oscillations up to spring constants of k = 150 , whereas the “old” relaxation in Equation (5) already exhibits oscillations which diverge towards infinity with these settings. In terms of stability, the possibility to equilibrate systems without oscillations for spring constants up to k = 150 for p = 0.8 instead of k = 30 for p = 0 (the old algorithm) corresponds to at least a factor of 150/30 = 5 in the grid size (towards smaller grids), or conversely for the same grid size translates into a convergence speed which is faster by a factor of 150/30 = 5.

While in the theory of differential equations it is customary to compute convergence radii, this cannot be done in our case, because we do not solve the underlying differential equation in detail, but only compute suitable equilibrium solutions: The improvements are shown by the numerical results, not by any algebraic relations.

The term ι p v n in Equation (8), i.e. the use of the velocity of step n, corresponds to an “explicit Euler” step. For the linear chain in the previous Section 2.2, we also tried out the corresponding “implicit Euler” step: We extrapolated the velocity to timestep n + 1 as

v ˜ n + 1 = v n + ι a n . (11)

and tried to advance the integrator with the ι p v ˜ n + 1 instead of ι p v n . It turned out that the convergence was worse and stability (absence of oscillations) was considerably reduced. The reason becomes obvious when one inserts Equation (11) into Equation (9) so that

r n + 1 = r n + p ( r n − r n − 1 ) + ι 2 a n , (12)

which corresponds to the original Verlet-method in the form of Equation (3) with a prefactor p in front of ( r n − r n − 1 ) : The accuracy order of the “implicit” step thus becomes higher than the one of the “explicit” step in the zero-order approach of Equation (5) because an additional first order term is added, and oscillations get amplified instead of curtailed. Therefore, this “implicit Euler” approach is not suitable for equilibration, e.g. our grid relaxation, because the “advection” to the equilibrium position is disturbed by the unwanted noise of the oscillations. That the improved accuracy delays the convergence to the equilibirum shows again that conventional stability theory cannot be meaningfully applied for zero-order equilibria.

In our two-dimensional, combined DEM-FEM simulation [

a n , e q = ( l a v e − l j ) ⋅ k with l a v e = 1 3 ∑ j = 1 3 l j . (13)

For each edge, the accelerations are then summed up into

a n = a n , e q + a n , g s (14)

and applied to the mesh nodes according to Equation (9). The nodes may move individually or in groups, in parallel or in opposite directions. Note that by treating directly the accelerations, not the forces, there is no need to additionally assign a virtual mass to the mesh nodes. In an additional buffer, the mesh node positions from the previous relaxation step are held to be used as r n − 1 in the next timestep. For the initialization of the first step, r n − 1 = r n is used (mesh nodes are at rest initially).

The relaxation process is performed on the existing Delaunay triangulation for every physical timestep with a set number of relaxation steps N s h o r t . In regular intervalls (usually every 50 physical timesteps), the grid is newly triangulated and relaxed over an increased amount of steps N l o n g , with additional re-triangulations every N t r i steps.

To verify the effects of the new relaxation algorithm, we keep spring constant k = 1 and step size ι = 0.05 from the old algorithm based on Equation (5) and set the partitioning to p = 0.9 . Only the number of relaxation steps per physical timestep will be adjusted.

First, we compared the behaviour of the old and new relaxation algorithms for the graded mesh around a granular step. Here, the two-dimensional behaviour is very similar to the one-dimensional case discussed in Section 2.2. If both algorithms are set to N s h o r t = 4 , N l o n g = 8 and N t r i = 4 , the new algorithm is slower to converge towards an equilibrium configuration. In

By increasing the parameters N s h o r t = 20 , N l o n g = 60 and N t r i = 20 for the new relaxation, there are enough steps so that the grid points reach their equilibrium position before the next physical timestep. In

allows more equilateral configurations in regions of the fine mesh that were not fully equilibrated before. With the nodes now in their equilibrium positions before the physical timestep is resumed, the wobble effect mentioned above is gone. This is in stark contrast to the old algorithm: With a similarly increased step count, oscillations would have time to build up and result in a faulty mesh or squeezed mesh elements. Profiling runs have been performed for the old relaxation with few steps and for the new relaxation with the increased step count. No discernable difference over the CPU-time required for computing a physical timestep was observed, which implies a negligible impact of the new relaxation algorithm, even though it performs more iteration loops. Further, while no change in CPU-time could be observed, the average physical timestep size increased slightly (albeit only about one percent) which warranted further investigation as discussed in the following.

For simulations of dry granular materials, adaptive time integrators are not very efficient: The timestep is essentially determined by the oscillation frequency due to the particle masses and Young’s moduli. In configurations with fluids and particles, the time scale of the dynamics can change much more due to changing motion patterns (release of avalanches, easing of movement after the collapse of aggregates etc.), and even the particle-particle interactions can be “damped away” from the dry oscillation frequency by the viscosity of the fluid in the porespace. In our simulation, we have implemented the time-adaptive BDF2 (backward differentiation formula/Gear Predictor-Corrector of second order) recommended in [

As the new relaxation algorithm shows a far more stable behaviour, we prepared a test simulation with nine particles sedimenting in water to compare the effects of new and old relaxation on the timestep (see

as the timestep remains near the maximum limit defined by the DEM. In this phase, the particles are simply sinking and nothing much of interest is happening. Once the first particle collisions occur, the sudden change in particle velocity causes the length of the timestep to drop. While the timestep for the simulation with the new relaxation algorithm seems to dip a bit further down in case of collisions with high impact forces, it is also able to recover slightly faster and seems to be less affected by collisions with small impact forces. The average timestep size is τ ¯ n e w = 3.2106 × 10 − 5 for the new relaxation compared to τ ¯ o l d = 2.9659 × 10 − 5 for the old one, an increase of about 8%. However, the effect on more complex geometries may be less pronounced. If small sections of the pore space prevent a more deformed triangle from relaxing at all (due to geometry constraints), the timestep will be impacted regardless of the relaxation algorithm until the geometry changes again. It should also be noted that in

To stress-test the relaxation, we modified the above simulation, so the nine particles sink through a greater height difference, resulting in higher particle velocities and thus more intense collisions. The simulation with the old relaxation algorithm failed even before any particles hit the ground: Once the particles reach a certain sinking speed, the relaxation struggles to keep the mesh nodes moving together with the particles until a node in front of a particle gets pushed inside it, causing the simulation to crash, which is the reason why in

given by the DEM but increased by a factor as the particle movement is damped by the fluid. With the increased particle velocities and even higher relative velocities due to the bouncing, the dampening effect of the fluid was insufficient. With the timestep at the moment of the collision still well above the limit for a dry DEM, the calculation of the contact forces resulted in unphysical values for the particle velocities which, when fed back into the FEM, locked the simulation. This of course can be remedied by reducing the maximum possible timestep size, but it is a great example that the new relaxation allows us to keep the timestep size limit coming from the FEM consistently above the one from the DEM, meaning timestep size will for the most part not be limited by the difference between predictor and corrector results anymore.

We used a spring-model between grid points to improve the quality of the FEM mesh generated via Delaunay triangulation: The relaxed length of a spring is matched to the side length of equilateral triangles, equilibrating all mesh triangles towards a more equilateral shape. An existing zero-order integrator was used to compute the equilibration process and by improving its convergence properties, we were able to suppress oscillations in the equilibration more efficiently and allow for the equilibrium state to be reached faster. The details of the grid relaxation do not influence the FEM-solution directly; they just increase the speed at which the quality of the mesh is improved. Nevertheless, as a “bad mesh” in the pore spaces between granular particles leads to ill-conditioning of the underlying nonlinear system of equations, the improved mesh generation helps to increase the overall stabilisation of the simulation and reduces the risk of faulty mesh structures locking the simulation.

For some setups, the possible physical timestep was increased by up to 8%, while for particles moving inside the fluid, the relaxation could now keep up with the changes of the particle outlines where the older algorithm failed, while both with respect to memory requirements and computational effort, the additional costs of the new algorithm are negligible.

The authors declare no conflicts of interest regarding the publication of this paper.

Mueller, J. and Matuttis, H.-G. (2021) Improved Grid Relaxation with Zero-Order Integrators. Journal of Applied Mathematics and Physics, 9, 1257-1270. https://doi.org/10.4236/jamp.2021.96086