Instance coqArbNat : CoArbitrary nat.Definition pathToPos p := pathToPosAux p (fun x => x).

(* Specifications: *)
Lemma posPathInj : forall p, pathToPos (posToPath p) = Some p.
Lemma lengthSplit1 : forall {A : Type} (l l' : list A), le (length l) (length l') -> exists p, lengthSplit l l' = Some p.
Lemma lengthSplit2 : forall {A : Type} (l l' l1 l2 : list A), lengthSplit l l' = Some (l1, l2) -> l1 ++ l2 = l'.
Lemma lengthSplit3 : forall {A : Type} (l l' l1 l2 : list A), lengthSplit l l' = Some (l1, l2) -> length l1 = length l.
Lemma lengthPathEven : forall p, exists n, length (posToPathAux p) = (2 * n)%nat.
Lemma evenPathAux : forall l l' l'' lApp f n p, length l = (2 * n)%nat -> pathToPosAux (l ++ l' ++ l'') f = Some p -> exists f', pathToPosAux (l ++ l') f = pathToPosAux l' f' /\ pathToPosAux (l ++ l' ++ lApp) f = pathToPosAux (l' ++ lApp) f'.
Lemma listAppNeq : forall (A : Type) (l1 l2 l3 l4 : list A), (forall (x y : A), {x = y} + {x <> y}) -> length l1 = length l2 -> l1 <> l2 -> l1 ++ l3 <> l2 ++ l4.