# Documentation

Mathlib.RingTheory.OreLocalization.Basic

# Localization over right Ore sets. #

This file defines the localization of a monoid over a right Ore set and proves its universal mapping property. It then extends the definition and its properties first to semirings and then to rings. We show that in the case of a commutative monoid this definition coincides with the common monoid localization. Finally we show that in a ring without zero divisors, taking the Ore localization at R - {0} results in a division ring.

## Notations #

Introduces the notation R[S⁻¹] for the Ore localization of a monoid R at a right Ore subset S. Also defines a new heterogeneous division notation r /ₒ s for a numerator r : R and a denominator s : S.

## Tags #

localization, Ore, non-commutative

def OreLocalization.oreEqv (R : Type u_1) [] (S : ) :
Setoid (R × { x // x S })

The setoid on R × S used for the Ore localization.

Instances For
def OreLocalization (R : Type u_1) [] (S : ) :
Type u_1

The ore localization of a monoid and a submonoid fulfilling the ore condition.

Instances For

The ore localization of a monoid and a submonoid fulfilling the ore condition.

Instances For
def OreLocalization.oreDiv {R : Type u_1} [] {S : } (r : R) (s : { x // x S }) :

The division in the ore localization R[S⁻¹], as a fraction of an element of R and S.

Instances For

The division in the ore localization R[S⁻¹], as a fraction of an element of R and S.

Instances For
theorem OreLocalization.ind {R : Type u_1} [] {S : } {β : Prop} (c : (r : R) → (s : { x // x S }) → β (r /ₒ s)) (q : ) :
β q
theorem OreLocalization.oreDiv_eq_iff {R : Type u_1} [] {S : } {r₁ : R} {r₂ : R} {s₁ : { x // x S }} {s₂ : { x // x S }} :
r₁ /ₒ s₁ = r₂ /ₒ s₂ u v, r₂ * u = r₁ * v s₂ * u = s₁ * v
theorem OreLocalization.expand {R : Type u_1} [] {S : } (r : R) (s : { x // x S }) (t : R) (hst : s * t S) :
r /ₒ s = r * t /ₒ { val := s * t, property := hst }

A fraction r /ₒ s is equal to its expansion by an arbitrary factor t if s * t ∈ S.

theorem OreLocalization.expand' {R : Type u_1} [] {S : } (r : R) (s : { x // x S }) (s' : { x // x S }) :
r /ₒ s = r * s' /ₒ (s * s')

A fraction is equal to its expansion by a factor from s.

theorem OreLocalization.eq_of_num_factor_eq {R : Type u_1} [] {S : } {r : R} {r' : R} {r₁ : R} {r₂ : R} {s : { x // x S }} {t : { x // x S }} (h : r * t = r' * t) :
r₁ * r * r₂ /ₒ s = r₁ * r' * r₂ /ₒ s

Fractions which differ by a factor of the numerator can be proven equal if those factors expand to equal elements of R.

def OreLocalization.liftExpand {R : Type u_1} [] {S : } {C : Sort u_2} (P : R{ x // x S }C) (hP : ∀ (r t : R) (s : { x // x S }) (ht : s * t S), P r s = P (r * t) { val := s * t, property := ht }) :
C

A function or predicate over R and S can be lifted to R[S⁻¹] if it is invariant under expansion on the right.

Instances For
@[simp]
theorem OreLocalization.liftExpand_of {R : Type u_1} [] {S : } {C : Sort u_2} {P : R{ x // x S }C} {hP : ∀ (r t : R) (s : { x // x S }) (ht : s * t S), P r s = P (r * t) { val := s * t, property := ht }} (r : R) (s : { x // x S }) :
def OreLocalization.lift₂Expand {R : Type u_1} [] {S : } {C : Sort u_2} (P : R{ x // x S }R{ x // x S }C) (hP : ∀ (r₁ t₁ : R) (s₁ : { x // x S }) (ht₁ : s₁ * t₁ S) (r₂ t₂ : R) (s₂ : { x // x S }) (ht₂ : s₂ * t₂ S), P r₁ s₁ r₂ s₂ = P (r₁ * t₁) { val := s₁ * t₁, property := ht₁ } (r₂ * t₂) { val := s₂ * t₂, property := ht₂ }) :
C

A version of liftExpand used to simultaneously lift functions with two arguments in R[S⁻¹].

Instances For
@[simp]
theorem OreLocalization.lift₂Expand_of {R : Type u_1} [] {S : } {C : Sort u_2} {P : R{ x // x S }R{ x // x S }C} {hP : ∀ (r₁ t₁ : R) (s₁ : { x // x S }) (ht₁ : s₁ * t₁ S) (r₂ t₂ : R) (s₂ : { x // x S }) (ht₂ : s₂ * t₂ S), P r₁ s₁ r₂ s₂ = P (r₁ * t₁) { val := s₁ * t₁, property := ht₁ } (r₂ * t₂) { val := s₂ * t₂, property := ht₂ }} (r₁ : R) (s₁ : { x // x S }) (r₂ : R) (s₂ : { x // x S }) :
OreLocalization.lift₂Expand P hP (r₁ /ₒ s₁) (r₂ /ₒ s₂) = P r₁ s₁ r₂ s₂
def OreLocalization.mul {R : Type u_1} [] {S : } :

The multiplication on the Ore localization of monoids.

Instances For
instance OreLocalization.instMulOreLocalization {R : Type u_1} [] {S : } :
Mul ()
theorem OreLocalization.oreDiv_mul_oreDiv {R : Type u_1} [] {S : } {r₁ : R} {r₂ : R} {s₁ : { x // x S }} {s₂ : { x // x S }} :
r₁ /ₒ s₁ * (r₂ /ₒ s₂) = r₁ * /ₒ (s₂ * )
theorem OreLocalization.oreDiv_mul_char {R : Type u_1} [] {S : } (r₁ : R) (r₂ : R) (s₁ : { x // x S }) (s₂ : { x // x S }) (r' : R) (s' : { x // x S }) (huv : r₂ * s' = s₁ * r') :
r₁ /ₒ s₁ * (r₂ /ₒ s₂) = r₁ * r' /ₒ (s₂ * s')

A characterization lemma for the multiplication on the Ore localization, allowing for a choice of Ore numerator and Ore denominator.

def OreLocalization.oreDivMulChar' {R : Type u_1} [] {S : } (r₁ : R) (r₂ : R) (s₁ : { x // x S }) (s₂ : { x // x S }) :
(r' : R) ×' (s' : { x // x S }) ×' r₂ * s' = s₁ * r' r₁ /ₒ s₁ * (r₂ /ₒ s₂) = r₁ * r' /ₒ (s₂ * s')

Another characterization lemma for the multiplication on the Ore localizaion delivering Ore witnesses and conditions bundled in a sigma type.

Instances For
instance OreLocalization.instOneOreLocalization {R : Type u_1} [] {S : } :
One ()
theorem OreLocalization.one_def {R : Type u_1} [] {S : } :
1 = 1 /ₒ 1
@[simp]
theorem OreLocalization.div_eq_one' {R : Type u_1} [] {S : } {r : R} (hr : r S) :
r /ₒ { val := r, property := hr } = 1
@[simp]
theorem OreLocalization.div_eq_one {R : Type u_1} [] {S : } {s : { x // x S }} :
s /ₒ s = 1
theorem OreLocalization.one_mul {R : Type u_1} [] {S : } (x : ) :
1 * x = x
theorem OreLocalization.mul_one {R : Type u_1} [] {S : } (x : ) :
x * 1 = x
theorem OreLocalization.mul_assoc {R : Type u_1} [] {S : } (x : ) (y : ) (z : ) :
x * y * z = x * (y * z)
theorem OreLocalization.mul_inv {R : Type u_1} [] {S : } (s : { x // x S }) (s' : { x // x S }) :
s /ₒ s' * (s' /ₒ s) = 1
@[simp]
theorem OreLocalization.mul_one_div {R : Type u_1} [] {S : } {r : R} {s : { x // x S }} {t : { x // x S }} :
r /ₒ s * (1 /ₒ t) = r /ₒ (t * s)
@[simp]
theorem OreLocalization.mul_cancel {R : Type u_1} [] {S : } {r : R} {s : { x // x S }} {t : { x // x S }} :
r /ₒ s * (s /ₒ t) = r /ₒ t
@[simp]
theorem OreLocalization.mul_cancel' {R : Type u_1} [] {S : } {r₁ : R} {r₂ : R} {s : { x // x S }} {t : { x // x S }} :
r₁ /ₒ s * (s * r₂ /ₒ t) = r₁ * r₂ /ₒ t
@[simp]
theorem OreLocalization.div_one_mul {R : Type u_1} [] {S : } {p : R} {r : R} {s : { x // x S }} :
r /ₒ 1 * (p /ₒ s) = r * p /ₒ s
def OreLocalization.numeratorUnit {R : Type u_1} [] {S : } (s : { x // x S }) :
()ˣ

The fraction s /ₒ 1 as a unit in R[S⁻¹], where s : S.

Instances For
def OreLocalization.numeratorHom {R : Type u_1} [] {S : } :
R →*

The multiplicative homomorphism from R to R[S⁻¹], mapping r : R to the fraction r /ₒ 1.

Instances For
theorem OreLocalization.numeratorHom_apply {R : Type u_1} [] {S : } {r : R} :
OreLocalization.numeratorHom r = r /ₒ 1
theorem OreLocalization.numerator_isUnit {R : Type u_1} [] {S : } (s : { x // x S }) :
IsUnit (OreLocalization.numeratorHom s)
def OreLocalization.universalMulHom {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) :
→* T

The universal lift from a morphism R →* T, which maps elements of S to units of T, to a morphism R[S⁻¹] →* T.

Instances For
theorem OreLocalization.universalMulHom_apply {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) {r : R} {s : { x // x S }} :
↑() (r /ₒ s) = f r * (fS s)⁻¹
theorem OreLocalization.universalMulHom_commutes {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) {r : R} :
↑() (OreLocalization.numeratorHom r) = f r
theorem OreLocalization.universalMulHom_unique {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) (φ : →* T) (huniv : ∀ (r : R), φ (OreLocalization.numeratorHom r) = f r) :
φ =

The universal morphism universalMulHom is unique.

theorem OreLocalization.oreDiv_mul_oreDiv_comm {R : Type u_1} [] {S : } {r₁ : R} {r₂ : R} {s₁ : { x // x S }} {s₂ : { x // x S }} :
r₁ /ₒ s₁ * (r₂ /ₒ s₂) = r₁ * r₂ /ₒ (s₁ * s₂)
def OreLocalization.localizationMap (R : Type u_1) [] (S : ) :

The morphism numeratorHom is a monoid localization map in the case of commutative R.

Instances For
noncomputable def OreLocalization.equivMonoidLocalization (R : Type u_1) [] (S : ) :

If R is commutative, Ore localization and monoid localization are isomorphic.

Instances For
instance OreLocalization.instAddOreLocalization {R : Type u_1} [] {S : } :
theorem OreLocalization.oreDiv_add_oreDiv {R : Type u_1} [] {S : } {r : R} {r' : R} {s : { x // x S }} {s' : { x // x S }} :
r /ₒ s + r' /ₒ s' = (r * ↑(OreLocalization.oreDenom (s) s') + r' * OreLocalization.oreNum (s) s') /ₒ (s * OreLocalization.oreDenom (s) s')
theorem OreLocalization.oreDiv_add_char {R : Type u_1} [] {S : } {r : R} {r' : R} (s : { x // x S }) (s' : { x // x S }) (rb : R) (sb : { x // x S }) (h : s * sb = s' * rb) :
r /ₒ s + r' /ₒ s' = (r * sb + r' * rb) /ₒ (s * sb)

A characterization of the addition on the Ore localizaion, allowing for arbitrary Ore numerator and Ore denominator.

def OreLocalization.oreDivAddChar' {R : Type u_1} [] {S : } (r : R) (r' : R) (s : { x // x S }) (s' : { x // x S }) :
(r'' : R) ×' (s'' : { x // x S }) ×' s * s'' = s' * r'' r /ₒ s + r' /ₒ s' = (r * s'' + r' * r'') /ₒ (s * s'')

Another characterization of the addition on the Ore localization, bundling up all witnesses and conditions into a sigma type.

Instances For
@[simp]
theorem OreLocalization.add_oreDiv {R : Type u_1} [] {S : } {r : R} {r' : R} {s : { x // x S }} :
r /ₒ s + r' /ₒ s = (r + r') /ₒ s
theorem OreLocalization.add_assoc {R : Type u_1} [] {S : } (x : ) (y : ) (z : ) :
x + y + z = x + (y + z)
theorem OreLocalization.zero_def {R : Type u_1} [] {S : } :
0 = 0 /ₒ 1
@[simp]
theorem OreLocalization.zero_div_eq_zero {R : Type u_1} [] {S : } (s : { x // x S }) :
0 /ₒ s = 0
theorem OreLocalization.zero_add {R : Type u_1} [] {S : } (x : ) :
0 + x = x
theorem OreLocalization.add_comm {R : Type u_1} [] {S : } (x : ) (y : ) :
x + y = y + x
theorem OreLocalization.zero_mul {R : Type u_1} [] {S : } (x : ) :
0 * x = 0
theorem OreLocalization.mul_zero {R : Type u_1} [] {S : } (x : ) :
x * 0 = 0
theorem OreLocalization.left_distrib {R : Type u_1} [] {S : } (x : ) (y : ) (z : ) :
x * (y + z) = x * y + x * z
theorem OreLocalization.right_distrib {R : Type u_1} [] {S : } (x : ) (y : ) (z : ) :
(x + y) * z = x * z + y * z
def OreLocalization.universalHom {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →+* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) :

The universal lift from a ring homomorphism f : R →+* T, which maps elements in S to units of T, to a ring homomorphism R[S⁻¹] →+* T. This extends the construction on monoids.

Instances For
theorem OreLocalization.universalHom_apply {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →+* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) {r : R} {s : { x // x S }} :
↑() (r /ₒ s) = f r * (fS s)⁻¹
theorem OreLocalization.universalHom_commutes {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →+* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) {r : R} :
↑() (OreLocalization.numeratorHom r) = f r
theorem OreLocalization.universalHom_unique {R : Type u_1} [] {S : } {T : Type u_2} [] (f : R →+* T) (fS : { x // x S } →* Tˣ) (hf : ∀ (s : { x // x S }), f s = ↑(fS s)) (φ : →+* T) (huniv : ∀ (r : R), φ (OreLocalization.numeratorHom r) = f r) :
φ =
def OreLocalization.neg {R : Type u_1} [Ring R] {S : } :

Negation on the Ore localization is defined via negation on the numerator.

Instances For
instance OreLocalization.instNegOreLocalization {R : Type u_1} [Ring R] {S : } :
Neg ()
@[simp]
theorem OreLocalization.neg_def {R : Type u_1} [Ring R] {S : } (r : R) (s : { x // x S }) :
-(r /ₒ s) = -r /ₒ s
theorem OreLocalization.add_left_neg {R : Type u_1} [Ring R] {S : } (x : ) :
-x + x = 0
instance OreLocalization.ring {R : Type u_1} [Ring R] {S : } :
Ring ()
theorem OreLocalization.numeratorHom_inj {R : Type u_1} [Ring R] {S : } (hS : ) :
Function.Injective OreLocalization.numeratorHom
theorem OreLocalization.nontrivial_of_nonZeroDivisors {R : Type u_1} [Ring R] {S : } [] (hS : ) :
instance OreLocalization.nontrivial {R : Type u_1} [Ring R] [] :
def OreLocalization.inv {R : Type u_1} [Ring R] [] [] :

The inversion of Ore fractions for a ring without zero divisors, satisying 0⁻¹ = 0 and (r /ₒ r')⁻¹ = r' /ₒ r for r ≠ 0.

Instances For
instance OreLocalization.inv' {R : Type u_1} [Ring R] [] [] :
Inv ()
theorem OreLocalization.inv_def {R : Type u_1} [Ring R] [] [] {r : R} {s : { x // }} :
(r /ₒ s)⁻¹ = if hr : r = 0 then 0 else s /ₒ { val := r, property := (_ : ∀ (x : R), x * r = 0x = 0) }
theorem OreLocalization.mul_inv_cancel {R : Type u_1} [Ring R] [] [] (x : ) (h : x 0) :
x * x⁻¹ = 1
theorem OreLocalization.inv_zero {R : Type u_1} [Ring R] [] [] :
0⁻¹ = 0
instance OreLocalization.divisionRing {R : Type u_1} [Ring R] [] [] :