Require Export FunctionProperties.
Require Export Relation_Definitions.
Inductive Cardinal : Type :=
| cardinality: Type -> Cardinal.
Fixpoint n_element_set (n:nat) : Set :=
match n with
| O => False
| S m => option (n_element_set m)
end.
Definition nat_to_cardinal (n:nat) :=
cardinality (n_element_set n).
Definition aleph0 := cardinality nat.
Inductive eq_cardinal : Cardinal -> Cardinal -> Prop :=
| bij_eq_cardinal: forall {X Y:Type} (f:X->Y),
bijective f -> eq_cardinal (cardinality X) (cardinality Y).
Inductive le_cardinal : Cardinal -> Cardinal -> Prop :=
| inj_le_cardinal: forall {X Y:Type} (f:X->Y),
injective f -> le_cardinal (cardinality X) (cardinality Y).
Definition lt_cardinal (kappa lambda:Cardinal) : Prop :=
le_cardinal kappa lambda /\ ~ eq_cardinal kappa lambda.
Definition ge_cardinal (kappa lambda:Cardinal) : Prop :=
le_cardinal lambda kappa.
Definition gt_cardinal (kappa lambda:Cardinal) : Prop :=
lt_cardinal lambda kappa.

Lemma le_cardinal_preorder: preorder le_cardinal.