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 / V05. Groups

Mathlib.Algebra.Divisibility.Basic

64 declarations and 1 deprecated aliases. Mathlib docs · Source

Divisibility

This file defines the basics of the divisibility relation in the context of (Comm) Monoids.

Main definitions

  • semigroupDvd

Implementation notes

The divisibility relation is defined for all monoids, and as such, depends on the order of multiplication if the monoid is not commutative. There are two possible conventions for divisibility in the noncommutative context, and this relation follows the convention for ordinals, so a | b is defined as ∃ c, b = a * c.

Tags

divisibility, divides

instance semigroupDvd E3 #

{α : Type u_1} → [Semigroup α] → Dvd α

There are two possible conventions for divisibility, which coincide in a CommMonoid. This matches the convention for ordinals.

theorem Dvd.intro E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α} (c : α), a * c = b → a ∣ b

theorem dvd_of_mul_right_eq E0 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α} (c : α), a * c = b → a ∣ b

Alias of Dvd.intro.

theorem exists_eq_mul_right_of_dvd E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, a ∣ b → ∃ c, b = a * c

theorem dvd_def E0 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, a ∣ b ↔ ∃ c, b = a * c

theorem dvd_iff_exists_eq_mul_right E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, a ∣ b ↔ ∃ c, b = a * c

Alias of dvd_def.

theorem Dvd.elim E1 #

∀ {α : Type u_1} [inst : Semigroup α] {P : Prop} {a b : α}, a ∣ b → (∀ (c : α), b = a * c → P) → P

theorem dvd_trans E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, a ∣ b → b ∣ c → a ∣ c

theorem Dvd.dvd.trans E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, a ∣ b → b ∣ c → a ∣ c

Alias of dvd_trans.

instance instIsTransDvd E0 #

∀ {α : Type u_1} [inst : Semigroup α], IsTrans α Dvd.dvd

Transitivity of | for use in calc blocks.

theorem dvd_mul_right E0 #

∀ {α : Type u_1} [inst : Semigroup α] (a b : α), a ∣ a * b

theorem dvd_mul_of_dvd_left E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, a ∣ b → ∀ (c : α), a ∣ b * c

theorem Dvd.dvd.mul_right E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, a ∣ b → ∀ (c : α), a ∣ b * c

Alias of dvd_mul_of_dvd_left.

theorem dvd_of_mul_right_dvd E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, a * b ∣ c → a ∣ c

def IsPrimal E1 #

{α : Type u_1} → [Semigroup α] → α → Prop

An element a in a semigroup is primal if whenever a is a divisor of b * c, it can be factored as the product of a divisor of b and a divisor of c.

class DecompositionMonoid E1 #

(α : Type u_1) → [Semigroup α] → Prop

A monoid is a decomposition monoid if every element is primal. An integral domain whose multiplicative monoid is a decomposition monoid, is called a pre-Schreier domain; it is a Schreier domain if it is moreover integrally closed.

theorem decompositionMonoid_iff E0 #

∀ (α : Type u_1) [inst : Semigroup α], DecompositionMonoid α ↔ ∀ (a : α), IsPrimal a

ctor DecompositionMonoid.mk E0 #

∀ {α : Type u_1} [inst : Semigroup α], (∀ (a : α), IsPrimal a) → DecompositionMonoid α

theorem DecompositionMonoid.primal E1 #

∀ {α : Type u_1} {inst : Semigroup α} [self : DecompositionMonoid α] (a : α), IsPrimal a

theorem exists_dvd_and_dvd_of_dvd_mul E1 #

∀ {α : Type u_1} [inst : Semigroup α] [DecompositionMonoid α] {b c a : α},
  a ∣ b * c → ∃ a₁ a₂, a₁ ∣ b ∧ a₂ ∣ c ∧ a = a₁ * a₂

theorem mul_dvd_mul_left E1 #

∀ {α : Type u_1} [inst : Semigroup α] {b c : α} (a : α), b ∣ c → a * b ∣ a * c

theorem IsLeftRegular.dvd_cancel_left E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, IsLeftRegular a → (a * b ∣ a * c ↔ b ∣ c)

def RightDvd E1 #

{α : Type u_1} → [Semigroup α] → α → α → Prop

Right divisibility relation. RightDvd a b means a right-divides b, i.e., ∃ c, b = c * a.

def «term_∣ᵣ_» E1 #

Lean.TrailingParserDescr

Right divisibility relation. RightDvd a b means a right-divides b, i.e., ∃ c, b = c * a.

theorem RightDvd.trans E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, a ∣ᵣ b → b ∣ᵣ c → a ∣ᵣ c

instance instIsTransRightDvd E0 #

∀ {α : Type u_1} [inst : Semigroup α], IsTrans α RightDvd

Transitivity of RightDvd for use in calc blocks.

theorem RightDvd.mul_self E0 #

∀ {α : Type u_1} [inst : Semigroup α] (a b : α), a ∣ᵣ b * a

theorem RightDvd.mul_left E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, a ∣ᵣ b → ∀ (c : α), a ∣ᵣ c * b

theorem RightDvd.of_mul_left E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, b * a ∣ᵣ c → a ∣ᵣ c

theorem RightDvd.mul_const E1 #

∀ {α : Type u_1} [inst : Semigroup α] {b c : α} (a : α), b ∣ᵣ c → b * a ∣ᵣ c * a

theorem IsRightRegular.rightDvd_cancel_right E1 #

∀ {α : Type u_1} [inst : Semigroup α] {a b c : α}, IsRightRegular a → (b * a ∣ᵣ c * a ↔ b ∣ᵣ c)

