(* Predecessor in a face - direct version: *)

Definition F_1 (m:fmap)(x:dart):=
  A m di0 (A m di1 x).(* To have a predecessor in a (direct) face for x: *)

Definition predf(m:fmap)(y:dart):Prop:=
  succ m di1 y /\ succ m di0 (A m di1 y).

(* Specifications: *)
Lemma predf_dec : forall (m:fmap)(x:dart), {predf m x}+{~predf m x}.
Lemma predf_exd : forall (m:fmap)(x:dart), inv_qhmap m -> predf m x -> exd m x.
Lemma F_nil : forall m:fmap, inv_qhmap m -> F m nil = nil.
Lemma F_1_nil : forall m:fmap, inv_qhmap m -> F_1 m nil = nil.
Lemma succf_exd_F : forall (m:fmap)(x:dart), inv_qhmap m -> succf m x -> exd m (F m x).
Lemma predf_exd_F_1 : forall (m:fmap)(x:dart), inv_qhmap m -> predf m x -> exd m (F_1 m x).
Lemma succf_F: forall (m:fmap)(x:dart), inv_qhmap m -> (succf m x <-> F m x <> nil).
Lemma predf_F_1: forall (m:fmap)(y:dart), inv_qhmap m -> (predf m y <-> F_1 m y <> nil).
Lemma not_exd_F_nil : forall (m:fmap)(x:dart), inv_qhmap m -> ~exd m x -> F m x = nil.
Lemma not_exd_F_1_nil : forall (m:fmap)(x:dart), inv_qhmap m -> ~exd m x -> F_1 m x = nil.
Lemma F_F_1 : forall (m:fmap)(x:dart), inv_qhmap m -> exd m x -> exd m (F_1 m x) -> F m (F_1 m x) = x.
Lemma F_1_F : forall (m:fmap)(x:dart), inv_qhmap m -> exd m x -> exd m (F m x) -> F_1 m (F m x) = x.
Lemma inj_F_succf : forall m:fmap, inv_qhmap m -> inj_dart (succf m) (F m).