From 876396eaaa6757525728489b2dac0211b4e73887 Mon Sep 17 00:00:00 2001 From: Patrick Stevens Date: Mon, 23 Dec 2019 10:26:20 +0000 Subject: [PATCH] Another phrasing of Euclidean Domain (#90) --- Rings/EuclideanDomains/Definition.agda | 83 +++++++++++++++++++ Rings/EuclideanDomains/Lemmas.agda | 19 ++++- Rings/PrincipalIdealDomains/Lemmas.agda | 1 + .../Definition.agda | 8 +- 4 files changed, 105 insertions(+), 6 deletions(-) diff --git a/Rings/EuclideanDomains/Definition.agda b/Rings/EuclideanDomains/Definition.agda index bfa964d..c7c0d20 100644 --- a/Rings/EuclideanDomains/Definition.agda +++ b/Rings/EuclideanDomains/Definition.agda @@ -14,13 +14,17 @@ open import Rings.Definition open import Rings.Homomorphisms.Definition open import Groups.Homomorphisms.Lemmas open import Rings.IntegralDomains.Definition +open import Orders open import Agda.Primitive using (Level; lzero; lsuc; _⊔_) module Rings.EuclideanDomains.Definition {a b : _} {A : Set a} {S : Setoid {a} {b} A} {_+_ _*_ : A → A → A} (R : Ring S _+_ _*_) where +open import Rings.Divisible.Definition R open Setoid S +open Equivalence eq open Ring R +open Group additiveGroup record DivisionAlgorithmResult (norm : {a : A} → ((a ∼ 0R) → False) → ℕ) {x y : A} (x!=0 : (x ∼ 0R) → False) (y!=0 : (y ∼ 0R) → False) : Set (a ⊔ b) where field @@ -29,9 +33,88 @@ record DivisionAlgorithmResult (norm : {a : A} → ((a ∼ 0R) → False) → remSmall : (rem ∼ 0R) || Sg ((rem ∼ 0R) → False) (λ rem!=0 → (norm rem!=0)