let R be Ring; :: thesis: for a, c being Data-Location of R

for i1 being Nat

for s being State of (SCM R) holds

( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

let a, c be Data-Location of R; :: thesis: for i1 being Nat

for s being State of (SCM R) holds

( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

let i1 be Nat; :: thesis: for s being State of (SCM R) holds

( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

let s be State of (SCM R); :: thesis: ( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

A1: the_Values_of (SCM R) = (SCM-VAL R) * SCM-OK by Lm1;

reconsider S = s as SCM-State of R by A1, CARD_3:107;

reconsider I = a =0_goto i1 as Element of SCM-Instr R by Def1;

reconsider i = 7 as Element of Segm 8 by NAT_1:44;

A2: ( a is Element of Data-Locations & i1 is Element of NAT ) by Th1, ORDINAL1:def 12;

A3: Exec ((a =0_goto i1),s) = SCM-Exec-Res (I,S) by Th10

.= SCM-Chg (S,(IFEQ ((S . (I cond_address)),(0. R),(I cjump_address),((IC S) + 1)))) by A2, AMI_3:27, SCMRING1:def 14 ;

A4: I = [i,<*i1*>,<*a*>] ;

thus ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) :: thesis: ( ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

thus ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) :: thesis: (Exec ((a =0_goto i1),s)) . c = s . c

hence (Exec ((a =0_goto i1),s)) . c = s . c by A3, AMI_3:27, SCMRING1:8; :: thesis: verum

for i1 being Nat

for s being State of (SCM R) holds

( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

let a, c be Data-Location of R; :: thesis: for i1 being Nat

for s being State of (SCM R) holds

( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

let i1 be Nat; :: thesis: for s being State of (SCM R) holds

( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

let s be State of (SCM R); :: thesis: ( ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) & ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

A1: the_Values_of (SCM R) = (SCM-VAL R) * SCM-OK by Lm1;

reconsider S = s as SCM-State of R by A1, CARD_3:107;

reconsider I = a =0_goto i1 as Element of SCM-Instr R by Def1;

reconsider i = 7 as Element of Segm 8 by NAT_1:44;

A2: ( a is Element of Data-Locations & i1 is Element of NAT ) by Th1, ORDINAL1:def 12;

A3: Exec ((a =0_goto i1),s) = SCM-Exec-Res (I,S) by Th10

.= SCM-Chg (S,(IFEQ ((S . (I cond_address)),(0. R),(I cjump_address),((IC S) + 1)))) by A2, AMI_3:27, SCMRING1:def 14 ;

A4: I = [i,<*i1*>,<*a*>] ;

thus ( s . a = 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = i1 ) :: thesis: ( ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) & (Exec ((a =0_goto i1),s)) . c = s . c )

proof

A6:
IC s = IC S
by Def1;
assume
s . a = 0. R
; :: thesis: (Exec ((a =0_goto i1),s)) . (IC ) = i1

then A5: S . (I cond_address) = 0. R by A4, A2, AMI_3:27, SCMRINGI:3;

thus (Exec ((a =0_goto i1),s)) . (IC ) = (Exec ((a =0_goto i1),s)) . NAT by Def1

.= IFEQ ((S . (I cond_address)),(0. R),(I cjump_address),((IC S) + 1)) by A3, SCMRING1:7

.= I cjump_address by A5, FUNCOP_1:def 8

.= i1 by A4, A2, AMI_3:27, SCMRINGI:3 ; :: thesis: verum

end;then A5: S . (I cond_address) = 0. R by A4, A2, AMI_3:27, SCMRINGI:3;

thus (Exec ((a =0_goto i1),s)) . (IC ) = (Exec ((a =0_goto i1),s)) . NAT by Def1

.= IFEQ ((S . (I cond_address)),(0. R),(I cjump_address),((IC S) + 1)) by A3, SCMRING1:7

.= I cjump_address by A5, FUNCOP_1:def 8

.= i1 by A4, A2, AMI_3:27, SCMRINGI:3 ; :: thesis: verum

thus ( s . a <> 0. R implies (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1 ) :: thesis: (Exec ((a =0_goto i1),s)) . c = s . c

proof

c is Element of Data-Locations
by Th1;
assume
s . a <> 0. R
; :: thesis: (Exec ((a =0_goto i1),s)) . (IC ) = (IC s) + 1

then A7: S . (I cond_address) <> 0. R by A4, A2, AMI_3:27, SCMRINGI:3;

thus (Exec ((a =0_goto i1),s)) . (IC ) = (Exec ((a =0_goto i1),s)) . NAT by Def1

.= IFEQ ((S . (I cond_address)),(0. R),(I cjump_address),((IC S) + 1)) by A3, SCMRING1:7

.= (IC s) + 1 by A6, A7, FUNCOP_1:def 8 ; :: thesis: verum

end;then A7: S . (I cond_address) <> 0. R by A4, A2, AMI_3:27, SCMRINGI:3;

thus (Exec ((a =0_goto i1),s)) . (IC ) = (Exec ((a =0_goto i1),s)) . NAT by Def1

.= IFEQ ((S . (I cond_address)),(0. R),(I cjump_address),((IC S) + 1)) by A3, SCMRING1:7

.= (IC s) + 1 by A6, A7, FUNCOP_1:def 8 ; :: thesis: verum

hence (Exec ((a =0_goto i1),s)) . c = s . c by A3, AMI_3:27, SCMRING1:8; :: thesis: verum