Skip to content

Commit 9a5014f

Browse files
authored
Merge branch 'master' into unary-disjoint-relation
2 parents 40ac5a0 + 3b9f62b commit 9a5014f

File tree

580 files changed

+2780
-1945
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

580 files changed

+2780
-1945
lines changed

CHANGELOG.md

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ Bug-fixes
1313
to `#-sym` in order to avoid overloaded projection.
1414
`irrefl` and `cotrans` are similarly renamed for the sake of consistency.
1515

16+
* In `Algebra.Definitions.RawMagma` and `Relation.Binary.Construct.Interior.Symmetric`,
17+
the record constructors `_,_` incorrectly had no declared fixity. They have been given
18+
the fixity `infixr 4 _,_`, consistent with that of `Data.Product.Base`.
19+
1620
Non-backwards compatible changes
1721
--------------------------------
1822

@@ -24,6 +28,9 @@ Non-backwards compatible changes
2428
Minor improvements
2529
------------------
2630

31+
* Moved the concept `Irrelevant` of irrelevance (h-proposition) from `Relation.Nullary`
32+
to its own dedicated module `Relation.Nullary.Irrelevant`.
33+
2734
Deprecated modules
2835
------------------
2936

@@ -36,6 +43,12 @@ Deprecated names
3643
_∤∤_ ↦ _∦_
3744
```
3845

46+
* In `Algebra.Lattice.Properties.BooleanAlgebra`
47+
```agda
48+
⊥≉⊤ ↦ ¬⊥≈⊤
49+
⊤≉⊥ ↦ ¬⊤≈⊥
50+
```
51+
3952
* In `Algebra.Module.Consequences`
4053
```agda
4154
*ₗ-assoc+comm⇒*ᵣ-assoc ↦ *ₗ-assoc∧comm⇒*ᵣ-assoc
@@ -44,6 +57,18 @@ Deprecated names
4457
*ₗ-assoc+comm⇒*ₗ-*ᵣ-assoc ↦ *ₗ-assoc∧comm⇒*ₗ-*ᵣ-assoc
4558
```
4659

60+
* In `Algebra.Modules.Structures.IsLeftModule`:
61+
```agda
62+
uniqueˡ‿⁻ᴹ ↦ Algebra.Module.Properties.LeftModule.inverseˡ-uniqueᴹ
63+
uniqueʳ‿⁻ᴹ ↦ Algebra.Module.Properties.LeftModule.inverseʳ-uniqueᴹ
64+
```
65+
66+
* In `Algebra.Modules.Structures.IsRightModule`:
67+
```agda
68+
uniqueˡ‿⁻ᴹ ↦ Algebra.Module.Properties.RightModule.inverseˡ-uniqueᴹ
69+
uniqueʳ‿⁻ᴹ ↦ Algebra.Module.Properties.RightModule.inverseʳ-uniqueᴹ
70+
```
71+
4772
* In `Algebra.Properties.Magma.Divisibility`:
4873
```agda
4974
∣∣-sym ↦ ∥-sym
@@ -54,18 +79,35 @@ Deprecated names
5479
∤∤-respˡ-≈ ↦ ∦-respˡ-≈
5580
∤∤-respʳ-≈ ↦ ∦-respʳ-≈
5681
∤∤-resp-≈ ↦ ∦-resp-≈
82+
∣-respʳ-≈ ↦ ∣ʳ-respʳ-≈
83+
∣-respˡ-≈ ↦ ∣ʳ-respˡ-≈
84+
∣-resp-≈ ↦ ∣ʳ-resp-≈
85+
x∣yx ↦ x∣ʳyx
86+
xy≈z⇒y∣z ↦ xy≈z⇒y∣ʳz
5787
```
5888

5989
* In `Algebra.Properties.Monoid.Divisibility`:
6090
```agda
6191
∣∣-refl ↦ ∥-refl
6292
∣∣-reflexive ↦ ∥-reflexive
6393
∣∣-isEquivalence ↦ ∥-isEquivalence
94+
ε∣_ ↦ ε∣ʳ_
95+
∣-refl ↦ ∣ʳ-refl
96+
∣-reflexive ↦ ∣ʳ-reflexive
97+
∣-isPreorder ↦ ∣ʳ-isPreorder
98+
∣-preorder ↦ ∣ʳ-preorder
6499
```
65100

66101
* In `Algebra.Properties.Semigroup.Divisibility`:
67102
```agda
68103
∣∣-trans ↦ ∥-trans
104+
∣-trans ↦ ∣ʳ-trans
105+
```
106+
107+
* In `Algebra.Structures.Group`:
108+
```agda
109+
uniqueˡ-⁻¹ ↦ Algebra.Properties.Group.inverseˡ-unique
110+
uniqueʳ-⁻¹ ↦ Algebra.Properties.Group.inverseʳ-unique
69111
```
70112

71113
* In `Data.List.Base`:
@@ -95,10 +137,18 @@ Deprecated names
95137
New modules
96138
-----------
97139

140+
* `Algebra.Module.Properties.{Bimodule|LeftModule|RightModule}`.
141+
98142
* `Data.List.Base.{and|or|any|all}` have been lifted out into `Data.Bool.ListAction`.
99143

100144
* `Data.List.Base.{sum|product}` and their properties have been lifted out into `Data.Nat.ListAction` and `Data.Nat.ListAction.Properties`.
101145

146+
* `Data.List.Relation.Binary.Prefix.Propositional.Properties` showing the equivalence to left divisibility induced by the list monoid.
147+
148+
* `Data.List.Relation.Binary.Suffix.Propositional.Properties` showing the equivalence to right divisibility induced by the list monoid.
149+
150+
* `Data.Sign.Show` to show a sign
151+
102152
Additions to existing modules
103153
-----------------------------
104154

@@ -131,6 +181,44 @@ Additions to existing modules
131181
commutativeRing : CommutativeRing c ℓ → CommutativeRing (a ⊔ c) (a ⊔ ℓ)
132182
```
133183

