Documentation

Mathlib.Data.Set.Pairwise.Basic

Relations holding pairwise #

This file develops pairwise relations and defines pairwise disjoint indexed sets.

We also prove many basic facts about Pairwise. It is possible that an intermediate file, with more imports than Logic.Pairwise but not importing Data.Set.Function would be appropriate to hold many of these basic facts.

Main declarations #

Notes #

The spelling s.PairwiseDisjoint id is preferred over s.Pairwise Disjoint to permit dot notation on Set.PairwiseDisjoint, even though the latter unfolds to something nicer.

theorem pairwise_on_bool {α : Type u_1} {r : ααProp} (hr : Symmetric r) {a : α} {b : α} :
Pairwise (r on fun (c : Bool) => bif c then a else b) r a b
theorem pairwise_disjoint_on_bool {α : Type u_1} [SemilatticeInf α] [OrderBot α] {a : α} {b : α} :
Pairwise (Disjoint on fun (c : Bool) => bif c then a else b) Disjoint a b
theorem Symmetric.pairwise_on {α : Type u_1} {ι : Type u_4} {r : ααProp} [LinearOrder ι] (hr : Symmetric r) (f : ια) :
Pairwise (r on f) ∀ ⦃m n : ι⦄, m < nr (f m) (f n)
theorem pairwise_disjoint_on {α : Type u_1} {ι : Type u_4} [SemilatticeInf α] [OrderBot α] [LinearOrder ι] (f : ια) :
Pairwise (Disjoint on f) ∀ ⦃m n : ι⦄, m < nDisjoint (f m) (f n)
theorem pairwise_disjoint_mono {α : Type u_1} {ι : Type u_4} {f : ια} {g : ια} [SemilatticeInf α] [OrderBot α] (hs : Pairwise (Disjoint on f)) (h : g f) :
Pairwise (Disjoint on g)
theorem Set.Pairwise.mono {α : Type u_1} {r : ααProp} {s : Set α} {t : Set α} (h : t s) (hs : Set.Pairwise s r) :
theorem Set.Pairwise.mono' {α : Type u_1} {r : ααProp} {p : ααProp} {s : Set α} (H : r p) (hr : Set.Pairwise s r) :
theorem Set.pairwise_top {α : Type u_1} (s : Set α) :
theorem Set.Subsingleton.pairwise {α : Type u_1} {s : Set α} (h : Set.Subsingleton s) (r : ααProp) :
@[simp]
theorem Set.pairwise_empty {α : Type u_1} (r : ααProp) :
@[simp]
theorem Set.pairwise_singleton {α : Type u_1} (a : α) (r : ααProp) :
theorem Set.pairwise_iff_of_refl {α : Type u_1} {r : ααProp} {s : Set α} [IsRefl α r] :
Set.Pairwise s r ∀ ⦃a : α⦄, a s∀ ⦃b : α⦄, b sr a b
theorem Set.Pairwise.of_refl {α : Type u_1} {r : ααProp} {s : Set α} [IsRefl α r] :
Set.Pairwise s r∀ ⦃a : α⦄, a s∀ ⦃b : α⦄, b sr a b

Alias of the forward direction of Set.pairwise_iff_of_refl.

theorem Set.Nonempty.pairwise_iff_exists_forall {α : Type u_1} {ι : Type u_4} {r : ααProp} {f : ια} [IsEquiv α r] {s : Set ι} (hs : Set.Nonempty s) :
Set.Pairwise s (r on f) ∃ (z : α), xs, r (f x) z
theorem Set.Nonempty.pairwise_eq_iff_exists_eq {α : Type u_1} {ι : Type u_4} {s : Set α} (hs : Set.Nonempty s) {f : αι} :
(Set.Pairwise s fun (x y : α) => f x = f y) ∃ (z : ι), xs, f x = z

For a nonempty set s, a function f takes pairwise equal values on s if and only if for some z in the codomain, f takes value z on all x ∈ s. See also Set.pairwise_eq_iff_exists_eq for a version that assumes [Nonempty ι] instead of Set.Nonempty s.

theorem Set.pairwise_iff_exists_forall {α : Type u_1} {ι : Type u_4} [Nonempty ι] (s : Set α) (f : αι) {r : ιιProp} [IsEquiv ι r] :
Set.Pairwise s (r on f) ∃ (z : ι), xs, r (f x) z
theorem Set.pairwise_eq_iff_exists_eq {α : Type u_1} {ι : Type u_4} [Nonempty ι] (s : Set α) (f : αι) :
(Set.Pairwise s fun (x y : α) => f x = f y) ∃ (z : ι), xs, f x = z

