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 / V04. Order and lattices

Mathlib.Order.Lattice

171 declarations. Mathlib docs · Source

Basic properties of lattices

This file contains some basic results, alternative constructors and instances for (semi)lattices. For the definitions, see Mathlib.Order.Defs.Lattice.

Main declarations

  • SemilatticeSup.mk': an alternative constructor for SemilatticeSup via proofs that ⊔ is commutative, associative and idempotent.
  • SemilatticeSup.mk': an alternative constructor for SemilatticeInf via proofs that ⊓ is commutative, associative and idempotent.
  • Lattice.mk': an alternative constructor for Lattice via proofs that ⊔ and ⊓ are commutative, associative and satisfy a pair of "absorption laws".

TODO

  • Alternative constructors for distributive lattices from the other distributive properties

Tags

semilattice, lattice

Semilattices

Lattices

Lattices derived from linear orders

Dual order

Function lattices

Monotone functions and lattices

Products of (semi-)lattices

Subtypes of (semi-)lattices

def SemilatticeSup.mk' E3 #

{α : Type u_1} →
  [inst : Max α] →
    (∀ (a b : α), a ⊔ b = b ⊔ a) → (∀ (a b c : α), a ⊔ b ⊔ c = a ⊔ (b ⊔ c)) → (∀ (a : α), a ⊔ a = a) → SemilatticeSup α

A type with a commutative, associative and idempotent binary sup operation has the structure of a join-semilattice.

The partial order is defined so that a ≤ b unfolds to a ⊔ b = b; cf. sup_eq_right.

def SemilatticeInf.mk' E1 #

{α : Type u_1} →
  [inst : Min α] →
    (∀ (a b : α), a ⊓ b = b ⊓ a) → (∀ (a b c : α), a ⊓ b ⊓ c = a ⊓ (b ⊓ c)) → (∀ (a : α), a ⊓ a = a) → SemilatticeInf α

A type with a commutative, associative and idempotent binary inf operation has the structure of a meet-semilattice.

The partial order is defined so that a ≤ b unfolds to b ⊓ a = a; cf. inf_eq_right.

theorem left_lt_sup E0 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b : α}, a < a ⊔ b ↔ ¬b ≤ a

theorem inf_lt_left E0 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b : α}, a ⊓ b < a ↔ ¬a ≤ b

theorem right_lt_sup E0 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b : α}, b < a ⊔ b ↔ ¬a ≤ b

theorem inf_lt_right E0 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b : α}, a ⊓ b < b ↔ ¬b ≤ a

theorem left_or_right_lt_sup E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b : α}, a ≠ b → a < a ⊔ b ∨ b < a ⊔ b

theorem inf_lt_left_or_right E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b : α}, a ≠ b → a ⊓ b < a ∨ a ⊓ b < b

theorem le_iff_exists_inf E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b : α}, b ≤ a ↔ ∃ c, b = a ⊓ c

theorem le_iff_exists_sup E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b : α}, a ≤ b ↔ ∃ c, b = a ⊔ c

theorem inf_congr_left E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b c : α}, a ⊓ c ≤ b → a ⊓ b ≤ c → a ⊓ b = a ⊓ c

theorem sup_congr_left E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b c : α}, b ≤ a ⊔ c → c ≤ a ⊔ b → a ⊔ b = a ⊔ c

theorem inf_congr_right E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b c : α}, b ⊓ c ≤ a → a ⊓ c ≤ b → a ⊓ c = b ⊓ c

theorem sup_congr_right E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b c : α}, a ≤ b ⊔ c → b ≤ a ⊔ c → a ⊔ c = b ⊔ c

theorem sup_eq_sup_iff_left E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b c : α}, a ⊔ b = a ⊔ c ↔ b ≤ a ⊔ c ∧ c ≤ a ⊔ b

theorem inf_eq_inf_iff_left E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b c : α}, a ⊓ b = a ⊓ c ↔ a ⊓ c ≤ b ∧ a ⊓ b ≤ c

theorem inf_eq_inf_iff_right E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b c : α}, a ⊓ c = b ⊓ c ↔ b ⊓ c ≤ a ∧ a ⊓ c ≤ b

theorem sup_eq_sup_iff_right E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b c : α}, a ⊔ c = b ⊔ c ↔ a ≤ b ⊔ c ∧ b ≤ a ⊔ c

theorem sup_eq_sup_mono_left E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b c d : α}, a ⊔ b = a ⊔ c → a ≤ d → d ⊔ b = d ⊔ c

theorem inf_eq_inf_mono_left E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b c d : α}, a ⊓ b = a ⊓ c → d ≤ a → d ⊓ b = d ⊓ c

theorem inf_eq_inf_mono_right E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b c d : α}, a ⊓ c = b ⊓ c → d ≤ c → a ⊓ d = b ⊓ d

theorem sup_eq_sup_mono_right E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b c d : α}, a ⊔ c = b ⊔ c → c ≤ d → a ⊔ d = b ⊔ d

theorem Ne.lt_sup_or_lt_sup E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {a b : α}, a ≠ b → a < a ⊔ b ∨ b < a ⊔ b

theorem Ne.inf_lt_or_inf_lt E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {a b : α}, a ≠ b → a ⊓ b < a ∨ a ⊓ b < b

