Instance THeap_SA: @SeparationAlgebra THeap THeap_Join.Inductive THeap_order': THeap' -> THeap' -> Prop:=
| THeap_ord (h1 h2:THeap'):
    (forall (n:nat) (c:htype), h2 n = Some c ->
           exists (c':htype), h1 n = Some c' /\
                         ht_ord c' c) ->
THeap_order' h2 h1.Inductive THeap_order': THeap' -> THeap' -> Prop:=
| THeap_ord (h1 h2:THeap'):
    (forall (n:nat) (c:htype), h2 n = Some c ->
           exists (c':htype), h1 n = Some c' /\
                         ht_ord c' c) ->
THeap_order' h2 h1.Definition THeap_order (h1 h2: THeap): Prop:=
  THeap_order' h1 h2.Instance THeap_preorder': PreOrder THeap_order'.

Lemma THeap_preorder: PreOrder THeap_order.