A function f : α → ι with nonempty codomain takes pairwise equal values on a set s if and only if for some z in the codomain, f takes value z on all x ∈ s. See also Set.Nonempty.pairwise_eq_iff_exists_eq for a version that assumes Set.Nonempty s instead of [Nonempty ι].

theorem Set.pairwise_union {α : Type u_1} {r : ααProp} {s : Set α} {t : Set α} :
Set.Pairwise (s t) r Set.Pairwise s r Set.Pairwise t r as, bt, a br a b r b a
theorem Set.pairwise_union_of_symmetric {α : Type u_1} {r : ααProp} {s : Set α} {t : Set α} (hr : Symmetric r) :
Set.Pairwise (s t) r Set.Pairwise s r Set.Pairwise t r as, bt, a br a b
theorem Set.pairwise_insert {α : Type u_1} {r : ααProp} {s : Set α} {a : α} :
Set.Pairwise (insert a s) r Set.Pairwise s r bs, a br a b r b a
theorem Set.pairwise_insert_of_not_mem {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (ha : as) :
Set.Pairwise (insert a s) r Set.Pairwise s r bs, r a b r b a
theorem Set.Pairwise.insert {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (hs : Set.Pairwise s r) (h : bs, a br a b r b a) :
theorem Set.Pairwise.insert_of_not_mem {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (ha : as) (hs : Set.Pairwise s r) (h : bs, r a b r b a) :
theorem Set.pairwise_insert_of_symmetric {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (hr : Symmetric r) :
Set.Pairwise (insert a s) r Set.Pairwise s r bs, a br a b
theorem Set.pairwise_insert_of_symmetric_of_not_mem {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (hr : Symmetric r) (ha : as) :
Set.Pairwise (insert a s) r Set.Pairwise s r bs, r a b
theorem Set.Pairwise.insert_of_symmetric {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (hs : Set.Pairwise s r) (hr : Symmetric r) (h : bs, a br a b) :
theorem Set.Pairwise.insert_of_symmetric_of_not_mem {α : Type u_1} {r : ααProp} {s : Set α} {a : α} (hs : Set.Pairwise s r) (hr : Symmetric r) (ha : as) (h : bs, r a b) :
theorem Set.pairwise_pair {α : Type u_1} {r : ααProp} {a : α} {b : α} :
Set.Pairwise {a, b} r a br a b r b a
theorem Set.pairwise_pair_of_symmetric {α : Type u_1} {r : ααProp} {a : α} {b : α} (hr : Symmetric r) :
Set.Pairwise {a, b} r a br a b
theorem Set.pairwise_univ {α : Type u_1} {r : ααProp} :
@[simp]
theorem Set.Pairwise.subsingleton {α : Type u_1} {s : Set α} :

Alias of the forward direction of Set.pairwise_bot_iff.

theorem Set.injOn_iff_pairwise_ne {α : Type u_1} {ι : Type u_4} {f : ια} {s : Set ι} :
Set.InjOn f s Set.Pairwise s fun (x x_1 : ι) => f x f x_1

See also Function.injective_iff_pairwise_ne

theorem Set.InjOn.pairwise_ne {α : Type u_1} {ι : Type u_4} {f : ια} {s : Set ι} :
Set.InjOn f sSet.Pairwise s fun (x x_1 : ι) => f x f x_1

Alias of the forward direction of Set.injOn_iff_pairwise_ne.


See also Function.injective_iff_pairwise_ne

theorem Set.Pairwise.image {α : Type u_1} {ι : Type u_4} {r : ααProp} {f : ια} {s : Set ι} (h : Set.Pairwise s (r on f)) :
theorem Set.InjOn.pairwise_image {α : Type u_1} {ι : Type u_4} {r : ααProp} {f : ια} {s : Set ι} (h : Set.InjOn f s) :

See also Set.Pairwise.image.

theorem Pairwise.range_pairwise {α : Type u_1} {ι : Type u_4} {r : ααProp} {f : ια} (hr : Pairwise (r on f)) :
theorem pairwise_subtype_iff_pairwise_set {α : Type u_1} (s : Set α) (r : ααProp) :
(Pairwise fun (x y : s) => r x y) Set.Pairwise s r
theorem Set.Pairwise.subtype {α : Type u_1} (s : Set α) (r : ααProp) :
Set.Pairwise s rPairwise fun (x y : s) => r x y

Alias of the reverse direction of pairwise_subtype_iff_pairwise_set.

theorem Pairwise.set_of_subtype {α : Type u_1} (s : Set α) (r : ααProp) :
(Pairwise fun (x y : s) => r x y)Set.Pairwise s r

Alias of the forward direction of pairwise_subtype_iff_pairwise_set.

def Set.PairwiseDisjoint {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] (s : Set ι) (f : ια) :

A set is PairwiseDisjoint under f, if the images of any distinct two elements under f are disjoint.

s.Pairwise Disjoint is (definitionally) the same as s.PairwiseDisjoint id. We prefer the latter in order to allow dot notation on Set.PairwiseDisjoint, even though the former unfolds more nicely.

Equations
Instances For
    theorem Set.PairwiseDisjoint.subset {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {t : Set ι} {f : ια} (ht : Set.PairwiseDisjoint t f) (h : s t) :
    theorem Set.PairwiseDisjoint.mono_on {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} {g : ια} (hs : Set.PairwiseDisjoint s f) (h : ∀ ⦃i : ι⦄, i sg i f i) :
    theorem Set.PairwiseDisjoint.mono {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} {g : ια} (hs : Set.PairwiseDisjoint s f) (h : g f) :
    @[simp]
    theorem Set.pairwiseDisjoint_empty {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {f : ια} :
    @[simp]
    theorem Set.pairwiseDisjoint_singleton {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] (i : ι) (f : ια) :
    theorem Set.pairwiseDisjoint_insert {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} {i : ι} :
    Set.PairwiseDisjoint (insert i s) f Set.PairwiseDisjoint s f js, i jDisjoint (f i) (f j)
    theorem Set.pairwiseDisjoint_insert_of_not_mem {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} {i : ι} (hi : is) :
    Set.PairwiseDisjoint (insert i s) f Set.PairwiseDisjoint s f js, Disjoint (f i) (f j)
    theorem Set.PairwiseDisjoint.insert {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) {i : ι} (h : js, i jDisjoint (f i) (f j)) :
    theorem Set.PairwiseDisjoint.insert_of_not_mem {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) {i : ι} (hi : is) (h : js, Disjoint (f i) (f j)) :
    theorem Set.PairwiseDisjoint.image_of_le {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) {g : ιι} (hg : f g f) :
    theorem Set.InjOn.pairwiseDisjoint_image {α : Type u_1} {ι : Type u_4} {ι' : Type u_5} [PartialOrder α] [OrderBot α] {f : ια} {g : ι'ι} {s : Set ι'} (h : Set.InjOn g s) :
    theorem Set.PairwiseDisjoint.range {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} (g : sι) (hg : ∀ (i : s), f (g i) f i) (ht : Set.PairwiseDisjoint s f) :
    theorem Set.pairwiseDisjoint_union {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {t : Set ι} {f : ια} :
    Set.PairwiseDisjoint (s t) f Set.PairwiseDisjoint s f Set.PairwiseDisjoint t f ∀ ⦃i : ι⦄, i s∀ ⦃j : ι⦄, j ti jDisjoint (f i) (f j)
    theorem Set.PairwiseDisjoint.union {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {t : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) (ht : Set.PairwiseDisjoint t f) (h : ∀ ⦃i : ι⦄, i s∀ ⦃j : ι⦄, j ti jDisjoint (f i) (f j)) :
    theorem Set.PairwiseDisjoint.elim {α : Type u_1} {ι : Type u_4} [PartialOrder α] [OrderBot α] {s : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) {i : ι} {j : ι} (hi : i s) (hj : j s) (h : ¬Disjoint (f i) (f j)) :
    i = j
    theorem Set.PairwiseDisjoint.elim' {α : Type u_1} {ι : Type u_4} [SemilatticeInf α] [OrderBot α] {s : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) {i : ι} {j : ι} (hi : i s) (hj : j s) (h : f i f j ) :
    i = j
    theorem Set.PairwiseDisjoint.eq_of_le {α : Type u_1} {ι : Type u_4} [SemilatticeInf α] [OrderBot α] {s : Set ι} {f : ια} (hs : Set.PairwiseDisjoint s f) {i : ι} {j : ι} (hi : i s) (hj : j s) (hf : f i ) (hij : f i f j) :
    i = j

    Pairwise disjoint set of sets #

    theorem Set.pairwiseDisjoint_fiber {α : Type u_1} {ι : Type u_4} (f : ια) (s : Set α) :
    Set.PairwiseDisjoint s fun (a : α) => f ⁻¹' {a}
    theorem Set.PairwiseDisjoint.elim_set {α : Type u_1} {ι : Type u_4} {s : Set ι} {f : ιSet α} (hs : Set.PairwiseDisjoint s f) {i : ι} {j : ι} (hi : i s) (hj : j s) (a : α) (hai : a f i) (haj : a f j) :
    i = j
    theorem Set.PairwiseDisjoint.prod {α : Type u_1} {β : Type u_2} {ι : Type u_4} {ι' : Type u_5} {s : Set ι} {t : Set ι'} {f : ιSet α} {g : ι'Set β} (hs : Set.PairwiseDisjoint s f) (ht : Set.PairwiseDisjoint t g) :
    Set.PairwiseDisjoint (s ×ˢ t) fun (i : ι × ι') => f i.1 ×ˢ g i.2
    theorem Set.pairwiseDisjoint_pi {ι : Type u_4} {ι' : ιType u_6} {α : ιType u_7} {s : (i : ι) → Set (ι' i)} {f : (i : ι) → ι' iSet (α i)} (hs : ∀ (i : ι), Set.PairwiseDisjoint (s i) (f i)) :
    Set.PairwiseDisjoint (Set.pi Set.univ s) fun (I : (i : ι) → ι' i) => Set.pi Set.univ fun (i : ι) => f i (I i)
    theorem Set.pairwiseDisjoint_image_right_iff {α : Type u_1} {β : Type u_2} {γ : Type u_3} {f : αβγ} {s : Set α} {t : Set β} (hf : as, Function.Injective (f a)) :
    (Set.PairwiseDisjoint s fun (a : α) => f a '' t) Set.InjOn (fun (p : α × β) => f p.1 p.2) (s ×ˢ t)

    The partial images of a binary function f whose partial evaluations are injective are pairwise disjoint iff f is injective .

    theorem Set.pairwiseDisjoint_image_left_iff {α : Type u_1} {β : Type u_2} {γ : Type u_3} {f : αβγ} {s : Set α} {t : Set β} (hf : bt, Function.Injective fun (a : α) => f a b) :
    (Set.PairwiseDisjoint t fun (b : β) => (fun (a : α) => f a b) '' s) Set.InjOn (fun (p : α × β) => f p.1 p.2) (s ×ˢ t)

    The partial images of a binary function f whose partial evaluations are injective are pairwise disjoint iff f is injective .

    theorem Set.exists_ne_mem_inter_of_not_pairwiseDisjoint {α : Type u_1} {ι : Type u_4} {s : Set ι} {f : ιSet α} (h : ¬Set.PairwiseDisjoint s f) :
    ∃ i ∈ s, ∃ j ∈ s, i j ∃ (x : α), x f i f j
    theorem Set.exists_lt_mem_inter_of_not_pairwiseDisjoint {α : Type u_1} {ι : Type u_4} {s : Set ι} [LinearOrder ι] {f : ιSet α} (h : ¬Set.PairwiseDisjoint s f) :
    ∃ i ∈ s, ∃ j ∈ s, i < j ∃ (x : α), x f i f j
    theorem exists_ne_mem_inter_of_not_pairwise_disjoint {α : Type u_1} {ι : Type u_4} {f : ιSet α} (h : ¬Pairwise (Disjoint on f)) :
    ∃ (i : ι) (j : ι), i j ∃ (x : α), x f i f j
    theorem exists_lt_mem_inter_of_not_pairwise_disjoint {α : Type u_1} {ι : Type u_4} [LinearOrder ι] {f : ιSet α} (h : ¬Pairwise (Disjoint on f)) :
    ∃ (i : ι) (j : ι), i < j ∃ (x : α), x f i f j
    theorem pairwise_disjoint_fiber {α : Type u_1} {ι : Type u_4} (f : ια) :
    Pairwise (Disjoint on fun (a : α) => f ⁻¹' {a})
    theorem subsingleton_setOf_mem_iff_pairwise_disjoint {α : Type u_1} {ι : Type u_4} {f : ιSet α} :
    (∀ (a : α), Set.Subsingleton {i : ι | a f i}) Pairwise (Disjoint on f)