equal
deleted
inserted
replaced
1 (* Title: HOL/UNITY/Reachability |
1 (* Title: HOL/UNITY/Reachability.thy |
2 ID: $Id$ |
|
3 Author: Tanja Vos, Cambridge University Computer Laboratory |
2 Author: Tanja Vos, Cambridge University Computer Laboratory |
4 Copyright 2000 University of Cambridge |
3 Copyright 2000 University of Cambridge |
5 |
4 |
6 Reachability in Graphs |
5 Reachability in Graphs. |
7 |
6 |
8 From Chandy and Misra, "Parallel Program Design" (1989), sections 6.2 and 11.3 |
7 From Chandy and Misra, "Parallel Program Design" (1989), sections 6.2 |
|
8 and 11.3. |
9 *) |
9 *) |
10 |
10 |
11 theory Reachability imports "../Detects" Reach begin |
11 theory Reachability imports "../Detects" Reach begin |
12 |
12 |
13 types edge = "(vertex*vertex)" |
13 types edge = "(vertex*vertex)" |
298 "[| v \<in> V; w \<in> V |] |
298 "[| v \<in> V; w \<in> V |] |
299 ==> F \<in> UNIV LeadsTo |
299 ==> F \<in> UNIV LeadsTo |
300 ((reachable v <==> {s. (root,v): REACHABLE}) \<inter> nmsg_eq 0 (v,w))" |
300 ((reachable v <==> {s. (root,v): REACHABLE}) \<inter> nmsg_eq 0 (v,w))" |
301 apply (rule LeadsTo_Reachability [THEN LeadsTo_Trans], blast) |
301 apply (rule LeadsTo_Reachability [THEN LeadsTo_Trans], blast) |
302 apply (subgoal_tac |
302 apply (subgoal_tac |
303 "F \<in> (reachable v <==> {s. (root,v) \<in> REACHABLE}) \<inter> |
303 "F \<in> (reachable v <==> {s. (root,v) \<in> REACHABLE}) \<inter> |
304 UNIV LeadsTo (reachable v <==> {s. (root,v) \<in> REACHABLE}) \<inter> |
304 UNIV LeadsTo (reachable v <==> {s. (root,v) \<in> REACHABLE}) \<inter> |
305 nmsg_eq 0 (v,w) ") |
305 nmsg_eq 0 (v,w) ") |
306 apply simp |
306 apply simp |
307 apply (rule PSP_Stable2) |
307 apply (rule PSP_Stable2) |
308 apply (rule MA7) |
308 apply (rule MA7) |