author | paulson |
Tue, 21 Sep 1999 11:11:09 +0200 | |
changeset 7547 | a72a551b6d79 |
parent 7359 | 98a2afab3f86 |
child 7826 | c6a8b73b6c2a |
permissions | -rw-r--r-- |
5252 | 1 |
(* Title: HOL/UNITY/Union.thy |
2 |
ID: $Id$ |
|
3 |
Author: Lawrence C Paulson, Cambridge University Computer Laboratory |
|
4 |
Copyright 1998 University of Cambridge |
|
5 |
||
6 |
Unions of programs |
|
7 |
||
5804
8e0a4c4fd67b
Revising the Client proof as suggested by Michel Charpentier. New lemmas
paulson
parents:
5648
diff
changeset
|
8 |
Partly from Misra's Chapter 5: Asynchronous Compositions of Programs |
7359 | 9 |
|
10 |
Do we need a Meet operator? (Aka Intersection) |
|
5252 | 11 |
*) |
12 |
||
13 |
Union = SubstAx + FP + |
|
14 |
||
15 |
constdefs |
|
5648 | 16 |
JOIN :: ['a set, 'a => 'b program] => 'b program |
6295
351b3c2b0d83
removed the infernal States, eqStates, compatible, etc.
paulson
parents:
6012
diff
changeset
|
17 |
"JOIN I F == mk_program (INT i:I. Init (F i), UN i:I. Acts (F i))" |
5252 | 18 |
|
5648 | 19 |
Join :: ['a program, 'a program] => 'a program (infixl 65) |
6295
351b3c2b0d83
removed the infernal States, eqStates, compatible, etc.
paulson
parents:
6012
diff
changeset
|
20 |
"F Join G == mk_program (Init F Int Init G, Acts F Un Acts G)" |
5252 | 21 |
|
6295
351b3c2b0d83
removed the infernal States, eqStates, compatible, etc.
paulson
parents:
6012
diff
changeset
|
22 |
SKIP :: 'a program |
351b3c2b0d83
removed the infernal States, eqStates, compatible, etc.
paulson
parents:
6012
diff
changeset
|
23 |
"SKIP == mk_program (UNIV, {})" |
5259 | 24 |
|
5648 | 25 |
Diff :: "['a program, ('a * 'a)set set] => 'a program" |
6295
351b3c2b0d83
removed the infernal States, eqStates, compatible, etc.
paulson
parents:
6012
diff
changeset
|
26 |
"Diff F acts == mk_program (Init F, Acts F - acts)" |
5648 | 27 |
|
5804
8e0a4c4fd67b
Revising the Client proof as suggested by Michel Charpentier. New lemmas
paulson
parents:
5648
diff
changeset
|
28 |
(*The set of systems that regard "v" as local to F*) |
5648 | 29 |
localTo :: ['a => 'b, 'a program] => 'a program set (infixl 80) |
5804
8e0a4c4fd67b
Revising the Client proof as suggested by Michel Charpentier. New lemmas
paulson
parents:
5648
diff
changeset
|
30 |
"v localTo F == {G. ALL z. Diff G (Acts F) : stable {s. v s = z}}" |
8e0a4c4fd67b
Revising the Client proof as suggested by Michel Charpentier. New lemmas
paulson
parents:
5648
diff
changeset
|
31 |
|
6012
1894bfc4aee9
Addition of the States component; parts of Comp not working
paulson
parents:
5804
diff
changeset
|
32 |
(*Two programs with disjoint actions, except for identity actions *) |
5804
8e0a4c4fd67b
Revising the Client proof as suggested by Michel Charpentier. New lemmas
paulson
parents:
5648
diff
changeset
|
33 |
Disjoint :: ['a program, 'a program] => bool |
6295
351b3c2b0d83
removed the infernal States, eqStates, compatible, etc.
paulson
parents:
6012
diff
changeset
|
34 |
"Disjoint F G == Acts F Int Acts G <= {Id}" |
5648 | 35 |
|
5313
1861a564d7e2
Constrains, Stable, Invariant...more of the substitution axiom, but Union
paulson
parents:
5259
diff
changeset
|
36 |
syntax |
7359 | 37 |
"@JOIN1" :: [pttrns, 'b set] => 'b set ("(3JN _./ _)" 10) |
5313
1861a564d7e2
Constrains, Stable, Invariant...more of the substitution axiom, but Union
paulson
parents:
5259
diff
changeset
|
38 |
"@JOIN" :: [pttrn, 'a set, 'b set] => 'b set ("(3JN _:_./ _)" 10) |
1861a564d7e2
Constrains, Stable, Invariant...more of the substitution axiom, but Union
paulson
parents:
5259
diff
changeset
|
39 |
|
1861a564d7e2
Constrains, Stable, Invariant...more of the substitution axiom, but Union
paulson
parents:
5259
diff
changeset
|
40 |
translations |
1861a564d7e2
Constrains, Stable, Invariant...more of the substitution axiom, but Union
paulson
parents:
5259
diff
changeset
|
41 |
"JN x:A. B" == "JOIN A (%x. B)" |
7359 | 42 |
"JN x y. B" == "JN x. JN y. B" |
43 |
"JN x. B" == "JOIN UNIV (%x. B)" |
|
5313
1861a564d7e2
Constrains, Stable, Invariant...more of the substitution axiom, but Union
paulson
parents:
5259
diff
changeset
|
44 |
|
5252 | 45 |
end |