From 90c7597b6f80e0bd5bb2a9a7245d097d40486518 Mon Sep 17 00:00:00 2001 From: Chloe Brown Date: Fri, 5 Mar 2021 00:22:20 +0000 Subject: Prove lemma 3.3 --- src/Cfe/Language/Construct/Union.agda | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/Cfe/Language/Construct') diff --git a/src/Cfe/Language/Construct/Union.agda b/src/Cfe/Language/Construct/Union.agda index 4ed0774..5099d04 100644 --- a/src/Cfe/Language/Construct/Union.agda +++ b/src/Cfe/Language/Construct/Union.agda @@ -25,7 +25,7 @@ module _ where infix 4 _≈ᵁ_ - infix 4 _∪_ + infix 6 _∪_ Union : List C → Set (a ⊔ b) Union l = l ∈ A ⊎ l ∈ B @@ -93,3 +93,9 @@ isCommutativeMonoid = record where module X≤Y = _≤_ X≤Y module U≤V = _≤_ U≤V + +∪-unique : ∀ {a aℓ b bℓ} {A : Language a aℓ} {B : Language b bℓ} → (∀ x → first A x → first B x → ⊥) → (𝕃.null A → 𝕃.null B → ⊥) → ∀ {l} → l ∈ A ∪ B → (l ∈ A × l ∉ B) ⊎ (l ∉ A × l ∈ B) +∪-unique fA∩fB≡∅ ¬nA∨¬nB {[]} (inj₁ []∈A) = inj₁ ([]∈A , ¬nA∨¬nB []∈A) +∪-unique fA∩fB≡∅ ¬nA∨¬nB {x ∷ l} (inj₁ xl∈A) = inj₁ (xl∈A , (λ xl∈B → fA∩fB≡∅ x (-, xl∈A) (-, xl∈B))) +∪-unique fA∩fB≡∅ ¬nA∨¬nB {[]} (inj₂ []∈B) = inj₂ (flip ¬nA∨¬nB []∈B , []∈B) +∪-unique fA∩fB≡∅ ¬nA∨¬nB {x ∷ l} (inj₂ xl∈B) = inj₂ ((λ xl∈A → fA∩fB≡∅ x (-, xl∈A) (-, xl∈B)) , xl∈B) -- cgit v1.2.3