Instance Join_resource: Join resource := res_join.
Instance Perm_resource: Perm_alg resource.
Instance Sep_resource: Sep_alg resource.

(* Specifications: *)
Lemma ghost_join_inv: forall m1 m2 m3, ghost_join m1 m2 m3 ->
match m1, m2 with
| nil, _ => m3 = m2
| _, nil => m3 = m1
| a1 :: m1, a2 :: m2 => match m3 with nil => False
| a3 :: m3 => join a1 a2 a3 /\ ghost_join m1 m2 m3 end
end.