(* A's inverse; CAUTION: that is not the true inverse
 in an fmap, but it is in a true map (or qhmap...)! *)

Fixpoint A_1 (m:fmap)(k:dim)(y:dart)
  {struct m}:dart:=
  match m with
      V => nil
    | I m0 x0 _ _ => A_1 m0 k y
    | L m0 k0 x0 y0 =>
          if (eq_dim_dec k0 k)
          then if (eq_dart_dec y0 y) then x0
              else A_1 m0 k y
          else A_1 m0 k y
  end.(* Idem: *)

Definition pred(m:fmap)(k:dim)(x:dart):=
  A_1 m k x <> nil.

Lemma pred_dec: forall (m:fmap)(k:dim)(x:dart), {pred m k x} + {~pred m k x}.