(* This program is free software; you can redistribute it and/or      *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1   *)
(* of the License, or (at your option) any later version.             *)
(*                                                                    *)
(* This program is distributed in the hope that it will be useful,    *)
(* but WITHOUT ANY WARRANTY; without even the implied warranty of     *)
(* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      *)
(* GNU General Public License for more details.                       *)
(*                                                                    *)
(* You should have received a copy of the GNU Lesser General Public   *)
(* License along with this program; if not, write to the Free         *)
(* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *)
(* 02110-1301 USA                                                     *)

(* Specifications: *)
Theorem subs_fresh_par_name :
forall (n m : name) (p : PP), n <> pname p -> subs_par_name n m p = n.
Theorem subs_fresh_par :
forall (P : proc) (n : name) (p : PP), fresh p P -> subs_par_proc P n p = P.
Theorem subs_par_after_subs_var_name :
forall (n : name) (p q : PP) (x : VV),
n <> pname q ->
subs_par_name (subs_var_name n (pname q) x) (pname p) q =
subs_var_name n (pname p) x.
Theorem subs_par_after_subs_var :
forall (P : proc) (p q : PP) (x : VV),
fresh q P ->
subs_par_proc (subs_var_proc P (pname q) x) (pname p) q =
subs_var_proc P (pname p) x.
Theorem subs_var_after_subs_par_name :
forall (n : name) (p q : PP) (x : VV),
n <> vname x ->
subs_var_name (subs_par_name n (vname x) p) (pname q) x =
subs_par_name n (pname q) p.
Theorem subs_var_after_subs_par :
forall (P : proc) (p q : PP) (x : VV),
freshvar x P ->
subs_var_proc (subs_par_proc P (vname x) p) (pname q) x =
subs_par_proc P (pname q) p.
Theorem inefficient_subs_par_name :
forall (n : name) (p : PP), subs_par_name n (pname p) p = n.
Theorem inefficient_subs_par :
forall (P : proc) (p : PP), subs_par_proc P (pname p) p = P.
Theorem switch_subs_name :
forall (n n1 n2 : name) (p : PP) (x : VV),
pname p <> n1 ->
vname x <> n2 ->
subs_var_name (subs_par_name n n2 p) n1 x =
subs_par_name (subs_var_name n n1 x) n2 p.
Theorem switch_subs :
forall (P : proc) (n1 n2 : name) (p : PP) (x : VV),
pname p <> n1 ->
vname x <> n2 ->
subs_var_proc (subs_par_proc P n2 p) n1 x =
subs_par_proc (subs_var_proc P n1 x) n2 p.
Theorem out_autored :
forall (P P' : proc) (p q : PP),
sem P (aout p q) P' -> forall G : env, typing G P -> typing G P'.
Theorem out_emits_correct_type :
forall (P P' : proc) (p q : PP),
sem P (aout p q) P' ->
forall G : env, typing G P -> typest (G q) (getobj (G p)).
Theorem inp_autored :
forall (P P' : proc) (p q : PP),
sem P (ainp p q) P' ->
forall G : env, typing G P -> typest (G q) (getobj (G p)) -> typing G P'.
Theorem inp_ind :
forall Pr : proc -> proc -> PP -> PP -> Prop,
(forall (p q : PP) (x : VV) (P : proc),
Pr (inp (pname p) x P) (subs_var_proc P (pname q) x) p q) ->
(forall (P P' : proc) (p q : PP) (x y : VV) (t : type),
(forall r : PP,
sem (subs_var_proc P (pname r) x) (ainp p q)
(subs_var_proc P' (pname r) y)) ->
(forall r : PP,
Pr (subs_var_proc P (pname r) x) (subs_var_proc P' (pname r) y) p q) ->
Pr (res x t P) (res y t P') p q) ->
(forall (P P' : proc) (p q : PP),
sem (par (ban P) P) (ainp p q) P' ->
Pr (par (ban P) P) P' p q -> Pr (ban P) P' p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (ainp p q) P' -> Pr P P' p q -> Pr (par P Q) (par P' Q) p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (ainp p q) P' -> Pr P P' p q -> Pr (par Q P) (par Q P') p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (ainp p q) P' -> Pr P P' p q -> Pr (sum P Q) P' p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (ainp p q) P' -> Pr P P' p q -> Pr (sum Q P) P' p q) ->
(forall (P P' : proc) (p q r : PP),
sem P (ainp p q) P' -> Pr P P' p q -> Pr (mat (pname r) (pname r) P) P' p q) ->
forall (P P' : proc) (p q : PP), sem P (ainp p q) P' -> Pr P P' p q.
Theorem out_ind :
forall Pr : proc -> proc -> PP -> PP -> Prop,
(forall (p q : PP) (P : proc), Pr (out (pname p) (pname q) P) P p q) ->
(forall (P P' : proc) (p q : PP) (x y : VV) (t : type),
(forall r : PP,
sem (subs_var_proc P (pname r) x) (aout p q)
(subs_var_proc P' (pname r) y)) ->
(forall r : PP,
Pr (subs_var_proc P (pname r) x) (subs_var_proc P' (pname r) y) p q) ->
Pr (res x t P) (res y t P') p q) ->
(forall (P P' : proc) (p q : PP),
sem (par (ban P) P) (aout p q) P' ->
Pr (par (ban P) P) P' p q -> Pr (ban P) P' p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (aout p q) P' -> Pr P P' p q -> Pr (par P Q) (par P' Q) p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (aout p q) P' -> Pr P P' p q -> Pr (par Q P) (par Q P') p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (aout p q) P' -> Pr P P' p q -> Pr (sum P Q) P' p q) ->
(forall (P P' Q : proc) (p q : PP),
sem P (aout p q) P' -> Pr P P' p q -> Pr (sum Q P) P' p q) ->
(forall (P P' : proc) (p q r : PP),
sem P (aout p q) P' -> Pr P P' p q -> Pr (mat (pname r) (pname r) P) P' p q) ->
forall (P P' : proc) (p q : PP), sem P (aout p q) P' -> Pr P P' p q.
Theorem bout_ind :
forall Pr : proc -> proc -> PP -> PP -> type -> Prop,
(forall (p q : PP) (x : VV) (t : type) (P P' : proc),
fresh q P ->
q <> p ->
sem (subs_var_proc P (pname q) x) (aout p q) P' -> Pr (res x t P) P' p q t) ->
(forall (p q : PP) (x y : VV) (t t' : type) (P P' : proc),
(forall r : PP,
sem (subs_var_proc P (pname r) x) (about p q t)
(subs_var_proc P' (pname r) y)) ->
(forall r : PP,
Pr (subs_var_proc P (pname r) x) (subs_var_proc P' (pname r) y) p q t) ->
Pr (res x t' P) (res y t' P') p q t) ->
(forall (P P' : proc) (p q : PP) (t : type),
sem (par (ban P) P) (about p q t) P' ->
Pr (par (ban P) P) P' p q t -> Pr (ban P) P' p q t) ->
(forall (P P' Q : proc) (p q : PP) (t : type),
fresh q Q ->
sem P (about p q t) P' -> Pr P P' p q t -> Pr (par P Q) (par P' Q) p q t) ->
(forall (P P' Q : proc) (p q : PP) (t : type),
fresh q Q ->
sem P (about p q t) P' -> Pr P P' p q t -> Pr (par Q P) (par Q P') p q t) ->
(forall (P P' Q : proc) (p q : PP) (t : type),
sem P (about p q t) P' -> Pr P P' p q t -> Pr (sum P Q) P' p q t) ->
(forall (P P' Q : proc) (p q : PP) (t : type),
sem P (about p q t) P' -> Pr P P' p q t -> Pr (sum Q P) P' p q t) ->
(forall (P P' : proc) (p q r : PP) (t : type),
sem P (about p q t) P' ->
Pr P P' p q t -> Pr (mat (pname r) (pname r) P) P' p q t) ->
forall (P P' : proc) (p q : PP) (t : type),
sem P (about p q t) P' -> Pr P P' p q t.
Theorem tau_ind :
forall Pr : proc -> proc -> Prop,
(forall (P P' Q Q' : proc) (p q : PP),
sem P (ainp p q) P' -> sem Q (aout p q) Q' -> Pr (par P Q) (par P' Q')) ->
(forall (P P' Q Q' : proc) (p q : PP),
sem P (ainp p q) P' -> sem Q (aout p q) Q' -> Pr (par Q P) (par Q' P')) ->
(forall (P P' Q Q' : proc) (p q r : PP) (t : type) (x : VV),
fresh q P ->
freshvar x P' ->
freshvar x Q' ->
sem P (ainp p q) P' ->
sem Q (about p r t) Q' ->
Pr (par P Q)
(res x t
(par (subs_par_proc P' (vname x) q) (subs_par_proc Q' (vname x) r)))) ->
(forall (P P' Q Q' : proc) (p q r : PP) (t : type) (x : VV),
fresh q P ->
freshvar x P' ->
freshvar x Q' ->
sem P (ainp p q) P' ->
sem Q (about p r t) Q' ->
Pr (par Q P)
(res x t
(par (subs_par_proc Q' (vname x) r) (subs_par_proc P' (vname x) q)))) ->
(forall (x y : VV) (t' : type) (P P' : proc),
(forall r : PP,
sem (subs_var_proc P (pname r) x) tau (subs_var_proc P' (pname r) y)) ->
(forall r : PP,
Pr (subs_var_proc P (pname r) x) (subs_var_proc P' (pname r) y)) ->
Pr (res x t' P) (res y t' P')) ->
(forall P P' : proc,
sem (par (ban P) P) tau P' -> Pr (par (ban P) P) P' -> Pr (ban P) P') ->
(forall P P' Q : proc, sem P tau P' -> Pr P P' -> Pr (par P Q) (par P' Q)) ->
(forall P P' Q : proc, sem P tau P' -> Pr P P' -> Pr (par Q P) (par Q P')) ->
(forall P P' Q : proc, sem P tau P' -> Pr P P' -> Pr (sum P Q) P') ->
(forall P P' Q : proc, sem P tau P' -> Pr P P' -> Pr (sum Q P) P') ->
(forall (P P' : proc) (r : PP),
sem P tau P' -> Pr P P' -> Pr (mat (pname r) (pname r) P) P') ->
forall P P' : proc, sem P tau P' -> Pr P P'.
Theorem freshname_is :
forall (p : PP) (n : name), freshname p n -> n <> pname p.
Theorem freshvarname_is :
forall (x : VV) (n : name), freshvarname x n -> n <> vname x.
Theorem fresh_after_subs_name :
forall (p q : PP) (x : VV) (n : name),
p <> q -> freshname p n -> freshname p (subs_var_name n (pname q) x).
Theorem fresh_after_subs :
forall (p q : PP) (x : VV) (P : proc),
p <> q -> fresh p P -> fresh p (subs_var_proc P (pname q) x).
Theorem fresh_after_subs_par_name :
forall (p q r : PP) (n : name),
r <> p -> freshname r n -> freshname r (subs_par_name n (pname p) q).
Theorem fresh_after_subs_par :
forall (p q r : PP) (P : proc),
r <> p -> fresh r P -> fresh r (subs_par_proc P (pname p) q).
Theorem fresh_after_subs_by_var_name :
forall (n : name) (p q : PP) (x : VV),
freshname p n -> freshname p (subs_par_name n (vname x) q).
Theorem fresh_after_subs_by_var :
forall (P : proc) (p q : PP) (x : VV),
fresh p P -> fresh p (subs_par_proc P (vname x) q).
Theorem fresh_before_subs_name :
forall (p q : PP) (x : VV) (n : name),
freshname p (subs_var_name n (pname q) x) -> freshname p n.
Theorem fresh_before_subs :
forall (p q : PP) (x : VV) (P : proc),
fresh p (subs_var_proc P (pname q) x) -> fresh p P.
Theorem out_known_name :
forall (P P' : proc) (p q : PP), sem P (aout p q) P' -> ~ fresh q P.
Theorem inp_on_known_name :
forall (P P' : proc) (p q : PP), sem P (ainp p q) P' -> ~ fresh p P.
Theorem fresh_masked_by_var_name :
forall (n : name) (p : PP) (x : VV),
freshname p (subs_par_name n (vname x) p).
Theorem fresh_masked_by_var :
forall (P : proc) (p : PP) (x : VV), fresh p (subs_par_proc P (vname x) p).
Theorem fresh_after_trans :
forall (P P' : proc) (mu : act),
sem P mu P' -> forall q : PP, fresh q P -> freshact q mu -> fresh q P'.
Theorem fresh_mask_name :
forall (n : name) (p q : PP),
p <> q -> freshname q (subs_par_name n (pname p) q).
Theorem fresh_mask :
forall (P : proc) (p q : PP),
p <> q -> fresh q (subs_par_proc P (pname p) q).
Theorem bout_autored :
forall (P P' : proc) (p q : PP) (t : type),
sem P (about p q t) P' ->
forall G : env, typing G P -> typing (addenv G q t) P'.
Theorem bout_emits_correct_type :
forall (P P' : proc) (p q : PP) (t : type),
sem P (about p q t) P' ->
forall G : env, typing G P -> typest t (getobj (G p)).
Theorem tau_red :
forall P P' : proc,
sem P tau P' -> forall G : env, typing G P -> typing G P'.