## Abstract

The collective ability of organisms to move coherently in space and time is ubiquitous in any group of autonomous agents that can move and sense each other and the environment. Here, we investigate the origin of collective motion and its loss using macroscopic self-propelled bristle-bots, simple automata made from a toothbrush and powered by an onboard cell phone vibrator-motor, that can sense each other through shape-dependent local interactions, and can also sense the environment non-locally via the effects of confinement and substrate topography. We show that when bristle-bots are confined to a limited arena with a soft boundary, increasing the density drives a transition from a disordered and uncoordinated motion to organized collective motion either as a swirling cluster or a collective dynamical stasis. This transition is regulated by a single parameter, the relative magnitude of spinning and walking in a single automaton. We explain this using quantitative experiments and simulations that emphasize the role of the agent shape, environment and confinement via boundaries. Our study shows how the behavioural repertoire of these physically interacting automatons controlled by one parameter translates into the mechanical intelligence of swarms.

## 1. Introduction

Collective behaviour is ubiquitous among living organisms: it occurs in sub-cellular systems, bacteria, insects, fish, birds and in general in nearly any group of individuals endowed with the ability to move and sense [1,2]. Recent studies of collective behaviour have focused on the mechanism that triggers the switch from disordered to organized motion in a swarm [2–7], and its implications for artificially engineering these strategies in robotic systems [8–10]. For example, in social insects, such as the agarophilic desert locusts, the transformation from solitary to social behaviour arises as a consequence of proximal tactile interactions that are density controlled [4]. Experiments on the claustrophilic termites, *Macrotermes michaelseni* that are used to living in confined spaces, have demonstrated the existence of a variety of collective behaviours such as coordinated circulation and arrest or stasis in a closed confined geometry. These different behaviours may be triggered by varying the density of the colony and disturbing it through external stimuli [11]. Understanding how these biological behaviours arise from a mechanistic perspective has been difficult, given our primitive experimental abilities to probe the neuro-ethology of these complex creatures. Theoretical attempts to understand these behaviours use putative models of interactions between organisms as a function of their density in periodic domains [2], whereas a practical approach circumvents the question of mechanism and implements workable strategies to actively direct the collective dynamics of ensembles of agents [9,10] using feedback control in individual agents [12]. These approaches clarify the common bases at the heart of all swarming behaviours: the ability of an agent to move, the ability to sense others and the environment and the ability to respond to both of these kinds of stimuli.

Here, we probe the transition from random swarming to collective motion and its loss using a minimal system composed of self-propelled automatons that can sense each other mechanically through contact and interact both with an environment of varying topography and with boundaries. Our setting is macroscopic, controllable and especially suitable to investigate the role of the environment in selecting and tuning the collective behaviour of the group. Unlike experiments on vibrated particles [13,14], where all particles are simultaneously driven using the same source, our agents are autonomous and self-propelled, with velocities that are independent, and yet show collective behaviour even in a small group of individuals in the presence of confinement.

## 2. Motion of an individual bristle-bot

Our experiments were carried out using a custom-fabricated swarm of bristle-bots^{1} (BBots) [15,16], simple self-propelled automata with similarities both to natural mechanical ratchets [17] and their artificial analogues [18]. Our system has three controllable features: (i) a tunable ratio of linear speed and rate of turning for individual agents; (ii) a collective ability to exert aligning forces and torques on each other by means of shape-dependent contact interactions; (iii) confinement induced by soft or hard boundaries. The design of our BBots (figure 1) is optimized to be small, light, stable and modular. An elliptical plastic chassis (major axis 7.92 cm, minor axis 1.85 cm) serves as a container for a 1.2 V Varta rechargeable battery which can slide inside the chassis to adjust the position of the centre of mass, and thus change the relative ratio of translational and rotational speed. The battery is connected to a motor (commonly used in cell phones) housed on the top side of the chassis, with a mass of 0.5 g and an eccentricity of 0.8 mm, designed to rotate at 150 rounds per second. Two rows of nylon bristles, obtained from a commercial toothbrush, form the legs of our BBots. The bristles are cut to 5 mm length to prevent tipping without compromising their flexibility and are attached to the chassis via a removable wedge. This allows us to control the inclination of the bristles relative to the chassis. The total mass of the object is 15.5 g.

