Why-provenance m-semiring Why[X] #
This file defines the Why provenance semiring Why α = Set (Set α).
Elements are sets of subsets of α (representing sets of witnesses). Addition
is union of families, and multiplication is pairwise union of witnesses.
Why α is idempotent but not absorptive when α is nonempty. It also
does not satisfy left-distributivity of multiplication over monus, contradicting
a claim in Amsterdamer, Deutch & Tannen, On the limitations of provenance for
queries with differences, Table on p. 4.
References #
Equations
- instCoeWhySet = { coe := Why.carrier }
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- instCommSemiringWithMonusWhy = { toSemiringWithMonus := instSemiringWithMonusWhy, mul_comm := ⋯ }
In Why[X], as long as X is non-empty, times is not distributive over monus. Note that this contradicts Amsterdamer, Deutch & Tannen, On the limitations of provenance for queries with differences, table page 4, which claims this semiring satisfies axiom A13.
There is no semiring homomorphism from BoolFunc Y to Why α (with α
inhabited) sending the variables to arbitrary values: Why α is not
absorptive (Why.not_absorptive), which contradicts var i + 1 = 1 in
BoolFunc Y.
The two natural expansions of HAVING (count = 2) for a three-tuple
group, (t₁ ⊗ t₂) ⊗ (𝟙 ⊖ t₃) ⊕ (t₁ ⊗ t₃) ⊗ (𝟙 ⊖ t₂) ⊕ (t₂ ⊗ t₃) ⊗ (𝟙 ⊖ t₁)
and (t₁ ⊗ t₂) ⊕ (t₁ ⊗ t₃) ⊕ (t₂ ⊗ t₃), are inequivalent in Why[X].
With t₁ = ⟨{{0}}⟩, t₂ = ⟨{{1}}⟩, t₃ = ⟨{∅}⟩ = 𝟙 over X = Fin 2, the
first expression has carrier {{0}, {1}} while the second has the strictly
larger carrier {{0, 1}, {0}, {1}}. The witness set {0, 1} separates
them.