The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V06. Rings, fields and ordered algebra

Mathlib.Algebra.Order.Ring.Ordering.Defs

32 declarations and 30 deprecated aliases. Mathlib docs · Source

Ring orderings

Let R be a commutative ring. We define orderings and preorderings on R as predicates on Subsemiring R.

Definitions

  • IsOrdering: an ordering is a subsemiring O such that O ∪ -O = R and the support O ∩ -O of O forms a prime ideal.
  • IsPreordering: a preordering is a subsemiring that contains all squares, but not -1.

All orderings are preorderings.

References

  • [An introduction to real algebra, T.Y. Lam][lam_1984]

Support

def RingPreordering.ctorIdx E1 #

{R : Type u_1} → {inst : CommRing R} → RingPreordering R → ℕ

theorem Subsemiring.supportIdeal.congr_simp E1 #

∀ {R : Type u_1} [inst : Ring R] {S S_1 : Subsemiring R} (e_S : S = S_1) (hS : S.toAddSubmonoid.IsSpanning),
  Subsemiring.supportIdeal hS = Subsemiring.supportIdeal ⋯

theorem RingPreordering.mk.inj E1 #

∀ {R : Type u_1} {inst : CommRing R} {toSubsemiring : Subsemiring R}
  {mem_of_isSquare' :
    autoParam (∀ {x : R}, IsSquare x → x ∈ toSubsemiring.carrier) RingPreordering.mem_of_isSquare'._autoParam}
  {neg_one_notMem' : autoParam (-1 ∉ toSubsemiring.carrier) RingPreordering.neg_one_notMem'._autoParam}
  {toSubsemiring_1 : Subsemiring R}
  {mem_of_isSquare'_1 :
    autoParam (∀ {x : R}, IsSquare x → x ∈ toSubsemiring_1.carrier) RingPreordering.mem_of_isSquare'._autoParam}
  {neg_one_notMem'_1 : autoParam (-1 ∉ toSubsemiring_1.carrier) RingPreordering.neg_one_notMem'._autoParam},
  { toSubsemiring := toSubsemiring, mem_of_isSquare' := mem_of_isSquare', neg_one_notMem' := neg_one_notMem' } =
      { toSubsemiring := toSubsemiring_1, mem_of_isSquare' := mem_of_isSquare'_1,
        neg_one_notMem' := neg_one_notMem'_1 } →
    toSubsemiring = toSubsemiring_1

theorem RingPreordering.mk.injEq E0 #

∀ {R : Type u_1} [inst : CommRing R] (toSubsemiring : Subsemiring R)
  (mem_of_isSquare' :
    autoParam (∀ {x : R}, IsSquare x → x ∈ toSubsemiring.carrier) RingPreordering.mem_of_isSquare'._autoParam)
  (neg_one_notMem' : autoParam (-1 ∉ toSubsemiring.carrier) RingPreordering.neg_one_notMem'._autoParam)
  (toSubsemiring_1 : Subsemiring R)
  (mem_of_isSquare'_1 :
    autoParam (∀ {x : R}, IsSquare x → x ∈ toSubsemiring_1.carrier) RingPreordering.mem_of_isSquare'._autoParam)
  (neg_one_notMem'_1 : autoParam (-1 ∉ toSubsemiring_1.carrier) RingPreordering.neg_one_notMem'._autoParam),
  ({ toSubsemiring := toSubsemiring, mem_of_isSquare' := mem_of_isSquare', neg_one_notMem' := neg_one_notMem' } =
      { toSubsemiring := toSubsemiring_1, mem_of_isSquare' := mem_of_isSquare'_1,
        neg_one_notMem' := neg_one_notMem'_1 }) =
    (toSubsemiring = toSubsemiring_1)

structure Subsemiring.IsOrdering E1 #

{R : Type u_1} → [inst : CommRing R] → Subsemiring R → Prop

An ordering O on a ring R is a subsemiring of R such that O ∪ -O = R and the support O ∩ -O of O forms a prime ideal.

ctor Subsemiring.IsOrdering.mk E0 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R},
  S.toAddSubmonoid.IsSpanning →
    S.toAddSubmonoid.support ≠ ⊤ →
      (∀ {x y : R}, x * y ∈ S.toAddSubmonoid.support → x ∈ S.toAddSubmonoid.support ∨ y ∈ S.toAddSubmonoid.support) →
        S.IsOrdering

theorem Subsemiring.IsOrdering.isSpanning E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsOrdering → S.toAddSubmonoid.IsSpanning

theorem Subsemiring.IsOrdering.support_ne_top E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsOrdering → S.toAddSubmonoid.support ≠ ⊤

theorem Subsemiring.IsOrdering.mem_support_or_mem_support E0 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R},
  S.IsOrdering →
    ∀ {x y : R}, x * y ∈ S.toAddSubmonoid.support → x ∈ S.toAddSubmonoid.support ∨ y ∈ S.toAddSubmonoid.support

theorem Subsemiring.IsOrdering.isPrime_supportIdeal E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R} (hS : S.IsOrdering), (Subsemiring.supportIdeal ⋯).IsPrime

theorem Subsemiring.IsOrdering.of_isPrime_supportIdeal E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R} (hS : S.toAddSubmonoid.IsSpanning),
  (Subsemiring.supportIdeal hS).IsPrime → S.IsOrdering