BBots move when the eccentrically loaded motor drives the legs of the machine, the bristles, which flex periodically. The bending of the tilted bristles on the substrate causes them to move more easily in the forward direction relative to the rear, leading to a rectification of the periodic driving and thus directed movement. Over each period of rotation of the eccentric motor, the sequence shown in figure 2 is followed (see also appendix A and the electronic supplementary material, movie S1): (i) the bristles are loaded by a force *F*=*Mg*+*mrω*^{2} (*Mg* weight of the BBot, *m* eccentric mass, *r* lever arm and *ω* angular frequency of the motor); (ii) as the eccentric mass rotates, the load on the bristles decreases, causing the bristles to recoil; (iii) the bristles slip forward on the underlying substrate, producing a net displacement of the object. To quantify the motion of an individual BBot, we analysed the shape of a row of bristles treated as a single elastic beam subject to a periodic tip load as well as a frictional force in the horizontal direction (see appendix A), and showed how the linear velocity of a BBot and its turning rate depend on the design parameters of the system.

In figure 3, we show how the motor speed, bristle position, length and angle, and the system mass leads to changes in the speed of an individual BBot confined to a narrow channel to prevent lateral drift. We see that the bristle inclination and length have a strong effect on BBot locomotion; increasing the angle *α* of the bristle with respect to the vertical direction causes the BBots to slow down substantially when *α* is varied from 5 to 30^{°}. The length of the bristles affects the motion of a BBot in two ways: longer bristles cause the centre of mass to be displaced further in each step, leading to a linear increase in the velocity (figure 3*c*), whereas short stiff bristles lead to a noisier dynamics associated with rebounds and jumps driven by the eccentric forcing. Furthermore, because long bristles cause the BBots to spend a longer time in contact with the substrate (where the transverse component of the eccentric force is balanced by friction), they move primarily along a straight line, whereas BBots equipped with short bristles are prone to move in a circle. This sensitive dependence on the bristle parameters allows us to tune the locomotion of individual subunits and study its role on the collective behaviour of the community. In particular, by choosing 5 mm bristles and varying *α* from 0^{°} (upright bristles) to 20^{°}, we obtained two distinct types of individuals: (i) spinners, which are BBots with *α*=0 and 5^{°} that tend to spin clockwise with an angular velocity of up to 30 rad s^{−1} while moving slowly; (ii) walkers, which are BBots with *α*≥10^{°} that move in a straight or weakly curved orbit (see the electronic supplementary material, movie S2).

## 3. The effect of boundaries and topography

In most prior studies of collective behaviour, the boundary is not considered; indeed, theoretical studies routinely treat only the case with periodic boundaries, whereas the few experimental studies that exist aim to minimize the role of boundaries. In our study, the boundaries play a most important role as we now discuss. Our arena consists of a circular plate, 44 cm in diameter, with a single BBot taking up approximately 0.8 per cent of the total available area.

### (a) Soft boundaries

We first consider the interaction of a BBot with the boundary that causes it to be reflected back from the edge, into the middle, using an arena with a gentle upward sloping edge, fabricated by oven-forming an acrylic disc over a frisbee-shaped aluminium mould. Here, we see that surface topography plays a role normally reserved for the boundary by influencing the motion of a BBot via environmental changes. With this *soft-boundary* setup, our BBots either turn back into the middle (behaviour typical of spinners, i.e. *α*=0^{°}, 5^{°}) or they oscillate back and forth in a periodic motion that causes them to remain in the neighbourhood of a particular location at the boundary (behaviour typical of walkers, i.e. *α*=10^{°}, 15^{°}) (figure 4*a*). This pendulum-like effect follows from the fact that the walker’s path is never perfectly radial, so that as a BBot climbs the edge it also turns sideways. On the steepening gradient near the edge, the BBot typically slips backwards, as it rotates by about 30^{°}, and Sisyphus-like, tries to climb up the edge again only to be kicked back to where it started. These oscillations may be repeated a few times for an individual BBot before it eventually moves back into the centre of the arena, and then onto another part of the edge where the same phenomena is repeated. Strong walkers with *α*=20^{°} do not experience the oscillatory motion at the boundary, because their forward propulsion dominates the role of sideways spinning motion and tends to align the BBots to be normal to the edge independent of how they initially approach the boundary.

### (b) Hard boundaries

