let s1, s2 be State of ; for J being InitHalting Program of st Initialized J c= s1 holds
for n being Element of NAT st ProgramPart (Relocated J,n) c= s2 & IC s2 = insloc n & DataPart s1 = DataPart s2 holds
for i being Element of NAT holds
( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) )
let J be InitHalting Program of ; ( Initialized J c= s1 implies for n being Element of NAT st ProgramPart (Relocated J,n) c= s2 & IC s2 = insloc n & DataPart s1 = DataPart s2 holds
for i being Element of NAT holds
( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) ) )
set JAt = Initialized J;
assume A1:
Initialized J c= s1
; for n being Element of NAT st ProgramPart (Relocated J,n) c= s2 & IC s2 = insloc n & DataPart s1 = DataPart s2 holds
for i being Element of NAT holds
( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) )
let n be Element of NAT ; ( ProgramPart (Relocated J,n) c= s2 & IC s2 = insloc n & DataPart s1 = DataPart s2 implies for i being Element of NAT holds
( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) ) )
assume that
A2:
ProgramPart (Relocated J,n) c= s2
and
A3:
IC s2 = insloc n
and
A4:
DataPart s1 = DataPart s2
; for i being Element of NAT holds
( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) )
A5: DataPart (Computation s1,0 ) =
DataPart s2
by A4, AMI_1:13
.=
DataPart (Computation s2,0 )
by AMI_1:13
;
defpred S1[ Element of NAT ] means ( (IC (Computation s1,$1)) + n = IC (Computation s2,$1) & IncAddr (CurInstr (Computation s1,$1)),n = CurInstr (Computation s2,$1) & DataPart (Computation s1,$1) = DataPart (Computation s2,$1) );
A6:
J c= Initialized J
by SCMFSA6A:26;
then A7:
dom J c= dom (Initialized J)
by GRFUNC_1:8;
A8:
for k being Element of NAT st S1[k] holds
S1[k + 1]
proof
let k be
Element of
NAT ;
( S1[k] implies S1[k + 1] )
A9:
Computation s1,
(k + 1) =
Following (Computation s1,k)
by AMI_1:14
.=
Exec (CurInstr (Computation s1,k)),
(Computation s1,k)
;
reconsider l =
IC (Computation s1,(k + 1)) as
Element of
NAT by ORDINAL1:def 13;
reconsider j =
CurInstr (Computation s1,(k + 1)) as
Instruction of ;
A10:
Computation s2,
(k + 1) =
Following (Computation s2,k)
by AMI_1:14
.=
Exec (CurInstr (Computation s2,k)),
(Computation s2,k)
;
A11:
IC (Computation s1,(k + 1)) in dom J
by A1, Def1;
assume A12:
S1[
k]
;
S1[k + 1]
hence A13:
(IC (Computation s1,(k + 1))) + n = IC (Computation s2,(k + 1))
by A9, A10, SCMFSA6A:41;
( IncAddr (CurInstr (Computation s1,(k + 1))),n = CurInstr (Computation s2,(k + 1)) & DataPart (Computation s1,(k + 1)) = DataPart (Computation s2,(k + 1)) )
then
(
IC (Computation s2,(k + 1)) in NAT &
IC (Computation s2,(k + 1)) in dom (Relocated J,n) )
by A11, AMI_1:def 4, SCMFSA_5:4;
then
IC (Computation s2,(k + 1)) in (dom (Relocated J,n)) /\ NAT
by XBOOLE_0:def 4;
then A14:
IC (Computation s2,(k + 1)) in dom (ProgramPart (Relocated J,n))
by RELAT_1:90;
dom (ProgramPart J) = (dom J) /\ NAT
by RELAT_1:90;
then A15:
l in dom (ProgramPart J)
by A11, XBOOLE_0:def 4;
j =
s1 . (IC (Computation s1,(k + 1)))
by AMI_1:54
.=
(Initialized J) . (IC (Computation s1,(k + 1)))
by A1, A7, A11, GRFUNC_1:8
.=
J . l
by A6, A11, GRFUNC_1:8
;
hence IncAddr (CurInstr (Computation s1,(k + 1))),
n =
(Relocated J,n) . (l + n)
by A15, SCMFSA_5:7
.=
(ProgramPart (Relocated J,n)) . (IC (Computation s2,(k + 1)))
by A13, FUNCT_1:72
.=
s2 . (IC (Computation s2,(k + 1)))
by A2, A14, GRFUNC_1:8
.=
CurInstr (Computation s2,(k + 1))
by AMI_1:54
;
DataPart (Computation s1,(k + 1)) = DataPart (Computation s2,(k + 1))
thus
DataPart (Computation s1,(k + 1)) = DataPart (Computation s2,(k + 1))
by A12, A9, A10, SCMFSA6A:41;
verum
end;
ProgramPart J = J
by AMI_1:105;
then A16:
insloc 0 in dom (ProgramPart J)
by Th11;
A17:
insloc 0 in dom J
by Th11;
A18:
IC SCM+FSA in dom (Initialized J)
by SCMFSA6A:24;
then A19: s1 . (IC s1) =
s1 . ((Initialized J) . (IC SCM+FSA ))
by A1, GRFUNC_1:8
.=
s1 . (insloc 0 )
by SCMFSA6A:46
.=
(Initialized J) . (insloc 0 )
by A1, A7, A17, GRFUNC_1:8
.=
J . (insloc 0 )
by A6, A17, GRFUNC_1:8
;
let i be Element of NAT ; ( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) )
insloc 0 in dom J
by Th11;
then
(insloc 0 ) + n in dom (Relocated J,n)
by SCMFSA_5:4;
then A20:
insloc (0 + n) in dom (ProgramPart (Relocated J,n))
by AMI_1:106;
A21: IC (Computation s1,0 ) =
s1 . (IC SCM+FSA )
by AMI_1:13
.=
(Initialized J) . (IC SCM+FSA )
by A1, A18, GRFUNC_1:8
.=
insloc 0
by SCMFSA6A:46
;
IncAddr (CurInstr (Computation s1,0 )),n =
IncAddr (CurInstr s1),n
by AMI_1:13
.=
(Relocated J,n) . ((insloc 0 ) + n)
by A19, A16, SCMFSA_5:7
.=
(ProgramPart (Relocated J,n)) . (insloc n)
by FUNCT_1:72
.=
CurInstr s2
by A2, A3, A20, GRFUNC_1:8
.=
CurInstr (Computation s2,0 )
by AMI_1:13
;
then A22:
S1[ 0 ]
by A3, A21, A5, AMI_1:13;
for k being Element of NAT holds S1[k]
from NAT_1:sch 1(A22, A8);
hence
( (IC (Computation s1,i)) + n = IC (Computation s2,i) & IncAddr (CurInstr (Computation s1,i)),n = CurInstr (Computation s2,i) & DataPart (Computation s1,i) = DataPart (Computation s2,i) )
; verum