@@ -19,7 +19,7 @@ module Function.Structures {a b ℓ₁ ℓ₂}
19
19
20
20
open import Data.Product.Base as Product using (∃; _×_; _,_)
21
21
open import Function.Base
22
- open import Function.Consequences
22
+ open import Function.Consequences.Setoid
23
23
open import Function.Definitions
24
24
open import Level using (_⊔_)
25
25
@@ -67,15 +67,8 @@ record IsSurjection (f : A → B) : Set (a ⊔ b ⊔ ℓ₁ ⊔ ℓ₂) where
67
67
68
68
open IsCongruent isCongruent public
69
69
70
- private module S = Section _≈₂_ surjective
71
-
72
- open S public using (section; inverseˡ)
73
-
74
- strictlySurjective : StrictlySurjective _≈₂_ f
75
- strictlySurjective = S.strictlySurjective Eq₁.refl
76
-
77
- strictlyInverseˡ : StrictlyInverseˡ _≈₂_ f section
78
- strictlyInverseˡ _ = inverseˡ Eq₁.refl
70
+ open Section Eq₁.setoid Eq₂.setoid surjective public
71
+ using (section; inverseˡ; strictlyInverseˡ; strictlySurjective)
79
72
80
73
81
74
record IsBijection (f : A → B) : Set (a ⊔ b ⊔ ℓ₁ ⊔ ℓ₂) where
@@ -94,16 +87,16 @@ record IsBijection (f : A → B) : Set (a ⊔ b ⊔ ℓ₁ ⊔ ℓ₂) where
94
87
; surjective = surjective
95
88
}
96
89
97
- open IsSurjection isSurjection public
98
- using (strictlySurjective; section; inverseˡ; strictlyInverseˡ)
90
+ private module S = Section Eq₁.setoid Eq₂.setoid surjective
99
91
100
- private module S = Section _≈₂_ surjective
92
+ open S public
93
+ using (strictlySurjective; section; inverseˡ; strictlyInverseˡ)
101
94
102
95
inverseʳ : Inverseʳ _≈₁_ _≈₂_ f section
103
- inverseʳ = S.inverseʳ injective Eq₁.refl Eq₂.trans
96
+ inverseʳ = S.inverseʳ injective
104
97
105
98
strictlyInverseʳ : StrictlyInverseʳ _≈₁_ f section
106
- strictlyInverseʳ _ = inverseʳ Eq₂.refl
99
+ strictlyInverseʳ = S.strictlyInverseʳ injective
107
100
108
101
109
102
------------------------------------------------------------------------
@@ -125,7 +118,7 @@ record IsLeftInverse (to : A → B) (from : B → A) : Set (a ⊔ b ⊔ ℓ₁
125
118
isSurjection : IsSurjection to
126
119
isSurjection = record
127
120
{ isCongruent = isCongruent
128
- ; surjective = inverseˡ⇒surjective _≈₂_ inverseˡ
121
+ ; surjective = inverseˡ⇒surjective Eq₁.setoid Eq₂.setoid inverseˡ
129
122
}
130
123
131
124
@@ -142,7 +135,7 @@ record IsRightInverse (to : A → B) (from : B → A) : Set (a ⊔ b ⊔ ℓ₁
142
135
strictlyInverseʳ _ = inverseʳ Eq₂.refl
143
136
144
137
injective : Injective _≈₁_ _≈₂_ to
145
- injective = inverseʳ⇒injective _≈₂_ to Eq₂.refl Eq₁.sym Eq₁.trans inverseʳ
138
+ injective = inverseʳ⇒injective Eq₁.setoid Eq₂.setoid to inverseʳ
146
139
147
140
isInjection : IsInjection to
148
141
isInjection = record
0 commit comments