FO(≤, IFP) into FO(LFP): the capture of the inflationary limit #
The hard half of the capture theorem FO(≤, IFP) = PTIME
(DescriptiveComplexity.ifpDefinable_iff_mem_PTIME): every ordered
inflationary definition translates back into FO(LFP)
(DescriptiveComplexity.IFPDefinable.lfpDefinable), so with the embedding of
DescriptiveComplexity.FixedPointInflationary the two logics are
interchangeable (DescriptiveComplexity.ifpDefinable_iff_lfpDefinable) and
FO(≤, IFP) captures polynomial time through Grädel's Horn fragment.
The construction #
Let d : StepDef (L.sum Language.order). Because inflation adds and never
removes, both a stage and its complement advance positively:
x̄ ∈ stage (s+1) of iiffx̄ ∈ stage sorstep iholds at stages– positive in the stage relations and in the truth relations below;x̄ ∉ stage (s+1) of iiffx̄ ∉ stage sandstep ifails at stages– positive in the complements and the falsity relations.
So the translated program (DescriptiveComplexity.IFPLfp.trDef) carries, for
each stage index (j, t̄) (the DescriptiveComplexity.FixedPointHorn stage
walk: hs static copies of hm-tuples in lexicographic order), the stage
S, its complement N, and a dual evaluator deriving truth T and
falsity F of every subformula of every step formula at that stage, with an
accumulator AC walking the order under universal quantifiers.
Base-vocabulary atoms become guards; block atoms read S/N at the current
stage – which is what distinguishes this evaluator from the one of
DescriptiveComplexity.FixedPointHorn, whose subformula relations read the
finished fixed point: here evaluation is per stage, mutually recursive with
the stages themselves, stratified as stage s before evaluator at s before
stage s + 1. The answer variables R are read off the maximal stage, and
the output sentence survives unchanged modulo the block injection
DescriptiveComplexity.SOBlock.homLHom – the point of targeting FO(LFP)
rather than SO-Horn: no evaluator is ever built for the output.
Correctness #
The canonical assignment (DescriptiveComplexity.IFPLfp.canonAssign) gives
every translated variable its intended value; soundness
(DescriptiveComplexity.IFPLfp.trRules_sound) shows it satisfies every rule,
and completeness derives every canonical fact – the dual evaluator by
induction on the subformula at a fixed stage
(DescriptiveComplexity.IFPLfp.derives_tf, with the stage's own S/N
derivability as hypotheses), the stages by induction along the cover walk of
the stage order (DescriptiveComplexity.IFPLfp.derives_SN), and the answer
variables by reading the top of the walk
(DescriptiveComplexity.IFPLfp.derives_r, through
DescriptiveComplexity.IFPLfp.inflStage_srank_top: the top rank is beyond
the atom count, where the stages have stabilized to the limit).
A step formula, as a bounded formula over Empty whose binders are the
arguments of its variable: the form the subformula machinery of
DescriptiveComplexity.FixedPointHorn operates on.
Equations
Instances For
Dependency graph
Dimensions #
The width of a stage tuple: the arity bound of the block.
Instances For
Dependency graph
The number of copies of the stage relations: as in
DescriptiveComplexity.LFPHorn.hs, enough for (hc + 1) · n^hm stages to
exceed the number of atoms of the block on every nonempty structure.
Equations
Instances For
Dependency graph
The number of copies of the stage relations: as in
DescriptiveComplexity.LFPHorn.hs, enough for (hc + 1) · n^hm stages to
exceed the number of atoms of the block on every nonempty structure.
Equations
Instances For
Dependency graph
The number of variables reserved for evaluating the step formulas: a bound on the binder depths of all their subformulas.
Equations
- DescriptiveComplexity.IFPLfp.hX d = Finset.univ.sup fun (i : d.B.ι) => DescriptiveComplexity.ctxB (DescriptiveComplexity.IFPLfp.stepB d i)
Instances For
Dependency graph
Dependency graph
The universally quantified first-order variables shared by all clauses: two stage-tuple blocks (current and next), the atom tuple, the evaluation block, and one spare for the accumulators.
Equations
Instances For
Dependency graph
The block of the translation #
Index of the truth, falsity and accumulator relations: a variable of the block together with a subformula of its step formula.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Dependency graph
Dependency graph
The binder depth of a subformula index is within the evaluation block.
Dependency graph
The relation variables of the translated program: the answer variables
R, the stages S, their complements N, the truth/falsity relations
T/F (Bool-tagged), and the ∀-accumulators AC.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The answer variables.
Equations
Instances For
Dependency graph
S j i (t̄, x̄): at stage (j, t̄), the atom i x̄ is derived.
Instances For
Dependency graph
N j i (t̄, x̄): at stage (j, t̄), the atom i x̄ is not derived.
Instances For
Dependency graph
Truth (true) and falsity (false) of a subformula of a step formula at
a stage.
Instances For
Dependency graph
The accumulator of a universally quantified subformula at a stage.
Instances For
Dependency graph
The arities: answer variables keep theirs, stage relations carry a stage tuple in front of theirs, subformula relations a stage tuple in front of their binder depth, accumulators one more.
Equations
- DescriptiveComplexity.IFPLfp.trArity d (Sum.inl i) = d.B.arity i
- DescriptiveComplexity.IFPLfp.trArity d (Sum.inr (Sum.inl (fst, fst_1, i))) = DescriptiveComplexity.IFPLfp.hm d + d.B.arity i
- DescriptiveComplexity.IFPLfp.trArity d (Sum.inr (Sum.inr (Sum.inl (fst, x_1, snd)))) = DescriptiveComplexity.IFPLfp.hm d + (↑x_1.snd).fst
- DescriptiveComplexity.IFPLfp.trArity d (Sum.inr (Sum.inr (Sum.inr (fst, x_1)))) = DescriptiveComplexity.IFPLfp.hm d + (↑x_1.snd).fst + 1
Instances For
Dependency graph
The block of the translated program.
Equations
- DescriptiveComplexity.IFPLfp.trBlock d = { ι := DescriptiveComplexity.IFPLfp.TrIx d, ιFinite := ⋯, arity := DescriptiveComplexity.IFPLfp.trArity d }
Instances For
Dependency graph
The shared first-order variables and their layout #
The current stage tuple t̄.
Equations
- DescriptiveComplexity.IFPLfp.vT1 d q = ⟨↑q, ⋯⟩
Instances For
Dependency graph
The next stage tuple t̄'.
Equations
Instances For
Dependency graph
The atom tuple x̄, the scratch the block-atom evaluation rules equate
with the (evaluated) arguments of a block atom.
Equations
- DescriptiveComplexity.IFPLfp.vX d q = ⟨2 * DescriptiveComplexity.IFPLfp.hm d + ↑q, ⋯⟩
Instances For
Dependency graph
The evaluation block ē, holding the free variables of a subformula of a
step formula.
Equations
- DescriptiveComplexity.IFPLfp.vE d q = ⟨3 * DescriptiveComplexity.IFPLfp.hm d + ↑q, ⋯⟩
Instances For
Dependency graph
The spare variable, the accumulator's predecessor.
Equations
Instances For
Dependency graph
The first n variables of the evaluation block.
Equations
- DescriptiveComplexity.IFPLfp.eSel d hn q = DescriptiveComplexity.IFPLfp.vE d ⟨↑q, ⋯⟩
Instances For
Dependency graph
The atom tuple of a relation variable i, inside the x̄ block.
Equations
Instances For
Dependency graph
The first copy.
Equations
Instances For
Dependency graph
The last copy.
Equations
Instances For
Dependency graph
Atom builders #
An atom of an answer variable.
Equations
- DescriptiveComplexity.IFPLfp.rAt d i sel = { idx := DescriptiveComplexity.IFPLfp.rIx d i, args := sel }
Instances For
Dependency graph
An atom S j i (t̄, x̄).
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
An atom N j i (t̄, x̄).
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
A truth or falsity atom of a subformula at a stage.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
An accumulator atom of a subformula at a stage.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The rules of the translated program #
The relation variables, as a list.
Equations
Instances For
Dependency graph
Dependency graph
The stage-successor pairs of copies: within one copy, or crossing to the
next (as in DescriptiveComplexity.LFPHorn.stagePairs).
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Dependency graph
The guard stepping from stage (j, t̄) to stage (j', t̄'): the successor
tuple within a copy, the wrap-around between consecutive copies.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The root subformula of a variable's step formula.
Equations
Instances For
Dependency graph
The evaluation selector of the root subformula is the atom tuple.
Equations
Instances For
Dependency graph
The stage rules #
Carry: a derived atom stays derived at the next stage.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Derive: an atom whose step formula is true at a stage is derived at the next stage. This is where inflation is used: the new stage is the old one plus what the step formulas add.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Base: at the first stage, nothing is derived.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Complement step: an underived atom whose step formula is false at a stage stays underived at the next stage. This is where inflation pays: non-membership in the next stage is a conjunction of two positive atoms.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Read-off: the answer variables hold the maximal stage.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The dual evaluator #
A term of a subformula, as a term of the guard vocabulary over the evaluation variables.
Equations
- DescriptiveComplexity.IFPLfp.evTerm d hn t = FirstOrder.Language.Term.relabel (Sum.elim (fun (e : Empty) => e.elim) (DescriptiveComplexity.IFPLfp.eSel d hn)) (DescriptiveComplexity.stripTerm t)
Instances For
Dependency graph
The rules evaluating one subformula of a step formula at the stages, by
shape: the dual T/F derivation, with base-vocabulary atoms and equalities
as guards, block atoms reading S/N at the current stage, and the
accumulator walking the order under a universal quantifier.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
All evaluation rules: every stage copy, every variable, every subformula of its step formula.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The rules of the translated program.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The translated definition #
The arities of the answer variables are those of the original block.
Dependency graph
The translated FO(LFP) definition: the rules above, with the original
output sentence transported along the answer-variable injection
(DescriptiveComplexity.SOBlock.homLHom).
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The canonical assignment #
Over a fixed ordered structure, each relation variable of the translated
block has an intended value; the correctness proof (to come) will show that
the least model of the rules is exactly this assignment. Every predicate is a
named definition, so reduction stops at it (the
DescriptiveComplexity.FixedPointHorn discipline).
The rank of a stage: its position in the lexicographic order of the pairs of a copy index and a stage tuple.
Equations
Instances For
Dependency graph
A stage of the inflationary iteration, at a stage index.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The complement of a stage of the inflationary iteration.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
The structure interpreting the expanded vocabulary at a stage of the iteration – the structure the step formulas are read in there.
Equations
Instances For
Dependency graph
Truth of a subformula of a step formula at a stage of the iteration.
Equations
- DescriptiveComplexity.IFPLfp.evalT d A r ψ v = ψ.Realize default v
Instances For
Dependency graph
The intended accumulator of a universally quantified subformula at a stage: the quantified subformula holds up to the last argument. Other subformulas have no accumulator; theirs is empty.
Equations
Instances For
Dependency graph
The canonical assignment: the limit on the answer variables, the stages
and their complements on S/N, truth and falsity of the step formulas'
subformulas at the stages, and the accumulators.
Equations
- One or more equations did not get rendered due to their size.
- DescriptiveComplexity.IFPLfp.canonAssign d A (Sum.inl i) = fun (x : Fin ((DescriptiveComplexity.IFPLfp.trBlock d).arity (Sum.inl i)) → A) => d.inflLimit A i x
- DescriptiveComplexity.IFPLfp.canonAssign d A (Sum.inr (Sum.inl (true, j, i))) = DescriptiveComplexity.IFPLfp.canonS d A j i
- DescriptiveComplexity.IFPLfp.canonAssign d A (Sum.inr (Sum.inl (false, j, i))) = DescriptiveComplexity.IFPLfp.canonN d A j i
Instances For
Dependency graph
Atom characterizations under the canonical assignment #
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
The accumulator of ∀, at an explicit snoc tuple.
Dependency graph
The stage walk, quantitatively #
The interface the correctness inductions consume: the first stage has rank
0, a stageG step raises the rank by one, and the last stage's rank is
beyond the atom count – so the stage read off by the answer rules is the
inflationary limit.
Dependency graph
Dependency graph
A cover of stages, as a realized stage guard.
Dependency graph
A cover of stages is a stage pair.
Dependency graph
A stageG step raises the stage rank by one.
Dependency graph
Dependency graph
The stage at the top rank is the inflationary limit.
Dependency graph
Soundness: the canonical assignment satisfies the rules #
The value of a term of the expanded vocabulary at a stage.
Equations
Instances For
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Truth of a step formula at a stage is one application of the step.
Dependency graph
Dependency graph
The evaluation tuple of a wider context, as a snoc.
Dependency graph
The stage rules are sound #
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
The evaluator is sound #
Dependency graph
All rules are sound #
Dependency graph
Completeness: every canonical fact is derivable #
Assembling a valuation of the shared variables from its blocks.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Extending a tuple to a wider block, junk-padded.
Equations
- DescriptiveComplexity.IFPLfp.padF f p = if h : ↑p < m then f ⟨↑p, h⟩ else Classical.arbitrary A
Instances For
Dependency graph
Dependency graph
Dependency graph
Membership of the rules in the program #
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
Dependency graph
The subformula relations are derivable #
The dual evaluator is complete at a stage: given that the stage and its complement are derivable there, truth and falsity of every subformula of every step formula are derivable, by induction on the subformula.
Dependency graph
The stages and their complements are derivable #
The stage walk is complete: at every stage index, the stage and its complement are derivable – by induction along the cover walk of the stage order, the evaluator supplying the step formulas' values at the predecessor stage.
Dependency graph
The answer variables are derivable #
Every atom of the inflationary limit is derivable on the answer variables: read the stage at the top of the walk.
Dependency graph
Assembly: the capture of the inflationary limit #
The answer variables of the least model are the inflationary limit: soundness bounds the least model by the canonical assignment, and completeness derives every limit atom.
Dependency graph
The translated definition means the inflationary definition.
Dependency graph
Every FO(≤, IFP) definition is an FO(LFP) definition: the hard half of the capture theorem FO(≤, IFP) = PTIME – translate the inflationary iteration into a stage walk with a dual truth/falsity evaluator for the step formulas.
Dependency graph
FO(≤, IFP) = FO(LFP) (Gurevich–Shelah 1986: on ordered structures, and indeed on all structures, the inflationary fixed point adds no power over the least fixed point; here the ordered capture, proved by translation in both directions).
Dependency graph
The capture theorem FO(≤, IFP) = PTIME: a problem is FO(≤, IFP) definable exactly when it is in PTIME.