theorem ite_le_sup E1 #

∀ {α : Type u} [inst : SemilatticeSup α] (a b : α) (P : Prop) [inst_1 : Decidable P], (if P then a else b) ≤ a ⊔ b

theorem inf_le_ite E1 #

∀ {α : Type u} [inst : SemilatticeInf α] (a b : α) (P : Prop) [inst_1 : Decidable P], a ⊓ b ≤ if P then a else b

theorem SemilatticeInf.ext_inf E1 #

∀ {α : Type u_1} {A B : SemilatticeInf α}, (∀ (y x : α), y ≤ x ↔ y ≤ x) → ∀ (x y : α), x ⊓ y = x ⊓ y

theorem SemilatticeSup.ext_sup E1 #

∀ {α : Type u_1} {A B : SemilatticeSup α}, (∀ (x y : α), x ≤ y ↔ x ≤ y) → ∀ (x y : α), x ⊔ y = x ⊔ y

theorem SemilatticeSup.ext E1 #

∀ {α : Type u_1} {A B : SemilatticeSup α}, (∀ (x y : α), x ≤ y ↔ x ≤ y) → A = B

theorem SemilatticeInf.ext E1 #

∀ {α : Type u_1} {A B : SemilatticeInf α}, (∀ (y x : α), y ≤ x ↔ y ≤ x) → A = B

instance OrderDual.instSemilatticeInf E0 #

(α : Type u_1) → [h : SemilatticeSup α] → SemilatticeInf αᵒᵈ

instance OrderDual.instSemilatticeSup E0 #

(α : Type u_1) → [h : SemilatticeInf α] → SemilatticeSup αᵒᵈ

theorem SemilatticeInf.dual_dual E1 #

∀ (α : Type u_1) [H : SemilatticeInf α], OrderDual.instSemilatticeInf αᵒᵈ = H

theorem SemilatticeSup.dual_dual E1 #

∀ (α : Type u_1) [H : SemilatticeSup α], OrderDual.instSemilatticeSup αᵒᵈ = H

abbrev SemilatticeSup.decidableLEOfDecidableEq E1 #

(α : Type u) → [inst : SemilatticeSup α] → [DecidableEq α] → DecidableLE α

In a (semi)lattice, a ≤ b can be decided by checking if a ⊔ b = b.

abbrev SemilatticeInf.decidableLEOfDecidableEq E1 #

(α : Type u) → [inst : SemilatticeInf α] → [DecidableEq α] → DecidableLE α

In a (semi)lattice, a ≤ b can be decided by checking if b ⊓ a = a.

instance OrderDual.instLattice E0 #

(α : Type u_1) → [Lattice α] → Lattice αᵒᵈ

theorem semilatticeSup_mk'_partialOrder_eq_semilatticeInf_mk'_partialOrder E1 #

∀ {α : Type u_1} [inst : Max α] [inst_1 : Min α] (sup_comm : ∀ (a b : α), a ⊔ b = b ⊔ a)
  (sup_assoc : ∀ (a b c : α), a ⊔ b ⊔ c = a ⊔ (b ⊔ c)) (sup_idem : ∀ (a : α), a ⊔ a = a)
  (inf_comm : ∀ (a b : α), a ⊓ b = b ⊓ a) (inf_assoc : ∀ (a b c : α), a ⊓ b ⊓ c = a ⊓ (b ⊓ c))
  (inf_idem : ∀ (a : α), a ⊓ a = a),
  (∀ (a b : α), a ⊔ a ⊓ b = a) →
    (∀ (a b : α), a ⊓ (a ⊔ b) = a) →
      (SemilatticeSup.mk' sup_comm sup_assoc sup_idem).toPartialOrder =
        (SemilatticeInf.mk' inf_comm inf_assoc inf_idem).toPartialOrder

The partial orders from SemilatticeSup_mk' and SemilatticeInf_mk' agree if sup and inf satisfy the lattice absorption laws sup_inf_self (a ⊔ a ⊓ b = a) and inf_sup_self (a ⊓ (a ⊔ b) = a).

def Lattice.mk' E3 #

{α : Type u_1} →
  [inst : Max α] →
    [inst_1 : Min α] →
      (∀ (a b : α), a ⊔ b = b ⊔ a) →
        (∀ (a b c : α), a ⊔ b ⊔ c = a ⊔ (b ⊔ c)) →
          (∀ (a b : α), a ⊓ b = b ⊓ a) →
            (∀ (a b c : α), a ⊓ b ⊓ c = a ⊓ (b ⊓ c)) →
              (∀ (a b : α), a ⊔ a ⊓ b = a) → (∀ (a b : α), a ⊓ (a ⊔ b) = a) → Lattice α

A type with a pair of commutative and associative binary operations which satisfy two absorption laws relating the two operations has the structure of a lattice.

The partial order is defined so that a ≤ b unfolds to a ⊔ b = b; cf. sup_eq_right.

theorem inf_eq_sup E0 #

∀ {α : Type u} [inst : Lattice α] {a b : α}, a ⊓ b = a ⊔ b ↔ a = b

theorem sup_eq_inf E0 #

∀ {α : Type u} [inst : Lattice α] {a b : α}, a ⊔ b = a ⊓ b ↔ a = b

theorem inf_lt_sup E0 #

∀ {α : Type u} [inst : Lattice α] {a b : α}, a ⊓ b < a ⊔ b ↔ a ≠ b

theorem sup_eq_and_inf_eq_iff E0 #

∀ {α : Type u} [inst : Lattice α] {a b c : α}, a ⊔ b = c ∧ a ⊓ b = c ↔ a = c ∧ b = c

theorem inf_eq_and_sup_eq_iff E0 #

∀ {α : Type u} [inst : Lattice α] {a b c : α}, a ⊓ b = c ∧ a ⊔ b = c ↔ a = c ∧ b = c

theorem Lattice.ext E1 #

∀ {α : Type u_1} {A B : Lattice α}, (∀ (x y : α), x ≤ y ↔ x ≤ y) → A = B

instance OrderDual.instDistribLattice E0 #

(α : Type u_1) → [DistribLattice α] → DistribLattice αᵒᵈ

instance LinearOrder.toLattice E0 #

{α : Type u} → [LinearOrder α] → Lattice α

theorem sup_ind E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b : α) {p : α → Prop}, p a → p b → p (max a b)

theorem inf_ind E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b : α) {p : α → Prop}, p a → p b → p (min a b)

