Swarmalators

Clocks that also move. Each agent carries a phase as well as a place; nearby phases can synchronise while phase similarity rewrites spatial attraction. Clusters, rings and travelling colour appear because organisation in one domain continually changes the conditions of organisati

The idea

Clocks that also move. Each agent carries a phase as well as a place; nearby phases can synchronise while phase similarity rewrites spatial attraction. Clusters, rings and travelling colour appear because organisation in one domain continually changes the conditions of organisation in the other.

Science and concept

The simplest way to understand a swarmalator is to combine two state variables that are usually modelled separately. The spatial state of agent (i) is a position (\mathbf x_i=(x_i,y_i)). Its oscillatory state is a phase (\theta_i), an angle defined modulo (2\pi). A phase can represent any repeated internal cycle: a flashing rhythm, a biochemical clock, a stroke cycle or an abstract oscillator.

Ordinary swarming models ask how positions and velocities organise. Ordinary phase-oscillator models ask how internal cycles synchronise. Swarmalator models ask a stronger question:

What collective states become possible when spatial proximity changes synchronisation and synchronisation changes spatial interaction?

The minimal model introduced by O’Keeffe, Hong and Strogatz has the structure

Compact form: \dot x_i = (1)/(N)Σ_j\ne i \left[ ( x_j- x_i)/(| x_j- x_i|) \left(A+J\cos(\theta_j-\theta_i)\right) - B( x_j- x_i)/(| x_j- x_i|^2) \right],

Compact form: \dot\theta_i = \omega_i+(K)/(N)Σ_j\ne i (\sin(\theta_j-\theta_i))/(| x_j- x_i|).

The first equation contains an attractive spatial term and a short-range repulsive term. The coefficient (J) determines how phase difference modifies attraction. When (J>0), similar phases attract more strongly. When (J<0), opposite phases receive the stronger spatial preference. The second equation contains Kuramoto-like phase coupling weighted by distance. Positive (K) tends to reduce phase differences; negative (K) tends to oppose local phase agreement.

This gives two directed causal channels:

  • phase → space: the value of (\cos(\theta_j-\theta_i)) changes attraction;
  • space → phase: the distance (|\mathbf x_j-\mathbf x_i|) changes the strength of synchronisation.

Neither channel is decorative. If colour merely displayed a passive phase that did not alter motion, the system would be mobile oscillators, not fully coupled swarmalators. If position affected phase but phase did not affect position, the feedback loop would remain one-way.

AL.Floys preserves this mathematical architecture. For each neighbour inside a finite interaction radius it computes a spatial radial term

Compact form: A+J\cos(\Delta\theta)

along with an inverse-distance repulsion and a phase term proportional to

Compact form: K(\sin(\Delta\theta))/(r).

The code then departs from the canonical minimal model in several important ways.

First, interactions are finite-range rather than global. An agent queries a spatial hash and considers only neighbours inside interactionRadius. This changes the meaning of synchrony. A high global Kuramoto order parameter can still emerge, but local phase domains, disconnected clusters and travelling fronts are more natural when information cannot pass instantly through the whole population.

Second, the spatial equation is no longer first-order. The canonical model directly specifies (\dot{\mathbf x}). AL.Floys treats the summed spatial interaction as an acceleration, updates a velocity, damps that velocity and clips it to maxSpeed. Inertia, friction and speed saturation can therefore sustain motion or delay settling even where the corresponding canonical first-order system would approach a static arrangement.

Third, natural frequencies are heterogeneous. Ordinary agents receive (\omega_i) from a uniform range controlled by Frequency spread. Without coupling, their phases drift at different intrinsic rates. Positive phase coupling must overcome this disorder to create coherence. Raising the spread can therefore dissolve global synchrony without changing the spatial force coefficients.

Fourth, the world wraps toroidally. Agents leaving one edge re-enter from the opposite edge, and neighbour distances use the corresponding wrapped displacement. The visible rectangle is not a closed arena; it is one tile of a repeating world.

Synchronisation is not the same as spatial–phase order

AL.Floys reports the ordinary Kuramoto order parameter

Compact form: R = \left|(1)/(N)Σ_j=1^Ne^i\theta_j\right|.

If every phase is nearly equal, (R) approaches one. If phases are uniformly spread around the cycle, (R) approaches zero. This is an excellent measure of global phase coherence.

