Structure-encoding validation belongs to P #
The explicit header, length, and one-hot conditions characterize exactly the
encoder's image. They are polynomial-time predicates by bounded quantification
over the arithmetic bit-access primitives. Thus recognizing valid encodings and
testing successful decoding belong to the existing machine class P.
This proves the validation part of the descriptive-complexity machine bridge.
ModelChecking.PolynomialTime combines it with fixed-formula evaluation to prove
first-order query languages belong to P. SecondOrder.PolynomialTime uses the
same validation predicate for its existential-SO certificate verifier.
Every encoded structure satisfies the explicit wire-format conditions.
Wire-format validation is equivalent to encoding a structure of the specified size.
Validation at the parsed universe size recognizes exactly all structure encodings.
Wire-format validation is polynomial-time when the string and universe size are.
Membership in the encoder's image is a polynomial-time predicate on every bit string.
Whether the existing exact decoder succeeds can be tested in polynomial time.
The binary language of valid encodings belongs to the actual deterministic machine class P.