theorem op_dvd_op_iff E0 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, MulOpposite.op a ∣ MulOpposite.op b ↔ a ∣ᵣ b

Left divisibility in the opposite semigroup is equivalent to right divisibility.

theorem op_rightDvd_op_iff E0 #

∀ {α : Type u_1} [inst : Semigroup α] {a b : α}, MulOpposite.op a ∣ᵣ MulOpposite.op b ↔ a ∣ b

Right divisibility in the opposite semigroup is equivalent to left divisibility.

theorem mul_rightDvd_mul_iff_left E0 #

∀ {α : Type u_1} [inst : RightCancelSemigroup α] {a b c : α}, b * a ∣ᵣ c * a ↔ b ∣ᵣ c

theorem dvd_refl E0 #

∀ {α : Type u_1} [inst : Monoid α] (a : α), a ∣ a

theorem dvd_rfl E2 #

∀ {α : Type u_1} [inst : Monoid α] {a : α}, a ∣ a

instance instIsPreorderDvd E0 #

∀ {α : Type u_1} [inst : Monoid α], IsPreorder α fun x1 x2 ↦ x1 ∣ x2

theorem one_dvd E1 #

∀ {α : Type u_1} [inst : Monoid α] (a : α), 1 ∣ a

theorem dvd_of_eq E0 #

∀ {α : Type u_1} [inst : Monoid α] {a b : α}, a = b → a ∣ b

theorem Eq.dvd E1 #

∀ {α : Type u_1} [inst : Monoid α] {a b : α}, a = b → a ∣ b

Alias of dvd_of_eq.

theorem pow_dvd_pow E2 #

∀ {α : Type u_1} [inst : Monoid α] {m n : ℕ} (a : α), m ≤ n → a ^ m ∣ a ^ n

theorem dvd_pow E1 #

∀ {α : Type u_1} [inst : Monoid α] {a b : α}, a ∣ b → ∀ {n : ℕ}, n ≠ 0 → a ∣ b ^ n

theorem Dvd.dvd.pow E1 #

∀ {α : Type u_1} [inst : Monoid α] {a b : α}, a ∣ b → ∀ {n : ℕ}, n ≠ 0 → a ∣ b ^ n

Alias of dvd_pow.

theorem dvd_pow_self E1 #

∀ {α : Type u_1} [inst : Monoid α] (a : α) {n : ℕ}, n ≠ 0 → a ∣ a ^ n

theorem RightDvd.refl E0 #

∀ {α : Type u_1} [inst : Monoid α] (a : α), a ∣ᵣ a

theorem RightDvd.rfl E1 #

∀ {α : Type u_1} [inst : Monoid α] {a : α}, a ∣ᵣ a

instance instIsPreorderRightDvd E0 #

∀ {α : Type u_1} [inst : Monoid α], IsPreorder α RightDvd

theorem RightDvd.of_eq E0 #

∀ {α : Type u_1} [inst : Monoid α] {a b : α}, a = b → a ∣ᵣ b

theorem Eq.rightDvd E1 #

∀ {α : Type u_1} [inst : Monoid α] {a b : α}, a = b → a ∣ᵣ b

Alias of RightDvd.of_eq.

theorem Dvd.intro_left E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α} (c : α), c * a = b → a ∣ b

theorem dvd_of_mul_left_eq E0 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α} (c : α), c * a = b → a ∣ b

Alias of Dvd.intro_left.

theorem exists_eq_mul_left_of_dvd E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α}, a ∣ b → ∃ c, b = c * a

theorem dvd_iff_exists_eq_mul_left E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α}, a ∣ b ↔ ∃ c, b = c * a

theorem Dvd.elim_left E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α} {P : Prop}, a ∣ b → (∀ (c : α), b = c * a → P) → P

theorem dvd_mul_left E0 #

∀ {α : Type u_1} [inst : CommSemigroup α] (a b : α), a ∣ b * a

theorem dvd_mul_of_dvd_right E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α}, a ∣ b → ∀ (c : α), a ∣ c * b

theorem Dvd.dvd.mul_left E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α}, a ∣ b → ∀ (c : α), a ∣ c * b

Alias of dvd_mul_of_dvd_right.

theorem mul_dvd_mul E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b c d : α}, a ∣ b → c ∣ d → a * c ∣ b * d

theorem dvd_of_mul_left_dvd E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b c : α}, a * b ∣ c → b ∣ c

theorem dvd_mul E1 #

∀ {α : Type u_1} [inst : CommSemigroup α] [DecompositionMonoid α] {k m n : α},
  k ∣ m * n ↔ ∃ d₁ d₂, d₁ ∣ m ∧ d₂ ∣ n ∧ k = d₁ * d₂

theorem rightDvd_iff_dvd E0 #

∀ {α : Type u_1} [inst : CommSemigroup α] {a b : α}, a ∣ᵣ b ↔ a ∣ b

theorem mul_dvd_mul_right E1 #

∀ {α : Type u_1} [inst : CommMonoid α] {a b : α}, a ∣ b → ∀ (c : α), a * c ∣ b * c

theorem pow_dvd_pow_of_dvd E1 #

∀ {α : Type u_1} [inst : CommMonoid α] {a b : α}, a ∣ b → ∀ (n : ℕ), a ^ n ∣ b ^ n

theorem pow_dvd_pow_of_dvd_of_le E1 #

∀ {α : Type u_1} [inst : CommMonoid α] {a b : α} {m n : ℕ}, a ∣ b → m ≤ n → a ^ m ∣ b ^ n

Deprecated aliases

NameNew nameSince
rightDvd_iff_op_dvd_opop_dvd_op_iff2026-09-30