It is not sufficient for swarmalators. A perfect phase ring can have every colour represented once around the cycle and therefore (R\approx0), even though phase and spatial angle are perfectly correlated. The original swarmalator work introduced spatial–phase order parameters

Compact form: W_\pm=(1)/(N)Σ_j=1^Ne^i(\phi_j\pm\theta_j), \qquad S=\max(|W_+|,|W_-|),

where (\phi_j) is the angular position of an agent around the aggregate. A phase wave can have low (R) but high (S). This distinction is central to interpreting the sphere: asynchrony can still be highly organised.

The current telemetry labels energy as phase coherence (R). That is truthful as far as it goes, but a low value should not be read as disorder. Adding (S_+) and (S_-) would let the HUD distinguish global synchrony from a spatially ordered phase wave.

Five canonical states and the limits of preset naming

The idealised global model predicts five prominent long-term states in a two-parameter ((J,K)) plane.

Static synchrony combines a stationary spatial aggregate with nearly identical phases. This is the easiest state for (R) to detect.

Static asynchrony also becomes spatially stationary, but phases remain distributed throughout the aggregate.

Static phase wave appears in the canonical model at (K=0) with positive phase-dependent attraction. Phases do not change, yet agents sort themselves so spatial angle correlates with phase around an annulus.

Splintered phase wave appears under mildly negative phase coupling in the canonical parameterisation. The annular correlation breaks into clusters that quiver in phase and space.

Active phase wave appears under stronger negative phase coupling and contains sustained motion in both phase and spatial angle.

These names have specific meanings in the original model. AL.Floys uses the preset names Phase Ring, Splintered Clock and Active Wave, but all three use positive phaseCoupling. Their behaviour may be visually related to rings, fragmented phase domains or travelling colour, yet it should not be described as an exact reproduction of the canonical static, splintered or active phase-wave states. Finite-range interaction, heterogeneous (\omega_i), inertia and damping create a different phase diagram.

This is not a weakness. The engine is a legitimate variant. The editorial requirement is simply to distinguish canonical lineage from preset analogy.

Two feedback loops can reinforce or frustrate one another

Positive (K) encourages nearby phases to agree. Positive (J) then makes those agreeing agents attract more strongly, bringing them closer and increasing their phase coupling. Synchronisation and aggregation can therefore form a mutually reinforcing loop:

phase agreement → stronger attraction → closer proximity → stronger phase agreement.

Other sign combinations frustrate that loop. With (J<0), phase agreement weakens spatial attraction relative to opposite phase. Positive (K) may pull phases together while spatial interaction favours phase contrast. The result can be bands, alternating neighbours, continual rearrangement or a compromise rather than simple synchrony.

The preset Repulsive Harmony operates in this conflicted regime: (K>0) encourages synchrony while (J=-1) reverses phase-dependent spatial preference. Its current description, “similar phases repel, producing anti-phase lattices,” is too strong. The baseline attraction (A) remains present, and the implementation does not diagnose a lattice or a precise anti-phase order. A more truthful name would be Opposite-Phase Attraction or Inverted Coupling.

Frequency disorder creates a competition of timescales

Each ordinary agent has an intrinsic phase drift (\omega_i). When the spread is small, coupling can entrain the population: agents adjust away from their natural rate and rotate together. When the spread is large, local groups may synchronise temporarily while the global population continues to shear in phase.

This is not random noise. The frequencies are seeded properties of agents and remain fixed until the spread control is changed or the world is reset. The result is quenched heterogeneity: persistent differences that coupling must overcome.

The current implementation redraws each non-pacemaker (\omega_i) when Frequency spread changes. Although the control schema marks it structural, the runtime applies it live without resetting positions or phases. The UI contract should be corrected in one direction or the other. A live redraw is scientifically useful, but it represents an instantaneous reassignment of intrinsic clocks rather than a gentle widening of the existing distribution.

Phase leaders, not fixed pacemakers

The advanced Spawn tool creates agents marked pacemaker. They begin with one shared phase, receive (\omega=0), and contribute 2.5 times the normal weight to neighbours’ phase updates. The code comment calls their phase fixed, but the update loop still changes it under coupling. They are therefore not mathematically pinned pacemakers.

The truthful description is zero-intrinsic-frequency phase leaders with amplified influence. The implementation can either adopt that language or change the dynamics so their phase is externally prescribed. The distinction matters because a true pacemaker is a reference signal; the current agents can themselves be entrained.

Rendering reveals phase but does not create it