To see what happens when we change the environment in which the BBots operate, we replaced the boundary of the arena with a gently curved edge with a flat circular disc of the same 44 cm diameter, bounded by a thick (vertical) strip of acetate approximately 4 cm high that is held firmly in place by a ring of thick translucent tubing. The most salient feature of this *hard-boundary* system is that the boundaries are not reflective, so that a BBot that hits the edge will begin to circulate in a particular direction around the arena, travelling always parallel to the edge (figure 4*b*). We observe stable motion in both a clockwise and counterclockwise direction, the determining factor being the angle of initial contact with the wall.

## 4. Collective behaviour of BBots: experiments

To study the collective dynamics of the BBots, we use a transparent plate that is backlit with a set of neon lamps and allows us to track the BBots with a digital camera at 40 fps. The resulting movies were processed with tracking software to compute the position, orientation and the translational and rotational velocity of each BBot, and thus quantify their individual behaviour. This allows us to calculate the following two order parameters to characterize the collective behaviour of the putative swarm
4.1where *N* is the total number of BBots and *v*_{i}(*t*) the velocity of the *i*th BBot at time *t*. We see that *v*_{1} is the average velocity of the BBots, whereas *v*_{2} is their average speed. When they move in a disordered fashion, *v*_{1}≈0 (becoming exact in the infinite particle limit) and *v*_{2}>0; BBots moving coherently in space have both *v*_{1}≠0 and *v*_{2}≠0, whereas if a cluster of BBots is dynamically arrested, *v*_{1}≈*v*_{2}≈0.

In our experiments we used a paperboard template that initially arrested the motion of the BBots. When this was removed, the BBots moved and eventually reached a statistical steady state (see the electronic supplementary material, movie S3). Alternatively, we progressively increased the BBot population from 2 to 16, adding a new one every 30 s and then removing them one at a time, to measure the hysteresis in the transition between states of collective behaviour.

In figure 5*a*,*b*, we show the results of our experiments on the collective motion of spinners (*N*=7, 24 with *α*=5^{°}) moving in an arena with a soft boundary for 3 min. Spinners spin rapidly and collide frequently and strongly with each other (see the electronic supplementary material, movie S3); when *N*<10 (corresponding to 8% area coverage) their motion is disordered, with *v*_{1}<*v*_{2} as seen in figure 5*a*(ii) and their centre of mass moves aperiodically as shown in figure 5*a*(iii). When *N*>10 the spinners aggregate at the edge of the arena while aligning themselves at an angle to the boundary, and start swirling collectively clockwise (the direction of spinning for individual BBots) coherently along the edge, as shown in figure 5*b*(ii). In this case, the order parameter *v*_{1} increases and saturates once the swirling cluster is formed (figure 5*b*(ii)).

Walkers at low density have a different behaviour than spinners; they move to the edge, stay for a while before they turn around randomly, eventually reaching an approximately antipodal point where this behaviour is repeated. As the number of walkers is increased, they form ephemeral clusters along the edge (see the electronic supplementary material, movie S4) that eventually break up. However, when *N*>8, clusters of BBots oriented perpendicular to the edge form and remain stable, as shown in figure 5*c* (*N*=15 with *α*=10^{°}). This corresponds to the order parameters *v*_{1}≈*v*_{2}≈0, and the centre of mass is essentially stationary (figure 5*c*(ii,iii)). In figure 6, we show a phase diagram that summarizes the collective behaviour of BBots confined to an arena with a soft boundary, showing disordered motion, swirling and stasis and highlights the hysteretic nature of the transitions between states. For example, once a swirling cluster of spinners has formed, it remains stable even when BBots are withdrawn from the cluster until *N*<6.

To understand how confinement and topography lead to these behaviours, we first use BBots with an intermediate bristle inclination to observe the assembly and disassembly of clusters at a soft boundary; for example, BBots with *α*=10^{°} resist the sideways motion necessary for swirling but they do not get trapped at the edge as easily as BBots with larger *α*. The result is that clusters can form orthogonal to the circular boundary, but if the cluster is too small in number, it will eventually disassemble owing to the growth of coordinated oscillations of the entire cluster (figure 7*a*). Indeed clusters of four or five bots remain stable for over a minute before disassembling. The stasis or jamming region in our phase diagram describes the formation of clusters at even higher densities when they become stable over very long times.