theorem inf_le_iff E0 #

∀ {α : Type u} [inst : LinearOrder α] {a b c : α}, min b c ≤ a ↔ b ≤ a ∨ c ≤ a

theorem le_sup_iff E0 #

∀ {α : Type u} [inst : LinearOrder α] {a b c : α}, a ≤ max b c ↔ a ≤ b ∨ a ≤ c

theorem lt_sup_iff E0 #

∀ {α : Type u} [inst : LinearOrder α] {a b c : α}, a < max b c ↔ a < b ∨ a < c

theorem inf_lt_iff E0 #

∀ {α : Type u} [inst : LinearOrder α] {a b c : α}, min b c < a ↔ b < a ∨ c < a

theorem lt_inf_iff E0 #

∀ {α : Type u} [inst : LinearOrder α] {a b c : α}, a < min b c ↔ a < b ∧ a < c

theorem sup_lt_iff E0 #

∀ {α : Type u} [inst : LinearOrder α] {a b c : α}, max b c < a ↔ b < a ∧ c < a

theorem min_min_min_comm E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b c d : α), min (min a b) (min c d) = min (min a c) (min b d)

theorem max_max_max_comm E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b c d : α), max (max a b) (max c d) = max (max a c) (max b d)

theorem sup_eq_maxDefault E1 #

∀ {α : Type u} [inst : SemilatticeSup α] [inst_1 : DecidableLE α] [Std.Total fun x1 x2 ↦ x1 ≤ x2],
  (fun x1 x2 ↦ x1 ⊔ x2) = maxDefault

theorem inf_eq_minDefault E1 #

∀ {α : Type u} [inst : SemilatticeInf α] [inst_1 : DecidableLE α] [Std.Total fun x1 x2 ↦ x1 ≤ x2],
  (fun x1 x2 ↦ x1 ⊓ x2) = minDefault

abbrev Lattice.toLinearOrder E1 #

(α : Type u) →
  [inst : Lattice α] →
    [DecidableEq α] → [DecidableLE α] → [DecidableLT α] → [Std.Total fun x1 x2 ↦ x1 ≤ x2] → LinearOrder α

A lattice with total order is a linear order.

See note [reducible non-instances].

instance instDistribLatticeOfLinearOrder E0 #

{α : Type u} → [LinearOrder α] → DistribLattice α

instance instDistribLatticeNat E0 #

DistribLattice ℕ

instance instLatticeInt E0 #

Lattice ℤ

theorem ofDual_inf E0 #

∀ {α : Type u} [inst : Max α] (a b : αᵒᵈ), OrderDual.ofDual (a ⊓ b) = OrderDual.ofDual a ⊔ OrderDual.ofDual b

theorem ofDual_sup E0 #

∀ {α : Type u} [inst : Min α] (a b : αᵒᵈ), OrderDual.ofDual (a ⊔ b) = OrderDual.ofDual a ⊓ OrderDual.ofDual b

theorem toDual_sup E0 #

∀ {α : Type u} [inst : Max α] (a b : α), OrderDual.toDual (a ⊔ b) = OrderDual.toDual a ⊓ OrderDual.toDual b

theorem toDual_inf E0 #

∀ {α : Type u} [inst : Min α] (a b : α), OrderDual.toDual (a ⊓ b) = OrderDual.toDual a ⊔ OrderDual.toDual b

theorem ofDual_max E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b : αᵒᵈ),
  OrderDual.ofDual (max a b) = min (OrderDual.ofDual a) (OrderDual.ofDual b)

theorem ofDual_min E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b : αᵒᵈ),
  OrderDual.ofDual (min a b) = max (OrderDual.ofDual a) (OrderDual.ofDual b)

theorem toDual_max E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b : α),
  OrderDual.toDual (max a b) = min (OrderDual.toDual a) (OrderDual.toDual b)

theorem toDual_min E1 #