Colour maps the circular phase angle. Trails reveal spatial motion. Pacemaker agents receive stronger visual emphasis. None of these rendering choices alters synchronisation. A colour wave can arise because phases change, because coloured agents move, or both. The most informative observation is therefore to compare colour motion with particle trajectories rather than treating a shifting palette as direct evidence of spatial travel.

History

Arthur Winfree’s 1967 study of populations of coupled biological oscillators established a modern route to collective synchronisation. He showed that a population with distributed intrinsic rhythms can spontaneously entrain when coupling passes a threshold. Yoshiki Kuramoto simplified the problem in 1975 into the phase-coupled form that became the standard model of synchronisation.

Those traditions generally treated oscillator locations as fixed or externally given. Swarming research, by contrast, studied movement and aggregation while often omitting an internal cyclic variable. Work on mobile oscillators began to connect proximity with phase, but typically only in one direction: position altered synchronisation while phase did not feed back into motion.

In 2017, Kevin O’Keeffe, Hyunsuk Hong and Steven Strogatz introduced a minimal model with explicit bidirectional coupling and coined swarmalators to emphasise the dual identity. Their analysis predicted static synchrony, static asynchrony, a static phase wave, a splintered phase wave and an active phase wave.

The concept has since grown into a model family spanning robotics, active matter, biological oscillators and networked mobile systems. A 2025 experimental study realised tunable colloidal swarmalators with hydrodynamic coupling, observing coevolving synchronisation and spatial aggregation in controlled active particles. That result strengthens the term’s scientific standing, but it does not make the AL.Floys engine a model of those particular colloids. The sphere belongs to the common theoretical framework, not to one experimental material.

What this simulates

Aspect Current implementation
Entities / field Discrete mobile agents; there is no continuous environmental field.
State Position, velocity, phase, natural frequency and a soft phase-leader flag.
Spatial coupling Baseline attraction plus phase-dependent attraction and inverse-distance short-range repulsion.
Phase coupling Distance-weighted sine coupling among neighbours within a finite radius.
Neighbourhood Metric radius accelerated with a spatial hash; unlike the original minimal model, interaction is not global.
Motion update Pair interaction produces acceleration; velocity is integrated, damped and capped before position advances.
Boundary conditions Toroidal wrap in both motion and neighbour displacement.
Heterogeneity Ordinary agents receive fixed natural frequencies from a configurable uniform range.
Phase leaders Spawned agents have zero intrinsic frequency and 2.5× outgoing phase influence, but their phase is not fixed.
Randomness Seeded initial position, velocity, phase and natural frequency; detuning and pointer-created leaders add seeded random perturbations.
Rendering interpretation Phase colour, spatial trails, glow, agent scale and optional density heatmap. Colour is an encoding of internal phase, not species.
Telemetry Population, global Kuramoto coherence (R), leader count and mean speed. No spatial–phase order parameter is computed.
Public simple controls Population, Spatial attraction, Phase coupling, Phase→space coupling, Frequency spread, Interaction radius, Trail persistence and Glow.
Public simple tool Couple only. Phase leader, Detune and Erase exist in the engine but are hidden from the current ecospheres.ai simple surface.

The most truthful one-line description is: mobile phase oscillators whose timing and attraction alter one another through finite-range local coupling.

What to look for

Synchronised clusters — timing and aggregation reinforce one another

In Static Choir, colours converge while the population condenses. The important observation is not merely that agents share a colour; it is that phase agreement alters the spatial force that keeps them together.

Phase rings — low global synchrony can conceal high organisation

A ring can display the full colour cycle around its circumference. The global coherence (R) may remain low because all phases are represented, yet spatial angle and phase are strongly correlated. This is the clearest reason to distrust one scalar measure of “order.”

Local synchrony, global fracture — interaction range limits information

With a smaller interaction radius or wider frequency distribution, nearby agents may share phase while distant clusters drift independently. The system can be coherent at one scale and asynchronous at another.

Travelling colour versus travelling matter

A colour band may propagate because agents change phase in place, because agents move through a spatial phase pattern, or both. Track individual particles and their trails to separate the two mechanisms.

Opposed couplings — one domain tries to agree while the other tries to separate

With positive (K) and negative (J), local phases tend to synchronise while spatial attraction favours phase contrast. Persistent rearrangement can result from competition between these objectives.

Entrainment and failure of entrainment