In contrast, collective behaviour in the presence of a hard boundary leads to contact with the vertical wall and aligns the BBots along the boundary, thus limiting their motion and reducing the interactions between BBots (figure 4*b*). BBots sliding along the boundary of the arena eventually form groups owing to the small variations in the velocity of individuals. However, as the number of BBots in a group increases, it becomes less stable and can abruptly self-arrest. These arrested states can take the shape of a half-aster as shown in figure 7*b* when the arena is bounded by a vertical, rigid boundary, in contrast with the orthogonally oriented jammed structures formed in the soft-boundary arena.

## 5. Collective behaviour of BBots: theory

The nature of the collective motion and stasis in our system of confined agents relies on the ability of the BBots to march in the direction of their major axis, and rotate and align with each other and with the boundary. In order to understand these effects quantitatively, we use simulations of self-propelled particles consisting of two-dimensional ellipses whose centre of mass position *r*_{i} and orientation *θ*_{i} are governed by the following dynamical system
5.1aand
5.1bThe first equation describes the over-damped motion of individual ellipses with velocity *v*_{0} along their major axis , where *F*_{ij} is the repulsive elastic force between the *i*th ellipse and its *N*_{i} neighbours, these being defined as the set of all ellipses that overlap with the *i*th. This force between the *i*th particles and its *N*_{i} neighbours is given by
5.2with ℓ a virtual *spring length*, which for the ellipses is calculated from the intersections between the two overlapping ellipses as illustrated in figure 8.

The second equation implies that the major axis of each ellipse rotates counterclockwise with frequency *ω* and can align with its neighbours as a consequence of the physical torque owing to the contact with the neighbours and is given by
5.3where *d*_{ij} is the lever arm of the force *F*_{ij} exerted by the *j*th neighbour on the *i*th ellipse and is the unit vector in the *z*-direction. The constant *k*_{2} measures the strength of this aligning interaction, whereas *ζ*_{i} is a delta-correlated random variable in the interval [−*ζ*,*ζ*] and represents the noise associated with all the non-deterministic factors that affect our system.