∀ {α : Type u} [inst : LinearOrder α] (a b : α),
  OrderDual.toDual (min a b) = max (OrderDual.toDual a) (OrderDual.toDual b)

instance Pi.instMinForall_mathlib E0 #

{ι : Type u_1} → {α' : ι → Type u_2} → [(i : ι) → Min (α' i)] → Min ((i : ι) → α' i)

instance Pi.instMaxForall_mathlib E0 #

{ι : Type u_1} → {α' : ι → Type u_2} → [(i : ι) → Max (α' i)] → Max ((i : ι) → α' i)

theorem Pi.sup_apply E0 #

∀ {ι : Type u_1} {α' : ι → Type u_2} [inst : (i : ι) → Max (α' i)] (f g : (i : ι) → α' i) (i : ι), (f ⊔ g) i = f i ⊔ g i

theorem Pi.inf_apply E0 #

∀ {ι : Type u_1} {α' : ι → Type u_2} [inst : (i : ι) → Min (α' i)] (f g : (i : ι) → α' i) (i : ι), (f ⊓ g) i = f i ⊓ g i

theorem Pi.inf_def E0 #

∀ {ι : Type u_1} {α' : ι → Type u_2} [inst : (i : ι) → Min (α' i)] (f g : (i : ι) → α' i), f ⊓ g = fun i ↦ f i ⊓ g i

theorem Pi.sup_def E0 #

∀ {ι : Type u_1} {α' : ι → Type u_2} [inst : (i : ι) → Max (α' i)] (f g : (i : ι) → α' i), f ⊔ g = fun i ↦ f i ⊔ g i

instance Pi.instSemilatticeSup E0 #

{ι : Type u_1} → {α' : ι → Type u_2} → [(i : ι) → SemilatticeSup (α' i)] → SemilatticeSup ((i : ι) → α' i)

instance Pi.instSemilatticeInf E0 #

{ι : Type u_1} → {α' : ι → Type u_2} → [(i : ι) → SemilatticeInf (α' i)] → SemilatticeInf ((i : ι) → α' i)

instance Pi.instLattice E0 #

{ι : Type u_1} → {α' : ι → Type u_2} → [(i : ι) → Lattice (α' i)] → Lattice ((i : ι) → α' i)

instance Pi.instDistribLattice E0 #

{ι : Type u_1} → {α' : ι → Type u_2} → [(i : ι) → DistribLattice (α' i)] → DistribLattice ((i : ι) → α' i)

theorem Function.update_inf E1 #

∀ {ι : Type u_1} {π : ι → Type u_2} [inst : DecidableEq ι] [inst_1 : (i : ι) → SemilatticeInf (π i)] (f : (i : ι) → π i)
  (i : ι) (a b : π i), Function.update f i (a ⊓ b) = Function.update f i a ⊓ Function.update f i b

theorem Function.update_sup E1 #

∀ {ι : Type u_1} {π : ι → Type u_2} [inst : DecidableEq ι] [inst_1 : (i : ι) → SemilatticeSup (π i)] (f : (i : ι) → π i)
  (i : ι) (a b : π i), Function.update f i (a ⊔ b) = Function.update f i a ⊔ Function.update f i b

theorem Monotone.sup E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeSup β] {f g : α → β},
  Monotone f → Monotone g → Monotone (f ⊔ g)

Pointwise supremum of two monotone functions is a monotone function.

theorem Monotone.inf E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeInf β] {f g : α → β},
  Monotone f → Monotone g → Monotone (f ⊓ g)

Pointwise infimum of two monotone functions is a monotone function.

theorem Monotone.max E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β},
  Monotone f → Monotone g → Monotone fun x ↦ max (f x) (g x)

Pointwise maximum of two monotone functions is a monotone function.

theorem Monotone.min E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β},
  Monotone f → Monotone g → Monotone fun x ↦ min (f x) (g x)

Pointwise minimum of two monotone functions is a monotone function.

theorem Monotone.le_map_sup E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeSup α] [inst_1 : SemilatticeSup β] {f : α → β},
  Monotone f → ∀ (x y : α), f x ⊔ f y ≤ f (x ⊔ y)

theorem Monotone.map_inf_le E0 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeInf α] [inst_1 : SemilatticeInf β] {f : α → β},
  Monotone f → ∀ (x y : α), f (x ⊓ y) ≤ f x ⊓ f y

theorem Monotone.of_map_inf_le_left E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeInf α] [inst_1 : Preorder β] {f : α → β},
  (∀ (x y : α), f (x ⊓ y) ≤ f x) → Monotone f

theorem Monotone.of_left_le_map_sup E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeSup α] [inst_1 : Preorder β] {f : α → β},
  (∀ (x y : α), f x ≤ f (x ⊔ y)) → Monotone f

theorem Monotone.of_le_map_sup E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeSup α] [inst_1 : SemilatticeSup β] {f : α → β},
  (∀ (x y : α), f x ⊔ f y ≤ f (x ⊔ y)) → Monotone f

theorem Monotone.of_map_inf_le E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeInf α] [inst_1 : SemilatticeInf β] {f : α → β},
  (∀ (x y : α), f (x ⊓ y) ≤ f x ⊓ f y) → Monotone f

