The reversible pebble game #
Bennett's reversible pebble game on a directed graph G uses the moves of the black pebble game
under one extra rule. Placing a pebble on v and removing the pebble from v both require every
predecessor of v to carry a pebble. Every move is therefore undone by the opposite move, so on a
loopless graph each run can be played backwards with the same budget. Pebbles model the
checkpoints of a reversible simulation of an irreversible computation: a checkpoint can be
computed, and reversibly erased, only from the checkpoint before it.
We take the toggling form of the rule, as in [LTV98], Section 6: place v requires
v to be unpebbled and remove v requires v to be pebbled. A no-op move would not change any
configuration, so this does not change which configurations are reachable.
A vertex is reversibly pebblable with s pebbles if some run from the empty configuration that
never holds more than s pebbles reaches a configuration containing it. It is persistently
pebblable if the run can end holding the vertex alone, as when a reversible computation keeps its
output and erases all its checkpoints. Both prices are the least such s, and 0 when no budget
suffices, as for blackPebblingPrice.
Main definitions #
Cslib.Pebbling.Move.swap: the opposite move.Cslib.Pebbling.RevStep: one legal move of the reversible game, with no pebble budget.Cslib.Pebbling.reversiblePebbleGame G s: the game withspebbles, as a cslibLTS.Cslib.Pebbling.ReversiblePebblable G s v,Cslib.Pebbling.reversiblePebblingPrice G v: reaching a configuration containingv, and the least budget for it.Cslib.Pebbling.PersistentReversiblePebblable G s v,Cslib.Pebbling.persistentReversiblePebblingPrice G v: reaching the configuration{v}, and the least budget for it.
Main results #
Cslib.Pebbling.reversiblePebbleGame_mTr_reverse: on a loopless graph a run played backwards, with each move swapped, is a run with the same budget.Cslib.Pebbling.RevStep.filter: restricting a move to a predecessor-closed set of vertices gives a move or no change.Cslib.Pebbling.ReversiblePebblable.blackPebblable: every reversible run is a black run, soblackPebblingPrice_le_reversiblePebblingPrice.Cslib.Pebbling.reversiblePebblingPrice_eq,Cslib.Pebbling.persistentReversiblePebblingPrice_eq: the prices are determined by matching upper and lower bounds.
References #
One legal move of the reversible pebble game, without a budget: a pebble may be placed on an unpebbled vertex, or removed from a pebbled one, only when every predecessor carries a pebble.
- place {V : Type u_1} [DecidableEq V] {G : Digraph V} {C : Finset V} {v : V} (hv : v ∉ C) (h : ∀ (u : V), G.Adj u v → u ∈ C) : RevStep G C (Move.place v) (insert v C)
- remove {V : Type u_1} [DecidableEq V] {G : Digraph V} {C : Finset V} {v : V} (hv : v ∈ C) (h : ∀ (u : V), G.Adj u v → u ∈ C) : RevStep G C (Move.remove v) (C.erase v)
The reversible pebble game with s pebbles.
v can be reversibly pebbled with at most s pebbles: some run from the empty configuration
reaches a configuration containing v.
v can be persistently reversibly pebbled with at most s pebbles: some run from the empty
configuration ends with v as the only pebble.
The reversible pebbling price of v: the least s such that v is reversibly pebblable with
s pebbles, and 0 when no budget suffices.
The persistent reversible pebbling price of v: the least s such that v is persistently
reversibly pebblable with s pebbles, and 0 when no budget suffices.
Every reversible move is a black move.
Restricting a move to a set of vertices closed under predecessors gives either a move or no change.
Every reversible run is a black run with the same moves and budget.
Reversibility. On a loopless graph, a run played backwards with each move swapped is a run with the same budget, provided the starting configuration fits in the budget.
A reversible pebbling is a black pebbling.
The reversible price is n when n pebbles suffice and every successful budget is at least
n.
The persistent reversible price is n when n pebbles suffice and every successful budget is
at least n.
Reversible pebbling costs at least as much as black pebbling.
Ending with the vertex alone costs at least as much as visiting it.