Formalisation · Lean 4 · Mobile agents · Mobile robots

Formalising a Whole Research Area to Find Its Gaps and Fill Them

Every assumption of the survey becomes a definition and every published result becomes an obligation that a proof checker accepts or rejects, and the obligations that are rejected show where the area has gaps.

Debasish Pattanayak · 20 Nov 2026 · 6 min read

Mobility Matters is a living survey of open problems on autonomous agents, robots and particles. It records four models: mobile agents on graphs, mobile robots in the plane, search in geometric domains, and programmable matter. For each problem it records the variants, their assumptions, the published results and the open questions. Mobility Matters in Lean writes the same content a second time, in a language in which a computer checks every statement and every proof.

What a formalisation of a survey is

An assumption is a definition. The order between two assumptions of one axis is a theorem: if the survey says that one value assumes less than another, then Lean has to prove the implication. A problem is a specification, which says what an execution has to achieve. A published result is an obligation: a proposition which says that some algorithm with the stated measures meets the goal in every instance, or that no algorithm with less of a measure does.

The obligations are generated from the data of the survey, and each of them takes the assumptions of its own variant as a hypothesis, so that a claim made for one variant cannot be used for another. At present 336 of the 426 variants of the survey have a generated model, and the survey gives 1412 generated obligations. An obligation is only a statement, and its proof is a separate piece of work.

A diagram. A survey record, audited against its source paper, generates a Lean obligation over the model of its variant. The obligation has four possible outcomes: proved, proved in a restricted form, refuted, and true only vacuously. Each outcome leads to a consequence: the record stands in this model; the missing assumption or the lost part of the bound is named; a corrected statement or a new theorem; the statement or the model is repaired.
From a record of the survey to an entry of the ledger.

Why every published result is formalised

The author states the reason in one sentence: “The reason behind formalizing the entire research is to find gaps and fill them.” A gap is hard to see in prose and easy to see in a formal statement. An implication between two assumptions which nobody wrote down, an assumption which a proof uses silently, a condition which every instance satisfies, a bound which is recorded without its exception, and a question which is listed as open although an answer follows from a known theorem are all gaps of this kind. In Lean each of them appears as a concrete event: a theorem that the survey does not state, a hypothesis that has to be added before a proof is accepted, or an obligation whose negation is proved.

An obligation that Lean does not accept as stated shows where the statement has a gap.

To fill a gap means to replace the statement by one that Lean accepts: a corrected record with its missing precondition, a theorem under an assumption that is now named, or a new theorem that answers a question. Hence the project covers the whole area and not a selection of results, and the ledger has a row for every obligation, including the rows that are not proved.

What the formalisation has found

The names of the Lean theorems are in brackets.

  • Missing implications. On the topology axis the survey places tree, grid and hypercube on the same level as bipartite, as alternatives. Every tree, every grid and every hypercube is bipartite (IsTreeTopology.isBipartite, IsGrid.isBipartite, IsHypercube.isBipartite), so algorithms for bipartite graphs carry over to these classes.
  • A vacuous condition. The condition of the value homonymous, 1≤∣{id(a)}∣≤k1\le|\{\mathrm{id}(a)\}|\le k, holds for every labelling of k≥1k\ge1 agents.
  • A hidden assumption. The implication from crash faults to weak Byzantine faults needs crashed agents to keep reporting their true identifier (CrashFaults.weakByzantine, hypothesis hrep).
  • A record without its exception. The survey records that three robots suffice for terminating exploration of a grid by oblivious robots. Three robots fail on the 2×22\times2 grid, so Lean proves the negation of the generated row (GridTwoByTwo.result_grid_false). The record is now restated on the class of all grids except the 2×22\times2 and the 3×33\times3 grid, and this restated row is not yet proved.

The ledger

The ledger gives every generated obligation one status. The counts are those of 20 November 2026.

StatusObligationsMeaning
Proved513The generated obligation is proved over the generated model of its variant.
Proved in a restricted or weakened form64The proof covers a sub-family, a relaxation, another model, or a weakened bound.
Refuted8The negation of the generated row is proved.
True only vacuously225The row holds only because no algorithm of the model meets the goal. It does not count.
Stated only, or not yet tracked602There is no proof yet.
Total1412

