Definition knot_rel (k1 k2:knot) :=
let (n,f) := unsquash k1 in
let (n',f') := unsquash k2 in
n = n' /\ Rel predicate predicate f f'.

(* Specifications: *)
Axiom knot_age1 : forall k:knot,
age1 k =
match unsquash k with
| (O,_) => None
| (S n,x) => Some (squash (n,x))
end.
Axiom knot_level : forall k:knot,
level k = fst (unsquash k).
Axiom hered_spec : forall p,
hered p =
(forall k k' k'' o o',
clos_refl_trans _ age k k' ->
knot_rel  k' k'' ->
ORel o o' ->
T_rel (p (k,o)) (p (k'',o'))).
Axiom knot_age1 : forall k:knot,
age1 k =
match unsquash k with
| (O,_) => None
| (S n,x) => Some (squash (n,x))
end.
Axiom knot_level : forall k:knot,
level k = fst (unsquash k).
Axiom hered_spec : forall p,
hered p =
(forall k k' k'' o o',
clos_refl_trans _ age k k' ->
knot_rel  k' k'' ->
ORel o o' ->
T_rel (p (k,o)) (p (k'',o'))).