Documentation

Graphon.RelationalSignature

Relational signatures and their structure carriers (AHK umbrella #103, R0 design checkpoint) #

A deliberately small, dependency-light checkpoint (issue #110) that locks the carrier design for the generic Aldous–Hoover–Kallenberg program before R1/R2 build size vectors, sortwise embeddings, topology, and measure theory on top of it. There is no topology, no probability, no projective extension, and no extremality here — only the data design and the sortwise-map machinery that the later layers will reuse, so the carrier decision stays easy to revise.

Contents #

Design decisions locked here #

External representation theorem this program targets (R0 acceptance item) #

The functional representation formalized in R4 (#107) is the Aldous–Hoover–Kallenberg theorem. In Kallenberg, Probabilistic Symmetries and Invariance Principles (Springer, 2005), §7.5: Theorem 7.22 is the jointly exchangeable representation of an array X : ℕ^d → E as X_J = f((ξ_{J'})_{J' ⊆ J}) (measurable f, i.i.d. U[0,1] latents ξ indexed by the subsets J' ⊆ J), and Corollary 7.23 is its separately exchangeable, fixed-dimensional consequence. The general multi-sorted action here mixes joint and separate symmetries, so it is not literally either single statement — R1/R2 make the exact mixture explicit. For relational structures the latents are indexed by finite subsets of tagged vertices Σ s : S.Srt, ℕ; R4 formalizes the dissociated specialization without the empty-subset latent ξ_∅, and R5 (#108) restores the full general-law form with ξ_∅. Locating and confirming these exact statements against the printing is part of R0's acceptance.

structure RelSignature :
Type (u + 1)

A purely relational, multi-sorted signature: sort labels Srt, relation symbols Rel, an arity for each relation, and the sort argSort R i of each argument position i of R. No function symbols or constants. (The field is Srt because Sort is a reserved token in Lean 4.)

  • Srt : Type u

    The type of sort labels.

  • Rel : Type u

    The type of relation symbols.

  • arity : self.Rel

    The arity of each relation symbol.

  • argSort (R : self.Rel) : Fin (self.arity R)self.Srt

    The sort of each argument position of each relation.

Instances For
    @[reducible, inline]
    abbrev RelSignature.RelCoord (S : RelSignature) (V : S.SrtType v) :
    Type (max v u_1)

    A coordinate of a relational structure over the sort-indexed value family V: a relation symbol R together with a value V (argSort R i) in each argument position i.

    Equations
    Instances For
      @[reducible, inline]
      abbrev RelSignature.RelStructure (S : RelSignature) (V : S.SrtType v) :
      Type (max v u_1)

      A relational structure over the value family V: a Boolean value at every coordinate (whether the tuple stands in the relation). Reducible so that it transparently inherits the Boolean-product topology and measurable-space structure (R1b).

      Equations
      Instances For

        Arity positivity, kept as an external predicate rather than a field of RelSignature, so nullary relations can be added later without changing the signature.

        Equations
        Instances For
          @[reducible, inline]
          abbrev RelSignature.Vfinite {S : RelSignature} (n : S.Srt) :
          S.SrtType

          The finite value carrier for a size vector n : S.Srt → ℕ: sort s has n s vertices.

          Equations
          Instances For
            @[reducible, inline]

            The infinite value carrier: every sort has vertex set .

            Equations
            Instances For
              def RelSignature.RelCoord.map {S : RelSignature} {V : S.SrtType u_1} {W : S.SrtType u_2} (f : (s : S.Srt) → V sW s) :
              S.RelCoord VS.RelCoord W

              The action of a sortwise family of maps f : ∀ s, V s → W s on coordinates: relabel each argument by the map for its sort, keeping the relation symbol. This is the coordinate half of the relabelling / consistency machinery R1 and R2 will build on.

              Equations
              Instances For
                def RelSignature.RelStructure.comap {S : RelSignature} {V : S.SrtType u_1} {W : S.SrtType u_2} (f : (s : S.Srt) → V sW s) :

                The pullback of a structure along a sortwise family of maps: comap f g asks whether the f-image tuple stands in g. (For a sortwise permutation this is the generic relabelling action.)

                Equations
                Instances For
                  @[simp]
                  theorem RelSignature.RelStructure.comap_apply {S : RelSignature} {V : S.SrtType u_1} {W : S.SrtType u_2} (f : (s : S.Srt) → V sW s) (g : S.RelStructure W) (c : S.RelCoord V) :
                  comap f g c = g (RelCoord.map f c)
                  @[simp]
                  theorem RelSignature.RelCoord.map_fst {S : RelSignature} {V : S.SrtType u_1} {W : S.SrtType u_2} (f : (s : S.Srt) → V sW s) (c : S.RelCoord V) :
                  (map f c).fst = c.fst

                  Worked examples #

                  The example signatures are abbrevs (reducible) so that the acceptance checks reduce by rfl; R1 will introduce its own opaque definitions.

                  @[reducible, inline]

                  Directed graphs: one sort, one binary relation, ordered arguments, diagonal allowed (the R1 instance underlying #85).

                  Equations
                  Instances For
                    @[reducible, inline]

                    Bipartite / separately exchangeable: two sorts, one binary relation whose first argument is the first sort and second argument the second sort.

                    Equations
                    Instances For
                      @[reducible, inline]

                      A one-sort ternary relation — the smallest signature that exercises repeated argument coordinates (the equality-pattern design of R4/#107).

                      Equations
                      Instances For
                        @[reducible, inline]

                        A ternary coordinate (i, i, j) with the first two arguments equal — the design admits repeated coordinates, and their equality pattern is intrinsic to the tuple.

                        Equations
                        Instances For
                          @[reducible, inline]

                          An example bipartite coordinate: the ordered pair (a, b) with a in the first sort and b in the second.

                          Equations
                          Instances For