structure Subsemiring.IsPreordering E1 #

{R : Type u_1} → [inst : CommRing R] → Subsemiring R → Prop

A preordering on a ring R is a subsemiring of R that contains all squares, but not -1.

ctor Subsemiring.IsPreordering.mk E0 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R},
  autoParam (∀ {x : R}, IsSquare x → x ∈ S) Subsemiring.IsPreordering.mem_of_isSquare._autoParam →
    autoParam (-1 ∉ S) Subsemiring.IsPreordering.neg_one_notMem._autoParam → S.IsPreordering

theorem Subsemiring.IsPreordering.mem_of_isSquare E0 #

∀ {R : Type u_1} [inst : CommRing R] (S : Subsemiring R), S.IsPreordering → ∀ {x : R}, IsSquare x → x ∈ S

theorem Subsemiring.IsPreordering.neg_one_notMem E1 #

∀ {R : Type u_1} [inst : CommRing R] (S : Subsemiring R), S.IsPreordering → -1 ∉ S

theorem Subsemiring.IsPreordering.mul_self_mem E0 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsPreordering → ∀ (x : R), x * x ∈ S

theorem Subsemiring.IsPreordering.pow_two_mem E0 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsPreordering → ∀ (x : R), x ^ 2 ∈ S

theorem Subsemiring.IsPreordering.sumSq_le E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsPreordering → Subsemiring.sumSq R ≤ S

theorem Subsemiring.IsPreordering.mem_of_isSumSq E0 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsPreordering → ∀ {x : R}, IsSumSq x → x ∈ S

theorem Subsemiring.IsPreordering.of_sumSq_le E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, Subsemiring.sumSq R ≤ S → -1 ∉ S → S.IsPreordering

theorem Subsemiring.IsPreordering.of_isSpanning E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.toAddSubmonoid.IsSpanning → S ≠ ⊤ → S.IsPreordering

theorem Subsemiring.IsOrdering.isPreordering E1 #

∀ {R : Type u_1} [inst : CommRing R] {S : Subsemiring R}, S.IsOrdering → S.IsPreordering

An ordering is a preordering.

theorem RingPreordering.ext E1 #

∀ {R : Type u_1} {inst : CommRing R} {x y : RingPreordering R}, (↑x).carrier = (↑y).carrier → x = y

abbrev RingPreordering.toSubsemiring E1 #

{R : Type u_1} → [inst : CommRing R] → RingPreordering R → Subsemiring R

ctor RingPreordering.mk E0 #

{R : Type u_1} →
  [inst : CommRing R] →
    (toSubsemiring : Subsemiring R) →
      autoParam (∀ {x : R}, IsSquare x → x ∈ toSubsemiring.carrier) RingPreordering.mem_of_isSquare'._autoParam →
        autoParam (-1 ∉ toSubsemiring.carrier) RingPreordering.neg_one_notMem'._autoParam → RingPreordering R