184+
* In `Algebra.Modules.Properties`:
185+
```agda
186+
inverseˡ-uniqueᴹ : x +ᴹ y ≈ 0ᴹ → x ≈ -ᴹ y
187+
inverseʳ-uniqueᴹ : x +ᴹ y ≈ 0ᴹ → y ≈ -ᴹ x
188+
```
189+
190+
* In `Algebra.Properties.Magma.Divisibility`:
191+
```agda
192+
∣ˡ-respʳ-≈ : _∣ˡ_ Respectsʳ _≈_
193+
∣ˡ-respˡ-≈ : _∣ˡ_ Respectsˡ _≈_
194+
∣ˡ-resp-≈ : _∣ˡ_ Respects₂ _≈_
195+
x∣ˡxy : ∀ x y → x ∣ˡ x ∙ y
196+
xy≈z⇒x∣ˡz : ∀ x y {z} → x ∙ y ≈ z → x ∣ˡ z
197+
```
198+
199+
* In `Algebra.Properties.Monoid.Divisibility`:
200+
```agda
201+
ε∣ˡ_ : ∀ x → ε ∣ˡ x
202+
∣ˡ-refl : Reflexive _∣ˡ_
203+
∣ˡ-reflexive : _≈_ ⇒ _∣ˡ_
204+
∣ˡ-isPreorder : IsPreorder _≈_ _∣ˡ_
205+
∣ˡ-preorder : Preorder a ℓ _
206+
```
207+
208+
* In `Algebra.Properties.Semigroup.Divisibility`:
209+
```agda
210+
∣ˡ-trans : Transitive _∣ˡ_
211+
x∣ʳy⇒x∣ʳzy : x ∣ʳ y → x ∣ʳ z ∙ y
212+
x∣ʳy⇒xz∣ʳyz : x ∣ʳ y → x ∙ z ∣ʳ y ∙ z
213+
x∣ˡy⇒zx∣ˡzy : x ∣ˡ y → z ∙ x ∣ˡ z ∙ y
214+
x∣ˡy⇒x∣ˡyz : x ∣ˡ y → x ∣ˡ y ∙ z
215+
```
216+
217+
* In `Algebra.Properties.CommutativeSemigroup.Divisibility`:
218+
```agda
219+
∙-cong-∣ : x ∣ y → a ∣ b → x ∙ a ∣ y ∙ b
220+
```
221+
134222
* In `Data.List.Properties`:
135223
```agda
136224
map-applyUpTo : ∀ (f : ℕ → A) (g : A → B) n → map g (applyUpTo f n) ≡ applyUpTo (g ∘ f) n
@@ -144,13 +232,28 @@ Additions to existing modules
144232
filter-↭ : ∀ (P? : Pred.Decidable P) → xs ↭ ys → filter P? xs ↭ filter P? ys
145233
```
146234

