Require Import preorder.From Stdlib Require Import Logic.FunctionalExtensionality.From Stdlib Require Import Logic.PropExtensionality.Definitionpower (A : Type) : Type :=
A -> Prop.Definitionmem {A : Type} (a : A) (S : power A) : Prop :=
S a.Notation"a ∈ S" := (mem a S) (at level70).SectionSets.Context {A : Type}.Definitionwhole_set : power A :=
fun_ => True.Definitionempty_set : power A :=
fun_ => False.Definitionsingleton (a : A) : power A :=
funx => x = a.Definitionbin_inter (S : power A) (T : power A) : power A :=
funx => x ∈ S /\ x ∈ T.Definitionunion (X : power (power A)) : power A :=
funx => existsS, S ∈ X /\ x ∈ S.Definitioninclusion (S : power A) (T : power A) : Prop :=
forallx, x ∈ S -> x ∈ T.Definitioncomplement (S : power A) : power A :=
funx => ~ (x ∈ S).Definitionoverlap (S : power A) (T : power A) : Prop :=
existsx, x ∈ S /\ x ∈ T.Definitiondisjoint (S : power A) (T : power A) : Prop :=
forallx,
x ∈ S ->
x ∈ T ->
False.EndSets.Notation"S ∩ T" := (bin_inter S T) (at level50).Notation"⋃ S" := (union S) (at level50).Notation"S ⊆ T" := (inclusion S T) (at level60).Notation"S ≬ T" := (overlap S T) (at level60).SectionSetProperties.Context {A : Type}.
A: Type
forallx : A, x ∈ empty_set -> False
A: Type
forallx : A, x ∈ empty_set -> False
A: Type x: A H: x ∈ empty_set
False
A: Type x: A H: empty_set x
False
A: Type x: A H: False
False
exact H.Qed.
A: Type
forallS : power A, empty_set ⊆ S
A: Type
forallS : power A, empty_set ⊆ S
A: Type S: power A
empty_set ⊆ S
A: Type S: power A
forallx : A, x ∈ empty_set -> x ∈ S
A: Type S: power A x: A H: x ∈ empty_set
x ∈ S
contradict H.Qed.
A: Type
forallST : power A, S ⊆ T -> T ⊆ S -> S = T
A: Type
forallST : power A, S ⊆ T -> T ⊆ S -> S = T
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S
S = T
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A
S x = T x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A
S x <-> T x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A
S x -> T x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A
T x -> S x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A
S x -> T x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A H1: S x
T x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A H1: S x
x ∈ S
assumption.
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A
T x -> S x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A H1: T x
S x
A: Type S, T: power A H: S ⊆ T H0: T ⊆ S x: A H1: T x
x ∈ T
assumption.Qed.
A: Type
forallS : power A, S ⊆ empty_set -> S = empty_set
A: Type
forallS : power A, S ⊆ empty_set -> S = empty_set
A: Type S: power A H: S ⊆ empty_set
S = empty_set
A: Type S: power A H: S ⊆ empty_set
S ⊆ empty_set
A: Type S: power A H: S ⊆ empty_set
empty_set ⊆ S
A: Type S: power A H: S ⊆ empty_set
S ⊆ empty_set
assumption.
A: Type S: power A H: S ⊆ empty_set
empty_set ⊆ S
apply empty_set_subset.Qed.
A: Type
forallS : power A, S ⊆ S
A: Type
forallS : power A, S ⊆ S
A: Type S: power A
S ⊆ S
A: Type S: power A
forallx : A, x ∈ S -> x ∈ S
A: Type S: power A x: A H: x ∈ S
x ∈ S
assumption.Qed.
A: Type
forallSTU : power A, S ⊆ T -> T ⊆ U -> S ⊆ U
A: Type
forallSTU : power A, S ⊆ T -> T ⊆ U -> S ⊆ U
A: Type S, T, U: power A H: S ⊆ T H0: T ⊆ U
S ⊆ U
A: Type S, T, U: power A H: S ⊆ T H0: T ⊆ U
forallx : A, x ∈ S -> x ∈ U
A: Type S, T, U: power A H: S ⊆ T H0: T ⊆ U x: A H1: x ∈ S
x ∈ U
A: Type S, T, U: power A H: S ⊆ T H0: T ⊆ U x: A H1: x ∈ S
x ∈ T
A: Type S, T, U: power A H: S ⊆ T H0: T ⊆ U x: A H1: x ∈ S
x ∈ S
assumption.Qed.
A: Type
is_preorder (power A) inclusion
A: Type
is_preorder (power A) inclusion
A: Type
forallx : power A, x ⊆ x
A: Type
forallxyz : power A, x ⊆ y -> y ⊆ z -> x ⊆ z
A: Type
forallx : power A, x ⊆ x
exact @inclusion_refl.
A: Type
forallxyz : power A, x ⊆ y -> y ⊆ z -> x ⊆ z
exact @inclusion_trans.Qed.
A: Type
forallx : A, x ∈ whole_set
A: Type
forallx : A, x ∈ whole_set
A: Type x: A
x ∈ whole_set
A: Type x: A
True
trivial.Qed.
A: Type
forallSTU : power A, S ⊆ U -> T ⊆ U -> S ∩ T ⊆ U
A: Type
forallSTU : power A, S ⊆ U -> T ⊆ U -> S ∩ T ⊆ U
A: Type S, T, U: power A H: S ⊆ U H0: T ⊆ U
S ∩ T ⊆ U
A: Type S, T, U: power A H: S ⊆ U H0: T ⊆ U
forallx : A, x ∈ S ∩ T -> x ∈ U
A: Type S, T, U: power A H: S ⊆ U H0: T ⊆ U x: A H1: x ∈ S ∩ T
x ∈ U
A: Type S, T, U: power A H: S ⊆ U H0: T ⊆ U x: A H1: x ∈ S H2: x ∈ T
x ∈ U
A: Type S, T, U: power A H: S ⊆ U H0: T ⊆ U x: A H1: x ∈ S H2: x ∈ T
x ∈ T
assumption.Qed.
A: Type
forallST : power A, S ∩ T = T ∩ S
A: Type
forallST : power A, S ∩ T = T ∩ S
A: Type S, T: power A
S ∩ T = T ∩ S
A: Type S, T: power A x: A
(S ∩ T) x = (T ∩ S) x
A: Type S, T: power A x: A
(x ∈ S /\ x ∈ T) = (x ∈ T /\ x ∈ S)
A: Type S, T: power A x: A
x ∈ S /\ x ∈ T <-> x ∈ T /\ x ∈ S
A: Type S, T: power A x: A
x ∈ S /\ x ∈ T -> x ∈ T /\ x ∈ S
A: Type S, T: power A x: A
x ∈ T /\ x ∈ S -> x ∈ S /\ x ∈ T
A: Type S, T: power A x: A
x ∈ S /\ x ∈ T -> x ∈ T /\ x ∈ S
A: Type S, T: power A x: A H: x ∈ S /\ x ∈ T
x ∈ T /\ x ∈ S
A: Type S, T: power A x: A H: x ∈ S H0: x ∈ T
x ∈ T /\ x ∈ S
refine (conj H0 H).
A: Type S, T: power A x: A
x ∈ T /\ x ∈ S -> x ∈ S /\ x ∈ T
A: Type S, T: power A x: A H: x ∈ T /\ x ∈ S
x ∈ S /\ x ∈ T
A: Type S, T: power A x: A H: x ∈ T H0: x ∈ S
x ∈ S /\ x ∈ T
refine (conj H0 H).Qed.
A: Type
forallST : power A, S ∩ T ⊆ S
A: Type
forallST : power A, S ∩ T ⊆ S
A: Type S, T: power A
S ∩ T ⊆ S
A: Type S, T: power A
forallx : A, x ∈ S ∩ T -> x ∈ S
A: Type S, T: power A x: A H: x ∈ S ∩ T
x ∈ S
A: Type S, T: power A x: A H: x ∈ S H0: x ∈ T
x ∈ S
assumption.Qed.
A: Type
forallS : power A, empty_set ∩ S = empty_set
A: Type
forallS : power A, empty_set ∩ S = empty_set
A: Type S: power A
empty_set ∩ S = empty_set
A: Type S: power A
empty_set ∩ S ⊆ empty_set
A: Type S: power A
empty_set ⊆ empty_set ∩ S
A: Type S: power A
empty_set ∩ S ⊆ empty_set
apply bin_inter_subset_left.
A: Type S: power A
empty_set ⊆ empty_set ∩ S
apply empty_set_subset.Qed.
A: Type
forallS : power A, S ∩ empty_set = empty_set
A: Type
forallS : power A, S ∩ empty_set = empty_set
A: Type S: power A
S ∩ empty_set = empty_set
A: Type S: power A
empty_set ∩ S = empty_set
apply bin_inter_empty_set_left.Qed.
A: Type
forallST : power A, S ⊆ T -> S ∩ T = S
A: Type
forallST : power A, S ⊆ T -> S ∩ T = S
A: Type S, T: power A H: S ⊆ T
S ∩ T = S
A: Type S, T: power A H: S ⊆ T
S ∩ T ⊆ S
A: Type S, T: power A H: S ⊆ T
S ⊆ S ∩ T
A: Type S, T: power A H: S ⊆ T
S ∩ T ⊆ S
apply bin_inter_subset_left.
A: Type S, T: power A H: S ⊆ T
S ⊆ S ∩ T
A: Type S, T: power A H: S ⊆ T
forallx : A, x ∈ S -> x ∈ S ∩ T
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ S ∩ T
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
(S ∩ T) x
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ S /\ x ∈ T
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ S
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ T
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ S
assumption.
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ T
A: Type S, T: power A H: S ⊆ T x: A H0: x ∈ S
x ∈ S
assumption.Qed.
A: Type
forallST : power A, T ⊆ S -> S ∩ T = T
A: Type
forallST : power A, T ⊆ S -> S ∩ T = T
A: Type S, T: power A H: T ⊆ S
S ∩ T = T
A: Type S, T: power A H: T ⊆ S
T ∩ S = T
A: Type S, T: power A H: T ⊆ S
T ⊆ S
assumption.Qed.
A: Type
forallS : power A, whole_set ∩ S = S
A: Type
forallS : power A, whole_set ∩ S = S
A: Type S: power A
whole_set ∩ S = S
A: Type S: power A x: A
(whole_set ∩ S) x = S x
A: Type S: power A x: A
(whole_set ∩ S) x <-> S x
A: Type S: power A x: A
(whole_set ∩ S) x -> S x
A: Type S: power A x: A
S x -> (whole_set ∩ S) x
A: Type S: power A x: A
(whole_set ∩ S) x -> S x
A: Type S: power A x: A H: (whole_set ∩ S) x
S x
A: Type S: power A x: A H: x ∈ whole_set H0: x ∈ S
S x
assumption.
A: Type S: power A x: A
S x -> (whole_set ∩ S) x
A: Type S: power A x: A H: S x
(whole_set ∩ S) x
A: Type S: power A x: A H: S x
x ∈ whole_set /\ x ∈ S
A: Type S: power A x: A H: S x
x ∈ whole_set
A: Type S: power A x: A H: S x
x ∈ S
A: Type S: power A x: A H: S x
x ∈ whole_set
apply whole_set_contains_everything.
A: Type S: power A x: A H: S x
x ∈ S
assumption.Qed.
A: Type
forallS : power A, S ∩ whole_set = S
A: Type
forallS : power A, S ∩ whole_set = S
A: Type S: power A
S ∩ whole_set = S
A: Type S: power A
whole_set ∩ S = S
apply bin_inter_left_unit.Qed.
A: Type
forallS : power A, S ⊆ whole_set
A: Type
forallS : power A, S ⊆ whole_set
A: Type S: power A
S ⊆ whole_set
A: Type S: power A
forallx : A, x ∈ S -> x ∈ whole_set
A: Type S: power A x: A H: x ∈ S
x ∈ whole_set
apply whole_set_contains_everything.Qed.
A: Type
forallX : power (power A), whole_set ∈ X -> ⋃ X = whole_set
A: Type
forallX : power (power A), whole_set ∈ X -> ⋃ X = whole_set
A: Type X: power (power A) H: whole_set ∈ X
⋃ X = whole_set
A: Type X: power (power A) H: whole_set ∈ X
⋃ X ⊆ whole_set
A: Type X: power (power A) H: whole_set ∈ X
whole_set ⊆ ⋃ X
A: Type X: power (power A) H: whole_set ∈ X
⋃ X ⊆ whole_set
apply whole_set_top.
A: Type X: power (power A) H: whole_set ∈ X
whole_set ⊆ ⋃ X
A: Type X: power (power A) H: whole_set ∈ X
forallx : A, x ∈ whole_set -> x ∈ ⋃ X
A: Type X: power (power A) H: whole_set ∈ X x: A H0: x ∈ whole_set
x ∈ ⋃ X
A: Type X: power (power A) H: whole_set ∈ X x: A H0: x ∈ whole_set
whole_set ∈ X /\ x ∈ whole_set
exact (conj H H0).Qed.
A: Type
forall (X : power (power A)) (U : power A),
(forallS : power A, S ∈ X -> S ⊆ U) -> ⋃ X ⊆ U
A: Type
forall (X : power (power A)) (U : power A),
(forallS : power A, S ∈ X -> S ⊆ U) -> ⋃ X ⊆ U
A: Type X: power (power A) U: power A H: forallS : power A, S ∈ X -> S ⊆ U
⋃ X ⊆ U
A: Type X: power (power A) U: power A H: forallS : power A, S ∈ X -> S ⊆ U
forallx : A, x ∈ ⋃ X -> x ∈ U
A: Type X: power (power A) U: power A H: forallS : power A, S ∈ X -> S ⊆ U x: A H0: x ∈ ⋃ X
x ∈ U
A: Type X: power (power A) U: power A H: forallS : power A, S ∈ X -> S ⊆ U x: A S: power A H1: S ∈ X H2: x ∈ S
x ∈ U
A: Type X: power (power A) U, S: power A H: S ⊆ U x: A H1: S ∈ X H2: x ∈ S
x ∈ U
A: Type X: power (power A) U, S: power A H: S ⊆ U x: A H1: S ∈ X H2: x ∈ S
x ∈ S
assumption.Qed.
A: Type
⋃ empty_set = empty_set
A: Type
⋃ empty_set = empty_set
A: Type
⋃ empty_set = empty_set
A: Type
⋃ empty_set ⊆ empty_set
A: Type x: A H: x ∈ ⋃ empty_set
x ∈ empty_set
A: Type x: A S: power A H0: S ∈ empty_set H1: x ∈ S