theorem Monotone.of_map_inf E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeInf α] [inst_1 : SemilatticeInf β] {f : α → β},
  (∀ (x y : α), f (x ⊓ y) = f x ⊓ f y) → Monotone f

theorem Monotone.of_map_sup E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeSup α] [inst_1 : SemilatticeSup β] {f : α → β},
  (∀ (x y : α), f (x ⊔ y) = f x ⊔ f y) → Monotone f

theorem Monotone.map_sup E0 #

∀ {α : Type u} {β : Type v} [inst : LinearOrder α] [inst_1 : SemilatticeSup β] {f : α → β},
  Monotone f → ∀ (x y : α), f (max x y) = f x ⊔ f y

theorem Monotone.map_inf E0 #

∀ {α : Type u} {β : Type v} [inst : LinearOrder α] [inst_1 : SemilatticeInf β] {f : α → β},
  Monotone f → ∀ (x y : α), f (min x y) = f x ⊓ f y

theorem exists_ge_and_iff_exists E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {P : α → Prop} {x₀ : α}, Monotone P → ((∃ x, x₀ ≤ x ∧ P x) ↔ ∃ x, P x)

theorem exists_and_iff_of_monotone E1 #

∀ {α : Type u} [inst : SemilatticeSup α] {P Q : α → Prop},
  Monotone P → Monotone Q → (((∃ x, P x) ∧ ∃ x, Q x) ↔ ∃ x, P x ∧ Q x)

theorem MonotoneOn.sup E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeSup β] {f g : α → β} {s : Set α},
  MonotoneOn f s → MonotoneOn g s → MonotoneOn (f ⊔ g) s

Pointwise supremum of two monotone functions is a monotone function.

theorem MonotoneOn.inf E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeInf β] {f g : α → β} {s : Set α},
  MonotoneOn f s → MonotoneOn g s → MonotoneOn (f ⊓ g) s

Pointwise infimum of two monotone functions is a monotone function.

theorem MonotoneOn.max E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β} {s : Set α},
  MonotoneOn f s → MonotoneOn g s → MonotoneOn (fun x ↦ max (f x) (g x)) s

Pointwise maximum of two monotone functions is a monotone function.

theorem MonotoneOn.min E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β} {s : Set α},
  MonotoneOn f s → MonotoneOn g s → MonotoneOn (fun x ↦ min (f x) (g x)) s

Pointwise minimum of two monotone functions is a monotone function.

theorem MonotoneOn.of_map_inf E1 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} [inst : SemilatticeInf α] [inst_1 : SemilatticeInf β],
  (∀ x ∈ s, ∀ y ∈ s, f (x ⊓ y) = f x ⊓ f y) → MonotoneOn f s

theorem MonotoneOn.of_map_sup E1 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} [inst : SemilatticeSup α] [inst_1 : SemilatticeSup β],
  (∀ x ∈ s, ∀ y ∈ s, f (x ⊔ y) = f x ⊔ f y) → MonotoneOn f s

theorem MonotoneOn.map_inf E0 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} {x y : α} [inst : LinearOrder α] [inst_1 : SemilatticeInf β],
  MonotoneOn f s → x ∈ s → y ∈ s → f (min x y) = f x ⊓ f y

theorem MonotoneOn.map_sup E0 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} {x y : α} [inst : LinearOrder α] [inst_1 : SemilatticeSup β],
  MonotoneOn f s → x ∈ s → y ∈ s → f (max x y) = f x ⊔ f y

theorem Antitone.sup E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeSup β] {f g : α → β},
  Antitone f → Antitone g → Antitone (f ⊔ g)

Pointwise supremum of two antitone functions is an antitone function.

theorem Antitone.inf E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeInf β] {f g : α → β},
  Antitone f → Antitone g → Antitone (f ⊓ g)

Pointwise infimum of two antitone functions is an antitone function.

theorem Antitone.max E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β},
  Antitone f → Antitone g → Antitone fun x ↦ max (f x) (g x)

Pointwise maximum of two antitone functions is an antitone function.

theorem Antitone.min E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β},
  Antitone f → Antitone g → Antitone fun x ↦ min (f x) (g x)

Pointwise minimum of two antitone functions is an antitone function.

theorem Antitone.le_map_inf E1 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeInf α] [inst_1 : SemilatticeSup β] {f : α → β},
  Antitone f → ∀ (x y : α), f x ⊔ f y ≤ f (x ⊓ y)

theorem Antitone.map_sup_le E0 #

∀ {α : Type u} {β : Type v} [inst : SemilatticeSup α] [inst_1 : SemilatticeInf β] {f : α → β},
  Antitone f → ∀ (x y : α), f (x ⊔ y) ≤ f x ⊓ f y

theorem Antitone.map_inf E0 #

∀ {α : Type u} {β : Type v} [inst : LinearOrder α] [inst_1 : SemilatticeSup β] {f : α → β},
  Antitone f → ∀ (x y : α), f (min x y) = f x ⊔ f y

theorem Antitone.map_sup E0 #

∀ {α : Type u} {β : Type v} [inst : LinearOrder α] [inst_1 : SemilatticeInf β] {f : α → β},
  Antitone f → ∀ (x y : α), f (max x y) = f x ⊓ f y