235+
* In `Relation.Binary.Construct.Add.Infimum.Strict`:
236+
```agda
237+
<₋-accessible-⊥₋ : Acc _<₋_ ⊥₋
238+
<₋-accessible[_] : Acc _<_ x → Acc _<₋_ [ x ]
239+
<₋-wellFounded : WellFounded _<_ → WellFounded _<₋_
240+
```
241+
242+
* In `Relation.Nullary.Decidable.Core`:
243+
```agda
244+
⊤-dec : Dec {a} ⊤
245+
⊥-dec : Dec {a} ⊥
246+
```
247+
147248
* In `Relation.Unary`:
148249
```agda
149250
_⊥_ _⊥′_ : Pred A ℓ₁ → Pred A ℓ₂ → Set _
150251
```
151252

152253
* In `Relation.Unary.Properties`:
153254
```agda
255+
≬-symmetric : Sym _≬_ _≬_
256+
⊥-symmetric : Sym _⊥_ _⊥_
154257
≬-sym : Symmetric _≬_
155258
⊥-sym : Symmetric _⊥_
156259
≬⇒¬⊥ : _≬_ ⇒ (¬_ ∘₂ _⊥_)

src/Algebra/Apartness/Bundles.agda

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ open import Relation.Binary.Core using (Rel)
1313
open import Relation.Binary.Bundles using (ApartnessRelation)
1414
open import Algebra.Core using (Op₁; Op₂)
1515
open import Algebra.Bundles using (CommutativeRing)
16-
open import Algebra.Apartness.Structures
16+
open import Algebra.Apartness.Structures using (IsHeytingCommutativeRing; IsHeytingField)
1717

1818
record HeytingCommutativeRing c ℓ₁ ℓ₂ : Set (suc (c ⊔ ℓ₁ ⊔ ℓ₂)) where
1919
infix 8 -_

src/Algebra/Bundles/Raw.agda

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,10 @@
88

99
module Algebra.Bundles.Raw where
1010

11-
open import Algebra.Core
11+
open import Algebra.Core using (Op₁; Op₂)
1212
open import Relation.Binary.Core using (Rel)
1313
open import Relation.Binary.Bundles.Raw using (RawSetoid)
1414
open import Level using (suc; _⊔_)
15-
open import Relation.Nullary.Negation.Core using (¬_)
1615

1716
------------------------------------------------------------------------
1817
-- Raw bundles with 1 unary operation & 1 element

src/Algebra/Consequences/Base.agda

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@
1010
module Algebra.Consequences.Base
1111
{a} {A : Set a} where
1212

13-
open import Algebra.Core
13+
open import Algebra.Core using (Op₁; Op₂)
1414
open import Algebra.Definitions
15-
open import Data.Sum.Base
16-
open import Relation.Binary.Core
15+
using (Selective; Idempotent; SelfInverse; Involutive)
16+
open import Data.Sum.Base using (_⊎_; reduce)
17+
open import Relation.Binary.Core using (Rel)
1718
open import Relation.Binary.Definitions using (Reflexive)
1819

1920
module _ {ℓ} {_•_ : Op₂ A} (_≈_ : Rel A ℓ) where

src/Algebra/Consequences/Propositional.agda

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ open import Relation.Binary.PropositionalEquality.Core
1919
open import Relation.Binary.PropositionalEquality.Properties
2020
using (setoid)
2121
open import Relation.Unary using (Pred)
22+
open import Algebra.Core using (Op₁; Op₂)
2223

23-
open import Algebra.Core
2424
open import Algebra.Definitions {A = A} _≡_
2525
import Algebra.Consequences.Setoid (setoid A) as Base
2626

src/Algebra/Consequences/Setoid.agda

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
{-# OPTIONS --cubical-compatible --safe #-}
99

10-
open import Relation.Binary.Core using (Rel)
1110
open import Relation.Binary.Bundles using (Setoid)
1211
open import Relation.Binary.Definitions
1312
using (Substitutive; Symmetric; Total)
@@ -22,6 +21,7 @@ open import Data.Product.Base using (_,_)
2221
open import Function.Base using (_$_; id; _∘_)
2322
open import Function.Definitions
2423
import Relation.Binary.Consequences as Bin
24+
open import Relation.Binary.Core using (Rel)
2525
open import Relation.Binary.Reasoning.Setoid S
2626
open import Relation.Unary using (Pred)
2727

src/Algebra/Construct/Add/Identity.agda

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,18 @@
99

1010
module Algebra.Construct.Add.Identity where
1111

12-
open import Algebra.Bundles
12+
open import Algebra.Bundles using (Semigroup; Monoid)
1313
open import Algebra.Core using (Op₂)
1414
open import Algebra.Definitions
15-
open import Algebra.Structures
16-
open import Relation.Binary.Construct.Add.Point.Equality renaming (_≈∙_ to lift≈)
15+
using (Congruent₂; Associative; LeftIdentity; RightIdentity; Identity)
16+
open import Algebra.Structures using (IsMagma; IsSemigroup; IsMonoid)
1717
open import Data.Product.Base using (_,_)
1818
open import Level using (Level; _⊔_)
19-
open import Relation.Binary.Core
20-
open import Relation.Binary.Definitions
21-
open import Relation.Binary.Structures
22-
open import Relation.Nullary.Construct.Add.Point
19+
open import Relation.Binary.Construct.Add.Point.Equality renaming (_≈∙_ to lift≈)
20+
open import Relation.Binary.Core using (Rel)
21+
open import Relation.Binary.Definitions using (Reflexive)
22+
open import Relation.Binary.Structures using (IsEquivalence)
23+
open import Relation.Nullary.Construct.Add.Point using (Pointed; [_]; ∙)
2324

2425
private
2526
variable
@@ -101,3 +102,4 @@ monoid : Semigroup a (a ⊔ ℓ) → Monoid a (a ⊔ ℓ)
101102
monoid S = record
102103
{ isMonoid = isMonoid S.isSemigroup
103104
} where module S = Semigroup S
105+

src/Algebra/Construct/Initial.agda

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ open import Algebra.Bundles.Raw
2121
open import Algebra.Core using (Op₂)
2222
open import Algebra.Definitions using (Congruent₂)
2323
open import Algebra.Structures using (IsMagma; IsSemigroup; IsBand)
24-
open import Data.Empty.Polymorphic
24+
open import Data.Empty.Polymorphic using (⊥)
2525
open import Relation.Binary.Core using (Rel)
2626
open import Relation.Binary.Structures using (IsEquivalence)
2727
open import Relation.Binary.Definitions

src/Algebra/Construct/LiftedChoice.agda

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ open import Algebra
1010

1111
module Algebra.Construct.LiftedChoice where
1212

13-
open import Algebra.Consequences.Base
13+
open import Algebra.Consequences.Base using (sel⇒idem)
1414
open import Data.Sum.Base as Sum using (_⊎_; inj₁; inj₂; [_,_]; [_,_]′)
1515
open import Data.Product.Base using (_×_; _,_)
1616
open import Function.Base using (const; _$_)

src/Algebra/Construct/NaturalChoice/Base.agda

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
{-# OPTIONS --cubical-compatible --safe #-}
99

10-
open import Algebra.Core
10+
open import Algebra.Core using (Op₂)
1111
open import Level as L hiding (_⊔_)
1212
open import Function.Base using (flip)
1313
open import Relation.Binary.Bundles using (TotalPreorder)

src/Algebra/Construct/NaturalChoice/Max.agda

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@ open import Relation.Binary.Bundles using (TotalOrder)
1111
module Algebra.Construct.NaturalChoice.Max
1212
{a ℓ₁ ℓ₂} (totalOrder : TotalOrder a ℓ₁ ℓ₂) where
1313

14-
open import Algebra.Core
15-
open import Algebra.Definitions
16-
open import Algebra.Construct.NaturalChoice.Base
14+
open import Algebra.Core using (Op₂)
15+
open import Algebra.Construct.NaturalChoice.Base using (MaxOperator)
1716
open import Relation.Binary.Construct.Flip.EqAndOrd using ()
1817
renaming (totalOrder to flip)
1918

src/Algebra/Construct/NaturalChoice/MaxOp.agda

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,21 @@
77

88
{-# OPTIONS --cubical-compatible --safe #-}
99

10-
open import Algebra.Core
11-
open import Algebra.Construct.NaturalChoice.Base
12-
import Algebra.Construct.NaturalChoice.MinOp as MinOp
13-
open import Function.Base using (flip)
14-
open import Relation.Binary.Core using (_Preserves_⟶_)
10+
open import Algebra.Construct.NaturalChoice.Base using (MaxOperator; MaxOp⇒MinOp)
1511
open import Relation.Binary.Bundles using (TotalPreorder)
16-
open import Relation.Binary.Construct.Flip.EqAndOrd using ()
17-
renaming (totalPreorder to flipOrder)
1812

1913
module Algebra.Construct.NaturalChoice.MaxOp
2014
{a ℓ₁ ℓ₂} {O : TotalPreorder a ℓ₁ ℓ₂} (maxOp : MaxOperator O)
2115
where
2216

23-
open TotalPreorder O renaming (Carrier to A; _≲_ to _≤_)
17+
import Algebra.Construct.NaturalChoice.MinOp as MinOp
18+
open import Algebra.Core using (Op₂)
19+
open import Function.Base using (flip)
2420
open MaxOperator maxOp
21+
open import Relation.Binary.Core using (_Preserves_⟶_)
22+
open import Relation.Binary.Construct.Flip.EqAndOrd using ()
23+
renaming (totalPreorder to flipOrder)
24+
open TotalPreorder O renaming (Carrier to A; _≲_ to _≤_)
2525

2626
-- Max is just min with a flipped order
2727

src/Algebra/Construct/NaturalChoice/Min.agda

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,18 @@
66

77
{-# OPTIONS --cubical-compatible --safe #-}
88

9-
open import Algebra.Core
10-
open import Algebra.Bundles
11-
open import Algebra.Construct.NaturalChoice.Base
12-
open import Data.Sum.Base using (inj₁; inj₂; [_,_])
13-
open import Data.Product.Base using (_,_)
14-
open import Function.Base using (id)
159
open import Relation.Binary.Bundles using (TotalOrder)
16-
import Algebra.Construct.NaturalChoice.MinOp as MinOp
1710

1811
module Algebra.Construct.NaturalChoice.Min
1912
{a ℓ₁ ℓ₂} (O : TotalOrder a ℓ₁ ℓ₂)
2013
where
2114

15+
open import Algebra.Core using (Op₂)
16+
open import Algebra.Construct.NaturalChoice.Base
17+
import Algebra.Construct.NaturalChoice.MinOp as MinOp
18+
open import Data.Sum.Base using (inj₁; inj₂; [_,_])
19+
open import Data.Product.Base using (_,_)
20+
open import Function.Base using (id)
2221
open TotalOrder O renaming (Carrier to A)
2322

2423
------------------------------------------------------------------------

src/Algebra/Construct/NaturalChoice/MinMaxOp.agda

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,22 +7,20 @@
77

88
{-# OPTIONS --cubical-compatible --safe #-}
99

10-
open import Algebra.Core
11-
open import Algebra.Bundles
12-
open import Algebra.Construct.NaturalChoice.Base
13-
open import Data.Sum.Base as Sum using (inj₁; inj₂; [_,_])
14-
open import Data.Product.Base using (_,_)
15-
open import Function.Base using (id; _∘_; flip)
16-
open import Relation.Binary.Core using (_Preserves_⟶_)
10+
open import Algebra.Construct.NaturalChoice.Base using (MinOperator; MaxOperator)
1711
open import Relation.Binary.Bundles using (TotalPreorder)
18-
open import Relation.Binary.Consequences
1912

2013
module Algebra.Construct.NaturalChoice.MinMaxOp
2114
{a ℓ₁ ℓ₂} {O : TotalPreorder a ℓ₁ ℓ₂}
2215
(minOp : MinOperator O)
2316
(maxOp : MaxOperator O)
2417
where
2518

19+
open import Data.Sum.Base as Sum using (inj₁; inj₂; [_,_])
20+
open import Data.Product.Base using (_,_)
21+
open import Function.Base using (id; _∘_; flip)
22+
open import Relation.Binary.Core using (_Preserves_⟶_)
23+
2624
open TotalPreorder O renaming
2725
( Carrier to A
2826
; _≲_ to _≤_

0 commit comments

Comments
 (0)