14 Flocking Rules Governing Swarm Robot as Tool to Describe …
225
14.2 Tool Description
A complete description of the algorithm is reported in dell’Erba 2018a, c). Here, we
briefly summarize that algorithm, breaking down its steps into “choices”. The twodimensional continuum is discretized into a finite number of particles occupying,
in their initial configuration, the nodes of a lattice, chosen between the five plane
Bravais lattices and the honeycomb lattice (Choice 1).
The lattice has four kinds of particles, but it is easy to introduce new kinds, to
describe other properties, due to the modular structure of the algorithm.
1. The leaders; their motion is assigned and determine the displacements of the
other particles.
2. The followers; their motion is determined by the interaction rule with other
particles.
3. The frame; they are introduced so that any particle can have the same number of
neighbours, to avoid edge effects. Their motion is determined by the frame rule.
4. The ghost; they are introduced to describe fracture mechanism.
Regarding the choice of the neighbours of any particles (Choice 2), typically nc
particles, where nc is the coordination number of the lattice (first gradient): the position of those points will determine the displacement of the point under investigation.
The chosen flocking rule (Choice 3) between the particles describes the position of a
particle as function of its neighbour’s positions. To avoid edge effects, it is necessary
to build a frame surrounding the body, by defining an external shell of points, so
that any follower interacts with the same number of elements. The displacement of
the frame points follows the motion of an assigned follower. If the displacement of
those assigned followers obeys a more complex rule (e.g. in a corner), then an average
displacement, or a more generic rule (Choice 4), may be considered. Next, a threshold
df (or a more complex rule) may be defined beyond which fracture appears (Choice
5). We assume that if the distance between points is larger than this threshold, they
stop to influence each other so they are no longer taken into account in the calculation of the follower position and fracture is declared. To balance computation of the
point’s displacements, we introduce ghost points, to avoid collapsing. The possible
positions of those ghost points (Choice 6) are chosen so that the original shape of the
lattice may be recovered. Different choices lead to different results, and our intention
will be to use different rules in order to approximate different constitutive equations.
Now, by the displacements of the leaders, we can start an iterative work flow until
an equilibrium state is reached. We would like to underline this point in each of the
possible choices; as an example, if we take a larger coordination number nc, like the
neighbours of the neighbours, we are in second gradient theory case. The algorithm
is suitable to change particle role and rules dynamically at each time step. The most
natural choice, concerning interaction rule, is the centre of gravity rule where the
new x-coordinate of the particle j is
x j (t) =
all neighbours of j
k=2
x k (t)
N
(14.1)
225
14.2 Tool Description
A complete description of the algorithm is reported in dell’Erba 2018a, c). Here, we
briefly summarize that algorithm, breaking down its steps into “choices”. The twodimensional continuum is discretized into a finite number of particles occupying,
in their initial configuration, the nodes of a lattice, chosen between the five plane
Bravais lattices and the honeycomb lattice (Choice 1).
The lattice has four kinds of particles, but it is easy to introduce new kinds, to
describe other properties, due to the modular structure of the algorithm.
1. The leaders; their motion is assigned and determine the displacements of the
other particles.
2. The followers; their motion is determined by the interaction rule with other
particles.
3. The frame; they are introduced so that any particle can have the same number of
neighbours, to avoid edge effects. Their motion is determined by the frame rule.
4. The ghost; they are introduced to describe fracture mechanism.
Regarding the choice of the neighbours of any particles (Choice 2), typically nc
particles, where nc is the coordination number of the lattice (first gradient): the position of those points will determine the displacement of the point under investigation.
The chosen flocking rule (Choice 3) between the particles describes the position of a
particle as function of its neighbour’s positions. To avoid edge effects, it is necessary
to build a frame surrounding the body, by defining an external shell of points, so
that any follower interacts with the same number of elements. The displacement of
the frame points follows the motion of an assigned follower. If the displacement of
those assigned followers obeys a more complex rule (e.g. in a corner), then an average
displacement, or a more generic rule (Choice 4), may be considered. Next, a threshold
df (or a more complex rule) may be defined beyond which fracture appears (Choice
5). We assume that if the distance between points is larger than this threshold, they
stop to influence each other so they are no longer taken into account in the calculation of the follower position and fracture is declared. To balance computation of the
point’s displacements, we introduce ghost points, to avoid collapsing. The possible
positions of those ghost points (Choice 6) are chosen so that the original shape of the
lattice may be recovered. Different choices lead to different results, and our intention
will be to use different rules in order to approximate different constitutive equations.
Now, by the displacements of the leaders, we can start an iterative work flow until
an equilibrium state is reached. We would like to underline this point in each of the
possible choices; as an example, if we take a larger coordination number nc, like the
neighbours of the neighbours, we are in second gradient theory case. The algorithm
is suitable to change particle role and rules dynamically at each time step. The most
natural choice, concerning interaction rule, is the centre of gravity rule where the
new x-coordinate of the particle j is
x j (t) =
all neighbours of j
k=2
x k (t)
N
(14.1)