theorem exists_le_and_iff_exists E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {P : α → Prop} {x₀ : α}, Antitone P → ((∃ x ≤ x₀, P x) ↔ ∃ x, P x)

theorem exists_and_iff_of_antitone E1 #

∀ {α : Type u} [inst : SemilatticeInf α] {P Q : α → Prop},
  Antitone P → Antitone Q → (((∃ x, P x) ∧ ∃ x, Q x) ↔ ∃ x, P x ∧ Q x)

theorem AntitoneOn.sup E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeSup β] {f g : α → β} {s : Set α},
  AntitoneOn f s → AntitoneOn g s → AntitoneOn (f ⊔ g) s

Pointwise supremum of two antitone functions is an antitone function.

theorem AntitoneOn.inf E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : SemilatticeInf β] {f g : α → β} {s : Set α},
  AntitoneOn f s → AntitoneOn g s → AntitoneOn (f ⊓ g) s

Pointwise infimum of two antitone functions is an antitone function.

theorem AntitoneOn.max E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β} {s : Set α},
  AntitoneOn f s → AntitoneOn g s → AntitoneOn (fun x ↦ max (f x) (g x)) s

Pointwise maximum of two antitone functions is an antitone function.

theorem AntitoneOn.min E1 #

∀ {α : Type u} {β : Type v} [inst : Preorder α] [inst_1 : LinearOrder β] {f g : α → β} {s : Set α},
  AntitoneOn f s → AntitoneOn g s → AntitoneOn (fun x ↦ min (f x) (g x)) s

Pointwise minimum of two antitone functions is an antitone function.

theorem AntitoneOn.of_map_sup E1 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} [inst : SemilatticeSup α] [inst_1 : SemilatticeInf β],
  (∀ x ∈ s, ∀ y ∈ s, f (x ⊔ y) = f x ⊓ f y) → AntitoneOn f s

theorem AntitoneOn.of_map_inf E1 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} [inst : SemilatticeInf α] [inst_1 : SemilatticeSup β],
  (∀ x ∈ s, ∀ y ∈ s, f (x ⊓ y) = f x ⊔ f y) → AntitoneOn f s

theorem AntitoneOn.map_inf E0 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} {x y : α} [inst : LinearOrder α] [inst_1 : SemilatticeSup β],
  AntitoneOn f s → x ∈ s → y ∈ s → f (min x y) = f x ⊔ f y

theorem AntitoneOn.map_sup E0 #

∀ {α : Type u} {β : Type v} {f : α → β} {s : Set α} {x y : α} [inst : LinearOrder α] [inst_1 : SemilatticeInf β],
  AntitoneOn f s → x ∈ s → y ∈ s → f (max x y) = f x ⊓ f y

instance Prod.instMax_mathlib E0 #

(α : Type u) → (β : Type v) → [Max α] → [Max β] → Max (α × β)

instance Prod.instMin_mathlib E0 #

(α : Type u) → (β : Type v) → [Min α] → [Min β] → Min (α × β)

theorem Prod.mk_inf_mk E0 #

∀ (α : Type u) (β : Type v) [inst : Min α] [inst_1 : Min β] (a₁ a₂ : α) (b₁ b₂ : β),
  (a₁, b₁) ⊓ (a₂, b₂) = (a₁ ⊓ a₂, b₁ ⊓ b₂)

theorem Prod.mk_sup_mk E0 #

∀ (α : Type u) (β : Type v) [inst : Max α] [inst_1 : Max β] (a₁ a₂ : α) (b₁ b₂ : β),
  (a₁, b₁) ⊔ (a₂, b₂) = (a₁ ⊔ a₂, b₁ ⊔ b₂)

theorem Prod.fst_inf E0 #

∀ (α : Type u) (β : Type v) [inst : Min α] [inst_1 : Min β] (p q : α × β), (p ⊓ q).1 = p.1 ⊓ q.1

theorem Prod.fst_sup E0 #

∀ (α : Type u) (β : Type v) [inst : Max α] [inst_1 : Max β] (p q : α × β), (p ⊔ q).1 = p.1 ⊔ q.1

theorem Prod.snd_inf E0 #

∀ (α : Type u) (β : Type v) [inst : Min α] [inst_1 : Min β] (p q : α × β), (p ⊓ q).2 = p.2 ⊓ q.2

theorem Prod.snd_sup E0 #

∀ (α : Type u) (β : Type v) [inst : Max α] [inst_1 : Max β] (p q : α × β), (p ⊔ q).2 = p.2 ⊔ q.2

theorem Prod.swap_sup E0 #

∀ (α : Type u) (β : Type v) [inst : Max α] [inst_1 : Max β] (p q : α × β), (p ⊔ q).swap = p.swap ⊔ q.swap

theorem Prod.swap_inf E0 #

∀ (α : Type u) (β : Type v) [inst : Min α] [inst_1 : Min β] (p q : α × β), (p ⊓ q).swap = p.swap ⊓ q.swap

theorem Prod.sup_def E0 #

∀ (α : Type u) (β : Type v) [inst : Max α] [inst_1 : Max β] (p q : α × β), p ⊔ q = (p.1 ⊔ q.1, p.2 ⊔ q.2)

