Ordered interpretations in logarithmic space #
The encoded map of a fixed ordered interpretation with a domain formula is computed by the
domain-counting transducer of Cslib.Logic.FO.Interpretation.computableInLogSpace_encodedMapWith,
instantiated with the ordered formula compiler: canonical numeric atoms (order, BIT, 0, 1,
max) are computed from cardinality and indices, and no numeric tables are supplied. The
coordinates are enumerated by Fin.revPerm, so that tuple indices are lexicographic ranks. The
transducer checks the source shape and size before emitting output, then writes the unary count of
the domain tuples and each target relation table over their ranks.
A full-tuple interpretation is the instance with domain ⊤, through
FullTupleInterpretation.encodedMap_toDomainInterpretation; it has no separate program.
Main definitions #
Cslib.Logic.FO.Ordered.ModelChecker.formulaCompiler: the ordered formula compiler.
Main results #
Cslib.Logic.FO.Ordered.DomainInterpretation.encodedMap_eq_encodedMapWith: the encoded image is the output of the domain-counting transducer.Cslib.Logic.FO.Ordered.DomainInterpretation.computableInLogSpace_encodedMap: ordered interpretations with a domain formula are computed in logarithmic space.Cslib.Logic.FO.Ordered.IsDomainMap.exists_computableInLogSpace: domain maps are simulated by logspace maps of encodings, the hypothesis ofCslib.Complexity.ManyOneReducibleBy.lift.Cslib.Logic.FO.Ordered.DomainInterpretation.logSpaceReducible: admissible interpretations reducing one ordered query to another induce logspace reductions of their encodings.Cslib.Logic.FO.Ordered.Reduces.logSpaceReducible: first-order reductions are logspace reductions;Reduces.encodedLanguage_mem_LandReduces.encodedLanguage_mem_Pgive closure ofLandP.Cslib.Logic.FO.Ordered.FullTupleInterpretation.computableInLogSpace_encodedMap: the full-domain instance.Cslib.Logic.FO.Ordered.FullTupleInterpretation.logSpaceReducible_onSentence: the exact map reduces the pulled-back ordered query to the target query.
References #
- N. Immerman, Descriptive Complexity, Theorem 3.1 and Propositions 3.5/3.10. Capture remains open.
- The order-free interpretation writer, shared counter-program simulation and Christian Reitwiessner's native arithmetic are reused with their source authorship retained.
The ordered formula compiler: canonical numeric atoms are computed natively, input atoms read from the input tables, and inputs of size below two are inadmissible.
Instances For
The encoded image is the output of the domain-counting transducer with the ordered formula compiler, numbering coordinates in reverse so that tuple indices are lexicographic ranks.
Ordered interpretations with a domain formula are computed in logarithmic space. For a fixed interpretation and fixed vocabularies, the encoded image, numbered by lexicographic rank of the domain tuples, is computed by a native transducer whose work space is logarithmic in the full encoded input length. The domain may have fewer than two tuples.
Domain maps are simulated in logarithmic space. Every image map of an admissible ordered interpretation with a domain formula is simulated, through partial decoding, by a map of encodings computable in logarithmic space: its encoded map.
Ordered interpretations are logspace reductions. An admissible ordered interpretation with
a domain formula whose image map reduces the query K to K' induces a logspace many-one
reduction between their encoded query languages.
First-order reductions are logspace reductions [Immerman1999, Theorem 3.1 and the remark
after Definition 2.14]: a first-order reduction of the ordered query K to K' induces a
logspace many-one reduction between their encoded query languages. The numeric certificate of the
reduction is not used; the transducer computes ranks by counting. The closure of L and P under
first-order reductions, encodedLanguage_mem_L and encodedLanguage_mem_P, are the corollaries of
[Immerman1999, Proposition 3.10].
Encoded ordered queries in L are closed under first-order reductions.
Encoded ordered queries in P are closed under first-order reductions.
The actual canonical full-tuple encoded map is computed by a native logspace transducer. The dimension, formulas and vocabularies are fixed. Space is logarithmic in full encoded input length; the unary target size and relation tables are streamed through the write-only output. It is the domain-counting transducer for the full domain.
For positive tuple dimension, the encoded map belongs to the target ordered query language if and only if the source belongs to the pulled-back ordered query language.
For positive tuple dimension, the canonical full-tuple encoded map is a logspace many-one reduction from the pulled-back ordered query language to the target ordered query language.