Increase Frequency spread while holding coupling fixed. A once coherent choir can fragment into phase groups or continual drift. The transition reveals coupling as a contest against heterogeneous intrinsic clocks.

Perturbation and recovery

Use Couple to gather and phase-align a local region, then release it. The affected group may retain coherence, merge with a larger cluster or lose alignment as surrounding frequencies reassert themselves.

How to explore

First 30 seconds

  1. Load Static Choir and identify colour as phase, not species.
  2. Watch whether colour agreement and spatial condensation occur together.
  3. Lower Phase coupling toward zero while leaving Phase→space coupling unchanged. Give the existing coherence time to decay.
  4. Restore positive Phase coupling and observe whether local groups entrain before the entire population does.
  5. Load Phase Ring. Ignore the coherence chip for a moment and follow the colour ordering around the ring.
  6. Use Couple on a small arc. Compare the local phase change with the later response of the whole ring.

Three experiments

Experiment Question Do Watch for Why it matters
Timing changes space Does phase merely colour the swarm? Phase Ring → move Phase→space coupling from positive toward zero while keeping Phase coupling fixed. Loss or weakening of phase-sorted spatial structure even if local synchrony remains. Demonstrates that phase is causal in motion.
Space changes timing How local is synchronisation? Static Choir → reduce Interaction radius in stages. Global coherence splitting into locally synchronised clusters. Makes the space→phase channel and finite-range network visible.
Coupling versus disorder When can shared influence overcome different clocks? Static Choir → raise Frequency spread gradually while holding Phase coupling fixed. Phase drift, cluster-specific colours and falling (R). Shows entrainment as competition, not automatic agreement.

An advanced fourth experiment uses the hidden phase-leader and Detune tools. Introduce one small leader cluster, let it entrain neighbours, then detune the same region. Describe the inserted agents as influential clocks unless their phases are made truly fixed.

Parameters that teach

Parameter What it really controls Increase it Decrease it What to watch
Population Number and density of mobile oscillators. More encounters and denser local coupling. Sparser groups and weaker network connectivity. Cluster number and local neighbour count.
Spatial attraction (A) Phase-independent baseline aggregation. Denser aggregates. Greater dispersal. Whether phase effects organise one cluster or several.
Phase coupling (K) Space→phase sine coupling. Positive values favour nearby synchrony; negative values oppose it. Faster local entrainment when positive. Weak agreement near zero; anti-aligning tendency when negative. Global (R), local colour domains and phase shear.
Phase→space coupling (J) How phase difference modifies attraction. With positive values, similar phases become preferred neighbours. At zero, attraction ignores phase; negative values favour opposite-phase proximity. Rings, colour sorting and alternating neighbourhoods.
Frequency spread Width of persistent natural-frequency heterogeneity. Harder global entrainment and more phase drift. More nearly identical clocks. Whether coupling produces one coherent phase or several local rhythms.
Interaction radius Metric neighbourhood for both motion and phase. More global coupling. More local clusters and fragmented information flow. Scale of synchrony and aggregate connectivity.
Short-range repulsion (advanced) Soft core preventing spatial collapse. Greater spacing and broader aggregates. Denser packing and overlap pressure. Internal cluster texture.
Friction (advanced) Velocity damping per second. Faster spatial settling. Longer inertial motion. Whether a colour pattern is static or carried by continuing movement.
Max speed (advanced) Hard cap on spatial velocity. Faster rearrangement allowed. More strongly clipped motion. Response time after a perturbation.
Trail persistence (visual) Duration of spatial drawing history. Longer visible trajectories. Cleaner instantaneous positions. It reveals movement but does not alter phase or force.
Glow (visual) Rendering emphasis. Brighter phase field. Flatter display. No scientific state changes.

The best first pair is Phase coupling and Phase→space coupling. Their names should retain the directional arrows or equally clear help because they represent opposite halves of the feedback loop.

Presets as experiments

Static Choir

The best introduction to global phase coherence. Positive (K), positive (J), narrow frequency spread and damping support a compact, nearly monochromatic population. Call it choir-like synchrony, not a proof that the final state is the canonical static-sync solution.

Phase Ring

The best demonstration that spatial–phase order differs from (R). The preset’s positive (K) means it is not the canonical (K=0) static phase wave. The title remains useful if the note calls it a phase-ordered ring rather than equating it with the exact analytic state.

Splintered Clock

