Quelle scmpds_7.miz
Sprache: Mizar
|
|
:: The Construction and Computation of For-loop Programs for SCMPDS
:: by JingChao Chen and Piotr Rudnicki
::
:: Received December 27, 1999
:: Copyright (c) 1999-2026 Association of Mizar Users
:: (Stowarzyszenie Uzytkownikow Mizara, Bialystok, Poland).
:: This code can be distributed under the GNU General Public Licence
:: version 3.0 or later, or the Creative Commons Attribution-ShareAlike
:: License version 3.0 or later, subject to the binding interpretation
:: detailed in file COPYING.interpretation.
:: See COPYING.GPL and COPYING.CC-BY-SA for the full text of these
:: licenses, or see http://www.gnu.org/licenses/gpl.html and
:: http://creativecommons.org/licenses/by-sa/3.0/.
environ
vocabularies NUMBERS, SUBSET_1, SCMPDS_2, AMI_1, FSM_1, INT_1, AMI_2, ARYTM_1,
COMPLEX1, ARYTM_3, CARD_1, RELAT_1, FUNCT_4, XBOOLE_0, CIRCUIT2, FUNCT_1,
NAT_1, TARSKI, TURING_1, VALUED_1, SCMPDS_4, AMISTD_2, XXREAL_0, AMI_3,
SCMFSA_7, UNIALG_2, SCMFSA7B, GRAPHSP, MSUALG_1, SCMFSA6B, SCMPDS_5,
STRUCT_0, SFMASTR3, SEMI_AF1, SCMP_GCD, FINSEQ_1, CARD_3, FINSEQ_3,
SCMPDS_7, PARTFUN1, EXTPRO_1, SCMFSA6C, COMPOS_1;
notations TARSKI, XBOOLE_0, ENUMSET1, SUBSET_1, CARD_1, ORDINAL1, NUMBERS,
XCMPLX_0, XXREAL_0, COMPLEX1, RELAT_1, FUNCT_1, PARTFUN1, FUNCT_4, INT_1,
NAT_1, FUNCOP_1, AFINSQ_1, VALUED_1, STRUCT_0, MEMSTR_0, COMPOS_0,
COMPOS_1, EXTPRO_1, AMI_2, FUNCT_7, SCMPDS_2, SCMPDS_4, SCMPDS_5,
SCMPDS_6, SCMP_GCD, FINSEQ_1, WSIERP_1;
constructors ENUMSET1, XXREAL_0, REAL_1, INT_2, WSIERP_1, SCM_1, SCMPDS_4,
SCMPDS_5, SCMPDS_6, SCMP_GCD, AMI_2, MEMSTR_0, RELSET_1, NUMBERS;
registrations ORDINAL1, RELSET_1, XXREAL_0, XREAL_0, NAT_1, INT_1, SCMPDS_2,
SCMPDS_4, SCMPDS_5, VALUED_0, FINSEQ_1, CARD_1, FUNCT_4, COMPOS_1,
AFINSQ_1, EXTPRO_1, MEMSTR_0, COMPOS_0;
requirements REAL, NUMERALS, SUBSET, ARITHM;
equalities FUNCOP_1, COMPOS_1, EXTPRO_1, AMI_3, SCMPDS_2, SCMP_GCD, SCMPDS_4,
MEMSTR_0;
expansions EXTPRO_1;
theorems NAT_1, FUNCOP_1, TARSKI, FUNCT_4, FUNCT_1, INT_1, MEMSTR_0, SCMPDS_2,
ABSVALUE, GRFUNC_1, SCMPDS_4, SCMPDS_5, SCMPDS_6, ENUMSET1, SCMP_GCD,
WSIERP_1, FINSEQ_1, RVSUM_1, RELAT_1, FINSEQ_3, XBOOLE_1, XREAL_1,
XXREAL_0, FINSEQ_2, VALUED_1, PBOOLE, PARTFUN1, AFINSQ_1, COMPOS_1,
EXTPRO_1, AMI_3, AMI_2, XTUPLE_0, NUMBERS;
schemes NAT_1;
begin :: Preliminaries
reserve x for set,
m,n for Nat,
a,b for Int_position,
i,j,k for Instruction of SCMPDS,
s,s1,s2 for State of SCMPDS,
k1,k2 for Integer,
loc,l for Nat,
I,J,K for Program of SCMPDS;
set A = NAT;
set D = SCM-Data-Loc;
theorem Th1: ::SCMPDS_6:23
for s being State of SCMPDS,m,n being Nat st IC s=
m holds ICplusConst(s,n-m)= n
proof
let s be State of SCMPDS,m,n be Nat;
ex k be Element of NAT st k = IC s &
ICplusConst(s,n-m) = |.k+(n-m).| by SCMPDS_2:def 18;
hence thesis by ABSVALUE:def 1;
end;
theorem Th2:
i ';' I ';' j ';' k = i ';' (I ';' j ';' k)
proof
thus i ';' I ';' j ';' k = i ';' (I ';' j) ';' k by SCMPDS_4: 15
.= i ';' (I ';' j ';' k) by SCMPDS_4: 15;
end;
theorem Th3:
Shift(J,card I) c= I ';' J ';' K
proof
set IJ= I ';' J;
dom IJ misses dom Shift(K, card IJ) by AFINSQ_1: 72;
then
A1: IJ c= IJ ';' K by FUNCT_4: 32;
Shift(J, card I) c= IJ by FUNCT_4: 25;
hence thesis by A1,XBOOLE_1: 1;
end;
theorem Th4:
I c= stop (I ';' J)
proof
stop (I ';' J) =I ';' (J ';' Stop SCMPDS) by AFINSQ_1: 27;
hence thesis by AFINSQ_1: 74;
end;
::$CT 2
theorem
for s being State of SCMPDS, i being Instruction of SCMPDS st InsCode
i in { 0, 4, 5, 6, 14} holds DataPart Exec(i,s) = DataPart s
proof
let s be State of SCMPDS,i be Instruction of SCMPDS;
assume
A1: InsCode i in { 0, 4, 5, 6, 14};
now
let a be Int_position;
per cases by A1,ENUMSET1:def 3;
suppose
InsCode i = 0;
hence Exec(i,s).a = s.a by SCMPDS_2: 86;
end;
suppose
InsCode i = 14;
then ex k1 st i = goto k1 by SCMPDS_2: 26;
hence Exec(i,s).a = s.a by SCMPDS_2: 54;
end;
suppose
InsCode i = 4;
then ex b,k1,k2 st i = (b,k1)<> 0_goto k2 by SCMPDS_2: 30;
hence Exec(i,s).a = s.a by SCMPDS_2: 55;
end;
suppose
InsCode i = 5;
then ex b,k1,k2 st i = (b,k1)<= 0_goto k2 by SCMPDS_2: 31;
hence Exec(i,s).a = s.a by SCMPDS_2: 56;
end;
suppose
InsCode i = 6;
then ex b,k1,k2 st i = (b,k1)>= 0_goto k2 by SCMPDS_2: 32;
hence Exec(i,s).a = s.a by SCMPDS_2: 57;
end;
end;
hence thesis by SCMPDS_4: 8;
end;
reserve P,P1,P2,Q for Instruction-Sequence of SCMPDS;
theorem Th6:
for s1,s2 being State of SCMPDS,I being Program of SCMPDS
st I is_closed_on s1,P1 & DataPart s1 = DataPart s2
for k being Nat
holds
Comput(P1 +* stop I,Initialize s1,k)
= Comput(P2 +* stop I,Initialize s2,k) &
CurInstr(P1 +* stop I,Comput(P1 +* stop I,Initialize s1,k)) =
CurInstr(P2 +* stop I,Comput(P2 +* stop I,Initialize s2,k))
proof
let s1,s2 be State of SCMPDS,I be Program of SCMPDS;
assume
A1: I is_closed_on s1,P1;
set pI = stop I;
set ss1 = Initialize s1, PP1 = P1 +* stop I;
set ss2 = Initialize s2, PP2 = P2 +* stop I;
A2: pI c= PP2 by FUNCT_4: 25;
A3: pI c= PP1 by FUNCT_4: 25;
assume
A4: DataPart s1 = DataPart s2;
let k be Nat;
A5: IC Comput(PP1,ss1,k) in dom pI by A1,SCMPDS_6:def 2;
A6: I is_closed_on s2,P2 by A1,A4,SCMPDS_6: 22;
then
A7: for m st m < k holds IC Comput(PP2,ss2,m) in dom pI by SCMPDS_6:def 2;
ss1 = ss2 by A4,MEMSTR_0: 80;
hence
A8: Comput(PP1,ss1,k) = Comput(PP2,ss2,k)
by A3,A2,A7,SCMPDS_4: 21;
A9: IC Comput(PP2,ss2,k) in dom pI by A6,SCMPDS_6:def 2;
thus CurInstr(PP2,Comput(PP2,ss2,k))
= PP2.IC Comput(PP2,ss2,k) by PBOOLE: 143
.= pI.IC Comput(PP2,ss2,k) by A2,A9,GRFUNC_1: 2
.= PP1.IC Comput(PP1,ss1,k) by A3,A8,A5,GRFUNC_1: 2
.= CurInstr(PP1,Comput(PP1,ss1,k)) by PBOOLE: 143;
end;
theorem Th7: ::SCMPDS_5:20
for s being 0-started State of SCMPDS
for I being Program of SCMPDS st I is_closed_on s,P1 &
stop I c= P1 & stop I c= P2
for k being Nat holds Comput(P1,s,k)
= Comput(P2,s,k)
& CurInstr(P1,Comput(P1,s,k)) = CurInstr(P2,Comput(P2,s,k))
proof
let s be 0-started State of SCMPDS;
let I be Program of SCMPDS;
set iI= stop I;
assume that
A1: I is_closed_on s,P1 and
A2: stop I c= P1 and
A3: stop I c= P2;
A4: Start-At( 0,SCMPDS) c= s by MEMSTR_0: 29;
A5: s = Initialize s by A4,FUNCT_4: 98;
A6: P2=P2 +* iI by A3,FUNCT_4: 98;
A7: DataPart s = DataPart s;
P1=P1 +* iI by A2,FUNCT_4: 98;
hence thesis by A1,A6,A7,Th6,A5;
end;
theorem Th8: ::SCMPDS_5:21
for s being 0-started State of SCMPDS
for I being Program of SCMPDS
st I is_closed_on s,P1 & I is_halting_on s,P1 &
stop I c= P1 & stop I c= P2
holds LifeSpan(P1,s) = LifeSpan(P2,s)
& Result(P1,s) = Result(P2,s)
proof
let s be 0-started State of SCMPDS;
let I be Program of SCMPDS;
assume that
A1: I is_closed_on s,P1 and
A2: I is_halting_on s,P1 and
A3: stop I c= P1 and
A4: stop I c= P2;
A5: Start-At( 0,SCMPDS) c= s by MEMSTR_0: 29;
A6: Start-At( 0,SCMPDS) c= s by MEMSTR_0: 29;
DataPart s = DataPart s;
then
A7: I is_halting_on s,P2 by A1,A2,SCMPDS_6: 23;
A8: Initialize s = s by A5,FUNCT_4: 98;
A9: Initialize s = s by A6,FUNCT_4: 98;
P2= P2 +* stop I by A4,FUNCT_4: 98;
then
A10: P2 halts_on s by A7,A9,SCMPDS_6:def 3;
P1=P1 +* stop I by A3,FUNCT_4: 98;
then
A11: P1 halts_on s by A2,A8,SCMPDS_6:def 3;
A12: now
let l be Nat;
assume
A13: CurInstr(P2,Comput(P2,s,l)) = halt SCMPDS;
CurInstr(P1,Comput(P1,s,l)) = CurInstr(P2,Comput(P2,s,l))
by A1,A3,A4,Th7;
hence LifeSpan(P1,s) <= l by A11,A13,EXTPRO_1:def 15;
end;
CurInstr(P2,Comput(P2,s,LifeSpan(P1,s)))
= CurInstr(P1,Comput(P1,s,LifeSpan(P1,s)))
by A1,A3,A4,Th7
.= halt SCMPDS by A11,EXTPRO_1:def 15;
hence LifeSpan(P1,s) = LifeSpan(P2,s) by A12,A10,EXTPRO_1:def 15;
then
A14: Result(P2,s) = Comput(P2,s,LifeSpan(
P1,s)) by A10,EXTPRO_1: 23;
Result(P1,s) = Comput(P1,s,LifeSpan(P1,s)) by A11,EXTPRO_1: 23;
hence thesis by A1,A3,A4,A14,Th7;
end;
theorem Th9:
for s1,s2 being State of SCMPDS,I being Program of SCMPDS st I
is_closed_on s1,P1 & I is_halting_on s1,P1 & DataPart s1 = DataPart s2
holds LifeSpan(P1 +* stop I,Initialize s1)
= LifeSpan(P2 +* stop I,Initialize s2) &
Result(P1 +* stop I,Initialize s1)
= Result(P2 +* stop I,Initialize s2)
proof
let s1,s2 be State of SCMPDS,I be Program of SCMPDS;
assume
A1: I is_closed_on s1,P1;
set ss1 = Initialize s1, PP1 = P1 +* stop I;
set ss2 = Initialize s2, PP2 = P2 +* stop I;
assume
A2: I is_halting_on s1,P1;
then
A3: PP1 halts_on ss1 by SCMPDS_6:def 3;
then
A4: Result(PP1,ss1) = Comput(PP1,ss1,LifeSpan(
PP1,ss1)) by EXTPRO_1: 23;
assume
A5: DataPart s1 = DataPart s2;
then I is_halting_on s2,P2 by A1,A2,SCMPDS_6: 23;
then
A6: PP2 halts_on ss2 by SCMPDS_6:def 3;
A7: now
let l be Nat;
assume
A8: CurInstr(PP2,Comput(PP2,ss2,l)) = halt SCMPDS;
CurInstr(PP1,Comput(PP1,ss1,l))
= CurInstr(PP2,Comput(PP2,ss2,l))
by A1,A5,Th6;
hence LifeSpan(PP1,ss1) <= l by A3,A8,EXTPRO_1:def 15;
end;
CurInstr(PP2,
Comput(PP2,ss2,LifeSpan(PP1,ss1))) =
CurInstr(PP1,
Comput(PP1,ss1,LifeSpan(PP1,ss1)))
by A1,A5,Th6
.= halt SCMPDS by A3,EXTPRO_1:def 15;
hence LifeSpan(PP1,ss1) = LifeSpan(PP2,ss2) by A7,A6,EXTPRO_1:def 15;
then Result(PP2,ss2) = Comput(PP2,ss2,LifeSpan(
PP1,ss1)) by A6,EXTPRO_1: 23;
hence thesis by A1,A5,A4,Th6;
end;
theorem
for s1,s2 being 0-started State of SCMPDS,I being Program of SCMPDS st I
is_closed_on s1,P1 & I is_halting_on s1,P1 &
stop I c= P1 & stop I c= P2 &
ex k being Nat st
Comput(P1,s1,k) = s2
holds Result(P1,s1) = Result(P2,s2)
proof
let s1,s2 be 0-started State of SCMPDS,I be Program of SCMPDS;
set pI =stop I;
assume
A1: I is_closed_on s1,P1;
assume
A2: I is_halting_on s1,P1;
assume stop I c= P1;
then
A3: P1 = P1 +* stop I by FUNCT_4: 98;
assume stop I c= P2;
then
A4: P2 = P2 +* stop I by FUNCT_4: 98;
A5: s1 = Initialize s1 by MEMSTR_0: 44;
then
A6: P1 halts_on s1 by A2,A3,SCMPDS_6:def 3;
then consider n being Nat such that
A7: CurInstr(P1,Comput(P1,s1,n)) = halt SCMPDS;
A8: s2 = Initialize s2 by MEMSTR_0: 44;
given k being Nat such that
A9: Comput(P1,s1,k) = s2;
set s3 = Comput(P1,s1,k), P3 = P1;
A10: IC SCMPDS in dom s3 by MEMSTR_0: 2;
IC s3 = 0 by A9,MEMSTR_0:def 11;
then Start-At( 0,SCMPDS) c= s3 by A10,FUNCOP_1: 73;
then
A11: s3 = Initialize s3 by FUNCT_4: 98;
A12: now
let n be Nat;
IC Comput(P1,s3,n) = IC Comput(P1,s1,k+n) by EXTPRO_1: 4;
hence IC Comput(P3,s3,n) in dom pI
by A1,A3,A5,SCMPDS_6:def 2;
end;
CurInstr(P3,Comput(P3,s3,n)) =
CurInstr(P1,Comput(P1,s1,k+n)) by EXTPRO_1: 4
.= CurInstr(P1,Comput(P1,s1,n)) by A7,EXTPRO_1: 5,NAT_1: 11;
then P3 halts_on s3 by A7,EXTPRO_1: 29;
then
A13: I is_halting_on s3,P3 by A11,A3,SCMPDS_6:def 3;
A14: DataPart s3 = DataPart s2 by A9;
consider k being Nat such that
A15: CurInstr(P1,Comput(P1,s1,k))
= halt SCMPDS by A6;
A16: P1.IC Comput(P1,s1,k) = halt SCMPDS by A15,PBOOLE: 143;
I is_closed_on s3,P3 by A11,A12,A3,SCMPDS_6:def 2;
then Result(P3,s3) = Result(P2,s2) by A8,A14,A11,A13,Th9,A4,A3;
hence thesis by A16,EXTPRO_1: 8;
end;
theorem Th11:
for s being State of SCMPDS,I being Program of SCMPDS, a being
Int_position st I is_halting_on s,P holds IExec(I,P,Initialize s).a =
Comput(P +* stop I,Initialize s, (LifeSpan(P +* stop I,Initialize s))).a
by SCMPDS_6:def 3,EXTPRO_1: 23;
theorem
for s being State of SCMPDS,I being parahalting Program of SCMPDS, a
being Int_position holds IExec(I,P,Initialize s).a =
Comput(P +* stop I,Initialize s, (LifeSpan(P +* stop I,Initialize s))).a
by SCMPDS_6: 21,Th11;
theorem Th13:
for s being 0-started State of SCMPDS
for I being Program of SCMPDS,i being Nat st
stop I c= P &
I is_closed_on s,P & I is_halting_on s,P
& i < LifeSpan(P,s)
holds IC Comput(P,s,i) in dom I
proof
let s be 0-started State of SCMPDS;
let I be Program of SCMPDS,i be Nat;
set sI = stop I, Ci = Comput(P,s,i), Lc = IC Ci;
assume that
A1: sI c= P and
A2: I is_closed_on s,P and
A3: I is_halting_on s,P and
A4: i < LifeSpan(P,s);
A5: Start-At( 0,SCMPDS) c= s by MEMSTR_0: 29;
A6: P +* sI = P by A1,FUNCT_4: 98;
A7: s = Initialize s by A5,FUNCT_4: 98;
then
A8: Lc in dom sI by A2,A6,SCMPDS_6:def 2;
A9: P halts_on s by A3,A7,A6,SCMPDS_6:def 3;
now
assume
A10: sI.Lc=halt SCMPDS;
CurInstr(P,Ci) =P.Lc by PBOOLE: 143
.=halt SCMPDS by A8,A1,A10,GRFUNC_1: 2;
hence contradiction by A4,A9,EXTPRO_1:def 15;
end;
hence thesis by A8,COMPOS_1: 51;
end;
theorem Th14:
for s1 being 0-started State of SCMPDS
for I being shiftable Program of SCMPDS st
stop I c= P1 &
I is_closed_on s1,P1 & I is_halting_on s1,P1
for n being Nat
st Shift(I,n) c= P2 & IC s2 = n & DataPart s1 = DataPart s2
for i being Nat holds i < LifeSpan(P1,s1) implies
IC Comput(P1,s1,i) + n = IC Comput(P2,s2,i) &
CurInstr(P1,Comput(P1,s1,i)) = CurInstr(P2,Comput(P2,s2,i))
& DataPart Comput(P1,s1,i) = DataPart Comput(P2,s2,i)
proof
let s1 be 0-started State of SCMPDS;
let I be shiftable Program of SCMPDS;
set SI=stop I;
assume that
A1: SI c= P1 and
A2: I is_closed_on s1,P1 and
A3: I is_halting_on s1,P1;
A4: Start-At( 0,SCMPDS) c= s1 by MEMSTR_0: 29;
let n be Nat;
assume that
A6: Shift(I,n) c= P2 and
A7: IC s2 = n and
A8: DataPart s1 = DataPart s2;
defpred P[Nat] means $ 1 < LifeSpan(P1,s1) implies IC
Comput(P1,s1,$ 1) + n = IC Comput(P2,s2,$ 1) & CurInstr(P1,
Comput(P1,s1,$ 1))
= CurInstr(P2,Comput(P2,s2,$ 1))
& DataPart Comput(P1,s1,$ 1) = DataPart Comput(P2,s2,$ 1);
A9: s1=Initialize s1 by A4,FUNCT_4: 98;
A10: for k being Nat st P[k] holds P[k + 1]
proof
let k be Nat;
assume
A11: P[k];
now
reconsider m = IC Comput(P1,s1,k) as Nat;
set i = CurInstr(P1,Comput(
P1,s1,k));
A12: k <= k+ 1 by NAT_1: 11;
reconsider l = IC Comput(P1,s1,k+ 1) as Nat;
A13: Comput(P1,s1,k+ 1) = Following(P1,Comput(P1,s1,k)) by EXTPRO_1: 3
.= Exec(CurInstr(P1,Comput(P1,s1,k)),
Comput(P1,s1,k));
assume
A14: k+ 1 < LifeSpan(P1,s1);
then
A15: l+n in dom Shift(I,n) by A1,A2,A3,Th13,VALUED_1: 24;
A16: Comput(P2,s2,k+ 1) = Following(P2,Comput(P2,s2,k)) by EXTPRO_1: 3
.= Exec(CurInstr(P2,Comput(P2,s2,k)),
Comput(P2,s2,k));
A17: P1 +* SI = P1 by A1,FUNCT_4: 98;
then
A18: IC Comput(P1,s1,k) in dom SI by A2,A9,SCMPDS_6:def 2;
A19: i = P1.IC Comput(P1,s1,k) by PBOOLE: 143
.= SI.IC Comput(P1,s1,k) by A1,A18,GRFUNC_1: 2;
then
A20: InsCode i <> 3 by A18,SCMPDS_4:def 9;
A21: IC Comput(P1,s1,k+ 1) in dom SI by A2,A9,A17,SCMPDS_6:def 2;
A22: i valid_at m by A18,A19,SCMPDS_4:def 9;
A23: InsCode i <> 1 by A18,A19,SCMPDS_4:def 9;
hence
A24: IC Comput(P1,s1,k+ 1) + n = IC Comput(P2,s2,k+ 1)
by A11,A14,A12,A13,A16,A20,A22,SCMPDS_4: 28,XXREAL_0: 2;
CurInstr(P1,Comput(P1,s1,k+ 1)) = P1.l by PBOOLE: 143
.= SI.l by A1,A21,GRFUNC_1: 2;
hence CurInstr(P1,Comput(P1,s1,k+ 1))
= Shift(SI,n).(l + n) by A21,VALUED_1:def 12
.= Shift(I,n).(IC Comput(P2,s2,k+ 1))
by A24,A14,A1,A2,A3,Th13,COMPOS_1: 65
.= P2.IC Comput(P2,s2,k+ 1) by A6,A24,A15,GRFUNC_1: 2
.= CurInstr(P2,Comput(P2,s2,k+ 1)) by PBOOLE: 143;
thus DataPart Comput(P1,s1,k+ 1) = DataPart Comput(
P2,s2,k+ 1) by A11,A14,A12,A13,A16,A23,A20,A22,SCMPDS_4: 28,XXREAL_0: 2;
end;
hence thesis;
end;
let i be Nat;
A25: 0 in dom SI by COMPOS_1: 36;
A26: 0 in dom I by AFINSQ_1: 66;
A27: P[ 0]
proof
assume
0 < LifeSpan(P1,s1);
A28: (( 0 qua Nat)+ n) in dom Shift(I,n) by A26,VALUED_1: 24;
A29: P1.IC s1
= P1. 0 by MEMSTR_0:def 11
.= SI. 0 by A1,A25,GRFUNC_1: 2;
IC Comput(P1,s1, 0) = 0 by MEMSTR_0:def 11;
hence IC Comput(P1,s1, 0) + n = IC Comput(P2,s2, 0) by A7;
A30: P1/.IC s1 = P1.IC s1 by PBOOLE: 143;
A31: P2/.IC s2 = P2.IC s2 by PBOOLE: 143;
thus CurInstr(P1,Comput(P1,s1, 0))
= Shift(SI,n).( ( 0 qua Nat)+ n) by A25,A29,A30,VALUED_1:def 12
.= Shift(I,n). n by COMPOS_1: 66
.= CurInstr(P2,Comput(P2,s2, 0)) by A6,A7,A28,A31,GRFUNC_1: 2;
thus DataPart Comput(P1,s1, 0) = DataPart Comput(P2,s2, 0) by A8;
end;
for k being Nat holds P[k] from NAT_1:sch 2(A27,A10);
hence thesis;
end;
theorem Th15:
for s being 0-started State of SCMPDS
for I being halt-free Program of SCMPDS st
stop I c= P &
I is_halting_on s,P holds LifeSpan(P,s) > 0
proof
let s be 0-started State of SCMPDS;
let I be halt-free Program of SCMPDS;
set si=Initialize s, Pi = P +* stop I;
assume that
A2: stop I c= P and
A3: I is_halting_on s,P;
A4: Start-At( 0,SCMPDS) c= s by MEMSTR_0: 29;
A5: P = P +* stop I by A2,FUNCT_4: 98;
A6: s=si by A4,FUNCT_4: 98;
assume
LifeSpan(P,s) <= 0;
then
A7: LifeSpan(P,s)= 0;
A8: I c= stop I by AFINSQ_1: 74;
then
A9: dom I c= dom stop I by RELAT_1: 11;
A10: 0 in dom I by AFINSQ_1: 66;
A11: Pi/.IC si = Pi.IC si by PBOOLE: 143;
A12: stop I c= Pi by FUNCT_4: 25;
Pi halts_on si by A3,SCMPDS_6:def 3;
then halt SCMPDS
= CurInstr(Pi,Comput(Pi,si, 0)) by A6,A7,A5,EXTPRO_1:def 15
.= Pi. 0 by A11,MEMSTR_0:def 11
.= (stop I). 0 by A10,A9,A12,GRFUNC_1: 2
.= I. 0 by A10,A8,GRFUNC_1: 2;
hence contradiction by A10,COMPOS_1:def 27;
end;
theorem Th16:
for s1 being 0-started State of SCMPDS
for I being halt-free shiftable Program of SCMPDS st
stop I c= P1 &
I is_closed_on s1,P1 & I is_halting_on s1,P1
for n being
Nat st Shift(I,n) c= P2 & IC s2 = n & DataPart
s1 = DataPart s2 holds IC Comput(P2,s2,LifeSpan(P1,s1)) = card I + n &
DataPart Comput(P1,s1,LifeSpan(P1,s1)) = DataPart
Comput(P2,s2,LifeSpan(P1,s1))
proof
let s1 be 0-started State of SCMPDS;
let I be halt-free shiftable Program of SCMPDS;
assume that
A1: stop I c= P1 and
A2: I is_closed_on s1,P1 and
A3: I is_halting_on s1,P1;
A4: Start-At( 0,SCMPDS) c= s1 by MEMSTR_0: 29;
A5: P1 +* stop I = P1 by A1,FUNCT_4: 98;
let n be Nat;
assume that
A6: Shift(I,n) c= P2 and
A7: IC s2 = n and
A8: DataPart s1 = DataPart s2;
1+( 0 qua Nat) <= LifeSpan(P1,s1) by A1,A3,Th15,INT_1: 7;
then consider i be Nat such that
A9: 1+i=LifeSpan(P1,s1) by NAT_1: 10;
A10: Initialize s1 = s1 by A4,FUNCT_4: 98;
reconsider i as Nat;
A11: i < LifeSpan(P1,s1) by A9,XREAL_1: 29;
then
A12: IC Comput(P1,s1,i) + n = IC Comput(P2,s2,i) by A1,A2,A3,A6,A7,A8,Th14;
set L1=IC Comput(P1,s1,i);
A13: L1 in dom I by A1,A2,A3,A9,Th13,XREAL_1: 29;
set i2=CurInstr(P2,Comput(P2,s2,i));
A14: Comput(P1,s1,i+ 1) = Following(P1,Comput(P1,s1,i)) by EXTPRO_1: 3
.= Exec(i2,Comput(P1,s1,i)) by A1,A2,A3,A6,A7,A8,A11,Th14;
A15: I c= stop I by AFINSQ_1: 74;
then
A16: dom I c= dom stop I by RELAT_1: 11;
A17: Comput(P2,s2,i+ 1) = Following(P2,Comput(P2,s2,i)) by EXTPRO_1: 3
.=Exec(i2,Comput(P2,s2,i));
reconsider m = L1 as Nat;
i2=CurInstr(P1,Comput(P1,s1,i)) by A1,A2,A3,A6,A7,A8,A11,Th14;
then
A18: i2=P1.L1 by PBOOLE: 143
.=(stop I).L1 by A1,A13,A16,GRFUNC_1: 2
.=I.L1 by A13,A15,GRFUNC_1: 2;
then
A19: InsCode i2 <> 1 by A13,SCMPDS_4:def 9;
A20: DataPart Comput(P1,s1,i) = DataPart Comput(P2,s2,i)
by A1,A2,A3,A6,A7,A8,A11,Th14;
A21: i2 valid_at m by A13,A18,SCMPDS_4:def 9;
A22: InsCode i2 <> 3 by A13,A18,SCMPDS_4:def 9;
IC Comput(P1,s1,i+ 1)= card I by A2,A3,A9,A5,A10,SCMPDS_6: 29;
hence IC Comput(P2,s2,LifeSpan(P1,s1)) = card I +
n by A9,A12,A19,A22,A21,A14,A20,A17,SCMPDS_4: 28;
thus thesis by A9,A12,A19,A22,A21,A14,A20,A17,SCMPDS_4: 28;
end;
theorem Th17: ::SCMPDS_5:33
for I being Program of SCMPDS,J being Program of SCMPDS, k being
Nat st I is_closed_on s,P & I is_halting_on s,P &
k <= LifeSpan(P +* stop I,Initialize s)
holds Comput(P +* stop I,Initialize s,k)
= Comput(P+*(I ';' J), Initialize s,k)
proof
let I be Program of SCMPDS,J be Program of SCMPDS,k be Nat;
set spI= stop I;
set s1 = Initialize s, P1 = P +* spI;
set s2 = Initialize s, P2 = P +* (I ';' J);
set n=LifeSpan(P1,s1);
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P;
assume
A3: k <= n;
defpred X[Nat] means $ 1 <= n implies
Comput(P1,s1,$ 1)
= Comput(P2,s2,$ 1);
A4: for m being Nat st X[m] holds X[m+ 1]
proof
let m be Nat;
assume
A5: m <= n implies
Comput(P1,s1,m) = Comput(P2,s2,m);
A6: Comput(P1,s1,m+ 1) = Following(P1,Comput(P1,s1,m)) by EXTPRO_1: 3
.= Exec(CurInstr(P1,Comput(P1,s1,m)),
Comput(P1,s1,m));
A7: IC Comput(P1,s1,m) in dom spI by A1,SCMPDS_6:def 2;
A8: Comput(P2,s2,m+ 1) = Following(P2,Comput(P2,s2,m)) by EXTPRO_1: 3
.= Exec(CurInstr(P2,Comput(P2,s2,m)),
Comput(P2,s2,m));
assume
A9: m+ 1 <= n;
then m < n by NAT_1: 13;
then
A10: IC Comput(P1,s1,m) in dom I by A1,A2,SCMPDS_6: 26;
then
A11: IC Comput(P1,s1,m) in dom (I ';' J) by FUNCT_4: 12;
CurInstr(P1,Comput(P1,s1,m))
= P1.IC Comput(P1,s1,m) by PBOOLE: 143
.= spI.IC Comput(P1,s1,m) by A7,FUNCT_4: 13
.= I.IC Comput(P1,s1,m) by A10,AFINSQ_1:def 3
.= (I ';' J).IC Comput(P1,s1,m) by A10,AFINSQ_1:def 3
.= P2.IC Comput(P1,s1,m) by A11,FUNCT_4: 13
.=CurInstr(P2,Comput(P2,s2,m)) by A5,A9,NAT_1: 13,PBOOLE: 143;
hence thesis by A5,A9,A8,A6,NAT_1: 13;
end;
A12: X[ 0];
for k being Nat holds X[k] from NAT_1:sch 2(A12, A4);
hence thesis by A3;
end;
theorem Th18: ::SCMPDS_5:29
for I,J being Program of SCMPDS,k be Nat st I c= J &
I is_closed_on s,P & I is_halting_on s,P &
k <= LifeSpan(P +* stop I,Initialize s)
holds Comput(P +* J, Initialize s,k)
= Comput(P +* stop I,Initialize s,k)
proof
let I,J be Program of SCMPDS,k be Nat;
set m=LifeSpan(P +* stop I,Initialize s);
assume that
A1: I c= J and
A2: I is_closed_on s,P and
A3: I is_halting_on s,P and
A4: k <= m;
set s1 = Initialize s, s2 = Initialize s,
P1 = P +* J, P2 = P +* stop I;
defpred P[Nat] means $ 1 <= m implies
Comput(P1,s1,$ 1) = Comput(P2,s2,$ 1);
A5: now
let k be Nat;
assume
A6: P[k];
now
A7: Comput(P2,s2,k+ 1) = Following(P2,Comput(P2,s2,k)) by EXTPRO_1: 3
.= Exec(CurInstr(P2,Comput(P2,s2,k)),
Comput(P2,s2,k));
A8: Comput(P1,s1,k+ 1) = Following(P1,Comput(P1,s1,k)) by EXTPRO_1: 3
.= Exec(CurInstr(P1,Comput(P1,s1,k)),
Comput(P1,s1,k));
A9: k < k+ 1 by XREAL_1: 29;
assume
A10: k+ 1 <= m;
then k < m by A9,XXREAL_0: 2;
then
A11: IC Comput(P2,s2,k) in dom I by A2,A3,SCMPDS_6: 26;
then
A12: IC Comput(P2,s2,k) in dom (stop I) by FUNCT_4: 12;
A13: J c= P1 by FUNCT_4: 25;
A14: dom I c= dom J by A1,RELAT_1: 11;
CurInstr(P1,Comput(P1,s1,k))
= P1.IC Comput(P2,s2,k) by A6,A10,A9,PBOOLE: 143,XXREAL_0: 2
.= J.IC Comput(P2,s2,k) by A13,A14,A11,GRFUNC_1: 2
.= I.IC Comput(P2,s2,k) by A1,A11,GRFUNC_1: 2
.= (stop I).IC Comput(P2,s2,k) by A11,AFINSQ_1:def 3
.= P2.IC Comput(P2,s2,k) by A12,FUNCT_4: 13
.= CurInstr(P2,Comput(P2,s2,k)) by PBOOLE: 143;
hence
Comput(P1,s1,k+ 1) = Comput(P2,s2,k+ 1)
by A6,A10,A9,A8,A7,XXREAL_0: 2;
end;
hence P[k+ 1];
end;
A15: P[ 0];
for k be Nat holds P[k] from NAT_1:sch 2(A15,A5);
hence thesis by A4;
end;
theorem Th19:
for I,J being Program of SCMPDS,k be Nat st k <=
LifeSpan(P +* stop I,Initialize s) & I c= J &
I is_closed_on s,P & I is_halting_on s,P
holds IC Comput(P +* J,Initialize s,k) in dom stop I
proof
let I,J be Program of SCMPDS,k be Nat;
set ss = Initialize s, PP = P +* stop I;
set s1= Comput(P +* J, Initialize s,k),
s2= Comput(PP, ss,k);
assume that
A1: k <= LifeSpan(PP,ss) and
A2: I c= J and
A3: I is_closed_on s,P and
A4: I is_halting_on s,P;
s1 = s2 by A1,A2,A3,A4,Th18;
hence thesis by A3,SCMPDS_6:def 2;
end;
theorem Th20: ::SCMPDS_5:31
for I,J being Program of SCMPDS st I c= J & I is_closed_on s,P & I
is_halting_on s,P
holds CurInstr(P +* J,Comput(P +* J, Initialize s,
LifeSpan(P +* stop I,Initialize s))) = halt SCMPDS
or IC Comput(P +* J,Initialize s,
LifeSpan(P +* stop I,Initialize s)) = card I
proof
let I,J be Program of SCMPDS;
set ss = Initialize s, PP = P +* stop I,
m=LifeSpan(PP,ss);
set s0=Initialize s, P0 = P +* J,
s1= Comput(P0, s0,m), s2= Comput(PP, ss,m),
P1 = P0, P2 = PP,
Ik = IC s2;
assume that
A1: I c= J and
A2: I is_closed_on s,P and
A3: I is_halting_on s,P;
A4: dom I c= dom J by A1,GRFUNC_1: 2;
reconsider n = Ik as Nat;
A5: stop I c= P2 by FUNCT_4: 25;
A6: PP halts_on ss by A3,SCMPDS_6:def 3;
A7: Ik in dom stop(I) by A2,SCMPDS_6:def 2;
card stop I = card I + 1 by COMPOS_1: 55;
then n < card I + 1 by A7,AFINSQ_1: 66;
then
A8: n <= card I by INT_1: 7;
A9: IC s1 = Ik by A1,A2,A3,Th18;
now
per cases by A8,XXREAL_0: 1;
case
n < card I;
then
A10: n in dom I by AFINSQ_1: 66;
thus halt SCMPDS = CurInstr(P2,s2) by A6,EXTPRO_1:def 15
.= PP.Ik by PBOOLE: 143
.= (stop I).Ik by A7,A5,GRFUNC_1: 2
.= I.Ik by A10,AFINSQ_1:def 3
.= J.Ik by A1,A10,GRFUNC_1: 2
.= P0.IC s1 by A4,A9,A10,FUNCT_4: 13
.=CurInstr(P1,s1) by PBOOLE: 143;
end;
case
n = card I;
hence IC s1= card I by A1,A2,A3,Th18;
end;
end;
hence thesis;
end;
theorem Th21:
for I,J being Program of SCMPDS st I is_halting_on s,P & J
is_closed_on IExec(I,P,Initialize s),P &
J is_halting_on IExec(I,P,Initialize s),P
holds J is_closed_on Comput(P +* stop I, Initialize s,
LifeSpan(P +* stop I,Initialize s)), P +* stop I & J
is_halting_on Comput(P +* stop I,
Initialize s,
LifeSpan(P +* stop I,Initialize s)), P +* stop I
proof
let I,J be Program of SCMPDS;
set s1= Initialize s, P1 = P +* stop I,
sm = Comput(P1,s1,LifeSpan(
P1,s1)),
sE = IExec(I,P,Initialize s);
assume that
A1: I is_halting_on s,P and
A2: J is_closed_on sE,P and
A3: J is_halting_on sE,P;
A4: P1 halts_on s1 by A1,SCMPDS_6:def 3;
DataPart sE = DataPart sm by A4,EXTPRO_1: 23;
hence thesis by A2,A3,SCMPDS_6: 23;
end;
theorem Th22:
for I being Program of SCMPDS,J being shiftable Program of
SCMPDS st I is_closed_on s,P & I is_halting_on s,P
& J is_closed_on IExec(I,P,Initialize s),P
& J is_halting_on IExec(I,P,Initialize s),P
holds I ';'J is_closed_on s,P & I ';' J is_halting_on s,P
proof
let I be Program of SCMPDS,J be shiftable Program of SCMPDS;
set sE=IExec(I,P,Initialize s);
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P and
A3: J is_closed_on sE,P and
A4: J is_halting_on sE, P;
set IJ =I ';' J, sIJ = stop IJ, spI = stop I,
ss=Initialize s, PP = P +* stop IJ;
set spJ = stop J,
s1 = Initialize s, P1 = P +* stop I,
m1 = LifeSpan(P1,s1), sm
= Comput(P1, s1,m1), s3 = Initialize sm,
P3 = P1 +* spJ,
m3 = LifeSpan(P3,s3);
J is_halting_on sm,P1 by A2,A3,A4,Th21;
then
A5: P3 halts_on s3 by SCMPDS_6:def 3;
A6: J is_closed_on sm,P1 by A2,A3,A4,Th21;
then
A7: J is_closed_on s3,P3 by SCMPDS_6: 24;
set s4 = Comput(PP, ss,m1), P4 = PP;
A8: spJ c= P3 by FUNCT_4: 25;
A9: DataPart sm = DataPart s3 by MEMSTR_0: 45;
A10: (I ';' (J ';' Stop SCMPDS)) = stop IJ by AFINSQ_1: 27;
A11: sm = s4 by A1,A2,Th17,A10;
sIJ = I ';' (J ';' Stop SCMPDS) by AFINSQ_1: 27
.= I +* Shift(spJ, card I);
then
A12: Shift(spJ, card I) c= sIJ by FUNCT_4: 25;
sIJ c= PP by FUNCT_4: 25;
then
A13: Shift(spJ, card I) c= P4 by A12,XBOOLE_1: 1;
A14: dom stop I c= dom sIJ by SCMPDS_5: 13;
now
let k be Nat;
per cases;
suppose
k <= m1;
then IC Comput(PP, ss,k) in dom stop I by A1,A2,Th4,Th19;
hence IC Comput(PP, ss,k) in dom sIJ by A14;
end;
suppose
A15: k > m1;
A16: IC s4 in dom spI by A1,A2,Th4,Th19;
hereby
per cases by A1,A2,Th4,Th20;
suppose
A17: IC s4 = card I;
consider ii be Nat such that
A18: k=m1+ii by A15,NAT_1: 10;
reconsider ii as Nat;
reconsider nn = IC Comput(P3, s3,ii) as Nat;
IC Comput(P3, s3,ii) + card I = IC Comput(P4, s4,ii)
by A8,A11,A9,A7,A13,A17,SCMPDS_6: 31;
then
A19: IC Comput(P4, ss,k)= nn+card I by A18,EXTPRO_1: 4;
nn in dom spJ by A6,SCMPDS_6:def 2;
then nn < card spJ by AFINSQ_1: 66;
then nn < card J+ 1 by COMPOS_1: 55;
then
A20: card I +nn < card I +(card J+ 1) by XREAL_1: 6;
card sIJ=card IJ+ 1 by COMPOS_1: 55
.=card I + card J+ 1 by AFINSQ_1: 17;
hence IC Comput(PP, ss,k) in dom sIJ by A20,A19,AFINSQ_1: 66;
end;
suppose
CurInstr(P4,s4) = halt SCMPDS;
then IC Comput(PP, ss,k)=IC s4 by A15,EXTPRO_1: 5;
hence IC Comput(PP, ss,k) in dom sIJ by A14,A16;
end;
end;
end;
end;
hence (I ';'J) is_closed_on s,P by SCMPDS_6:def 2;
A21: Comput(PP,ss,m1+m3)
= Comput(PP,Comput(PP,ss,m1),m3) by EXTPRO_1: 4;
per cases by A1,A2,Th4,Th20;
suppose
CurInstr(P4,s4) = halt SCMPDS;
then PP halts_on ss by EXTPRO_1: 29;
hence thesis by SCMPDS_6:def 3;
end;
suppose
IC s4 = card I;
then
CurInstr(PP,Comput(PP,ss,m1+m3)) =
CurInstr(P3,Comput(P3,s3,m3)) by A21,A8,A11,A9,A7,A13,SCMPDS_6: 31
.= halt SCMPDS by A5,EXTPRO_1:def 15;
then PP halts_on ss by EXTPRO_1: 29;
hence thesis by SCMPDS_6:def 3;
end;
end;
theorem Th23: :: SCMPDS_5:30
for I be halt-free Program of SCMPDS,J be Program of SCMPDS st
I c= J & I is_closed_on s,P & I is_halting_on s,P
holds IC Comput(P+*J, Initialize s,
LifeSpan(P +* stop I,Initialize s)) = card I
proof
let I be halt-free Program of SCMPDS,J be Program of SCMPDS;
set s1 = Initialize s, P1 = P +* J,
ss = Initialize s,
PP = P +* stop I,
m=LifeSpan(PP,ss);
assume that
A1: I c= J and
A2: I is_closed_on s,P and
A3: I is_halting_on s,P;
thus IC Comput(P1, s1,m) =IC Comput(PP, ss,LifeSpan(PP,ss)) by A1,A2,A3,Th18
.= card I by A2,A3,SCMPDS_6: 29;
end;
theorem ::SCMPDS_6:42
for I being Program of SCMPDS,s being State of SCMPDS, k being Nat
st I is_halting_on s,P
& k < LifeSpan(P+*stop I,Initialize s) holds
CurInstr(P+*stop I,Comput(P +* stop I,Initialize s,k)) <> halt SCMPDS
proof
let I be Program of SCMPDS,s be State of SCMPDS,k be Nat;
set ss=Initialize s, PP = P +* stop I,
m=LifeSpan(PP,ss);
assume that
A1: I is_halting_on s,P and
A2: k < m;
assume
A3: CurInstr(PP,Comput(PP,ss,k))=halt SCMPDS;
PP halts_on ss by A1,SCMPDS_6:def 3;
hence thesis by A2,A3,EXTPRO_1:def 15;
end;
theorem Th25: ::SCMPDS_6:42
for I,J being Program of SCMPDS,s being 0-started State of SCMPDS, k being
Nat st I is_closed_on s,P & I is_halting_on s,P
& k < LifeSpan(P +* stop I,s) holds
CurInstr(P+*stop(I ';' J),Comput(P+*stop(I ';' J),s,k))
<> halt SCMPDS
proof
let I,J be Program of SCMPDS,
s be 0-started State of SCMPDS,k be Nat;
set P1 = P +* stop I, P2 = P +* stop (I ';' J),
m= LifeSpan(P1,s), s3=Comput(P2,s,k), P3 = P2;
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P and
A3: k < m;
assume CurInstr(P3,s3) = halt SCMPDS;
then
A4: CurInstr(P1,Comput(P1,s,k)) = halt SCMPDS by A1,A2,A3,SCMPDS_6: 27;
Initialize s = s by MEMSTR_0: 44;
then P1 halts_on s by A2,SCMPDS_6:def 3;
hence thesis by A3,A4,EXTPRO_1:def 15;
end;
Lm1: for I being halt-free Program of SCMPDS,J being shiftable Program of
SCMPDS,s being 0-started State of SCMPDS st I is_closed_on s,P
& I is_halting_on s,P &
J is_closed_on IExec(I,P,s),P &
J is_halting_on IExec(I,P,s),P &
P2=P +* stop (I ';' J) & P1=P +* stop I
holds IC Comput(P2,s,LifeSpan(P1,s)) = card I &
DataPart Comput(P2,s,LifeSpan(P1,s))
= DataPart(Initialize Comput(P1,s,LifeSpan(P1,s))) &
Shift(stop J,card I) c= P2 &
LifeSpan(P2,s)
= LifeSpan(P1,s) + LifeSpan(P1 +* stop J,Initialize Result(P1,s))
proof
let I be halt-free Program of SCMPDS,J be shiftable Program of SCMPDS,
s be 0-started State of SCMPDS;
set spJ = stop J,
IJ = I ';' J, sIJ = stop IJ,
m1 = LifeSpan(P1,s), sm =
Comput(P1, s,m1), s3 = Initialize sm, P3 = P1 +* spJ;
set m3 = LifeSpan(P3,s3), sE = IExec(I,P,s);
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P and
A3: J is_closed_on sE,P and
A4: J is_halting_on sE,P and
A5: P2=P +* stop (I ';' J) and
A6: P1=P +* stop I;
set s4 = Comput(P2, s,m1), P4 = P2;
A7: Initialize s = s by MEMSTR_0: 44;
hence
A8: IC s4 = card I by A1,A2,Th4,Th23,A5,A6;
A9: spJ c= P3 by FUNCT_4: 25;
A10: DataPart Comput(P1,s,m1) = DataPart s3 by MEMSTR_0: 45;
(I ';' (J ';' Stop SCMPDS)) = stop IJ by AFINSQ_1: 27;
hence
A11: DataPart s4 = DataPart s3 by A10,A1,A2,Th17,A6,A7,A5;
reconsider m = m1 + m3 as Nat;
sIJ = I ';' (J ';' Stop SCMPDS) by AFINSQ_1: 27
.= I +* Shift(spJ, card I);
then
A12: Shift(spJ, card I) c= sIJ by FUNCT_4: 25;
sIJ c= P2 by A5,FUNCT_4: 25;
hence
A13: Shift(spJ, card I) c= P4 by A12,XBOOLE_1: 1;
J is_halting_on sm,P1 by A2,A3,A4,Th21,A6,A7;
then
A14: P3 halts_on s3 by SCMPDS_6:def 3;
A15: Comput(P2,s,m1+m3) = Comput(P2,Comput(P2,s,m1),m3) by EXTPRO_1: 4;
J is_closed_on sm, P1 by A2,A3,A4,Th21,A6,A7;
then
A16: J is_closed_on s3,P3 by SCMPDS_6: 24;
then CurInstr(P3,Comput(P3,s3,m3)) = CurInstr(P2,Comput(P2,s,m1+m3))
by A15,A9,A8,A11,A13,SCMPDS_6: 31;
then
A17: CurInstr(P2,Comput(P2,s,m))
= halt SCMPDS by A14,EXTPRO_1:def 15;
A18: now
let k be Nat;
assume
m1 + k < m;
then
A19: k < m3 by XREAL_1: 6;
assume
A20: CurInstr(P2,Comput(P2,s,m1+k))
= halt SCMPDS;
CurInstr(P3,Comput(P3,s3,k)) = CurInstr(P4,Comput(P4,s4,k))
by A9,A16,A8,A11,A13,SCMPDS_6: 31
.= halt SCMPDS by A20,EXTPRO_1: 4;
hence contradiction by A14,A19,EXTPRO_1:def 15;
end;
now
let k be Nat;
assume
A21: k < m;
per cases;
suppose
k < m1;
hence CurInstr(P2,Comput(P2,s,k)) <> halt SCMPDS by A1,A2,Th25,A5,A6;
end;
suppose
m1 <= k;
then consider kk being Nat such that
A22: m1 + kk = k by NAT_1: 10;
reconsider kk as Nat;
m1+kk=k by A22;
hence CurInstr(P2,Comput(P2,s,k)) <>
halt SCMPDS by A18,A21;
end;
end;
then
A23: for k being Nat st
CurInstr(P2,Comput(P2,s,k)) = halt SCMPDS
holds m <= k;
A24: P1 halts_on s by A2,A6,A7,SCMPDS_6:def 3;
A25: Result(P1,s) =
Comput(P1,s,LifeSpan(P1,s)) by A24,EXTPRO_1: 23;
IJ is_halting_on s,P by A1,A2,A3,A4,Th22,A7;
then P2 halts_on s by A5,A7,SCMPDS_6:def 3;
hence thesis by A25,A17,A23,EXTPRO_1:def 15;
end;
theorem ::SCMPDS_5:37
for s being 0-started State of SCMPDS
for I being halt-free Program of SCMPDS,J being shiftable Program of
SCMPDS st I is_closed_on s,P & I is_halting_on s,P
& J is_closed_on IExec(I,P,s),P & J
is_halting_on IExec(I,P,s),P
holds LifeSpan(P+*stop(I ';' J),s) =
LifeSpan(P +* stop I,s) +
LifeSpan(P +* stop I +* stop J,
Initialize Result(P +* stop I,s)) by Lm1;
theorem Th27: :: SCMPDS_5:38
for s being 0-started State of SCMPDS
for I being halt-free Program of SCMPDS, J being shiftable
Program of SCMPDS st I is_closed_on s,P & I is_halting_on s,P
& J is_closed_on IExec(I,P,s),P & J is_halting_on IExec(I,P,s),P
holds IExec(I ';' J,P,s)
= IncIC(IExec(J,P,Initialize IExec(I,P,s)), card I)
proof
let s be 0-started State of SCMPDS;
let I be halt-free Program of SCMPDS,J be shiftable Program of SCMPDS;
set
IJ = I ';' J, s1 = s, P1 = P +* stop I,
m1 = LifeSpan(P1,s1), P2 = P +* stop IJ,
s3 = Initialize Comput(P1,s1,m1), P3 = P1 +* stop J,
m3 = LifeSpan(P3,s3), sE = IExec(I,P,s);
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P and
A3: J is_closed_on sE,P and
A4: J is_halting_on sE,P;
A5: Initialize s = s by MEMSTR_0: 44;
A6: DataPart Comput(P2,s,m1) = DataPart(Initialize Comput(P1,s1,m1))
by A1,A2,A3,A4,Lm1;
J is_closed_on Comput(P1,s1,m1),P1 by A2,A3,A4,Th21,A5;
then
A7: J is_closed_on s3,P3 by SCMPDS_6: 24;
A8: stop J c= P3 by FUNCT_4: 25;
A9: Shift(stop J,card I) c= P2 by A1,A2,A3,A4,Lm1;
A10: IC Comput(P2,s,m1) = card I by A1,A2,A3,A4,Lm1;
then
A11: IC Comput(P2, Comput(P2,s,m1),m3) = IC Comput(P3,s3,m3) + card I
by A8,A6,A9,A7,SCMPDS_6: 31;
A12: DataPart Comput(P2, Comput(
P2,s,m1),m3) = DataPart Comput(P3,s3,m3)
by A8,A10,A6,A9,A7,SCMPDS_6: 31;
set R1=Initialize IExec(I,P,s),
R2=Initialize Result(P1,s1);
A13: stop J c= P+*stop J by FUNCT_4: 25;
A14: stop J c= P1+*stop J by FUNCT_4: 25;
A15: P1 halts_on s1 by A2,A5,SCMPDS_6:def 3;
then
A16: s3 = Initialize Result(P1,s1) by EXTPRO_1: 23;
A17: DataPart sE = DataPart Initialize sE by MEMSTR_0: 45;
then
A18: J is_closed_on Initialize sE, P +* stop J by A3,A4,SCMPDS_6: 23;
A19: J is_halting_on Initialize sE, P +* stop J
by A3,A4,A17,SCMPDS_6: 23;
IJ is_halting_on s,P by A1,A2,A3,A4,Th22,A5;
then
A20: P2 halts_on s by A5,SCMPDS_6:def 3;
J is_halting_on Comput(P1,s1,m1), P1 by A2,A3,A4,Th21,A5;
then
A21: P3 halts_on s3 by SCMPDS_6:def 3;
A22: IExec(I,P,s) = Comput(P1,s1,m1) by A15,EXTPRO_1: 23;
Result(P +* stop J,Initialize IExec(I,P,s))
= Result(P3,s3) by A13,A14,A18,A19,Th8,A22;
then
A23: IExec(J,P,Initialize IExec(I,P,s)) = Comput(P3,s3,m3)
by A21,EXTPRO_1: 23;
A24: IC IExec(I ';' J,P,s)
= IC Comput(P2,s,LifeSpan(P2,s)) by A20,EXTPRO_1: 23
.= IC Comput(P2,s,m1+m3) by A1,A2,A3,A4,A16,Lm1
.= IC Comput(P3,s3,m3) + card I by A11,EXTPRO_1: 4
.= IC Result(P3,s3) + card I by A21,EXTPRO_1: 23
.= IC Result(P1 +* stop J, Initialize Result(P1,s1)) + card I
by A15,EXTPRO_1: 23
.= IC IExec(J,P,Initialize IExec(I,P,s)) + card I by A13,A14,A18,A19,Th8;
IExec(I ';' J,P,s) = Comput(P2,s,LifeSpan(P2,s))
by A20,EXTPRO_1: 23
.= Comput(P2,s,m1+m3) by A1,A2,A3,A4,A16,Lm1;
then
A25: DataPart IExec(I ';' J,P,s)
= DataPart IExec(J,P,Initialize IExec(I,P,s)) by A23,A12,EXTPRO_1: 4;
hereby
reconsider l = IC IExec(J,P,Initialize IExec(I,P,s)) +
card I as Nat;
A26: dom Start-At(l,SCMPDS) = {IC SCMPDS} by FUNCOP_1: 13;
A27: now
let x be object;
assume
A28: x in dom IExec(I ';' J,P,s);
per cases by A28,SCMPDS_4: 6;
suppose
A29: x is Int_position;
then x <> IC SCMPDS by SCMPDS_2: 43;
then
A30: not x in dom Start-At(l,SCMPDS) by A26,TARSKI:def 1;
IExec(I ';' J,P,s).x
= IExec(J,P,Initialize IExec(I,P,s)).x by A25,A29,SCMPDS_4: 8;
hence
IExec(I ';' J,P,s).x
= (IncIC(IExec(J,P,Initialize IExec(I,P,s)),card I)).x
by A30,FUNCT_4: 11;
end;
suppose
A31: x = IC SCMPDS;
then x in {IC SCMPDS} by TARSKI:def 1;
then
A32: x in dom Start-At(l,SCMPDS) by FUNCOP_1: 13;
thus IExec(I ';' J,P,s).x = (Start-At(l,SCMPDS)).IC SCMPDS
by A24,A31,FUNCOP_1: 72
.= (IncIC(IExec(J,P,Initialize IExec(I,P,s)),card I)).x
by A31,A32,FUNCT_4: 13;
end;
end;
dom IExec(I ';' J,P,s) = the carrier of SCMPDS by PARTFUN1:def 2
.= dom IncIC(IExec(J,P,Initialize IExec(I,P,s)),card I)
by PARTFUN1:def 2;
hence thesis by A27,FUNCT_1: 2;
end;
end;
theorem Th28: ::SCMPDS_5:39
for s being 0-started State of SCMPDS
for I being halt-free Program of SCMPDS, J being shiftable
Program of SCMPDS st I is_closed_on s,P & I is_halting_on s,P
& J is_closed_on
IExec(I,P,s),P & J is_halting_on IExec(I,P,s),P
holds IExec(I ';' J,P,s).a
= IExec(J,P,Initialize IExec(I,P,s)).a
proof
let s be 0-started State of SCMPDS;
let I be halt-free Program of SCMPDS,J be shiftable Program of SCMPDS;
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P and
A3: J is_closed_on IExec(I,P,s),P and
A4: J is_halting_on IExec(I,P,s),P;
A5: not a in dom Start-At (IC IExec(J,P,Initialize IExec(I,P,s))
+ card I,SCMPDS) by SCMPDS_4: 18;
IExec(I ';' J,P,s)
= IncIC(IExec(J,P,Initialize IExec(I,P,s)),card I)
by A1,A2,A3,A4,Th27;
hence thesis by A5,FUNCT_4: 11;
end;
theorem Th29: ::SCMPDS_5:46
for s being 0-started State of SCMPDS
for I being halt-free Program of SCMPDS,j being parahalting
shiftable Instruction of SCMPDS st I is_closed_on s,P & I is_halting_on s,P
holds
IExec(I ';' j,P,s).a = Exec(j, IExec(I,P,s)).a
proof
let s be 0-started State of SCMPDS;
let I be halt-free Program of SCMPDS,j be parahalting shiftable
Instruction of SCMPDS;
assume that
A1: I is_closed_on s,P and
A2: I is_halting_on s,P;
set Mj = Load j;
A3: a in SCM-Data-Loc by AMI_2:def 16;
for a holds (Initialize IExec(I,P,s)).a
=IExec(I,P,s).a by SCMPDS_5: 15;
then
A4: DataPart Initialize IExec(I,P,s)
= DataPart IExec(I,P,s) by SCMPDS_4: 8;
A5: Mj is_halting_on IExec(I,P,s),P by SCMPDS_6: 21;
Mj is_closed_on IExec(I,P,s),P by SCMPDS_6: 20;
hence IExec(I ';' j,P,s).a = IExec(Mj,P,Initialize IExec(I,P,s)).a
by A1,A2,A5,Th28
.= Exec(j, Initialize IExec(I,P,s)).a by SCMPDS_5: 40
.= (DataPart Exec(j, Initialize IExec(I,P,s))).a
by A3,FUNCT_1: 49,SCMPDS_2: 84
.= (DataPart Exec(j, IExec(I,P,s))).a by A4,SCMPDS_5: 39
.= Exec(j, IExec(I,P,s)).a by A3,FUNCT_1: 49,SCMPDS_2: 84;
end;
begin :: The construction of for-up loop program
:: while (a,i)<=0 do { I, (a,i)+=n }
definition
let a be Int_position, i be Integer,n be Nat;
let I be Program of SCMPDS;
func for-up(a,i,n,I) -> Program of SCMPDS equals
(a,i)>= 0_goto (card I + 3)
';' I ';' AddTo(a,i,n) ';' goto -(card I+ 2);
coherence;
end;
begin :: The computation of for-up loop program
theorem Th30:
for a be Int_position,i be Integer,n be Nat,I be
Program of SCMPDS holds card for-up(a,i,n,I)= card I + 3
proof
let a be Int_position,i be Integer,n be Nat, I be Program of
SCMPDS;
set i1=(a,i)>= 0_goto (card I + 3), i2=AddTo(a,i,n);
set I4=i1 ';' I, I5=I4 ';' i2;
card I4=card I+ 1 by SCMPDS_6: 6;
then card I5=card I + 1 + 1 by SCMP_GCD: 4
.=card I+ ( 1+ 1);
hence card for-up(a,i,n,I)=card I + 2 + 1 by SCMP_GCD: 4
.=card I + 3;
end;
Lm2: for a be Int_position,i be Integer,n be Nat, I be Program of
SCMPDS holds card stop for-up(a,i,n,I)= card I+ 4
proof
let a be Int_position,i be Integer,n be Nat, I be Program of
SCMPDS;
thus card stop for-up(a,i,n,I)= card for-up(a,i,n,I) + 1 by COMPOS_1: 55
.= card I + 3+ 1 by Th30
.= card I + 4;
end;
theorem Th31:
for a be Int_position,i be Integer,n,m be Nat, I be
Program of SCMPDS holds m < card I+ 3 iff m in dom for-up(a,i,n,I)
proof
let a be Int_position,i be Integer,n,m be Nat, I be Program of
SCMPDS;
card for-up(a,i,n,I)=card I + 3 by Th30;
hence thesis by AFINSQ_1: 66;
end;
theorem Th32:
for a be Int_position,i be Integer,n be Nat, I be
Program of SCMPDS holds for-up(a,i,n,I). 0=(a,i)>= 0_goto (card I + 3) &
for-up(a,i,n,I). (card I+ 1)=AddTo(a,i,n) & for-up(a,i,n,I). (card I
+ 2)=goto -(card I+ 2)
proof
let a be Int_position,i be Integer,n be Nat, I be Program of
SCMPDS;
set i1=(a,i)>= 0_goto (card I + 3), i2=AddTo(a,i,n), i3=goto -(card I+ 2);
set I4=i1 ';' I, I5=I4 ';' i2;
set J6=i2 ';' i3, J5=I ';' J6;
set FLOOP= for-up(a,i,n,I);
FLOOP=I4 ';' J6 by SCMPDS_4: 13;
then FLOOP=i1 ';' J5 by SCMPDS_4: 14;
hence FLOOP. 0=i1 by SCMPDS_6: 7;
A1: card I4=card I+ 1 by SCMPDS_6: 6;
hence FLOOP.(card I+ 1)=i2 by SCMP_GCD: 7;
card I5=card I + 1 + 1 by A1,SCMP_GCD: 4
.=card I+ ( 1+ 1);
hence thesis by SCMP_GCD: 6;
end;
theorem Th33:
for s being State of SCMPDS,I being Program of SCMPDS,a being
Int_position, i being Integer,n be Nat st s.DataLoc(s.a,i) >= 0
holds for-up(a,i,n,I) is_closed_on s,P & for-up(a,i,n,I) is_halting_on s,P
proof
let s be State of SCMPDS,I be Program of SCMPDS,a be Int_position, i be
Integer,n be Nat;
set d1=DataLoc(s.a,i);
assume
A1: s.d1 >= 0;
set i1=(a,i)>= 0_goto (card I+ 3), i2=AddTo(a,i,n), i3=goto -(card I+ 2);
set FOR= for-up(a,i,n,I), pFOR=stop FOR, s3 = Initialize s,
P3 = P +* pFOR,
s4 = Comput(P3,s3, 1), P4 = P3;
A2: IC s3 = 0 by MEMSTR_0:def 11;
A3: not d1 in dom Start-At( 0,SCMPDS) by SCMPDS_4: 18;
not a in dom Start-At( 0,SCMPDS) by SCMPDS_4: 18;
then
A4: s3.DataLoc(s3.a,i)=s3.d1 by FUNCT_4: 11
.= s.d1 by A3,FUNCT_4: 11;
A5: FOR = i1 ';' (I ';' i2 ';' i3) by Th2;
Comput(P3, s3,( 0 qua Nat)+ 1) = Following(P3,
Comput(P3,s3, 0)) by EXTPRO_1: 3
.= Exec(i1,s3) by A5,SCMPDS_6: 11;
then
A6: IC s4 = ICplusConst(s3,(card I+ 3)) by A1,A4,SCMPDS_2: 57
.= (( 0 qua Nat)+(card I+ 3)) by A2,SCMPDS_6: 12;
A7: card FOR=card I+ 3 by Th30;
then
A8: (card I+ 3) in dom pFOR by COMPOS_1: 64;
pFOR c= P4 by FUNCT_4: 25;
then P4.(card I+ 3) = pFOR.(card I+ 3) by A8,GRFUNC_1: 2
.=halt SCMPDS by A7,COMPOS_1: 64;
then
A9: CurInstr(P4,s4) = halt SCMPDS by A6,PBOOLE: 143;
now
let k be Nat;
per cases;
suppose
0 < k;
then 1+( 0 qua Nat) <= k by INT_1: 7;
hence IC Comput(P3,s3,k) in dom pFOR
by A8,A6,A9,EXTPRO_1: 5;
end;
suppose
k = 0;
then Comput(P3,s3,k) = s3;
hence IC Comput(P3,s3,k) in dom pFOR by A2,COMPOS_1: 36;
end;
end;
hence FOR is_closed_on s,P by SCMPDS_6:def 2;
P3 halts_on s3 by A9,EXTPRO_1: 29;
hence thesis by SCMPDS_6:def 3;
end;
theorem Th34:
for s being State of SCMPDS,I being Program of SCMPDS,a,c being
Int_position, i being Integer,n be Nat st s.DataLoc(s.a,i) >= 0
holds IExec( for-up(a,i,n,I),P,Initialize s)
= s +* Start-At((card I+ 3),SCMPDS)
proof
let s be State of SCMPDS,I be Program of SCMPDS, a,c be Int_position, i be
Integer,n be Nat;
set d1=DataLoc(s.a,i);
set FOR= for-up(a,i,n,I), pFOR=stop FOR,
s3 = Initialize s, P3 = P +* pFOR,
s4 = Comput(P3, s3, 1), P4 = P3,
i1=(a,i)>= 0_goto (card I+ 3), i2=
AddTo(a,i,n), i3
=goto -(card I+ 2);
set SAl=Start-At((card I+ 3),SCMPDS);
A1: IC s3 = 0 by MEMSTR_0:def 11;
A2: not d1 in dom Start-At( 0,SCMPDS) by SCMPDS_4: 18;
A3: pFOR c= P4 by FUNCT_4: 25;
not a in dom Start-At( 0,SCMPDS) by SCMPDS_4: 18;
then
A4: s3.DataLoc(s3.a,i)=s3.d1 by FUNCT_4: 11
.= s.d1 by A2,FUNCT_4: 11;
A5: FOR = i1 ';' (I ';' i2 ';' i3) by Th2;
A6: Comput(P3, s3,( 0 qua Nat)+ 1) = Following(P3,
Comput(P3,s3, 0)) by EXTPRO_1: 3
.= Exec(i1,s3) by A5,SCMPDS_6: 11;
assume
s.d1 >= 0;
then
A7: IC s4 = ICplusConst(s3,(card I+ 3)) by A6,A4,SCMPDS_2: 57
.= (( 0 qua Nat)+(card I+ 3)) by A1,SCMPDS_6: 12;
A8: card FOR=card I+ 3 by Th30;
then (card I+ 3) in dom pFOR by COMPOS_1: 64;
then P4.(card I+ 3) = pFOR.(card I+ 3) by A3,GRFUNC_1: 2
.=halt SCMPDS by A8,COMPOS_1: 64;
then
A9: CurInstr(P4,s4) = halt SCMPDS by A7,PBOOLE: 143;
then
A10: P3 halts_on s3 by EXTPRO_1: 29;
A11: CurInstr(P3,s3) = i1 by A5,SCMPDS_6: 11;
now
let l be Nat;
assume l < ( 0 qua Nat)+ 1;
then l= 0 by NAT_1: 13;
hence CurInstr(P3,Comput(P3,s3,l)) <> halt SCMPDS by A11;
end;
then for l be Nat st
CurInstr(P3,Comput(P3,s3,l)) = halt SCMPDS
holds 1 <= l;
then
A12: LifeSpan(P3,s3) = 1 by A9,A10,EXTPRO_1:def 15;
A13: now
let x be object;
A14: dom SAl = {IC SCMPDS} by FUNCOP_1: 13;
assume
A15: x in dom IExec( FOR,P,Initialize s);
per cases by A15,SCMPDS_4: 6;
suppose
A16: x is Int_position;
then x <> IC SCMPDS by SCMPDS_2: 43;
then
A17: not x in dom SAl by A14,TARSKI:def 1;
A18: not x in dom Start-At( 0,SCMPDS) by A16,SCMPDS_4: 18;
thus IExec( FOR,P,Initialize s).x = s4.x by A12,A10,EXTPRO_1: 23
.= s3.x by A6,A16,SCMPDS_2: 57
.= s.x by A18,FUNCT_4: 11
.= (s +* SAl).x by A17,FUNCT_4: 11;
end;
suppose
A19: x = IC SCMPDS;
thus IExec( FOR,P,Initialize s).x = card I + 3
by A7,A12,A19,A10,EXTPRO_1: 23
.= (s +* SAl).x by A19,FUNCT_4: 113;
end;
end;
dom IExec( FOR,P,Initialize s) = the carrier of SCMPDS by PARTFUN1:def 2
.= dom (s +* SAl) by PARTFUN1:def 2;
hence thesis by A13,FUNCT_1: 2;
end;
theorem
for s being State of SCMPDS,I being Program of SCMPDS,a being
Int_position, i being Integer,n be Nat st s.DataLoc(s.a,i) >= 0
holds IC IExec( for-up(a,i,n,I),P,Initialize s) = card I + 3
proof
let s be State of SCMPDS,I be Program of SCMPDS,a be Int_position, i be
Integer,n be Nat;
assume
s.DataLoc(s.a,i) >= 0;
then IExec( for-up(a,i,n,I),P,Initialize s) =s +* Start-At((card I+ 3),SCMPDS)
by Th34;
hence thesis by FUNCT_4: 113;
end;
theorem
for s being State of SCMPDS,I being Program of SCMPDS,a,b being
Int_position, i being Integer,n be Nat st s.DataLoc(s.a,i) >= 0
holds IExec( for-up(a,i,n,I),P,Initialize s).b = s.b
proof
let s be State of SCMPDS,I be Program of SCMPDS,a,b be Int_position, i be
Integer,n be Nat;
assume
s.DataLoc(s.a,i) >= 0;
then
A1: IExec( for-up(a,i,n,I),P,Initialize s) = s +* Start-At((card I+ 3),SCMPDS)
by Th34;
not b in dom Start-At((card I+ 3),SCMPDS) by SCMPDS_4: 18;
hence thesis by A1,FUNCT_4: 11;
end;
Lm3: for I being Program of SCMPDS,a being Int_position,i being Integer, n be
Nat holds Shift(I, 1) c= for-up(a,i,n,I)
proof
let I be Program of SCMPDS,a be Int_position,i be Integer, n be Nat;
set i1=(a,i)>= 0_goto (card I+ 3), i2=AddTo(a,i,n), i3=goto -(card I+ 2);
A1: for-up(a,i,n,I) = Load i1 ';' I ';' (i2 ';' i3) by SCMPDS_4: 13;
card Load i1= 1 by COMPOS_1: 54;
hence thesis by A1,Th3;
end;
theorem Th37:
for s being State of SCMPDS,I being halt-free shiftable
Program of SCMPDS, a be Int_position, i be Integer,n be Nat,X be set
st s.DataLoc(s.a,i) < 0 & not DataLoc(s.a,i) in X & n > 0 &
a <> DataLoc(s.a,i) &
( for t be State of SCMPDS,Q st ( for x be Int_position st x in X
holds t.x=s.x) & t.a=s.a holds IExec(I,Q,Initialize t).a=t.a &
IExec(I,Q,Initialize t).DataLoc(s.a,i)=t.DataLoc(s.a,i) &
I is_closed_on t,Q & I is_halting_on t,Q &
for y be Int_position
st y in X holds IExec(I,Q,Initialize t).y=t.y)
holds for-up(a,i,n,I) is_closed_on s,P
& for-up(a,i,n,I) is_halting_on s,P
proof
let s be State of SCMPDS,I be halt-free shiftable Program of SCMPDS, a be
Int_position, i be Integer,n be Nat,X be set;
set b=DataLoc(s.a,i);
set FOR= for-up(a,i,n,I), pFOR=stop FOR,
pI=stop I;
set i1=(a,i)>= 0_goto (card I+ 3), i2=AddTo(a,i,n), i3=goto -(card I+ 2);
assume
A1: s.b < 0;
defpred P[Nat] means
for t be State of SCMPDS,Q st -t.b <= $ 1 & (
for x be Int_position st x in X holds t.x=s.x) & t.a=s.a
holds FOR is_closed_on t,Q & FOR is_halting_on t,Q;
assume
A2: not b in X;
assume
A3: n > 0;
assume
A4: a <> b;
assume
A5: for t be State of SCMPDS,Q st ( for x be Int_position st x in X holds t
.x=s.x) & t.a=s.a holds IExec(I,Q,Initialize t).a=t.a &
IExec(I,Q,Initialize t).b=t.b
& I is_closed_on t,Q
& I is_halting_on t,Q & for y be Int_position st y in X
holds IExec(I,Q,Initialize t).y=t.y;
A6: for k be Nat st P[k] holds P[k + 1]
proof
let k be Nat;
assume
A7: P[k];
let t be State of SCMPDS,Q;
assume
A8: -t.b <= k+ 1;
assume
A9: for x be Int_position st x in X holds t.x=s.x;
assume
A10: t.a=s.a;
per cases;
suppose
t.b >= 0;
hence FOR is_closed_on t,Q & FOR is_halting_on t,Q by A10,Th33;
end;
suppose
A11: t.b < 0;
set t2 = Initialize t, t3 = Initialize t,
Q2 = Q +* stop I,
Q3 = Q +* pFOR,
t4 = Comput(Q3,t3, 1), Q4 = Q3;
A12: stop I c= Q2 by FUNCT_4: 25;
A13: FOR = i1 ';' (I ';' i2 ';' i3) by Th2;
A14: Comput(Q3, t3,( 0 qua Nat)+ 1) = Following(Q3,
Comput(Q3,t3, 0)) by EXTPRO_1: 3
.= Exec(i1,t3) by A13,SCMPDS_6: 11;
for a holds t2.a = t4.a by A14,SCMPDS_2: 57;
then
A15: DataPart t2 = DataPart t4 by SCMPDS_4: 8;
A16: IExec(I,Q,Initialize t).b=t.b by A5,A9,A10;
-(-n) > 0 by A3;
then -n < 0;
then -n <= - 1 by INT_1: 8;
then
A17: -n-t.b <= - 1-t.b by XREAL_1: 9;
-t.b- 1 <= k by A8,XREAL_1: 20;
then
A18: -n-t.b <= k by A17,XXREAL_0: 2;
A19: I is_closed_on t,Q by A5,A9,A10;
then
A20: I is_closed_on t2,Q2 by SCMPDS_6: 24;
A21: not b in dom Start-At( 0,SCMPDS) by SCMPDS_4: 18;
set m2=LifeSpan(Q2,t2), t5= Comput(Q4, t4,m2), Q5 = Q4,
l1= (card I +
1);
A22: IC t3 = 0 by MEMSTR_0:def 11;
set m3=m2 + 1;
set t6= Comput(Q3, t3,m3), Q6 = Q3;
card I + 1 < card I + 3 by XREAL_1: 6;
then
A23: l1 in dom FOR by Th31;
set m5=m3+ 1+ 1, t8= Comput(Q3, t3,m5), Q8 = Q3;
set t7= Comput(Q3, t3,m3+ 1), Q7 = Q3;
A24: IExec(I,Q,Initialize t).a=t.a by A5,A9,A10;
set l2=(card I+ 2);
A25: 0 in dom pFOR by COMPOS_1: 36;
card I + 2 < card I + 3 by XREAL_1: 6;
then
A26: l2 in dom FOR by Th31;
A27: pFOR c= Q3 by FUNCT_4: 25;
FOR c= pFOR by AFINSQ_1: 74;
then
A28: FOR c= Q3 by A27,XBOOLE_1: 1;
Shift(I, 1) c= FOR by Lm3;
then
A29: Shift(I, 1) c= Q4 by A28,XBOOLE_1: 1;
I is_halting_on t,Q by A5,A9,A10;
then
A30: Q2 halts_on t2 by SCMPDS_6:def 3;
Q2 +* stop I halts_on Initialize t2 by A30;
then
A31: I is_halting_on t2,Q2 by SCMPDS_6:def 3;
not a in dom Start-At( 0,SCMPDS) by SCMPDS_4: 18;
then t3.DataLoc(t3.a,i)= t3.b by A10,FUNCT_4: 11
.= t.b by A21,FUNCT_4: 11;
then
A32: IC t4 = 0+ 1 by A22,A11,A14,SCMPDS_2: 57;
then
A33: IC t5=l1 by A12,A31,A20,A15,A29,Th16;
A34: Q6/.IC t6 = Q6.IC t6 by PBOOLE: 143;
A35: t6=t5 by EXTPRO_1: 4;
then
A36: CurInstr(Q6,t6)
=Q3.l1 by A12,A31,A20,A32,A15,A29,Th16,A34
.= FOR.l1 by A23,A28,GRFUNC_1: 2
.=i2 by Th32;
A37: t7 = Following(Q3,t6) by EXTPRO_1: 3
.= Exec(i2,t6) by A36;
then
A38: IC t7= IC t6 + 1 by SCMPDS_2: 48
.= card I+( 1+ 1) by A33,A35;
then
A39: CurInstr(Q7,t7)=Q3.l2 by PBOOLE: 143
.= FOR.l2 by A28,A26,GRFUNC_1: 2
.=i3 by Th32;
A40: t8 = Following(Q3,t7) by EXTPRO_1: 3
.= Exec(i3,t7) by A39;
then IC t8=ICplusConst(t7,( 0 qua Nat)-(card I+ 2)) by SCMPDS_2: 54
.= 0 by A38,Th1;
then
A41: Initialize t8=t8 by MEMSTR_0: 46;
A42: DataPart Comput(Q2, t2,m2) = DataPart t5 by A12,A31,A20,A32,A15,A29
,Th16;
then
A43: t5.a= Comput(Q2, t2,m2).a by SCMPDS_4: 8
.=s.a by A10,A24,A30,EXTPRO_1: 23;
then DataLoc(t6.a,i)=b by EXTPRO_1: 4;
then t7.a=t6.a by A4,A37,SCMPDS_2: 48
.=s.a by A43,EXTPRO_1: 4;
then
A44: t8.a=s.a by A40,SCMPDS_2: 54;
A45: now
let x be Int_position;
assume
A46: x in X;
t5.x= Comput(Q2, t2,m2).x by A42,SCMPDS_4: 8
.=IExec(I,Q,Initialize t).x by A30,EXTPRO_1: 23
.=t.x by A5,A9,A10,A46
.=s.x by A9,A46;
then t7.x=s.x by A2,A43,A35,A37,A46,SCMPDS_2: 48;
hence t8.x=s.x by A40,SCMPDS_2: 54;
end;
A47: t5.b= Comput(Q2, t2,m2).b by A42,SCMPDS_4: 8
.=t.b by A16,A30,EXTPRO_1: 23;
t8.b=t7.b by A40,SCMPDS_2: 54
.=t.b+n by A43,A47,A35,A37,SCMPDS_2: 48;
then
A48: -t8.b=-n-t.b;
then
A49: FOR is_closed_on t8,Q8 by A7,A44,A45,A18;
now
let k be Nat;
per cases;
suppose
k < m5;
then:: Received December 27, 1999
then
A50:: licenses, or see http://www.gnu.org/:: http://creativecommons.org/
hereby
per cases ,TURING_1,VALUED_1, SCMPDS_4, AMISTD_2,XXREAL_0,AMI_3java.lang.StringIndex OutOfBoundsException: Range [77, 78) out of bounds for length 77
suppose
A51: k <=m2;
hereby
per cases;
suppose
k=java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24
hence IC Comput(Q3,t3, in dom pFORbyA25A22;
end;
java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 15
k< WSIERP_1 FINSEQ_1,RVSUM_1, RELAT_1,FINSEQ_3,XBOOLE_1,XREAL_1,
thenconsider kn be Nat such that
: k=kn+ by NAT_1:;
reconsider kn as Nat;
,k2 for Integer,
set D = SCM-ata-oc;
kn < k by A52,XREAL_1:29;
:2;
thenjava.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
Q4t4,n)
by ,A20,32,15,29,h14;
then
A53: IC ;
ICComput(2, t2,kn) in dompIby A19,CMPDS_6:ef 2
lm <card pI by AFINSQ_1:6;
<card I+ :;
A1: IJ c= IJ ';' K by FU32
A54: lm+ < card I 1by INT_1:7;
card;
then lm+ < card I +4 by A54,XXREAL_0:;
thenlm+ <card pFOR by ;
hence thesis AFINSQ_1:4;
;
end;
end;
suppose
A55: kper cases by A1,NUMSET1:ef 3;
l1 in pFOR by A23,OMPOS_1:;
hence
IC Comput(Q3, t3,k) in dom pFOR by A12,A31,A20,A32,A15,A29,A35
,A55,Th16;
end;
suppose
k=m3+1;
hence IC end;
end;
;
m5java.lang.StringIndexOutOfBoundsException: Range [20, 21) out of bounds for length 20
then consider nn be Nat such that
A56: k=m5+nn by NAT_1:10;
reconsider nn as Nat;
Comput(Q3,t3,k)=
Comput(Q8 +* pFOR, Initialize t8,nn) by A41,A56,EXTPRO_1:4;
hence IC Comput(Q3, t3,k) in dom pFOR by A49,SCMPDS_6:def 2;
end;
end;
hence FOR is_closed_on t,Q by SCMPDS_6:def 2;
A57: Q8 +* pFOR = Q3;
FOR is_halting_on t8,Q8 by A7,A44,A45,A18,A48;
then Q3 halts_on t8 by A41,A57,SCMPDS_6:def 3;
then Q3 halts_on t3 by EXTPRO_1:22;
hence(is. . by :;
end;
end;
reconsider nn=-s.b as Element of NAT by A1,INT_1:3;
:P0java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
proof
lettbeStateofSCMPDS ;
assume
t. =0java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
thenA1:I is_closed_on s1,P1;
then
A59:t. > 0 :24
assume:pIc=PP2 by FUNCT_4:25;
for x be Int_position st x X holds t.x=s.x;
assume
t.a=s.a;
hence thesis by A59,Th33;
ndjava.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
for A3,2AS:;
then
A60:P[n]
for x be Int_position st .= PP1.IC Comput(PP1,s)by A3,8AG:
hence ::thesis
for-p( sP
& Program of SCMPDS st I is_closed_on s,P1 &
end;
theorem
of SCMPDS, being -free shiftable Program of
assumethat
stop c P2;
DataLoc(s.a,iA5 =Initialize s by A4,UNCT_498java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
t ofSCMPDS,
st (for s being0startedState SCMPDS
stopI=P1 stop c P2
& IExec(I,Q,Initialize t).DataLoc(s.a,i)=t.
DataLoc(s.a,i) & I is_closed_on t,Q & I is_halting_on t,Q &
fory be Int_position
st y that
holdsA3:stop Ic
=IExec(or-up(ai,,)P,
InitializeIExec(I '' AddTo(a,,)P,)
let s beA9 byA6F:;
I be halt- =P2 + stop byA4,UNCT_498java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36
A11 halts_ons ,8,CMPDS_6def;
set b=ataLoc(.,)
CurInstr,(1sl)=CurInstrP2,(P2sl)
pFOR = stop FOR,
s1= s, P1 = P +* pFOR;
set i1=(a,i)>=0_goto (card I+3), i2=AddTo(a,i,n), i3=goto -(card I+2);
assume
A1: s.b < 0;
set s4 = Comput(P1,s1,1), P4 = P1;
A2: IC s1 = 0 by MEMSTR_0:def 11;
set m0=LifeSpan(P1,s1);
set l2= card I+2;
set sI= s, PI = P +* stop I,
m1=LifeSpan(PI,sI)+3,
J=I ';' AddTo(a,i,n), sJ= s,
PJ = P +* stop J,
s2=Initialize IExec(J,P,s), P2 = P +* pFOR,
m2=LifeSpan(P2,s2);
set Es=IExec(J,P,s), bj=DataLoc(Es.a,i);
A3: stop I c= PI by FUNCT_4:25;
A4: FOR = i1 ';' (I ';' i2 ';' i3) by Th2;
set mI=LifeSpan(PI,sI), s5= Comput(P4, s4,mI), P5 = P4,
l1= card I + 1;
set m3=mI +1;
set s6= Comput(P1, s1,m3), P6 = P1;
set s7= Comput(P1, s1,m3+1), P7 = P1;
A5: pFOR c= P1 by FUNCT_4:25;
FOR c= pFOR by AFINSQ_1:74;
then
A6: FOR c= P1 by A5,XBOOLE_1:1;
Shift(I,1) c= FOR by Lm3;
then
A7: Shift(I,1) c= P4 by A6,XBOOLE_1:1;
card I + 2 < card I + 3 by XREAL_1:6;
then
A8: l2 in dom FOR by Th31;
set m5=m3+1+1, s8= Comput(P1, s1,m5);
card I + 1 < card I + 3 by XREAL_1:6;
then
CurInstrP1,)
assume
A10: not b in X;
Results ComputP1,,ifeSpan(1,)A11,EXTPRO_123
A11: n > 0theorem Th9:
assume
A12: a <> b;
:Initialize s =s by MEMSTR_0:4java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
assume
A14: for t be State of SCMPDS,
st (for x be Int_position st Initialize ,PP2=P2 *stopI;
ialize t)at. &
IExec(I,Q,Initialize t).b=t.b
& I is_closed_on t,Q
&PP1,ss1)bEXTPRO_1:;
java.lang.StringIndexOutOfBoundsException: Range [31, 3) out of bounds for length 39
then FORA8:CurInstr(P2,Comput(,s2l)=haltSCMPDSjava.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
A15:P1 halts_on s1 by A13,SCMPDS_6:ef3;
Int_position st x in X holds s.x=.;
then
A17: IExec hence LifeSpan(PP1,s1) = LifeSpan(P2,s2)by ,6,XTPRO_1d ;
A18: IExec(I,PPP1,s1) by A6,XTPRO_1:java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
A19: b=DataLoc(IExec(I,P,s).a,i) by A14,A16,A13;
A20: IExec(I,P,s).a=s.a by A14,A16,A13;
A21: java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
P1s1) :
.= Exec(i1,s1) by A1,A3,A5,SCMPdef 2;
:IC s4 =0+by,A1A21,SCMPDS_2:7;
for a holds sI.a = s4.a by A21,SCMPDS_2:57;
then
A23: DataPart sI = y ;
A24: I is_halting_on sA14:DataParts3 = DataPart s2 by A9;
consider such
:PI SCMPDS_6d 3;
PI +*stop I halts_on sI by A25;
then
A26: I is_halting_on sI,I by ,CMPDS_6:ef 3;
A27;
theoreTh11:
A28: Es.=xec(2,IExec(,,). by A24,h29
.IExec(,Ps.b+ by A18,SCMPDS_2:48
,A16,13;
A29: java.lang.StringIndexOutOfBoundsException: Range [0, 6) out of bounds for length 0
then
A30:IC s5=1 A3A26,22,23A7,h16;
s6=5 by EXTPRO_1:;
then
A33:CurInstr(P6,6)
=P1.1 by ,A26,29,22,23,7,h16,31
.=FOR.proof
.i2 by Th32;
: DataPart Comput(PI,sI,I)=DataPart s5 A3,26,29,22A23A,Th16;
then
A35:A4: LifeSpan(Ps;
.=s.a A6: P +sI= byA1,UNCT_4:8java.lang.StringIndexOutOfBoundsException: Range [33, 34) out of bounds for length 33
A36: Es.A9 halts_on sby A3,7,6,CMPDS_6: ;
.s. byA12,18,CMPDS_2:;
now
per cases;
suppose
Es.bj >= 0;
is_halting_on , Th33;
end;
suppose
A37: .j<;
now
let t be State of for I being shiftable Program st
assumefor n being Nat
A38: for x be Int_positionfor i being Nat holds i <LifeSpan(P1,1) implies
A39: t.CurInstr(P1,omputP1,i) =CurInstr(P2,omput(2,2,)
A40: now
let x be Int_position;
assume
xi ;
hence t.=. by A38
=(2,IExec(I,,s).x by
.IExec(,,s).x by A10,18,41,CMPDS_248
.s. by,16,A41,A13;
end;
hence IExec(,Q,Initialize t)a=. by ,A36,39;
thus IExec(I,A10: for k being Nat s[k holds Pk+1]
java.lang.StringIndexOutOfBoundsException: Range [27, 12) out of bounds for length 55
for y be Int_position: Comput(P1,1,k+)=Following(1,omput(,,) by EXTPRO_13
in X holds IExecA14 k+<LifeSpanPs)java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
end;
hence FOR is_halting_on Es, =ExecCurInstrP2,(,2k)java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
end;
endjava.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
then
A42:A23: InsCode i < 1b ,19,CMPDS_4:ef 9;
A43: s7 = Following(P1,s6) by EXTPRO_1:3
. Exec(2,6)by A33;
A44: IC s7= IC s6 + 1 by SCMPDS_2:48
.= card I+(1+1) by hence CurInstr(1Comput(1,1,k+)
then
by A24,14,1,2,A3,h13,COMPOS_1:5
.=FOR.l2 by A6,A8,GRFUNC_1:2
.=i3 by Th32;
A46: s8 = thus DataPart Comput(1,k1 =DataPart Comput(
.= Exec(i3,s7) by A45;
then IC s8=java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 8
.= 0 by A44,Th1;
then
A47:IC s2 =C Comput(P1,1,) by MEMSTR_0:ef 11;
A48: s5.b= Comput(PI, sI,mI).b by A34,SCMPDS_4:8
.:23;
A49: s8.b=s7.b by ,)= by MEMSTR_0d 11;
.=s.b+n by A30: P1/.IC s1 = P1 by PBOOLE:143;
now
let x be = Shift(SI)( (0 qua Nat)+n)by A25,A29,30,VALUED_1:ef 12
A50:not x in dom Start-t(,CMPDS)by :;
then
A51:s2.=IExec(,,)x by FUNCT_4:11;
per cases;
suppose
x=b;
hence s8.x=s2.x by A49,A28,A50,FUNCT_4:11;
end;
suppose
A53: s5.x= Comput(PI set siInitialize s, Pi = P*stop I;
.=IExec(I,PA3:I is_halting_on s,;
A54: s7.x=s5A5:P =P + stop I by A2,:8;
Es assume
.=IExec(I,A7: LifeSpan(P,s)=0
hence java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 6
;
end;
then
55: DataPart s8 DataPart s2 by :;
A56: Comput(P1, =(top I) 0 byA10,A9,12,GRFUNC_1:
by ,A47,EMSTR_0:;
then CurInstr(P1,Comput(P1,s1,m1))=i1
by A4,CMPDS_6:;
then for I haltfree Program of SCMPDS st
uch that
+nn by NAT_1:0;
reconsider nn as Nat;
Comput(P1,s1,1+m2 Comput(2,2,2)by A56,XTPRO_1:;
thenCurInstrP1,omput(P1,1,1+)java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
SCMPDS by A42,XTPRO_1:ef 15;
then m1 + m2 >= m0 by A15,EXTPRO_1:java.lang.StringIndexOutOfBoundsException: Range [0, 40) out of bounds for length 13
A4: St-(0,)c byMEMSTR_0:29java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
A58: assumethat
A59:Comput(P1,1,m0)=by A56,57,XTPRO_1:4;
then CurInstr(P2 1+( qua Nat)< LifeSpan(P1,1) byA1,3,h15,NT_1:7;
=altSCMPDS by A15EXTPRO_1:ef 5
then nn >= m2 A10: Initialize s1 =s1 by A4,FUNCT_4:8;
then nn=m2 by A58,XREAL_0:;
then Result(1,1)= Comput(2,2,2)by 15A59EXTPRO_1:3java.lang.StringIndexOutOfBoundsException: Index 63 out of bounds for length 63
hence thesis by A42,EXTPRO_1:23;
;
registration
let I be shiftable Program of SCMPDS, be ,ibe ,
Nat;
cluster for-up(,i,,)- shiftable;
correctness
proof
set FOR=or-p(a,,,) i1= (i>0_oto( 3,i2 (,in)
set PF= Load i1 ';' I set PF= Load i1 ';' I :2;
card PF=card (A20:DataPart Comput(1,i DataPartComput(sijava.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
.=card I + 1+1 by SCMPDS_6:6
.=card I +(1+1);
then card PF+ -(card I+2) =0;
hence thesis by SCMPDS_4:23;
end; thus thesis A9,12,AA,,20,SCMPDS_4:8java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60
end;
registration
let I holds Comput( *stop IInitialize skjava.lang.StringIndexOutOfBoundsException: Range [45, 46) out of bounds for length 45
Nat;
cluster set s1 = In s,P1 = + spI;
correctness
proof
reconsider
i3=oto -(ard I+2) as No-topCode Instruction of SCMPDS by SCMPDS_5:1;
for-p(,,,)=(,i)=_oto (ard I''AddTo(,,)''
i3;
hence thesis;
end;
end;
begin :: The construction of for-down loop program
:: while (a,i)>=0 do { I, (a,i)-=n }
Nat;
let I be Program of SCMPDS;
func for-down(a,i,n,I) .= I.IC Comput(P1,sm)by A10,AFINSQ_1:ef 3
(a,i)<=0_goto (card I +3)
';' .CurInstr(2,omput(2,s2,) by A5,9,NAT_1:3,PBOOLE:43;
coherence
end;
begin :: The computation of for-down loop program
theorem Th39:
for a be Int_position, for I, Program of SCMPDS, be Nat st I c= J&
ProgramIis_closed_ons, &I is_halting_on s, &
proof
let ComputP*stop I,nitialize s,)
SCMPDS;
set i1=(a,i)<=0_goto (card I +3 set mLifeSpan( + stopI,nitializes;
set I4=1 ''I, I5=4 ;'i2;
I+ by :;
then card I5=card I + set s1 =Initialize s, s2 =Initialize,
.=card I+ (1+1;
hence card for-own(a,,,)card I 2+1 by SCMP_GCD:
.=card I + 3;
nd
Lm4:for a e, Integer,n be Nat, I be Program of
SCMPDS .=CurInstrP1,omput(1,1,)java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
proof
let a be Int_position,i be Integer, then
;
thus card stop for-own(a,,I)= card down(,,I)+ by COMPOS_1java.lang.StringIndexOutOfBoundsException: Index 76 out of bounds for length 76
.= card I +3+1 stop I)IC Comput(2,s2,)by A11AFINSQ_1def 3
.= card I + 4;
end;
theorem Th40:
for a be java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 6
Program of SCMPDS hence thesis A4java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
,n, be ,I Programof
SCMPDS;
card for-down(a,i,n,I)=card
hence set ss =Initialize s,PP =P+ stop I;
ends2=Comput(PP,ss,;
for a be nt_positioni be Integer, be Nat, I be
Program of SCMPDS holds
-downa,,n,) (ard I+1)AddTo(,,n)& fordown(,,,) (
I+)goto -(ard I+)
proof
a be Int_position, be Integer, eNat,I be Program
SCMPDS;
set i1=(a,i)<=p
set I4=i1 ';' I, I5=I4 ';' ss=Initialize,PP=P+ stopIjava.lang.StringIndexOutOfBoundsException: Range [42, 43) out of bounds for length 42
P1=P0 =PP,
set A1: I c= J
=4 ''J6by:;
then FLOOP=i1 ';' J5 reconsider n = Ik as Natjava.lang.StringIndexOutOfBoundsException: Range [27, 28) out of bounds for length 27
hence FLOOP. 0=i1 byA7:Ik7
A1: card per casesb A8XXREAL_0:;
hence
ardI5 I + + ,CMP_GCD:4
.card I+(1+)
hence thesis by SCMP_GCD:6;
end;
theorem Th42:
for s being ;
, i being Integer,n Nat st s.DataLoc(.,) < 0
holds for-
-down(,,,)is_halting_on s,P
let s be State of SCMPDS,I be Program of SCMPDS,a be Int_position, i be
Integer,n be Nat;
set d1=DataLoc(s.a,i);
assume
A9 DataPart sm =DataPart s3 by MEMSTR_0:45java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
set i1=(a,i)<= sIJ =I ''(; SCMPDS :java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
setFOR=or-own(ainI) pFOR=top FORjava.lang.StringIndexOutOfBoundsException: Range [43, 44) out of bounds for length 43
= Initialize s,P3=P +* pFORjava.lang.StringIndexOutOfBoundsException: Range [36, 37) out of bounds for length 36
s4 = Comput(P3,s3,1), P4 = P3;
per cases;
A3: notk< m1;
a indom Start-t(,SCMPDS) SCMPDS_4:8;
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
A4: s3.:k>;
.= s.d1 by A3,FUNCT_4:java.lang.StringIndexOutOfBoundsException: Range [0, 28) out of bounds for length 12
A5: FOR A17 ICs4 ;
consider ii be Nat such
Comput(P3,s3,0)) by EXTPRO_1:3
. Exec(1,3)by A5,CMPDS_6:1;
then
A6: IC s4 = ICplusConst( in dom spJ bySCMPDS_6:ef 2;
.= ((0quaNat+(card I+) by ,SCMPDS_6:;
A7: card FOR=card I+3 java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 14
then
A8: (card I+3) in dom pFOR by COMPOS_1:64;
pFOR c= P3 by FUNCT_4:25;
then P4.(card I+3) = pFOR.(card I+3) by A8,GRFUNC_1 CurInstr(4,4) =halt SCMPDS;
.=halt SCMPDS by A7,COMPOS_1:4;
then
java.lang.StringIndexOutOfBoundsException: Range [26, 2) out of bounds for length 51
now
let k be Nat;
per cases;
suppose
0 < k;
then
hence IC Comput(3,3,) ndompFOR
by A8,A6,A9,EXTPRO_1:5;
end;
suppose
k = 0;
then Comput(P3,s3,k) = s3;
hence IC Comput(P3,s3,k) in dom
end;
end Initializesjava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
hence A2 I is_closed_on,Pand
ComputP1 s1,)=C Comput(P, s,ifeSpan(PP,s)by ,2,3,
hence thesis SCMPDS_6def3;
end;
theorem &k<LifeSpan(+*top IInitializes
for s being State of SCMPDS,I being Program of SCMPDS,a,c being
Int_position, i being nteger be Nat st s.ataLoc(.a,)< 0
holds IExec(for-down( let I be Program ofSCMPDS,s be State of SCMPDS, be Nat;
=s + -(card I+)SCMPDS)
proof
let s be State java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
Integer,n be Nat;
set d1=DataLoc(s.a,i);
set FOR=for-down(a, I, being Program of SCMPDS,s being 0-tartedState SCMPDS being
s3 = InitializeNat I is_closed_on s,P & I is_halting_onsP
s4 = Comput( CurInstr(+stop( ''J)ComputP*( ' ),)
i1=a,i)<=0_goto( I+) =AddTo(,,n
i3=goto -(card I+2);
set set P1 =P + stop I,P2=P +* stop( ;'J)
A1: IC s3 = 0 by MEMSTR_0:def 11;
:n -(,CMPDS)by SCMPDS_4:18;
A3: pFOR:k<;
not a in java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 6
then
A4:s3.(3.,)d1 FUNCT_411
.= s.d1 by A2,java.lang.StringIndexOutOfBoundsException: Range [0, 25) out of bounds for length 0
A5: FOR = i1 ';' (I ';' i2 ';' i3 & I is_halting_on s,P &
A6:is_halting_onIExec(I,,s),&
Following(P3,Comput(P3,s3,0)) by P2=P +*stop( '' J) &= +*stopI
. Exec(i1,3) by A5,SCMPDS_6:1;
m1=LifeSpan(P1,, sm =
then
A7: IC s4 = ICplusConst(s3,(card I+3 assume that
. (0 uaNat+(ard I+) by ,:;
A8: card FOR=cardA4:J is_halting_on sEP and
then (card I+3) in dom pFOR by COMPOS_1:64;
then P4.java.lang.StringIndexOutOfBoundsException: Range [10, 11) out of bounds for length 7
.=halt A10: DataPart Comput(P1,s,m1) = DataPart s3 by MEMSTR_0:45;
then
A9: CurInstr(P4,s4) = A11 DataPart s4 = DataPart s3 by A10,1,2,h17,A6,7,java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
then
A10: P3 halts_on s3 by EXTPRO_1:29;
,CMPDS_611;
now
let l be Nat;
assume
l < (0 qua Nat)+1;
then l=0 by NAT_1:13;
,Comput,s3,) < halt
end;
then for l be Nat st CurInstr
Comput(P3A21:k <m;
hen
A12: LifeSpan(P3,java.lang.StringIndexOutOfBoundsException: Range [42, 19) out of bounds for length 42
:java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
A14: dom SAl
A15: x in domIExec(OR,,nitialize )java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
per cases by A15,CMPDS_4:;
suppose
: is Int_position;
then x ( +stopIs
then
A17:
A18: for s being-tarted State of SCMPDS
,EXTPRO_1:23
. s3.x by A6,16,CMPDS_2:6
.=s. by A18,FUNCT_4:1
.= (s +* SAl).x by java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 25
end;
suppose let I be halt-ree Program of SCMPDS, be shiftable Program of SCMPDS;
A19: IJ =I ''J =s P1 = +stopI,
thus IExec(FOR,P,Initialize s).x = (card I + 3)
by A7,A12,A19,A10,EXTPRO_1:23
.= (s + SAl)x by A19,FUNCT_4:113;
end;
end;
dom:J is_closed_on sE,and
.= dom (sA5:Initialize s = byMEMSTR_044;
hence thesis by A13,FUNCT_1:2;
end;
theorem
for s being State of SCMPDS,I being Program of SCMPDS,a being
Int_position, i being Integer,n be Nat st s.ataLoc(.i = 0
holds IC IExec(for-down(a,i,n, holds IC IExec(,,m1 cardI A1A2,3ALm1java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53
proof
let s be State of SCMPDS,java.lang.StringIndexOutOfBoundsException: Range [0, 28) out of bounds for length 6
Integer,n be Nat;
assume s.DataLoc(s.aA:DataPartComput(P2 (
then IExec(for-down(a,i,n,I),P,Initialize s)
=s +* Start-At((card I+ by A8,10A,9A,SCMPDS_631java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
= Result(1,1)
nd
theorem Th45:
for s being State of java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 6
, beingInteger, be Nat sts.ataLoc(.,)< 0
A18: J InitializesE, P + stop J by A3,A4,SCMPDS_6:3;
proof
byA3,4,17SCMPDS_6:;
Integer,n be Nat;
assume s.ataLoc(s.a,)< 0;
then
A1: IExec(for-down(a,i,n J is_halting_on Comput(P1,1,,P1 by A2,3,A4,h21,;
Th43;
not b in dom A22: IExec(I,P,s= Comput(P1,1, ,XTPRO_12;
hencethesisby ,UNCT_4:1;
end;
Lm5: for I being A23: IExec(J,P,Initialize IExec(I,P,s)) = Comput(P3,s3,m3)
Nat holds Shift(I,1) c= for-down(A24:IC IExec( '',,java.lang.StringIndexOutOfBoundsException: Range [26, 27) out of bounds for length 26
let I be Program of SCMPDS,a be Int_position,i be Integer, n be ;
i1=a,i)=_oto (ard I+),i2=ddTo(,,-) i3=oto -(card I+2);
. IC Result(1 +stop J,InitializeResult(s) java.lang.StringIndexOutOfBoundsException: Range [65, 66) out of bounds for length 65
card Load i1=1 by COMPOS_1byCOMPOS_1:4;
IExecI ';'J,,s) =Comput(s)
end;
theorem Th46:
being State ofSCMPDS, being halt-ree shiftable
Program of ,a be Int_position,ibe , Nat, be set
st s.DataLoc(s.a,i) > 0 & not DataLoc(.,)in X &n >0 &a >
DataLoc(s. card I Nat;
(or t be 0-tarted State of SCMPDS, st (for x be Int_position st x in X
holds t.x=s.x) & beobjectjava.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
IExec(I,Q,t).DataLoc(s.a,i)=t.DataLoc(s.java.lang.StringIndexOutOfBoundsException: Range [0, 46) out of bounds for length 34
I is_closed_on t,A29 x isInt_position;
for y be Int_position st y in X holds IExec(I,Q,t).ythen
holds -down(,,,I) is_closed_on s, java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
for= IExec(,,nitialize IExec(I,,s).x by A25,29,CMPDS_4:8;
proof
let s =(ncIC(IExecJP,nitialize IExec(,Ps)c ).java.lang.StringIndexOutOfBoundsException: Range [64, 65) out of bounds for length 64
Int_position, i be Integer,n be Nat,X be set;
set b=DataLoc(s.a,i);
set FOR=or-own(a,i,,) pFOR=stop FOR,
pI=stop I;
set i1=(a,i)<=0_goto (card I+3), IExec( ''J,s)x =(tart-t(,SCMPDS)I
assume . (IncIC(ExecJ,Initialize IExec(,,)card I).
A1: s.b > 0;
defpred P[ end;
for t be State of SCMPDS,1&
(or x be Int_position st x X .x=s.) &t.=.java.lang.StringIndexOutOfBoundsException: Index 61 out of bounds for length 61
holds FOR is_closed_on t, & FOR is_halting_on t,Q;
assume
A2: not b in X;
assume
A3: n > 0;
assume
A4: a <> b;
assume
A5:for t be 0-started State of SCMPDS, st (for x be Int_position st x in X
holds t.x=s.x) & t.a=s. (,P,s),P & J is_halting_on IExec(,P,s)P
IExecI,Q,t)b=. &
I is_closed_on ,java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
& I is_halting_on t,Q & for y belet I be halt-free Program ofSCMPDS, be shiftable Program of SCMPDS;
holds IExec(I,Q,t).y=t.y;
A6: for k be Nat st P[k] holds P[k + 1]
proof
let k be Nat;
sume
A7: P[k];
let t be State of SCMPDS,Q;
assume
A8: tb= +java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
assume
A9: for
A10: for x java.lang.StringIndexOutOfBoundsException: Range [0, 14) out of bounds for length 0
proof let x be Int_position;
assume x in X;
then t.x=s.x by A9func for-up(a,i,n,I) -> Program of SCMPDS equals
hence (Initialize t).x=s.x by SCMPDS_5:15;
end;
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 4
A11: t.a=s.a;
then
A12: (Initialize t).a=s.a by SCMPDS_5:15;
per cases;
suppose
t.b <= 0;
hence FOR is_closed_on t,Q & FOR i1(,i)>=0_gotoc +,i2=ddTo(,,)
end;
suppose
A13: t.b > 0;
set t2 = Initialize t,t3 =Initialize t,
Q2 = Q +* stop I, Q3 = Q +*end;
t4 = Comput(Q3,3,) Q4 =Q3;
:25;
A15: FOR = i1 ';' java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
A16: Comput(Q3, t3,(0 qua Nat)+1) = Following(Q3,
thuscard or-p(in,)card for-(,,nI)+ byCOMPOS_1:5
.= Exec(i1,t3) by A15,SCMPDS_6:11;
for
then
A17: DataPart t2 = DataPart t4 by SCMPDS_4:8;
A18: IExec(I,Q,Initialize t).b= (Initialize t).b by A5,A10,java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
.= t.b by SCMPDS_5
--)> by ;
then - <0;
then -n <= -1
then
A19: -n+t.b <= - Program of SCMPDS for-p(,,,) 0=ai)=_oto card +)java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 72
.-1 < kby ,REAL_1:0
then
A20: -n+ let a be Int_position, be Integer,n be Nat,I be Program of
I is_closed_on set i1=(a,i)>=0_goto (card I +3=(,,) i3=oto -card I+2)
then
A21: I is_closed_on t,Q by setFLOOP=or-p(a,,,;
then
A22: I is_closed_on t2,Q2 by SCMPDS_6:24;
A23: not b in dom Start-A1 card I4=cardI+ bySCMPDS_66
set m2=LifeSpan(Q2,2) t5=Comput(4,t4,2),Q5 =Q4,
l1= (card I +
1);
A24: IC t3 = 0 by MEMSTR_0:def 11;
set m3=2 +1;
set t6= Comput(Q3, t3,m3)e;
card I + 1 < card I + 3 theorem Th33:
then
A25: l1 FOR Th40java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
set m5=m3+1+1, t8= Comput(Q3, t3,java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
set t7= Comput(Q3, t3,m3+1), Q7 = Q3;
26 IExec(IQ, t). =(nitialize t)a by A5,10,12
.=t.a byA1: s.d1 >= 0;
set l2=card I+);
A27: 0 in dompFOR by COMPOS_1:6;
card I + 2 < card I + 3 java.lang.StringIndexOutOfBoundsException: Range [0, 34) out of bounds for length 32
then
A28: l2 in dom FOR by Th40;
A29: pFOR c= Q3 by FUNCT_4:25;
FOR c= pFOR by AFINSQ_1:74;
then
A30: FOR c=Q3 yA29,BOOLE_11;
Shift(A5: FOR = i1 ';I ;'i2 ' ) ;
Comput(3,s3( qua Nat)1 FollowingP3java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46
A31: Shift(I, .=Execi1,3 ,CMPDS_6:java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
t,Qby,A10,12;
then I is_halting_on t, . (0 qua )(ard I+)) by ,CMPDS_6:2;
then
: Q2 halts_on t2 SCMPDS_6:ef 3;
Q2+ stop I halts_on Initialize t2by ;
A33: I s_halting_on,2 by : ;
not a in dom Start-At(0,java.lang.StringIndexOutOfBoundsException: Range [0, 38) out of bounds for length 6
then t3.DataLoclet k be Nat;
.= t.b by A23,java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 11
then
A34: IC t4 = 0+1 by A24,A13,A16,SCMPDS_2:56;
then
A14,33,22,17,31,h16java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
A36: Q6/.IC t6 = endjava.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
A37: t6=t5 by EXTPRO_1:4;
then
A38: CurInstr(Q6,t6)=Q5.l1 by A14,A33,A22,A34,A17,A31,Th16,A36
.=FOR.l1 by A25,A30,hence FOR is_closed_on s,P by SCMPDS_6;
.=i2 by Th41;
A39: t7 = Following(Q3,t6) byend;
. Exec(2,6 ;
1by SCMPDS_2:48
. card I+(+1)by A35,37;
then
A41: CurInstrlets of SCMPDS, be of ,acbe Int_position,ibe
.=FOR.l2 by A30,A28,GRFUNC_1:2
. set d1=ataLocsa,;
A42: t8 (,7) by EXTPRO_1:
.=Exec(i3,7)by A41;
then IC t8=ICplusConst(t7,(0 qua Nat)-(card I+2)) by SCMPDS_2:54
.= 0 by A40,Th1;
then
A43: Initialize t8=t8 by MEMSTR_0:46;
: DataPart Comput(Q2,t2,m2)=DataPart t5 by A14,A33,22,A34,17,31
,Th16;
then
A45: t5.a= Comput(Q2, s3 = 0 by MEMSTR_0:def 11;
RO_1:23java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
then DataLoct6.,)bby :;
then t7.a=t6.a by A4,A39,A4: s3.DataLoc(s3.a,i)=s3.d1 by FUNCT_4:11
.s. by A45,EXTPRO_14
A46: t8.=. A42,SCMPDS_2:4;
A47: now
let x be Int_position;
assume
A48: x in X;
t5x=Comput(,t2,)x by ,CMPDS_4:
.IExec(I,,nitialize t)x byA32,XTPRO_1:3
by A5A48,10,12
.=t.x by SCMPDS_5:15
.s by A9,48;
then t7.x=s.x by A2,A45,A37,A39, then P4.(ard I3 .card I+)byA3,RFUNC_1:2
hence t8.x=s.x by A42,SCMPDS_2:54;
end
A49: t5.bA10: byEXTPRO_1:9;
=. by A18,32,XTPRO_1:3;
A50: t8.=7. ,CMPDS_2:java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36
.=t.b+ -n by A45,A49,A37,A39,SCMPDS_2:48;
then
A51: FOR is_closed_on t8 for l be Natst
now
let k be Nat;
per cases;
suppose
k <m5;
k <=m3+ by INT_1:7java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
then
A52: k <= m3 or assume
hereby
per cases by A52,NAT_1:8;
suppose
A53: k <= m2;
hereby
per cases;
suppose
k=0;
hence IC Comput(Q3, t3,k) in dom pFOR by A27,A24;
end;
suppose
k<>0;
then consider kn be Nat such that
A54: k=kn+1 by NAT_1:6;
reconsider kn as Nat;
reconsider lm = IC Comput(Q2, t2,kn) as
Nat;
kn < k by A54,XREAL_1:29;
then kn < m2 by A53,XXREAL_0:2;
then IC Comput(Q2, t2,kn) + 1 = IC Comput(
Q4,t4,kn)
by A14,A33,A22,A34,A17,A31,Th14;
then
A55: IC Comput(Q3, then x< IC SCMPDS by 43;
IC Comput(Q2, t2,kn) in dom pI by A21,SCMPDS_6:def 2;
then lm < card pI by AFINSQ_1:66;
then lm < card I+1 by COMPOS_1:55;
then
A56: lm+ < card +1 by INT_1:7;
card I + 1 < card I + 4 by XREAL_1:6;
then lm+1 < card I +4 by A56,XXREAL_0:2;
then lm+1 < card pFOR by Lm4;
hence IC Comput(Q3, t3,k) in dom pFOR by A55,AFINSQ_1:66;
end;
end;
end;
suppose
;
l1 in dom pFOR by A25,COMPOS_1:62;
hence
IC Comput(Q3, t3,k . ( *SAl)xbyA19FUNCT_4113
,A57,Th16;
end;
suppose
k=m3+1;
hence IC Comput(Q3, t3end;
end;
end;
;
suppose
k >= m5;
then consider nn be Nat such
A58: set i1=ai>0_oto (card I+), ,,) i3goto -card I+;
reconsidernn asN;
Comput(Q3,t3,k)=
Comput( card Load i1=1 byCOMPOS_154
by A43,A58,EXTPRO_1:4;
java.lang.StringIndexOutOfBoundsException: Range [0, 17) out of bounds for length 0
end;
end;
hence FOR is_closed_on t,Q by SCMPDS_6:def 2;
A59: Q3 = Q8 +* pFOR;
FOR is_halting_on t8, Q8 by A7,A46,A47,A50,A20holds t.=.)&t.. holds IExec(I,,nitialize t).=. &
halts_on t8 A43,59,CMPDS_6:def 3;
then Q3 halts_on t3 by EXTPRO_1:22;
hence FOR is_halting_on t,Q by SCMPDS_6: for y be Int_position
end;
end;
reconsider n=s.b as Element & for-up(a,i,n,I) is_halting_on
letletjava.lang.StringIndexOutOfBoundsException: Range [75, 6) out of bounds for length 75
atholds P[k] from NAT_1:ch 2(A60,6)
then
A61: P[]java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
x beInt_positionst x in X holds s.=.;
hence thesis by 61;
end;
theoremTh47java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
for 0-started State , -
Program of SCMPDS, a holds FOR is_closed_ont & FORis_halting_on t,Qjava.lang.StringIndexOutOfBoundsException: Range [52, 53) out of bounds for length 52
taLocs.,i) 0 ¬ DataLoc(.a,i)in X &n 0 &a <>
DataLoc(s.a,i) &
(for t be 0-started State of SCMPDS,Q st (for x be Int_position st x in X
holds t.=.x) & t.=. holds IExec(,
& IExec(,,)DataLoc(.,)t.
DataLoc(s.a,)&I twnikow Mizara, Bialystok, :: This code can be distributed under the GNU General Public Licence
environ
st y in X holds IExec & I is_halting_on t, for ybe st java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
or-downai,I)P,)
(ainI),
proof
s be A7 Pk]
Ibe halt-Programof
be ,be,nbe ,X setjava.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
et=DataLoc.a;
set TARSKI ta.a
(,<_ card +3 AddTo(i,)i3g-card I+;
assume
A1:java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
set s4 = Computjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 7
2 s=0 def 11java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
,s;
suppose
+ I,
m1=LifeSpan(PI,sI3,
J=I ';AddToai,n) sJ =,
PJ = P +* stop J,
s2=Initialize IExec( =Comput(3t,1,Q4 =Q3;
P2 = P +* pFOR,
=ifeSpan(2,2)
set Es=IExec(J,P,s), bj=DataLoc(Es.a,i);
A3: stop I c= PI by FUNCT_4:25;
A4: FOR = i1 ';' (IComput(3t3,)) by EXTPRO_1:
set mI=LifeSpan(PI,sI), s5= Comput(P4, s4,mI), java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
l1=card I 1)
set =mI+;
Comput(1,s,3,P6=P1;
set s7= Comput(P1, s,m3+1), P7 = n<;
then - < - by INT_1:;
FOR c= pFOR by AFINSQ_1:74;
then
A6: FOR c= P1
Shift(I,1) c= FOR by Lm5;
then
A7: Shift(I,1) c= P4 by A6,XBOOLE_1:1;
card I + 2 <cardXREAL_1:;
then
A8: l2 in dom FOR by Th40;
A22: t3 = 0 :ef 11java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
card I +1 < card I+3by XREAL_1:6;
then
A9: l1 in dom FOR by Th40;
assume
A10: not b in X;
:n>0;
assume
A12: a <> b;
A13: Initialize s = s by MEMSTR_0:44;
assume
A14:: l2 in dom FOR by Th31;
( be st x in holds
xsx) &t.=. (,,)at. &
IExec(I,Q,t).b=t.b
& I is_closed_on t,Q
& I is_halting_on t,Q & for y be Int_position
holds IExec(I,Q,t).y=t.y;
then FOR is_halting_on s,P by A1,A10,A11,A12,Th46;
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
A15: P1 halts_on s by A13,SCMPDS_6: I is_halting_on , by SCMPDS_6: 3;
A16:for x be st x X .=s.;
then t3.ataLoc(3.a,i) bby A10,UNCT_4:1
A17: IExec(I,P,s).b=s.b by A14;
A18: IC t4 =0SCMPDS_2:7;
A19: reserve forLeftMod ofA33:IC =1 by ,2,A,;
a ,A16;
A21: Comput(P1, s,(0 A35: t6=t5 by EXTPRO_
.= Exec(i1 A36: Q6t6
A22 =3.l1 byA12,31,20,32A15,29,h16,34
theoremTh1
then
aParts4SCMPDS_48
A24:Is, by A14,16;
then
A25:PI halts_on sI by A13,CMPDS_6:ef suppose
PI=PI+I;
A26: I is_halting_on sI, A13,java.lang.StringIndexOutOfBoundsException: Range [0, 47) out of bounds for length 40
A27: I is_closed_on s,
:s.Execi2,I,)A24Th29
=(P,)+n A18CMPDS_248
.s.b+ INT;
A29:P6/IC =.s6 PBOOLE143java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
6;
assume =0.;
A32:;
then
P,=. by,A26,,A23A7h16
=ORl A9, t7.t6.java.lang.StringIndexOutOfBoundsException: Range [26, 25) out of bounds for length 44
.=i2 by Th41;
A34java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
then-45:now
.=ComputPI sImI. SCMPDS_48
.. byA20,:;
A36: EsbeingofRing,
=.b A121,,:48;
now
percasesjava.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
suppose
Es.bj < ;
hence FOR is_halting_on Es, P by Th42;
end;
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
: Es49 t8 A7,AAjava.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49
java.lang.StringIndexOutOfBoundsException: Range [9, 10) out of bounds for length 9
assu A1:is Multcancelable 5java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19
A3: a * v w;
A38: for x be Int_position st x in X holds t.x=Es.x and
A39: t.a=Es.a;
A40: now
let x beInt_position;
assume
A41: x in X;
hence t.x=Es.x by A38
.= per cases byA50,AT_18java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
.=IExec(I,P,s).x by A10,A18,A41,SCMPDS_2:48
.=s.x by A14,A16,A41;
end;
hence IExec(I,Q,t).a=t.a by A14,A36,A39;
thus IExec(I,Q,t).bj= t.bj by A14,A36,A39,A40 hence Comput(3, t3k pFOR by A25A22;
thus I is_closed_on t,Q & java.lang.StringIndexOutOfBoundsException: Range [0, 35) out of bounds for length 25
y be st
A52: k+ :;
end;
hence FOR is_halting_on Es, P by A10,A11,A12,A36,A37,Th46;
end;
end;
then
A42: P2 halts_on s2 by SCMPDS_6:def kn <k by A52,REAL_1:9;
A43: s7 = Following(P1,s6) by EXTPRO_1:3
.= Exec(i2,s6) by A33;
then
A44: IC s7 IC s6 1 by :java.lang.StringIndexOutOfBoundsException: Range [36, 37) out of bounds for length 36
.= card I+(1+1) by A31,A32;
then
A45ICComput(Q2, t2,kn) dompIby A19,SCMPDS_6:ef2
.FORl2by ,8,RFUNC_1:2
.i3 by Th41java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
A46: s8 = Following(P1,s7) by EXTPRO_1:3
.= Exec(i3,s7) by A45;
then IC s8=ICplusConst(s7,(0 qua Nat)-(card I+2)) by SCMPDS_2:54
.= 0 byA56:km5:10
then: nnasNat;
A47: IC s2 =IC Comput(P1,s,m1) by MEMSTR_0:def 11;
A48: s5.b= Comput(PI, sI,java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
.25EXTPRO_1:;
A49 s8.roof
.=s.b+ -n by A35,A48, by;
now
Int_position;
A50 x StartAt,) SCMPDS_4:;
java.lang.StringIndexOutOfBoundsException: Range [8, 9) out of bounds for length 8
A51: s2.x=IExec(J,P,s).x by FUNCT_4:11;
per cases;
suppose
x=b;
hence s8.x=s2.x by A49,A28, assume
end;
suppose
A52:A59: .b > 0 by XREAL_1:24;
A53: s5.x= Comput(PI, sI,mI).x by A34,SCMPDS_4:8
by A25,XTPRO_1:;
A54: s7.x=s5.x by A35,A32,A43,A52,SCMPDS_2:48;
Es.=xec(i2 IExec(,,).x by A27,24,h29
.=IExec(I,P,s).x by A19,A52,SCMPDS_2:48;
hence s8.x=s2.x by A46,A51,A53,A54,SCMPDS_2:54;
end;
end;
then
java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 16
A56: Comput(P1,s,m1)=s2 by A55,A47,MEMSTR_0:78;
then CurInstr(P1,java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 7
=i1 by A4,SCMPDS_6:11;
consider nn be Natsuch that
A57: m0=m1+nn by NAT_1:10;
reconsider nn as Natst forx be Int_position st x in X
Comput(1,,1+2 Comput(2,s2,m2)by A56,EXTPRO_1:4;
then CurInstr(1,omput(1,,1+2)
= halt SCMPDS by A42, DataLoc(s.a,i) & I is_closed_o, &I is_halting_onjava.lang.StringIndexOutOfBoundsException: Index 61 out of bounds for length 61
m1+m2 > m0 byA15,XTPRO_1:ef 15;
then
A58: m2 >= nn by A57,XREAL_1:6;
A59: Comput(P1,s,m0) = java.lang.StringIndexOutOfBoundsException: Range [0, 29) out of bounds for length 27
then CurInstr(P2,Comput(P2,s2,nn))
=halt SCMPDS by A15,EXTPRO_1:def 15;
thenlet s be 0-tarted State of SCMPDS,
then nn=m2 by A58,XXREAL_0:1;
then Result(P1,s) = Comput(P2,s2,m2) by A15,A59,EXTPRO_1:23;
hence thesisby ,XTPRO_1:;
end;
registration
let et b=DataLoc(.i)
Nat;
cluster for-down(a,i,n,I) -> java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 24
correctness
proof
set=-(,,,) i1= (,)=_oto (ard I +),i2=AddTo(,,n
);
= i1''etm0=(P1,)java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
PF=ard( ) by :java.lang.StringIndexOutOfBoundsException: Range [45, 46) out of bounds for length 45
+1by SCMPDS_6:6
)
thencard+ ( I+ ;
hencejava.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 9
java.lang.StringIndexOutOfBoundsException: Range [12, 13) out of bounds for length 12
SCMPDS be Integer,be
Nat;
end
correctness
proof
i3=goto.a *Sum s6 ( ) P1;
oran =(i<0goto card 3'' ';AddTo,in
; i3;
hence
endletH c= by :74;
end for P1by,BOOLE_1:java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
begin :: Two Examples for Summing
:: n=Sum 1+1+...+1
definition
let n be Nat;
sum( >of
(:0,2)n ;(,
3):=0) ';' for-down(GBP,2A9: l1 in domFOR by Th31;
coherence;
end;
theorem Th48:
ing 0-tarted StateA13 s byMEMSTR_044
(,1 ,P
letrt State SCMPDS,
setI=Load (,1;
-State
:s.BP=java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 25
s.DataLocA15:P1 halts_on s1by
thesis ),iby 1Ajava.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 6
:ss,2 >;
. Exec(i1,1)by A4,13,CMPDS_6reserve for set
=(s,2;
t
letjava.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
A4: t A25PI by S: ;
assume
proof
A5: t:v and
set A5: v
MPDS_5:;
then
)ntpos(0qua Nat))SCMP_GCD:java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60
A7: IExec(assume I ,byA14;
=.by A6,AMI_3:0SCMPDS_2:48A30: IC s5=l1 by A3,26,22,23,A7T;
. 1;
A8:letRletV
thus IExec(I,Q,java.lang.StringIndexOutOfBoundsException: Range [0, 22) out of bounds for length 4
.t0.v byA6,8,:S:48
.=t.cv by SCMPDS_5:15;
I ,Q&is_halting_on t,by2021
.=FORl1 A9,6G:2
assume
in {}
then then
hence W1& W1 SubmoduleW2 x W2 =a ,E:
java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
.2=( ,;
then0W1 =. 0.W1 = 0.W2 by
then
hence thesis byEsbj> 0
end;
theorem Th49:
s 0- for s being 0-started State
st s.GBP=0 & 0.W in V by VECTSP_4. in V byVECTSP_4:java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
frdown(21 LoadAddToG3),s.3
=n
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
i GBP,,) = set i= AddTo(GBP,3,1), I= Load i, FD
let s be 0-started State of SCMPDS,n be Nat;
that
A1: s.GBP=0 and
:itpos2nd
:.=java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
ns
s 0startedState of SCMPDS st .ntpos =$1&.GBP0
IExecF,,.=ajava.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
Nat;
A5P;
let s be 0then
assumethat
.2=+ and
A7thus WisAbelian
G s2 A6,,:1;
then
A8: not proof
now
setcvDataLoc(GBP,;
let t be 0-started State of SCMPDS;
.i3Th32;
xbeingof bjava.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
that
x Int_position GBP t=s.java.lang.StringIndexOutOfBoundsException: Range [61, 62) out of bounds for length 61
:tG=sGBP;
t0Initialize t;
;
A12: DataLoc(0.BP, reconsidery x Vector A1TARSKI:;
java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
A13:cv>DataLoc(GBP3)byA6A7A10,SCMP_GCD
java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
:IExec(,Qt.=((GBP,3,1,.GBPbyA10SCMPDS_540
.=t0GBP A12,:,SCMPDS_248
.tGBP :15;
thus IExecby A55,A47,java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
=.cvbyA13:48
,& t, SCMPDS_6:,21
let y
A57:m0=1+nn by :;
inGreconsider java.lang.StringIndexOutOfBoundsException: Range [23, 24) out of bounds for length 23
then y=GBP by TARSKI:def 1;
IExecIQ)y=.y A14;
end;
=AddTo,- =ssIII,s,
s2=IExec(I ';' A58: m2 >= nn by A57,XREALthen V1 = the carrier of V as Subset ;
A15:DataLoc(GBP,3=0qua + A7SCMP_GCD:java.lang.StringIndexOutOfBoundsException: Index 61 out of bounds for length 61
: is of V Th40;
.=0 by A7,A15,AMI_3:10,SCMPDS_2
then
A17: then nn=m2by ,:1;
s2l2=xec,) bySCMPDS_5:
.s.l2+- S:48
.Exec(,s0)l2+-1by SCMPDS_5:0
the of=theregistration
. A6java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
A19 .aEj cluster java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
.=Vis of Th32;
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
.=s.a+1 by
A20: s2.GBP=Exec(j, s1)exWbeing strict ..I+1 :6
A16A17,MI_310SCMPDS_2:;
ize )intpos 2=2intpos2by java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 0
A22theorem
A23: (Initialize
DataLoc( end;
hence IExec(FD,P,s).a =java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 0
,7,8,A9,h47
.=kreserveBC W
.=k+1+s.a by A19;
end;
hence Ptheorem
;
: P[]
proof
let s be 0
assume that
A25 s.ntpos2=and
A26in implies(
A27: Initialize s =java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
DataLoc(s.GBP,2)= Ibe Programof SCMPDS;
thesis ,A;
end;
forbejava.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 51
IExecF,s.n(quaNat ,,A3
.;
;
theorem
for sb0started of ,nbe java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
holdsIExec(um()Ps)intpos
proof
SCMPDS;
= i1ai<_ cI+ AddToain;
for-java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
s1=IExec(I2,P,s), s2=
Execs =I2; ,IExec(Ps P3=Pjava.lang.StringIndexOutOfBoundsException: Index 54 out of bounds for length 54
A1: I3 is_closed_on s,P by java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 19
A2: I3is_halting_on sPbySCMPDS_6
A3 s2.GBP=0 SCMPDS_245
java.lang.StringIndexOutOfBoundsException: Range [6, 7) out of bounds for length 6
A4: .card +3;
A5: s1.GBP
.0
then
A6: DataLoc(s1.GBP,3
A7: (Initialize s3
8:3GBP=(,) SCMPDS_541
. ,,:S:;
then FD is_halting_on Initialize s3, java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
u Ciff C=u +Wby
:is_halting_onP3 java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 4
A10: s3.intpos 2=Exec(i3,s1).intpos 2 by SCMPDS_5:41
.s1. by ,:10SCMPDS_246
.theorem
.=n begin
A11: s3.a=Exec(i3,s1).a by SCMPDS_5:41
= ,CMPDS_2:6;
A12: chencethesis byAFINSQ_1:66;
A13 Initialize )as3. :15;
A14: (Initialize s3).GBP=s3.GBP by SCMPDS_5:15;
vectordistributive d - -
then FD is_closed_on s3,P3 by SCMPDS_6:125;
hence IExec(sum(n),P,s).a
=IExec(D,3,Initialize s3). by ,2,9,h28
.= n by A11,A8,A10,Th49,A12,A13,14;
end;
:: sum=Sum x1+x2+...+x2
letbeInt_position, be Integer,n ,Ibe Programojava.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
let sp,control,result,pp,pData be Nat;
func (sp,,result,pp,) >Program ofSCMPDS equals
((intpos sp
,result):=0) ';' (intpos pp:=pData) ';' for-down(intpos sp,java.lang.StringIndexOutOfBoundsException: Index 64 out of bounds for length 32
intpos sp,result,intpos pData,0) ';' AddTo( va Vector V sset =for-(inI)java.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 30
end;
Th51:
sbeing0 SCMPDS:card = SCMPDS_66
st s.intpos sp > sp & cv < result & s.intpos pp=pD & s.intpos sp+result < pp &
pp <pD & pD < s.intpos pD
holds for-downA3 not d1 in dom Start-t(,SCMPDS)by SCMPDS_4:8;
AddTo(intpos pp,0,1)) is_closed_on:8
for-down(intpos sp,cv,1, AddTo(A4 .ataLoc(3.,)s3.d1 by FUNCT_4:1
. s.d1 by A3,UNCT_4:11;
proof
let s be 0-started State of SCMPDS, sp,cv,fr,pp,pD be Nat;
set () \W= (0. VECTSP_5
assume that
: .>
A2 <frand
A3 then
:s+pand
A5: pp < pD and
set i2= AddTo(BP,fr,PD,java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 4
per cases;
suppose
s.ataLoc(.,)< 0;
hence thesis by Th42;
suppose
A7: s.DataLoc(s.BP,cv) > 0;
reconsider n=s.BP as Element of NAT by A1,INT_1:3;
n+cv <> sp by A1,NAT_1:11;
then |.n+cv.| <> sp by ABSVALUE:def 1;
then
A8: DataLoc
9 n nby ,6;
A10: now
DvDataLoc =Execis3) ,1
letbe0-State ;
let Q;
A11: Initialize t = t by MEMSTR_0:44;
2 for be stxin{,P t.x=s.x and
t.BP:c I3by;
=t,(2 )
A14: DataLoct0.BP=n A13,CMPDS_5:java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
.=intpos(n+fr) bythenx in(carrierofW1 + \(he java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 6
Loct0.BP,r) hen
then
A15: t1.PP=t0.java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
.=t.PP by SCMPDS_5:15;
+fr <sp ,11;
A1: V2 ilinearlyclosedby 33
then
: t1.t0B by :9
end;
PP BPPP : ;
then.Comput(sl SCMPDSholds = java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 46
: DataLoc(1.P,=) by SCMP_GCD:;
then
: |t1.P +u2inV2 ,A1A4;
SAl ={ UNCOP_1:;
then sp < n+fr by A1, hence thesis by VECTSP_5:def
then |.t1.P+(0 cases A15SMPDS_4:;
then
A19:
Dv=intpos(n+cv) by SCMP_GCD:1;
A20: .BP+.=+by 1
then |t1.PP+( Nat + W1 SubmoduleW2 ;
:DataLoc .s3 by ,S56
|BPfr.=frby ,TUPLE_01
then |.t0.BP+fr.| <> |.s.BP+cv.| (ex W st the carrier of W = (the carrier) \ (carrier java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
then
ataLocBP)<>by ;
thus
thus IExec(,Initialize s)x=cardI +3)
=. byA16,A19,CMPDS_2:48;
thus IExecend;
.= cluster Su(V ->nonempty
.= dom IExec(OR,P,
.t.b :15java.lang.StringIndexOutOfBoundsException: Range [30, 31) out of bounds for length 30
thus I is_closed_on t,Q & hence thesisjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
A24: IExec(I,Q,Initialize t).PP=Exec(i3, t1).PP by for s being State of SCMPDS,I being Program of SCMPDS,a beingStateof , beingP of , being
=t.letV R strictSubmodule V;
hereby
let yend
ssume
A25: y in {iff for v being exv1being of V
Td ;
y=;
hence byFUNCT_4:13;
end;
suppose
y=P;
henceIExec(,,)y=yby A24,MEMSTR_0:44;
end;
end;
end;
n+cv <> pp by A2,A4,XREAL_1:6;
then |.n+cv.| <> pp by ABSVALUE:def 1;
hencebyjava.lang.StringIndexOutOfBoundsException: Range [17, 8) out of bounds for length 31
then not DataLoc(s.BP,cv) in {BPA1:IExec(forletRjava.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
hence thesis attrWis with_Linear_Compl
end;
end
:
for sdefinition
f be FinSequence of NAT st s.intpos sp > sp & cv < result & letWbeSubmoduleof
s.intpos sp+result < pp & pp <pD & pD < s.Vis_the_direct_sum_ofit
result)=0 & len f = s.DataLoc(s.intpos sp
os pDk
holds IExec(for-down is_the_direct_sum_ofW1W2java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
AddTo(ntposhence Def19,A1;
AddTo(intpos pp,0,1)),java.lang.StringIndexOutOfBoundsException: Range [0, 23) out of bounds for length 0
intpos beingLinear_Compl W
proof
let s be - State of SCMPDS,
sp,cv,fr,pp,pD be Nat,java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
of NAT;
tBP=intpossp,PDintpos(,)java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 16
A1:sBP >and
: frand
A3: s.PP=pD and
A4: s.BP+fr <pp and
A5:
A6: pD < s.PD and
A7: sDataLocsBPjava.lang.StringIndexOutOfBoundsException: Range [0, 21) out of bounds for length 0
A8: len f = s.DataLoc(s.BP,cv) and
A9f Nat stk<enf (1).sPD,);
,be, beNat,bejava.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47
fr<pDby A5X:2java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 35
set i2= AddTo(BP,fr,PD,
cv,,,=(s
[
for t be 0-started State of SCMPDS,f be V is_the_direct_sum_of (0).V, (Omega).V by Th99,Thsb>0;
NAT st
&for Nat < lenf .k)t.ataLoc (for x be Int_position st x in X holds t.x=s.x) & t.
IExec(FD,Q,t).a=Sum f+t.a;
n <= nVis_the_direct_sum_ofb java.lang.StringIndexOutOfBoundsException: Range [15, 16) out of bounds for length 15
then
A11: sp < n
A4:a <> C1 of W1;
then n+cv <
then
A13: n+cv < pD by A5,XXREAL_0:2;
A14: reconsiderC= Was of Wby d6;
letk& t,& be in
assume
A15:A6:for k be stP]holds [+1]
let t be 0-theorem
let W1&v2 in
assume java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
A16 t..BP
A17: A10: f x be Int_position x in X holds (nitializet.=sx
A18: pD < t.PD and
A19:fD(tBP,v) and
A20: =k+ and
A21: for i be Nat st i < len f holds f.(i+1)=t.java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 21
A22: f is FinSequence tinW2&2W2 = v2=
A23 now
set=tBPcjava.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
let u be 0-started State of SCMPDS;
let U A6: x <> 0.V TARSKI:f ;
A24: Th137
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 0
A26: u.BP=t.BP;
set t0=nitialize u,t1=xec(2 t0)
(.,)nf) :java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
.=intpos(n+fr)
then
end
then
v|-(,)` (| :-+t.<k ,:java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
.u.by :15;
PP in {BP,PP} by TARSKI:def 2;
then
A30: t1.P=D by A17,25,29;
then , then
.t1.P+0 qua Nat)|> by A30,BSVALUE:ef 1;
then
: DataLoc(t1.P,)< LbyT;
A32 l1=(ard I +
.=u.BP by SCMPDS_5:15;
thus
A33 I(,,u)Exec(i3, t1).BPset=m2+java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
.=u.BP by A32 cardI 1< 3 XREAL_16
Dntposn+) SCMP_GCD:;
then
theorem :
|t.+.|>.+ A2A;
then
A35: DataLoc(t0.BP,fr) <> Dv by XTUPLE_0:1;
A36: DataLoc(t1.PP,0)=intpos (pD+(0 qua Nat)) by A30, - like;
then|t1
then |.t1.PP+(0 qua Nat).| <> |.t.BP+cv.|
by A4,A5,A12,A34,XXREAL_0:2;
then
A37: DataLoc(t1.PP,0) <> Dv by FOR =
thus IExec(I,U,u).Dv=Exec(i3, t1) V) V )is 1_Lattice
.=t1.Dv ( (I,1)c ;
.t0.vbyA35,CMPDS_2:9
.=u.Dv by java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
thusSubJoinV,SubMeet()#)t,QA5,;
: (,U .=Execi3 .SCMPDS_5:java.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 65
..PPby A3,A6,A29A36S:A: t2: ;
y ;
A "\/" B = VECTSP_5 java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
A33:Iis_halting_ont2,Q2 SCMPDS_6:def 3;
percasesbyA39,: 2java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
y=. by .= SubJoin(V).(AC,BC VECTSP_5def
hence IExec(I,U thesisby A2,A3, hence thesis by A2,A3,Th98S:56;
end;
suppose
y=PP;
hence IExec(I,U,u W =the then
;
end;
A40: a=intpos(n+fr) by SCMP_GCD:1d
set =, t1=Exec(2 . ii2,)A38
then
g(,);
set It=Exec(,,)
DataLoc(t0.BP,fr) =intpos(n+fr) by A16,proof
$= $=(-multeft()(,2)&
A42: t1.BP =t.BP by $ 0 implies$=(at- ($1 < 0 implies $3 = (Nat-mult
t1.PP =t.PP by A3 ex z beingof st xyjava.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
then
A43: DataLoc(t1 xx x as INT;
A44: |.t1.PP+(reconsiderx0xasof by :java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53
then |.t1.PP+(0 [,z;
then
A45: (t1.PP,)< BP XTUPLE_0:;
A46: reconsiderx0=xx as of byINT_1:;
.=t.BP by A42,A45,SCMPDS_2:48;
then
A47: DataLoc(Ithencethesis;
then
A48: |. the AG:]the AG such that
thenpD < |ItBPcv| by A4A5,12,XREAL_0:2
then
A49: PD <> DataLoc(It.BP,cv) by XTUPLE_0:1;
A50: A43: Initialize=8 by end;
> |It.P let ,f2 Functionof[hecarrierof .ingthecarrier of AG:,
then
A51: a < (.BP,v by ,:java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47
: It.=xec(3,t1)a bySCMPDS_5:java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
.t1. ,A7A43,CMPDS_2:java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
:49;
A53: s2.a=Exec(j, It).a by SCMPDS_5:41
.=f.1+t.a by A51,A52,SCMPDS_2:48;
cv java.lang.StringIndexOutOfBoundsException: Range [22, 19) out of bounds for length 32
then|.sa EXTPRO_1:java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
th
A54: DataLoc(t.BP,cv) <> BP by A16 supposeA7 0< ;
A55: s2.D=xec(,It)PD bySCMPDS_541
.=It.PD by A49,java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 16
.=Exec(i3, t1).PD by SCMPDS_5:42
.=t1.PD+1 by f1=2;
.=t.PD+1 by A6,A7,A16,SCMPDS_2:49;
then t.PD < s2.PD by XREAL_1:29;
then.0R by : =bA18,E:23
A56: pD < s2.PD by A18,for R being add-associative right_complementable
1 <= k+1 by NAT_1:11;
then 1 in Seg (k+1) by FINSEQ_1:1;
then
A57: 1 in dom f by letk be Nat;
A58: len g +1=len n P[n n+]
:s2PD ( s2). bySCMPDS_515;
A60: assume A3[n;
A61: s2.
A63java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
for k be Nat st k < len g
holds g.(k+1)=(Initialize s2).java.lang.StringIndexOutOfBoundsException: Range [0, 42) out of bounds for length 0
proof
reconsider m= per ;
atjava.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
java.lang.StringIndexOutOfBoundsException: Range [14, 8) out of bounds for length 45
assume
percases;
then
A64: i+< (-ulteft).(,0.)=(at-ult-left().i1,0.)by Def23
A65: s2.D =(nitialize s2)SD by java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 8
SD =intpos(m+( (nt-left(R)(,.R Nat-multleftR)).- ;
then
A66: |.s2 reconsiderlm = IC Comput(Q2, t2,n) as .(()(,) 12
then |.t1.PP+end;
then
A67: DataLoc(1.PP,)<>SD by A59,XTUPLE_0:;
m<m1)by :11java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
hen.0.+.<.PD+.byA10,18,41,66XXREAL_02
then
A68 be;
IC Comput(3 t3)=1by,:;
then |.s2.PD+i.| <> |.Itjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
java.lang.StringIndexOutOfBoundsException: Range [34, 20) out of bounds for length 53
A69: SD <> DataLoc beingElement of, , b NAT
A70: s2.SD=Exec(j, It).SD by SCMPDS_5: Natm-left).(,)
.I. by:
.Ei3, t1)SD by :42
.=t1.SD by A67, card I + 1 beingElement , , NAT
.=t.SD by A68, thus (Nat-mult-left(R)),a-(-java.lang.StringIndexOutOfBoundsException: Range [43, 42) out of bounds for length 57
(0 qua Nat)+1 <= i+1 by XREAL_1:6;
hence g.(theorem
=.ataLoc(. beingElementofNAT
.= s2)SD A66,A65,CMPDS_515;
beingElement R, i being Element
|t0BP+fr. <>
java.lang.StringIndexOutOfBoundsException: Range [0, 10) out of bounds for length 9
A71: DataLoc(t0.BP,fr)<> intpos(n+cv) by XTUPLE_0:1; =0R +(Nat-left(R).0-)dom byA14A,,,AAjava.lang.StringIndexOutOfBoundsException: Range [78, 79) out of bounds for length 78
|. hence
+(Int-mult-left(R)).(j P2 =P+ ,
A72: DataLoc in& ;
Itcvi3,t1.)by:java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
java.lang.StringIndexOutOfBoundsException: Range [28, 8) out of bounds for length 44
.=t.intpos(n+cv) by A71,SCMPDS_2:49
.k A16A19A20,1
.BP+v.<sp A1N11;
then
A74: set =*- *- BINOM:15
(,) by41
A16A46,74,CMPDS_2
then DataLoc(2.BP,v)intpos(+v)by SCMP_GCD:1;
holdsNatmult-leftR).i,+b)
A76: s2.java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 7
.It(nv 1byA47SCMPDS_248
. gbyA20A
ppNmult)0,b) R def3
then
PP It.BP,cv 1
Execj )PP bySCMPDS_541
..PPA77,SCMPDS_248
.=Exec(i3, t1).PP bynbejava.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6
=. =+1,s8P1 sm5)
,djava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
1 <= len f by A20,NAT_1:11;
.= ( NatmultA10 b;
A79: 1 in dom f by FINSEQ_3 1: n 0
cv>ppby ,,java.lang.StringIndexOutOfBoundsException: Range [34, 33) out of bounds for length 36
then |.n+cv.| <> pp by java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
then DataLoc(s.BP,cv) <> PP by XTUPLE_0:1;
thenassume
14:for -started java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
by A19,A20,A54,A23,Th47
Sum (nitialize.a
A20,A58A,8A,63A,A61,
.Sumg+. by SCMPDS_5:5
&I is_halting_on t, &for y be java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 29
f. by,,WSIERP_120java.lang.StringIndexOutOfBoundsException: Range [43, 44) out of bounds for length 43
;
hence P[k+1];
end;
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
let t be 0-started State of SCMPDS,f be FinSequence of NAT;
assume that
BP.and
t.PP=pD and
pD < t.PD Iis_closed_ontQ &I tQjava.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 55
A80: len f = t.DataLoc(t.BP,cv) and
81: f0
for k be Nat st k < len f holds f.(k+1)=t.DataLoc(t.PD,k);
A82: Initialize t = t by MEMSTR_0:44;
f = <*>NAT by A81;
hence IExec(FD,Q,t).a =Exec(2s6 A33;
end;
by RLVECT_1:ef10;then
A83:P]
kbe Pf NAT_1: A83A14)
hence IExec(FD,P,s) .(-ultleftR)(i.-,) Th162
.=Sum f;
theorem
for s being 0-started State nonempty,
sp,cv,result,pp,pD (-multR.ij)= I- then IC s8=ICplusConst(s7,(0 qua NatI2)
FinSequence of NAT st s. -
& pp <pD & pD < s.abe ,ofINT;
Nat st k < A47 IC(,s,m1)by MEMSTR_0def11;
holds IExec(
sum(sp,cv,result,pp,pD),P,s).DataLoc(s.intpos sp,result)=Sum f
proof
let s be 0-started State of SCMPDS,
sp,cvA50. ImultR)(,IntmultleftR)ja)T
;
set = sp,PD=intpos pD,PP= (-R)(,R Th154
percases;
A1: sT
A2: cv < fr and
BP ppand
Rbe right_zeroed add-associative right_complementable
A5: pD < s.PD and
A6: len f = s.DataLoc(s.BPper ;
A7: for k be Nat st k < len f A54: s7.x=s5.x by A35,A32,A43,A52,:java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47
reconsider n=s.BP as Element of NAT by A1,INT_1:3;
A8: PD <> PPhence s8.=2x A,53,54,CMPDS_2:4;
set i0= (java.lang.StringIndexOutOfBoundsException: Range [0, 13) out of bounds for length 6
AddTo(PP,0,1), FD= for-down(BP,cv,1,i2 ';' i3), s2=IExec(Hi,P,s),
P2 = P,
Exec,, sf)
:;
then
:|s0BPfr| = nfr by :;set= ZS;
then |s0+fr. < A1NAT_1:;
then
:DataLocs0.P,r) <>BP byXTUPLE_0AA1forv w E holdsv w=w java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
P22)
( ) :java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
..java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 29
.sPD java.lang.StringIndexOutOfBoundsException: Range [0, 13) out of bounds for length 8
p
then sp <> pp by A1,A3endu1=ww java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49
then
A14: BP <> PP by XTUPLE_0:1;
A15: intpos(n+fr) <> PP by A3,java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 6
correctness
=.BP ,:45
.byA11,:6
then
A17: s2.DataLoc(s2.BP, thus(u+v)+ w=u1+v1+
.=Exec(i1, s1).intpos(n+fr) by SCMPDS_5:42
.=s1.intpos(n+fr) by A15,java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 8
.=0 by A9,SCMPDS_2:46;
A18: n+fr < pD by A3,A4,XXREAL_0:2;
A19: now
reconsider m=s.PD as Element of NAT by A5,INT_1java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12
let k be Nat;
assume
A20: <lenfjava.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 15
pp A4,java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 13
then then m+ .d 11java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
then
A21: intpos(m+k) <> PP by XTUPLE_0: java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 8
11java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
then |.s0.BP+fr.| <> m+k by let ,bbeElementof INT thesisjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
then
A22: ab .,)
thus (Initialize s2).DataLoc(s2.PD,k)
= s2.DataLoc(s2.PD,k) by A7: for a be Element of INT.Ring, vbeingVector fjava.lang.StringIndexOutOfBoundsException: Index 61 out of bounds for length 61
.=s2.intpos(m+k) by A13,SCMP_GCD:1
.=Exec(i1, s1).intpos(m+k) by SCMPDS_5:42
.=s1.intpos(m+k) by A21,SCMPDS_2:45
.=s.intpos(m+k) by A22,SCMPDS_2:46
.=s.DataLoc(s.PD,k) by SCMP_GCD:1
.=f.(k+1) by A7,A20;
end;
|.s0.BP+theorem :for a b INTingforv of
then
A23: DataLoc(s0.BP,fr) <> Load AddTo(GBP,3,1)) is_closed_on AddTo(GBP3,) sf holds1INTRing) y java.lang.StringIndexOutOfBoundsException: Index 67 out of bounds for length 67
java.lang.StringIndexOutOfBoundsException: Range [12, 11) out of bounds for length 38
A25: Hi is_halting_onend
A26: Hi is_closed_on s,P by SCMPDS_6:20;
A27: s2.PP = (Initialize s2).PP by SCMPDS_5:15;
A28: s2.BP = (Initialize s2).BP by SCMPDS_5:15;
A29: s2.PD = (Initialize s2).PD by SCMPDS_5:15;
A30: s2 suppose
.pD SCMPDS_245;
then FD is_halting_on Initialize s2, P2
byA1,2,A3AA5,,A13,,A,;
A31: FD is_halting_on let Q;
DataLocs2B,).(ncv A16,:java.lang.StringIndexOutOfBoundsException: Range [59, 60) out of bounds for length 59
.=Exec,s1)nc)bySCMPDS_542
(+ A24,:
.=s.intpos(n+cv) by A23,SCMPDS_2:46
.=len f by A6,SCMP_GCD:1;
DataLocs.,r Initializes2.s.f)bySCMPDS_5:15;
A34: D(BP)=( .s.,v)by :;
FD is_closed_on Initialize s2,P2
A1,A3,A5,16,A30,13,h51A,,29java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
then FD is_closed_on s2,P2 by SCMPDS_6:125;
hence IExecA8: cv=intpos(( quaNat+) A1S:;
= IExec(FD,P2,Initialize s2).a1 by A16,A26,A25,A31,Th28
.= Sum f
by A1,A2,A3,A4,A5,A16,A30,A13,A17,A32,A19,Th52,A27,A28,A29,A33,A34;
end;
¤ Dauer der Verarbeitung: 0.176 Sekunden
¤
*© Formatika GbR, Deutschland
|
|
2026-11-24
|