The ellipses are confined to a circular arena of radius *R* and subject to a non-local exponentially decaying torque exerted by the boundary that reorients them towards the interior, which reflects the torque produced by the curvature of the experimental arena along the edge. The interaction between the particles and the boundary takes place through a virtual linear spring acting at the centre of mass
5.4and a long range torque of the form
5.5where *ξ* is a constant length that can be used to tune the range of the interaction. When a particle is in proximity of the boundary [i.e. (|*r*_{i}|−*R*)/*ξ*≈1], this boundary torque has the effect of rotating the particle towards the interior. The non-locality of the boundary torque in (5.5) mimics the distributed gravitational torque produced by the curvature of the dish in which the particles move, and appears to have a significant role for the clustering of the particles at the boundary. Compared with its local-analogue (i.e. a torque of the same form that acts only when |*r*_{i}|>*R*), the torque (5.5) has the effect of producing more densely packed clusters of particles along the boundary, and thus fundamentally changes the collective behaviour of the BBots. Being curved, the boundary of the arena has the effect of getting the particles to form densely packed clusters. Extending the range of the particle–boundary interaction is equivalent to increasing the curvature and thus accentuates the focusing effect. This is also the simplest situation where we see how the physical environment can control the behaviour of these autonomous agents.

Our system differs fundamentally from those studied in the past by accounting correctly for orientational effects using torque balance rather than an ad hoc alignment term, while also exploring the role of non-local interactions using topography and finite size boundaries. The dynamical system (5.1) is characterized by four dimensionless parameters: the scaled density *ϕ*=*R*^{2}/*ab* (where *a* and *b* are the minor and major semi-axes of the ellipses), the spinning to walking ratio *ωa*/*v*_{0}, the orienting parameter *k*_{2}*a*^{2}/*k*_{1} and the scaled noise parameter *ζa*/*v*_{0}. In our experiments, the relevant experimental variables are the scaled density and the spinning ratio, because the orienting parameter and the noise are intrinsic to the shape of the agents and the motor characteristic.

Varying the two relevant parameters in equation (5.1) and integrating them numerically leads to a variety of collective behaviours consistent with our observations as shown in figure 9 (appendix B and electronic supplementary material, movie S5). We see that individual self-propelled walkers or spinners tend to migrate towards the boundary of the arena where they experience a torque that reorients the individual towards the interior. At low densities, the primary interactions of these automata are with the boundary and so one sees random uncoordinated movements (figure 9*a*). At higher densities, as more ellipses simultaneously cluster in the same region of the boundary, the aligning force exerted on the ellipses by each other can overcome the action of the boundary provided the cluster is large enough. Thus walkers for whom *ωa*/*v*_{0}∼0 tend to aggregate into a static structure at the boundary at high enough density (figure 9*c*). However, spinners for whom *ωa*/*v*_{0}>0 form clusters at the boundary that are tilted, and this broken symmetry together with the effect of the weak topography (boundary curvature) keeps them confined to the neighbourhood of the boundary and causes the automata to eventually synchronize their velocities resulting in a collective swirling motion of the entire cluster (figure 9*b*). Thus both collective swirling and stasis originate from the interplay between self-propulsion, particle geometry and confinement. By contrast, in the absence of confinement, our system shows the typical flocking behaviour of the Vicsek model [7], so that for large density and small noise, the particles become self-organized into lanes or coherently moving subunits (figure 10 and electronic supplementary material, movie S6), exhibiting neither swirling nor stasis.

Our model described by equation (5.1) illustrates the origin of the three observed behaviours in a broader context. Analogously to the simple self-propelled particles, BBots tend to migrate to the boundary, which depending on the local density of the BBots and their angular velocity, can either play the role of an obstacle that causes the objects to jam, or a confining channel that collects and aligns the BBots into a coordinated moving cluster. For a cluster of walkers at the boundary, each BBot in the cluster is trapped by its neighbours and cannot escape. As their angular velocity increases, they can exert a sufficient torque on their neighbours to push them aside and escape from the cluster, consistent with the observation that the number of BBots required for jamming decreases with their angular velocity, as shown in the phase diagram in figure 6. BBots that are spinners have a relatively small translational velocity and so are easily trapped by their neighbours at the boundary, once their density is large enough and they are unable to reverse direction and escape. However, the finite spinning torque leads to a global tilt of the BBots, leading to a global swirling motion of the entire cluster along the edge of the arena.

## 6. Discussion

While the geometric structure of the clusters depends significantly on the shape of the particles, the occurrence of these three collective behaviours observed in the experiment is rather general. To demonstrate this, we have run an additional set of simulations using self-propelled polar discs in place of elliptical particles (see appendix B). The discs’ dynamics is also dictated by equation (5.1), in which the physical torque is *M*_{ij} now replaced by a generic aligning interaction of the form: (which has no real physical basis in our system). With this choice, equation (5.1b) becomes a short-range version of the Kuramoto model for phase-synchronization in chemical and biological oscillators [19]. Analogously to the ellipses, the dynamics of the polar discs is also characterized by three regimes: random motion at low densities, jamming at the boundary for large densities when the angular velocity of the discs vanishes, and the formation of a compact cluster that circulates along the boundary for large densities when the discs have a finite angular velocity (see appendix B).

The similarity between our experimental system and the two models described above suggests that the coordinated circulation and jamming in a system of confined agents is generic. This form of collective behaviour relies on simple, but crucial features of the individual agents as well as the environment: the ability to translate and rotate, and the ability to interact with each other and with the environment, here including the boundary and the local topography. While the spatial structure of the clusters crucially depends on the shape and the packing properties of the particles, their collective motion is very robust, and depends on simple non-specific principles.

In living systems, where similar behaviours such as the density-driven transitions are seen in confined *Macrotermes michaelseni* [11], they have been linked with insect cognition and social interactions. Our study suggests that particle motion, shape and spatial interactions are sufficient and might in fact play equivalent roles. In a biological setting such as termite swarms, one might test these ideas by controlling the confinement of termites by varying the substrate curvature and slipperiness, gluing circular discs on their backs to make the interactions more isotropic, etc. In an artificial setting, the collective abilities of spinner and walker BBots to convert environmental interactions into dynamical behaviour may allow us to explore functional swarms that can search and sense environments. For example, they have the ability to sense substrate roughness by slowing down, and they can search topography (curvature) in massively parallel ways, using mechanical intelligence, and suggesting the use of these automata as fast, cheap, leaderless explorers.

## Acknowledgements

We thank the Wyss Institute, the Harvard-Kavli Nano-Bio Science and Technology Center, the Harvard-NSF MRSEC, DARPA and the MacArthur Foundation for support; J. McArthur for constructing the charger used to recharge the batteries of the BBots; Teo Guo Xuan for figure 1*a*; Joe Ustinowich and Anas Chalah for help in fabricating our bots; VARTA Microbattery; and A. Mukherjee and M. Bandi for many useful discussions and suggestions.

## Appendix A. Locomotion of an individual BBot

The principle of motion of a single BBot, as inferred from high-speed videos, relies on the sequence of events illustrated in figure 3. At each cycle of the eccentric motor, the following sequence of events takes place: (i) the bristles bend as they are loaded by a force *F*=*Mg*+*mrω*^{2}, where *Mg* is the weight of the BBot, *m* the eccentric mass, *r* the lever arm and *ω* the angular frequency of the motor. (ii) While the eccentric mass rotates, the load on the bristles decreases; this causes the bristles to unbend. (iii) The unbending bristles slip on the underlying substrate, producing a forward displacement of the object in the horizontal direction (figure 11).

A quantitative description of the gait reduces to calculating the horizontal displacement Δ*x* of the bristles at each cycle of the eccentric motor. To accomplish this, we ignore the collective dynamics of the bristles and focus on a planar description, replacing the rows of bristles as an ideal elastic rod subject to periodic tip-load acting in the *y* direction:
A1When the eccentric mass is oriented with its axis of symmetry towards the negative *y*-direction, the load is and the bristles are maximally deflected. As the eccentric mass moves away from the vertical direction, the bristles start to recoil and their tip slides on the substrate. The sliding tip of the bristles is subject to a dynamic frictional force acting along the *x*-direction
A2where *μ* is the kinetic friction coefficient. The unbending of the bristles terminates when the eccentric mass is oriented along the positive *y*-direction and the load is minimal: .

To make progress, we assume that the inertia of the bristles is negligible so that bristle deflection and sliding occurs *quasi-statically*. This implies that the conformation of the bristles is, at any time of the gait cycle, in equilibrium with the external load and the frictional force acting, respectively, on the *y* and *x* direction. Under this assumption, the shape of the bristles is governed by the classical equilibrium equations of an ideal elastic beam
A3** F** and

**are, respectively, the force and torque per unit length and the subindices denote a derivative with respect to the arc-length**

*M**s*of the beam. The tangent vector

**of the bristles is given by A4where**

*t**θ*is the angle formed by the bristles with the vertical direction. Finally,

**is the external force acting on the tip of the bristles, thus A5where**

*K**L*is the length of the bristles and the delta function reflects the fact that the force is applied at the tip. Integrating the force equation and replacing it in the torque equation gives A6The torque

**acting in the beam and its curvature**

*M**κ*=

*θ*

_{s}are related by the Euler–Bernoulli constitutive equation

**/**

*M**EI*=−

*κ*

**, where**

*b***is the binormal vector of the beam ( in this case) and**

*b**EI*is its bending rigidity (with

*E*the Young modulus and

*I*the area–moment of inertia). This yields a single differential equation for the angle

*θ*: A7with boundary conditions A8These are the typical boundary conditions of a cantilever beam, with one end fixed at an angle

*α*and the other free of torques. It is convenient to work with dimensionless quantities, by re-scaling the arc-length with the total length of the bristles:

*t*=

*s*/

*L*, so that equation (A7) can then be recast in the form A9where A10Equation (A9) can be integrated exactly in terms of Jacobi elliptic functions to yield A11a A11band A11cwhere equations (A 11) follow using standard techniques (see for instance [20]), and we use the standard notation for elliptic functions and integral, i.e. given the elliptic integral of the first kind: A12with 0<

*m*

^{2}<1, the elliptic modulus and

*ϕ*the Jacobi amplitude:

*ϕ*=am(

*u*,

*m*). From this it follows that A13

Finally, the quantity *K* in equations (A 11) is the complete elliptic integral of the first kind: *K*=*F*(*π*/2,*m*). This enforces the boundary condition at the free end *t*=1
A14The elliptic modulus *m*, on the other hand, is obtained from the boundary condition at the fixed end through equations (A11a)
A15With the solution (A 11) in hand, we can now construct a parametric equation for the shape of the deflected bristles by integrating the tangent vector ** t**
A16In order to use equation (A16), we first set and and note that
A17aand
A17band that the integrals of terms containing

*A*and

*B*are given, up to a constant, by A18aand A18bwhere

*E*is the elliptic integral of the second kind, defined as A19Then, combining equations (A 17) and (A 18) we obtain the following parametric expression of the coordinate of the bristles A20aand A20bwhere we have called

*τ*=

*k*(

*t*−1)+

*K*for brevity. The integration constants

*x*

_{0}and

*y*

_{0}are set so that

*x*(0)=

*y*(0)=0, so that A21aand A21bEquations (A 20)–(A 21) and (A15) along with the definitions (A10) give the shape of the bristles. In figure 12, we show a sequence of typical configurations obtained from this solution for various values of

*W*/

*EI*/

*L*

^{2}.

Given the shape of the bristles, the step size Δ*x* of a BBot associated with each gait cycle is dictated by the position of the tip of the bristles. The latter can be obtained from equations (A 20) by setting *t*=1 and noting that cn(*K*,*m*)=0, am(*K*,*m*)=*π*/2. Then
A22where *E*(*m*)=*E*(*π*/2,*m*) is the complete elliptic integral of the second kind. Because of our quasi-static approximation, *x*(1) depends exclusively on the applied load and so the step size is simply given by the difference in the position of the tip associated with the maximal (eccentric motor in the negative *y*-direction) and minimal (eccentric motor in the positive *y*-direction) load. Using the definition
A23we can finally express the step size in the form
A24where *m*_{±}=*m*(*k*_{±}) and Δ_{0}=*x*_{0}(*k*_{+})−*x*_{0}(*k*_{−}). The model is valid only as long as , which implies *Mg*>*mgω*^{2}. For light BBots, where this condition does not hold, locomotion is complicated by the fact that when the eccentric mass is oriented along the positive *y*-direction, there is an upward directed force that makes the BBot lose contact with the substrate. The resulting jumping motion then couples with the dynamics of the bristles making the gait cycle intractable with the methods used here. Figure 13 shows a typical step size obtained from equations (A 20) as a function of the ratio *M*/*m* and the bristles inclination angle *α*.

Our analytical results allow us to capture the qualitative aspects of the motion of a single BBot and its dependence on the magnitude and frequency of the eccentric driving motor, as well as the dependence on the mass of the BBot, the orientation and length of the bristles, consistent with experimental observations. An alternative analysis of the locomotion of an individual BBot was carried out by DeSimone & Tatone [21] using methods of geometric control theory [22].

## Appendix B. Collective behaviour of self-propelled discs

In order to gain insight into the origin and the generality of the behaviours observed in our experiments and numerical simulations of interacting BBots, we also compared the results with those obtained from the numerical simulation of self-propelled disc-like particles that are isotropic. The particles have both a positional degree of freedom given by their centre of mass *r*_{i} and an orientation with the position *r*_{i} and the angle *θ*_{i} that evolve according to equations (5.1), but, in contrast with the case of elliptical collisions where there is a physical torque that causes alignment, *M*_{ij} is chosen to be
A25With this choice, equation (5.1b) is a short-range version of the Kuramoto model for phase-synchronization [19], and can serve as a rather general model for aligning interactions among self-propelled particles, although it has no direct physical origin.

For our simulations, we assume that the particles are confined to a circular domain of radius *R* centred at the origin. The interaction between the particles and the boundary that takes place is assumed to have an identical form to that used in the simulations of the elliptical particles.

While the spatial structure and packing properties of the clusters depends on the details of the system, and in particular on the shape of the particles, the occurrence of the coordinated behaviours (swarming, swirling and stasis) appears to be a very robust property of systems of self-propelled agents in a confined space. These behaviours are not sensitive to the presence of inertia [this is present in the experiment and is neglected in equations (5.1)] or to the shape of the particles and the precise form of the aligning torque *M*_{ij}. However, there are features that do depend on the details; a most interesting example is what we term *treadmilling*, observed in the numerical simulation of both ellipses and discs. Figure 14 shows an example of treadmilling in a group of polar discs, wherein particles move through the cluster and eventually leave it, only to join it later at the other end. For very large densities, the self-propelled discs also exhibit a *breathing mode*, in which the particles periodically migrate from the centre to the boundary and vice-versa by mean of sudden bursts (figure 15) reminiscent of those observed in *excitable* active systems [23,24].

## Footnotes

- Received October 28, 2012.
- Accepted December 21, 2012.

- © 2013 The Author(s) Published by the Royal Society. All rights reserved.