Wide frequency spread and finite-range coupling can produce local phase domains and fractured spatial organisation. The name is editorially strong, but it should not be described as the canonical splintered phase wave, which occurs under a different coupling regime in the original minimal model.

Active Wave

Low friction and a higher speed cap support persistent spatial motion, while frequency disorder keeps colour evolving. Its activity arises partly from the implementation’s inertial velocity and disorder. Use active phase motion rather than claiming the original active-phase-wave state.

Sudden Consensus

Designed near an apparent transition between asynchronous clouds and coherence. The word sudden is visually plausible, but “near-critical” should be retained only if a documented parameter sweep identifies a reproducible transition and finite-size sensitivity. The current engine does not expose such evidence.

Repulsive Harmony

Positive phase coupling competes with negative phase-dependent spatial coupling. Rename the description to opposite-phase spatial preference under synchronising phase coupling. “Anti-phase lattice” is too specific without an order parameter or lattice diagnostic.

Recommended learning order: Static Choir → Phase Ring → Splintered Clock → Active Wave → Repulsive Harmony → Sudden Consensus.

Interactions

  • Couple is the only tool currently exposed on the ecospheres.ai simple surface. In attractive mode it pulls nearby agents toward the pointer and nudges their phases toward the local circular mean. In repelling mode it pushes them away and adds a common phase offset; it is a perturbation, not a canonical negative-(K) update.
  • Phase leader (engine tool currently labelled Pacemaker) inserts a small group with shared initial phase, zero intrinsic frequency and amplified outgoing phase influence. Their phases remain dynamical.
  • Detune perturbs natural frequencies and phases inside the brush and removes leader status. It changes the agents’ internal clocks, not merely their colour.
  • Erase removes agents inside the radius.

The public Couple tool is scientifically valuable because it acts in both domains. It should be presented as an external local intervention rather than an ordinary interaction already present in the model.

What this does not mean

Swarmalators are not automatically biological organisms, robots, frogs, sperm cells or colloids. Position and phase are abstract state variables whose physical meaning depends on an application.

The current implementation is not the exact two-parameter model analysed in the 2017 paper. It uses finite-range neighbours, toroidal boundaries, heterogeneous frequencies, inertial velocity, damping and a speed cap. Its phase diagram can therefore differ substantially.

The named presets Phase Ring, Splintered Clock and Active Wave should not be equated with the canonical static, splintered and active phase-wave states solely by appearance. Their (K) values and dynamics differ.

A high global coherence (R) measures phase synchrony, not spatial order. A low (R) does not imply disorder when phase is correlated with spatial angle.

Colour is phase, not species or identity. A particle changing colour has advanced through its internal cycle.

The current pacemakers are not fixed phase sources. They are influential, zero-frequency agents that can themselves be entrained.

Trails are visual histories, not emitted signals. Glow does not represent energy.

The defensible conclusion is:

When internal oscillation and spatial interaction feed back into one another, collective order can combine synchronisation, segregation, rings and motion in ways unavailable to either a fixed oscillator network or a phase-blind swarm.

Why it belongs

Swarmalators add an internal clock to collective motion. Flock demonstrates local directional consensus among moving peers; Swarmalators show that entities can also organise by where they are in a cycle, and that the cycle itself can be changed by proximity. The sphere is the atlas’s clearest example of two distinct state spaces becoming mutually causal.

Sources

Foundational and primary sources

  1. Arthur T. Winfree, “Biological rhythms and the behavior of populations of coupled oscillators,” Journal of Theoretical Biology 16(1), 15–42 (1967). DOI: 10.1016/0022-5193(67)90051-3.
  2. Yoshiki Kuramoto, “Self-entrainment of a population of coupled non-linear oscillators,” in International Symposium on Mathematical Problems in Theoretical Physics, Lecture Notes in Physics 39, 420–422 (1975). DOI: 10.1007/BFb0013365.
  3. Kevin P. O’Keeffe, Hyunsuk Hong and Steven H. Strogatz, “Oscillators that sync and swarm,” Nature Communications 8, 1504 (2017). DOI: 10.1038/s41467-017-01190-3.

Modern experimental context

  1. Veit-Lorenz Heuthe, Priyanka Iyer, Gerhard Gompper and Clemens Bechinger, “Tunable colloidal swarmalators with hydrodynamic coupling,” Nature Communications 16, 10984 (2025). DOI: 10.1038/s41467-025-66830-5.
Enter this field →