The counts are rows and not independent results: 140 of the 513 proved rows are optimality rows derived from an upper and a lower bound. Moreover, “proved” means proved in the generated model, and it does not mean that the model has been compared with the paper. That comparison is a separate audit of each record's statement, model and assumptions against its source, and 815 of 1929 survey records have passed it. Finally, a refuted row is not always an error of a paper: the eight refuted rows include records that lost a precondition, as in the grid example above.

Four pairs of bars, one pair for each model. Mobile agents on graphs: 296 of 759 obligations proved, 590 of 1070 records audited. Mobile robots in the plane: 51 of 298 and 44 of 395. Search in geometric domains: 163 of 264 and 165 of 327. Programmable matter: 3 of 91 and 16 of 137.
The ledger and the audit for the four models of the survey.

An open question, answered

The survey lists the following question as open. Can three oblivious robots with visibility φ=1\varphi=1 explore a ring perpetually under the SSYNC or the ASYNC scheduler, or are two colours necessary? A robot sees its own node and its two neighbours and counts the robots on each of them. In each round the SSYNC scheduler, which is an adversary, activates some of the robots, and it must activate every robot infinitely often. It was known that three robots with two colours can explore under ASYNC, and that three robots with one colour can under FSYNC, where all robots are activated in every round.

Three rings of ten nodes. Left, the start: a tower of two robots and one robot on the next node. Middle, under FSYNC all three robots move and the group advances by one node. Right, under SSYNC only the single robot is activated and steps away; the tower and the robot are then two nodes apart, nobody moves again, and a node on the far side of the ring is never visited.
An algorithm that explores a ring under FSYNC and fails under SSYNC. A robot beside a tower steps away from it, and a tower beside a robot steps towards it. (c) If only the single robot is activated, then no robot sees another robot afterwards.
Theorem (Hand.no_perpetual_exploration). Let n≥7n\ge7. For every algorithm for three oblivious robots with visibility one and every starting configuration on a ring of nn nodes, there is a fair SSYNC execution in which the robots occupy at most six nodes. Hence some node is never visited, and two colours are necessary.

The proof by hand sorts every configuration into one of six shapes and gives, for each shape, a short sequence of activations that ends in a loop. The Lean file follows this proof lemma by lemma. The proof uses only the three standard axioms propext, Classical.choice and Quot.sound.

The project also records what the theorem does not say. Rings of five and six nodes are covered only by an exhaustive search which Lean does not check, and on four nodes some algorithms work. The transfer from SSYNC to a native ASYNC model is not formalised. Moreover, for n≥9n\ge9 the result already follows from Theorem 14 of Ooshita and Tixeuil (2022), although that paper does not state the consequence.

Further questions are answered in the 148 research reports of the project, which count 17 open questions solved out of 43 attacked. One more answer is the following.

Theorem (RingCrash.no_perpetual_exploration). If up to ff robots may crash, then f+2f+2 oblivious robots with visibility one cannot explore a ring of n≥10(f+2)n\ge10(f+2) nodes perpetually under FSYNC. Hence the optimal number of robots needs at least two colours.

Not every answer of a report is a Lean theorem: 18 results have a Lean proof, and the other answers are proofs by hand.

What is not formalised yet

Most of the work remains. There are 602 obligations without a proof, and 639 of the 2045 entries of the survey have no generated obligation at all. Of the 324 assumptions of the survey, 171 have a tagged Lean definition. More than half of the survey records still wait for their audit. The generated models have known defects: in the model of agents on graphs, for example, the time measure is 00 when no uniform bound exists.

How the work is organised and checked

The library builds with no sorry, which is the keyword of Lean for a missing proof. Labels are withdrawn when a check fails: a refutation audit on 24 October 2026 withdrew six labels that had problems of scope or used placeholders. Reports are read by a second agent, whose verdict is a referee report of its own, and there are 43 of them so far.

Read the full paper

Mobility Matters in Lean — Debasish Pattanayak

Cite
@unpublished{pattanayak2026mobility,
  author = {Debasish Pattanayak},
  title  = {Mobility Matters in Lean},
  year   = {2026},
  note   = {Ongoing formalisation},
  url    = {https://debasishpattanayak.com/Research/papers/mobility-matters-lean/}
}