theorem Prod.inf_def E0 #

∀ (α : Type u) (β : Type v) [inst : Min α] [inst_1 : Min β] (p q : α × β), p ⊓ q = (p.1 ⊓ q.1, p.2 ⊓ q.2)

instance Prod.instSemilatticeInf E0 #

(α : Type u) → (β : Type v) → [SemilatticeInf α] → [SemilatticeInf β] → SemilatticeInf (α × β)

instance Prod.instSemilatticeSup E0 #

(α : Type u) → (β : Type v) → [SemilatticeSup α] → [SemilatticeSup β] → SemilatticeSup (α × β)

instance Prod.instLattice E0 #

(α : Type u) → (β : Type v) → [Lattice α] → [Lattice β] → Lattice (α × β)

instance Prod.instDistribLattice E0 #

(α : Type u) → (β : Type v) → [DistribLattice α] → [DistribLattice β] → DistribLattice (α × β)

abbrev Subtype.semilatticeSup E1 #

{α : Type u} →
  [inst : SemilatticeSup α] → {P : α → Prop} → (∀ ⦃x y : α⦄, P x → P y → P (x ⊔ y)) → SemilatticeSup { x // P x }

A subtype forms a ⊔-semilattice if ⊔ preserves the property. See note [reducible non-instances].

abbrev Subtype.semilatticeInf E1 #

{α : Type u} →
  [inst : SemilatticeInf α] → {P : α → Prop} → (∀ ⦃x y : α⦄, P x → P y → P (x ⊓ y)) → SemilatticeInf { x // P x }

A subtype forms a ⊓-semilattice if ⊓ preserves the property. See note [reducible non-instances].

abbrev Subtype.lattice E1 #

{α : Type u} →
  [inst : Lattice α] →
    {P : α → Prop} → (∀ ⦃x y : α⦄, P x → P y → P (x ⊔ y)) → (∀ ⦃x y : α⦄, P x → P y → P (x ⊓ y)) → Lattice { x // P x }

A subtype forms a lattice if ⊔ and ⊓ preserve the property. See note [reducible non-instances].

theorem Subtype.coe_sup E0 #

∀ {α : Type u} [inst : SemilatticeSup α] {P : α → Prop} (Psup : ∀ ⦃x y : α⦄, P x → P y → P (x ⊔ y)) (x y : Subtype P),
  ↑(x ⊔ y) = ↑x ⊔ ↑y

theorem Subtype.coe_inf E0 #

∀ {α : Type u} [inst : SemilatticeInf α] {P : α → Prop} (Pinf : ∀ ⦃x y : α⦄, P x → P y → P (x ⊓ y)) (x y : Subtype P),
  ↑(x ⊓ y) = ↑x ⊓ ↑y

theorem Subtype.mk_inf_mk E0 #

∀ {α : Type u} [inst : SemilatticeInf α] {P : α → Prop} (Pinf : ∀ ⦃x y : α⦄, P x → P y → P (x ⊓ y)) {x y : α} (hx : P x)
  (hy : P y), ⟨x, hx⟩ ⊓ ⟨y, hy⟩ = ⟨x ⊓ y, ⋯⟩

theorem Subtype.mk_sup_mk E0 #

∀ {α : Type u} [inst : SemilatticeSup α] {P : α → Prop} (Psup : ∀ ⦃x y : α⦄, P x → P y → P (x ⊔ y)) {x y : α} (hx : P x)
  (hy : P y), ⟨x, hx⟩ ⊔ ⟨y, hy⟩ = ⟨x ⊔ y, ⋯⟩

abbrev Function.Injective.semilatticeSup E1 #

{α : Type u} →
  {β : Type v} →
    [inst : Max α] →
      [inst_1 : LE α] →
        [inst_2 : LT α] →
          [inst_3 : SemilatticeSup β] →
            (f : α → β) →
              Function.Injective f →
                (∀ {x y : α}, f x ≤ f y ↔ x ≤ y) →
                  (∀ {x y : α}, f x < f y ↔ x < y) → (∀ (a b : α), f (a ⊔ b) = f a ⊔ f b) → SemilatticeSup α

A type endowed with ⊔ is a SemilatticeSup, if it admits an injective map that preserves ⊔ to a SemilatticeSup. See note [reducible non-instances].

abbrev Function.Injective.semilatticeInf E1 #

{α : Type u} →
  {β : Type v} →
    [inst : Min α] →
      [inst_1 : LE α] →
        [inst_2 : LT α] →
          [inst_3 : SemilatticeInf β] →
            (f : α → β) →
              Function.Injective f →
                (∀ {x y : α}, f y ≤ f x ↔ y ≤ x) →
                  (∀ {x y : α}, f y < f x ↔ y < x) → (∀ (a b : α), f (a ⊓ b) = f a ⊓ f b) → SemilatticeInf α

A type endowed with ⊓ is a SemilatticeInf, if it admits an injective map that preserves ⊓ to a SemilatticeInf. See note [reducible non-instances].

abbrev Function.Injective.lattice E1 #

{α : Type u} →
  {β : Type v} →
    [inst : Max α] →
      [inst_1 : Min α] →
        [inst_2 : LE α] →
          [inst_3 : LT α] →
            [inst_4 : Lattice β] →
              (f : α → β) →
                Function.Injective f →
                  (∀ {x y : α}, f x ≤ f y ↔ x ≤ y) →
                    (∀ {x y : α}, f x < f y ↔ x < y) →
                      (∀ (a b : α), f (a ⊔ b) = f a ⊔ f b) → (∀ (a b : α), f (a ⊓ b) = f a ⊓ f b) → Lattice α

A type endowed with ⊔ and ⊓ is a Lattice, if it admits an injective map that preserves ⊔ and ⊓ to a Lattice. See note [reducible non-instances].

abbrev Function.Injective.distribLattice E1 #

{α : Type u} →
  {β : Type v} →
    [inst : Max α] →
      [inst_1 : Min α] →
        [inst_2 : LE α] →
          [inst_3 : LT α] →
            [inst_4 : DistribLattice β] →
              (f : α → β) →
                Function.Injective f →
                  (∀ {x y : α}, f x ≤ f y ↔ x ≤ y) →
                    (∀ {x y : α}, f x < f y ↔ x < y) →
                      (∀ (a b : α), f (a ⊔ b) = f a ⊔ f b) → (∀ (a b : α), f (a ⊓ b) = f a ⊓ f b) → DistribLattice α

A type endowed with ⊔ and ⊓ is a DistribLattice, if it admits an injective map that preserves ⊔ and ⊓ to a DistribLattice. See note [reducible non-instances].

abbrev Subtype.distribLattice E1 #

{α : Type u} →
  [inst : DistribLattice α] →
    {P : α → Prop} →
      (∀ ⦃s t : α⦄, P s → P t → P (s ⊔ t)) → (∀ ⦃s t : α⦄, P s → P t → P (s ⊓ t)) → DistribLattice (Subtype P)

A subtype forms a distributive lattice if ⊔ and ⊓ preserve the property. See note [reducible non-instances].

abbrev Equiv.preorder E1 #

{α : Type u} → {β : Type v} → α ≃ β → [Preorder β] → Preorder α

Transfer Preorder across an Equiv.

abbrev Equiv.partialOrder E1 #

{α : Type u} → {β : Type v} → α ≃ β → [PartialOrder β] → PartialOrder α

Transfer PartialOrder across an Equiv.

abbrev Equiv.linearOrder E1 #

{α : Type u} → {β : Type v} → α ≃ β → [LinearOrder β] → [DecidableEq α] → LinearOrder α

Transfer LinearOrder across an Equiv.

abbrev Equiv.semilatticeSup E1 #

{α : Type u} → {β : Type v} → α ≃ β → [SemilatticeSup β] → SemilatticeSup α

Transfer SemilatticeSup across an Equiv.

abbrev Equiv.semilatticeInf E1 #

{α : Type u} → {β : Type v} → α ≃ β → [SemilatticeInf β] → SemilatticeInf α

Transfer SemilatticeInf across an Equiv.

abbrev Equiv.lattice E1 #

{α : Type u} → {β : Type v} → α ≃ β → [Lattice β] → Lattice α

Transfer Lattice across an Equiv.

abbrev Equiv.distribLattice E1 #

{α : Type u} → {β : Type v} → α ≃ β → [DistribLattice β] → DistribLattice α

Transfer DistribLattice across an Equiv.

instance ULift.instSemilatticeInf E0 #

{α : Type u} → [SemilatticeInf α] → SemilatticeInf (ULift.{v, u} α)

instance ULift.instSemilatticeSup E0 #

{α : Type u} → [SemilatticeSup α] → SemilatticeSup (ULift.{v, u} α)

instance ULift.instLattice E0 #

{α : Type u} → [Lattice α] → Lattice (ULift.{v, u} α)

instance ULift.instDistribLattice E0 #

{α : Type u} → [DistribLattice α] → DistribLattice (ULift.{v, u} α)

instance ULift.instLinearOrder E0 #

{α : Type u} → [LinearOrder α] → LinearOrder (ULift.{v, u} α)

instance Bool.instPartialOrder E0 #

PartialOrder Bool

instance Bool.instDistribLattice E0 #

DistribLattice Bool

theorem pairwise_iff_lt E1 #

∀ {α : Type u} [inst : LinearOrder α] {p : α → α → Prop} [Std.Symm p], Pairwise p ↔ ∀ ⦃a b : α⦄, a < b → p a b

theorem pairwise_iff_gt E1 #

∀ {α : Type u} [inst : LinearOrder α] {p : α → α → Prop} [Std.Symm p], Pairwise p ↔ ∀ ⦃a b : α⦄, b < a → p a b

theorem Pairwise.of_lt E1 #

∀ {α : Type u} [inst : LinearOrder α] {p : α → α → Prop} [Std.Symm p], (∀ ⦃a b : α⦄, a < b → p a b) → Pairwise p

Alias of the reverse direction of pairwise_iff_lt.

theorem Pairwise.of_gt E1 #

∀ {α : Type u} [inst : LinearOrder α] {p : α → α → Prop} [Std.Symm p], (∀ ⦃a b : α⦄, b < a → p a b) → Pairwise p

Alias of the reverse direction of pairwise_iff_gt.