The circuit of a system of rules #
A system of rules (DescriptiveComplexity.HornProgram) over an ordered
structure is drawn as a monotone circuit whose gates evaluate its least fixed
point: DescriptiveComplexity.CircNum.drawInterp.
- One disjunction gate per relation variable
iand per tuple, canonically padded (DescriptiveComplexity.Padding): the atomi(x̄). Its inputs – all on theleftwire, a disjunction of the circuit vocabulary being true as soon as some gate wired to its left is – are the rule instances deriving it: the rules whose head is that atom, at the valuations satisfying their guard. The guard is a formula of the input vocabulary, so it is evaluated by the wiring, not by the circuit. - One conjunction chain per rule
cand per valuationv̄of its variables: the gate(c, j, v̄)is the conjunction of thej-th body atom, atv̄, and of the gate(c, j + 1, v̄); past the last body atom, the gate is the constant1. So(c, 0, v̄)is “every body atom ofcholds atv̄”. - The outputs are the atoms of the relation variables
bit τ, compared first byτ, then lexicographically.
Nothing is stratified by stages: the circuit may have cycles, and the
evaluation of DescriptiveComplexity.GateVal, a least derivation, is the
least fixed point of the rules as it stands.
This file holds the interpretation and reads its relations; the evaluation is
DescriptiveComplexity.Problems.CircuitNumber.Hardness.
Tags #
The tags of the drawing: one per relation variable, for the atoms, and one per rule and position in its body, for the conjunction chains.
Equations
- DescriptiveComplexity.CircNum.DrawTag prog = (B.ι ⊕ (c : Fin (List.length prog)) × Fin ((DescriptiveComplexity.clauseAt prog c).body.length + 1))
Instances For
Dependency graph
The tag of the atoms of the relation variable i.
Equations
Instances For
Dependency graph
The tag of the j-th link of the conjunction chains of the rule c.
Equations
Instances For
Dependency graph
The interpretation #
The circuit of a system of rules, drawn inside an ordered structure,
with the atoms of the relation variables bit τ as outputs.
Equations
- One or more equations did not get rendered due to their size.