theorem RingPreordering.mem_of_isSquare' E0 #

∀ {R : Type u_1} [inst : CommRing R] (self : RingPreordering R) {x : R}, IsSquare x → x ∈ (↑self).carrier

theorem RingPreordering.neg_one_notMem' E1 #

∀ {R : Type u_1} [inst : CommRing R] (self : RingPreordering R), -1 ∉ (↑self).carrier

ctor RingPreordering.HasIdealSupport.mk E0 #

∀ {R : Type u_1} [inst : CommRing R] {P : RingPreordering R},
  (∀ (x : R) {a : R}, a ∈ P.supportAddSubgroup → x * a ∈ P.supportAddSubgroup) → P.HasIdealSupport

theorem RingPreordering.HasIdealSupport.smul_mem_support E1 #

∀ {R : Type u_1} {inst : CommRing R} (P : RingPreordering R) [self : P.HasIdealSupport] (x : R) {a : R},
  a ∈ P.supportAddSubgroup → x * a ∈ P.supportAddSubgroup

ctor RingPreordering.IsOrdering.mk E0 #

∀ {R : Type u_1} [inst : CommRing R] {P : RingPreordering R} [toHasMemOrNegMem : HasMemOrNegMem P]
  [toIsPrime : P.support.IsPrime], P.IsOrdering

instance RingPreordering.IsOrdering.toHasMemOrNegMem E0 #

∀ {R : Type u_1} {inst : CommRing R} {P : RingPreordering R} [self : P.IsOrdering], HasMemOrNegMem P

instance RingPreordering.IsOrdering.toIsPrime E0 #

∀ {R : Type u_1} {inst : CommRing R} {P : RingPreordering R} [self : P.IsOrdering], P.support.IsPrime

Deprecated aliases

NameNew nameSince
RingPreorderingSubsemiring.IsPreordering2026-10-28
RingPreordering.HasIdealSupport2026-10-28
RingPreordering.IsOrderingSubsemiring.IsOrdering2026-10-28
RingPreordering.coe_copy2026-10-28
RingPreordering.coe_set_mk2026-10-28
RingPreordering.coe_supportSubsemiring.coe_supportIdeal2026-10-28
RingPreordering.coe_supportAddSubgroupAddSubmonoid.coe_support2026-10-28
RingPreordering.coe_toSubsemiring2026-10-28
RingPreordering.copy2026-10-28
RingPreordering.copy_eq2026-10-28
RingPreordering.ext_iff2026-10-28
RingPreordering.hasIdealSupport_iff2026-10-28
RingPreordering.instHasIdealSupportOfHasMemOrNegMemSubsemiring.supportIdeal2026-10-28
RingPreordering.instPartialOrder2026-10-28
RingPreordering.instSetLike2026-10-28
RingPreordering.instSubsemiringClass2026-10-28
RingPreordering.mem_copy2026-10-28
RingPreordering.mem_mk2026-10-28
RingPreordering.mem_of_isSquareSubsemiring.IsPreordering.mem_of_isSquare2026-10-28
RingPreordering.mem_supportSubsemiring.mem_supportIdeal2026-10-28
RingPreordering.mem_supportAddSubgroupAddSubmonoid.mem_support2026-10-28
RingPreordering.mem_toSubsemiring2026-10-28
RingPreordering.mul_self_memSubsemiring.IsPreordering.mul_self_mem2026-10-28
RingPreordering.neg_one_notMemSubsemiring.IsPreordering.neg_one_notMem2026-10-28
RingPreordering.pow_two_memSubsemiring.IsPreordering.pow_two_mem2026-10-28
RingPreordering.supportSubsemiring.supportIdeal2026-10-28
RingPreordering.supportAddSubgroupAddSubmonoid.support2026-10-28
RingPreordering.supportAddSubgroup_eqSubsemiring.supportIdeal_toAddSubgroup2026-10-28
RingPreordering.toSubsemiring_inj2026-10-28
RingPreordering.toSubsemiring_injective2026-10-28