Expose bundles and apply so renames to IterProd

Signed-off-by: Danila Fedorin <danila.fedorin@gmail.com>
This commit is contained in:
Danila Fedorin 2024-02-11 21:10:51 -08:00
parent 6e26aa1580
commit bfb32092c2

View File

@ -21,17 +21,14 @@ IterProd k = iterate k (λ t → A × t) B
-- records, perform the recursion, and unpackage.
private module _ where
BLattice : Lattice B
BLattice = record
lattice : {k : } Lattice (IterProd k)
lattice {0} = record
{ _≈_ = _≈₂_
; _⊔_ = _⊔₂_
; _⊓_ = _⊓₂_
; isLattice = lB
}
IterProdLattice : {k : } Lattice (IterProd k)
IterProdLattice {0} = BLattice
IterProdLattice {suc k'} = record
lattice {suc k'} = record
{ _≈_ = _≈_
; _⊔_ = _⊔_
; _⊓_ = _⊓_
@ -39,7 +36,7 @@ private module _ where
}
where
Right : Lattice (IterProd k')
Right = IterProdLattice {k'}
Right = lattice {k'}
open import Lattice.Prod
_≈₁_ (Lattice._≈_ Right)
@ -48,7 +45,7 @@ private module _ where
lA (Lattice.isLattice Right)
module _ (k : ) where
open Lattice.Lattice (IterProdLattice {k}) public
open Lattice.Lattice (lattice {k}) public
module _ (≈₁-dec : IsDecidable _≈₁_) (≈₂-dec : IsDecidable _≈₂_)
(h₁ h₂ : )
@ -67,8 +64,8 @@ module _ (≈₁-dec : IsDecidable _≈₁_) (≈₂-dec : IsDecidable _≈₂_)
open IsFiniteHeightLattice isFiniteHeightLattice public
BFiniteHeightLattice : FiniteHeightAndDecEq B
BFiniteHeightLattice = record
finiteHeightAndDec : {k : } FiniteHeightAndDecEq (IterProd k)
finiteHeightAndDec {0} = record
{ height = h₂
; _≈_ = _≈₂_
; _⊔_ = _⊔₂_
@ -79,10 +76,7 @@ module _ (≈₁-dec : IsDecidable _≈₁_) (≈₂-dec : IsDecidable _≈₂_)
}
; ≈-dec = ≈₂-dec
}
IterProdFiniteHeightLattice : {k : } FiniteHeightAndDecEq (IterProd k)
IterProdFiniteHeightLattice {0} = BFiniteHeightLattice
IterProdFiniteHeightLattice {suc k'} = record
finiteHeightAndDec {suc k'} = record
{ height = h₁ + FiniteHeightAndDecEq.height Right
; _≈_ = P._≈_
; _⊔_ = P._⊔_
@ -94,7 +88,7 @@ module _ (≈₁-dec : IsDecidable _≈₁_) (≈₂-dec : IsDecidable _≈₂_)
; ≈-dec = ≈-dec ≈₁-dec (FiniteHeightAndDecEq.≈-dec Right)
}
where
Right = IterProdFiniteHeightLattice {k'}
Right = finiteHeightAndDec {k'}
open import Lattice.Prod
_≈₁_ (FiniteHeightAndDecEq._≈_ Right)
@ -103,10 +97,10 @@ module _ (≈₁-dec : IsDecidable _≈₁_) (≈₂-dec : IsDecidable _≈₂_)
lA (FiniteHeightAndDecEq.isLattice Right) as P
module _ (k : ) where
open FiniteHeightAndDecEq (IterProdFiniteHeightLattice {k}) using (isFiniteHeightLattice) public
open FiniteHeightAndDecEq (finiteHeightAndDec {k}) using (isFiniteHeightLattice) public
private
FHD = IterProdFiniteHeightLattice {k}
FHD = finiteHeightAndDec {k}
finiteHeightLattice : FiniteHeightLattice (IterProd k)
finiteHeightLattice = record