| 1 |
|
| 2 |
Require Import Corelib.Setoids.Setoid. |
| 3 |
|
| 4 |
Set Implicit Arguments. |
| 5 |
|
| 6 |
Record PartialOrder : Type := |
| 7 |
{ po_car :> Type |
| 8 |
; le : po_car -> po_car -> Prop |
| 9 |
; monotone : (po_car -> po_car) -> Prop |
| 10 |
}. |
| 11 |
Notation "x <= y" := (le _ x y). |
| 12 |
|
| 13 |
Section PartialOrder. |
| 14 |
|
| 15 |
Variable X : PartialOrder. |
| 16 |
|
| 17 |
Lemma monotone_def : forall f, monotone X f <-> (forall x y, x <= y -> (f x) <= (f y)). |
| 18 |
Admitted. |
| 19 |
|
| 20 |
End PartialOrder. |
| 21 |
Set Firstorder Depth 5. |
| 22 |
|
| 23 |
Record SemiLattice : Type := |
| 24 |
{ po :> PartialOrder |
| 25 |
; meet : po -> po -> po |
| 26 |
|
| 27 |
}. |
| 28 |
|
| 29 |
Arguments meet [s]. |
| 30 |
|
| 31 |
Axiom X : SemiLattice. |
| 32 |
|
| 33 |
Lemma meet_monotone_l : forall a : X, monotone X (fun x => meet x a). |
| 34 |
Admitted. |
| 35 |
|
| 36 |
Lemma meet_le_compat : forall w x y z : X, w<=y -> meet w x <= meet y x. |
| 37 |
Proof. |
| 38 |
intros. |
| 39 |
solve [firstorder using meet_monotone_l, monotone_def]. |
| 40 |
Qed. |