File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change 1+ ------------------------------------------------------------------------
2+ -- Coprimality of ideals
3+ --
4+ -- The Agda standard library
5+ ------------------------------------------------------------------------
6+
7+ {-# OPTIONS --safe --cubical-compatible #-}
8+
9+ open import Algebra.Bundles
10+
11+ module Algebra.Ideal.Coprimality {c ℓ} (R : Ring c ℓ) where
12+
13+ open Ring R hiding (sym)
14+
15+ open import Algebra.Ideal R
16+ open import Data.Product.Base
17+ open import Level
18+ open import Relation.Binary.Reasoning.Setoid setoid
19+
20+ Coprime : ∀ {c₁ c₂ ℓ₁ ℓ₂} → Ideal c₁ ℓ₁ → Ideal c₂ ℓ₂ → Set (ℓ ⊔ c₁ ⊔ c₂)
21+ Coprime I J = Σ[ (i , j) ∈ I.I.Carrierᴹ × J.I.Carrierᴹ ] I.ι i + J.ι j ≈ 1#
22+ where
23+ module I = Ideal I
24+ module J = Ideal J
25+
26+ sym : ∀ {c₁ c₂ ℓ₁ ℓ₂} {I : Ideal c₁ ℓ₁} {J : Ideal c₂ ℓ₂} → Coprime I J → Coprime J I
27+ sym {I = I} {J = J} ((i , j) , p) = record
28+ { fst = j , i
29+ ; snd = begin
30+ J.ι j + I.ι i ≈⟨ +-comm (J.ι j) (I.ι i) ⟩
31+ I.ι i + J.ι j ≈⟨ p ⟩
32+ 1# ∎
33+ }
34+ where
35+ module I = Ideal I
36+ module J = Ideal J
You can’t perform that action at this time.
0 commit comments