| author | oheimb | 
| Tue, 02 Jan 2001 22:41:17 +0100 | |
| changeset 10763 | 08e1610c1dcb | 
| parent 6068 | 2d8f3e1f1151 | 
| child 11317 | 7f9e4c389318 | 
| permissions | -rw-r--r-- | 
| 1461 | 1  | 
(* Title: ZF/AC/recfunAC16.ML  | 
| 1196 | 2  | 
ID: $Id$  | 
| 1461 | 3  | 
Author: Krzysztof Grabczewski  | 
| 1196 | 4  | 
|
5  | 
Properties of the recursive definition used in the proof of WO2 ==> AC16  | 
|
6  | 
*)  | 
|
7  | 
||
8  | 
(* ********************************************************************** *)  | 
|
| 1461 | 9  | 
(* Basic properties of recfunAC16 *)  | 
| 1196 | 10  | 
(* ********************************************************************** *)  | 
11  | 
||
| 5068 | 12  | 
Goalw [recfunAC16_def] "recfunAC16(f,fa,0,a) = 0";  | 
| 
1208
 
bc3093616ba4
Ran expandshort and corrected spelling of Grabczewski
 
paulson 
parents: 
1196 
diff
changeset
 | 
13  | 
by (rtac transrec2_0 1);  | 
| 3731 | 14  | 
qed "recfunAC16_0";  | 
| 1196 | 15  | 
|
| 6068 | 16  | 
Goalw [recfunAC16_def]  | 
17  | 
"recfunAC16(f,fa,succ(i),a) = \  | 
|
18  | 
\ (if (EX y:recfunAC16(f,fa,i,a). fa ` i <= y) then recfunAC16(f,fa,i,a) \  | 
|
19  | 
\ else recfunAC16(f,fa,i,a) Un \  | 
|
20  | 
\           {f ` (LEAST j. fa ` i <= f ` j &  \
 | 
|
21  | 
\ (ALL b<a. (fa`b <= f`j \  | 
|
22  | 
\ --> (ALL t:recfunAC16(f,fa,i,a). ~ fa`b <= t))))})";  | 
|
| 
1208
 
bc3093616ba4
Ran expandshort and corrected spelling of Grabczewski
 
paulson 
parents: 
1196 
diff
changeset
 | 
23  | 
by (rtac transrec2_succ 1);  | 
| 3731 | 24  | 
qed "recfunAC16_succ";  | 
| 1196 | 25  | 
|
| 5137 | 26  | 
Goalw [recfunAC16_def] "Limit(i) \  | 
| 1461 | 27  | 
\ ==> recfunAC16(f,fa,i,a) = (UN j<i. recfunAC16(f,fa,j,a))";  | 
| 
1208
 
bc3093616ba4
Ran expandshort and corrected spelling of Grabczewski
 
paulson 
parents: 
1196 
diff
changeset
 | 
28  | 
by (etac transrec2_Limit 1);  | 
| 3731 | 29  | 
qed "recfunAC16_Limit";  | 
| 1196 | 30  | 
|
31  | 
(* ********************************************************************** *)  | 
|
| 1461 | 32  | 
(* Monotonicity of transrec2 *)  | 
| 1196 | 33  | 
(* ********************************************************************** *)  | 
34  | 
||
35  | 
val [prem1, prem2] = goal thy  | 
|
| 2469 | 36  | 
"[| !!g r. r <= B(g,r); Ord(i) |] \  | 
| 1461 | 37  | 
\ ==> j<i --> transrec2(j, 0, B) <= transrec2(i, 0, B)";  | 
| 1196 | 38  | 
by (resolve_tac [prem2 RS trans_induct] 1);  | 
| 
1208
 
bc3093616ba4
Ran expandshort and corrected spelling of Grabczewski
 
paulson 
parents: 
1196 
diff
changeset
 | 
39  | 
by (rtac Ord_cases 1 THEN (REPEAT (assume_tac 1)));  | 
| 2469 | 40  | 
by (Fast_tac 1);  | 
41  | 
by (Asm_simp_tac 1);  | 
|
| 1196 | 42  | 
by (fast_tac (FOL_cs addSIs [succI1, prem1]  | 
| 1461 | 43  | 
addSEs [ballE, leE, prem1 RSN (2, subset_trans)]) 1);  | 
| 4091 | 44  | 
by (fast_tac (claset() addIs [OUN_I, ltI]  | 
| 1461 | 45  | 
addSEs [Limit_has_succ RS ltE, succI1 RSN (2, Ord_in_Ord) RS le_refl,  | 
46  | 
transrec2_Limit RS ssubst]) 1);  | 
|
| 3731 | 47  | 
qed "transrec2_mono_lemma";  | 
| 1196 | 48  | 
|
49  | 
val [prem1, prem2] = goal thy "[| !!g r. r <= B(g,r); j le i |] \  | 
|
| 1461 | 50  | 
\ ==> transrec2(j, 0, B) <= transrec2(i, 0, B)";  | 
| 1196 | 51  | 
by (resolve_tac [prem2 RS leE] 1);  | 
52  | 
by (resolve_tac [transrec2_mono_lemma RS impE] 1);  | 
|
| 4091 | 53  | 
by (TRYALL (fast_tac (claset() addSIs [prem1, prem2, lt_Ord2])));  | 
| 3731 | 54  | 
qed "transrec2_mono";  | 
| 1196 | 55  | 
|
56  | 
(* ********************************************************************** *)  | 
|
| 1461 | 57  | 
(* Monotonicity of recfunAC16 *)  | 
| 1196 | 58  | 
(* ********************************************************************** *)  | 
59  | 
||
| 5068 | 60  | 
Goalw [recfunAC16_def]  | 
| 1461 | 61  | 
"!!i. i le j ==> recfunAC16(f, g, i, a) <= recfunAC16(f, g, j, a)";  | 
| 
1208
 
bc3093616ba4
Ran expandshort and corrected spelling of Grabczewski
 
paulson 
parents: 
1196 
diff
changeset
 | 
62  | 
by (rtac transrec2_mono 1);  | 
| 
5116
 
8eb343ab5748
Renamed expand_if to split_if and setloop split_tac to addsplits,
 
paulson 
parents: 
5068 
diff
changeset
 | 
63  | 
by (REPEAT (fast_tac (claset() addIs [split_if RS iffD2]) 1));  | 
| 3731 | 64  | 
qed "recfunAC16_mono";  | 
| 1196 | 65  |