:: TURING_1 semantic presentation begin definition let A, B be non empty set ; let f be Function of A,B; let g be PartFunc of A,B; :: original: +* redefine funcf +* g -> Function of A,B; coherence f +* g is Function of A,B proof A1: now__::_thesis:_for_x_being_set_st_x_in_A_holds_ (f_+*_g)_._x_in_B let x be set ; ::_thesis: ( x in A implies (f +* g) . b1 in B ) assume A2: x in A ; ::_thesis: (f +* g) . b1 in B percases ( x in dom g or not x in dom g ) ; supposeA3: x in dom g ; ::_thesis: (f +* g) . b1 in B then (f +* g) . x = g . x by FUNCT_4:13; hence (f +* g) . x in B by A3, PARTFUN1:4; ::_thesis: verum end; suppose not x in dom g ; ::_thesis: (f +* g) . b1 in B then (f +* g) . x = f . x by FUNCT_4:11; hence (f +* g) . x in B by A2, FUNCT_2:5; ::_thesis: verum end; end; end; A4: ( dom f = A & dom g c= A ) by FUNCT_2:def_1, RELAT_1:def_18; dom (f +* g) = (dom f) \/ (dom g) by FUNCT_4:def_1 .= A by A4, XBOOLE_1:12 ; hence f +* g is Function of A,B by A1, FUNCT_2:3; ::_thesis: verum end; end; definition let X, Y be non empty set ; let a be Element of X; let b be Element of Y; :: original: .--> redefine funca .--> b -> PartFunc of X,Y; coherence a .--> b is PartFunc of X,Y proof set p = a .--> b; ( dom (a .--> b) = {a} & rng (a .--> b) = {b} ) by FUNCOP_1:8, FUNCOP_1:13; hence a .--> b is PartFunc of X,Y by RELSET_1:7; ::_thesis: verum end; end; notation let n be Nat; synonym SegM n for succ n; end; definition let n be Nat; :: original: SegM redefine func SegM n -> Subset of NAT equals :: TURING_1:def 1 { k where k is Element of NAT : k <= n } ; coherence SegM n is Subset of NAT proof SegM n in NAT by ORDINAL1:def_12; then SegM n c= NAT by ORDINAL1:5; hence SegM n is Subset of NAT ; ::_thesis: verum end; compatibility for b1 being Subset of NAT holds ( b1 = SegM n iff b1 = { k where k is Element of NAT : k <= n } ) by NAT_1:54; end; :: deftheorem defines SegM TURING_1:def_1_:_ for n being Nat holds SegM n = { k where k is Element of NAT : k <= n } ; registration let n be Nat; cluster SegM n -> non empty finite ; coherence ( SegM n is finite & not SegM n is empty ) proof n is Element of NAT by ORDINAL1:def_12; hence SegM n is finite by CQC_THE1:2; ::_thesis: not SegM n is empty thus not SegM n is empty ; ::_thesis: verum end; end; theorem Th1: :: TURING_1:1 for k, n being Element of NAT holds ( k in SegM n iff k <= n ) proof let k, n be Element of NAT ; ::_thesis: ( k in SegM n iff k <= n ) thus ( k in SegM n implies k <= n ) ::_thesis: ( k <= n implies k in SegM n ) proof assume k in SegM n ; ::_thesis: k <= n then ex i being Element of NAT st ( k = i & i <= n ) ; hence k <= n ; ::_thesis: verum end; thus ( k <= n implies k in SegM n ) ; ::_thesis: verum end; theorem Th2: :: TURING_1:2 for f being Function for x, y, z, u, v being set st u <> x holds (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] proof let f be Function; ::_thesis: for x, y, z, u, v being set st u <> x holds (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] let x, y, z, u, v be set ; ::_thesis: ( u <> x implies (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] ) set p = [x,y] .--> z; assume u <> x ; ::_thesis: (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] then A1: [u,v] <> [x,y] by XTUPLE_0:1; dom ([x,y] .--> z) = {[x,y]} by FUNCOP_1:13; then not [u,v] in dom ([x,y] .--> z) by A1, TARSKI:def_1; hence (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] by FUNCT_4:11; ::_thesis: verum end; theorem Th3: :: TURING_1:3 for f being Function for x, y, z, u, v being set st v <> y holds (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] proof let f be Function; ::_thesis: for x, y, z, u, v being set st v <> y holds (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] let x, y, z, u, v be set ; ::_thesis: ( v <> y implies (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] ) set p = [x,y] .--> z; assume v <> y ; ::_thesis: (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] then A1: [u,v] <> [x,y] by XTUPLE_0:1; dom ([x,y] .--> z) = {[x,y]} by FUNCOP_1:13; then not [u,v] in dom ([x,y] .--> z) by A1, TARSKI:def_1; hence (f +* ([x,y] .--> z)) . [u,v] = f . [u,v] by FUNCT_4:11; ::_thesis: verum end; notation let i be Nat; let f be FinSequence; synonym Prefix (f,i) for f | i; end; definition let i be Element of NAT ; let f be FinSequence of NAT ; :: original: Prefix redefine func Prefix (f,i) -> FinSequence of INT ; coherence Prefix (f,i) is FinSequence of INT proof set p = f | (Seg i); now__::_thesis:_for_j_being_Nat_st_j_in_dom_(f_|_(Seg_i))_holds_ (f_|_(Seg_i))_._j_in_INT let j be Nat; ::_thesis: ( j in dom (f | (Seg i)) implies (f | (Seg i)) . j in INT ) assume A1: j in dom (f | (Seg i)) ; ::_thesis: (f | (Seg i)) . j in INT then j in dom f by RELAT_1:57; then A2: f . j in NAT by FINSEQ_2:11; (f | (Seg i)) . j = f . j by A1, FUNCT_1:47; hence (f | (Seg i)) . j in INT by A2, NUMBERS:17; ::_thesis: verum end; hence Prefix (f,i) is FinSequence of INT by FINSEQ_2:12; ::_thesis: verum end; end; theorem Th4: :: TURING_1:4 for x1, x2 being Element of NAT holds ( Sum (Prefix (<*x1,x2*>,1)) = x1 & Sum (Prefix (<*x1,x2*>,2)) = x1 + x2 ) proof let x1, x2 be Element of NAT ; ::_thesis: ( Sum (Prefix (<*x1,x2*>,1)) = x1 & Sum (Prefix (<*x1,x2*>,2)) = x1 + x2 ) reconsider y1 = x1 as Element of INT by INT_1:def_2; thus Sum (Prefix (<*x1,x2*>,1)) = Sum <*y1*> by FINSEQ_6:3 .= x1 by FINSOP_1:11 ; ::_thesis: Sum (Prefix (<*x1,x2*>,2)) = x1 + x2 reconsider y2 = x2 as Element of INT by INT_1:def_2; len <*x1,x2*> = 2 by FINSEQ_1:44; hence Sum (Prefix (<*x1,x2*>,2)) = Sum <*y1,y2*> by FINSEQ_3:49 .= x1 + x2 by RVSUM_1:77 ; ::_thesis: verum end; theorem Th5: :: TURING_1:5 for x1, x2, x3 being Element of NAT holds ( Sum (Prefix (<*x1,x2,x3*>,1)) = x1 & Sum (Prefix (<*x1,x2,x3*>,2)) = x1 + x2 & Sum (Prefix (<*x1,x2,x3*>,3)) = (x1 + x2) + x3 ) proof let x1, x2, x3 be Element of NAT ; ::_thesis: ( Sum (Prefix (<*x1,x2,x3*>,1)) = x1 & Sum (Prefix (<*x1,x2,x3*>,2)) = x1 + x2 & Sum (Prefix (<*x1,x2,x3*>,3)) = (x1 + x2) + x3 ) reconsider y1 = x1 as Element of INT by INT_1:def_2; thus Sum (Prefix (<*x1,x2,x3*>,1)) = Sum <*y1*> by FINSEQ_6:4 .= x1 by FINSOP_1:11 ; ::_thesis: ( Sum (Prefix (<*x1,x2,x3*>,2)) = x1 + x2 & Sum (Prefix (<*x1,x2,x3*>,3)) = (x1 + x2) + x3 ) reconsider y2 = x2 as Element of INT by INT_1:def_2; thus Sum (Prefix (<*x1,x2,x3*>,2)) = Sum <*y1,y2*> by FINSEQ_6:5 .= x1 + x2 by RVSUM_1:77 ; ::_thesis: Sum (Prefix (<*x1,x2,x3*>,3)) = (x1 + x2) + x3 reconsider y3 = x3 as Element of INT by INT_1:def_2; len <*x1,x2,x3*> = 3 by FINSEQ_1:45; hence Sum (Prefix (<*x1,x2,x3*>,3)) = Sum <*y1,y2,y3*> by FINSEQ_3:49 .= (x1 + x2) + x3 by RVSUM_1:78 ; ::_thesis: verum end; begin definition attrc1 is strict ; struct TuringStr -> ; aggrTuringStr(# Symbols, FStates, Tran, InitS, AcceptS #) -> TuringStr ; sel Symbols c1 -> non empty finite set ; sel FStates c1 -> non empty finite set ; sel Tran c1 -> Function of [: the FStates of c1, the Symbols of c1:],[: the FStates of c1, the Symbols of c1,{(- 1),0,1}:]; sel InitS c1 -> Element of the FStates of c1; sel AcceptS c1 -> Element of the FStates of c1; end; definition let T be TuringStr ; mode State of T is Element of the FStates of T; mode Tape of T is Element of Funcs (INT, the Symbols of T); mode Symbol of T is Element of the Symbols of T; end; definition let T be TuringStr ; let t be Tape of T; let h be Integer; let s be Symbol of T; func Tape-Chg (t,h,s) -> Tape of T equals :: TURING_1:def 2 t +* (h .--> s); coherence t +* (h .--> s) is Tape of T proof set X = INT ; set Y = the Symbols of T; A1: ex f being Function st ( t = f & dom f = INT & rng f c= the Symbols of T ) by FUNCT_2:def_2; rng (h .--> s) = {s} by FUNCOP_1:8; then ( rng (t +* (h .--> s)) c= (rng t) \/ (rng (h .--> s)) & (rng t) \/ (rng (h .--> s)) c= the Symbols of T ) by A1, FUNCT_4:17, XBOOLE_1:8; then A2: rng (t +* (h .--> s)) c= the Symbols of T by XBOOLE_1:1; A3: h in INT by INT_1:def_2; dom (t +* (h .--> s)) = (dom t) \/ (dom (h .--> s)) by FUNCT_4:def_1 .= (dom t) \/ {h} by FUNCOP_1:13 .= INT by A1, A3, ZFMISC_1:40 ; hence t +* (h .--> s) is Tape of T by A2, FUNCT_2:def_2; ::_thesis: verum end; end; :: deftheorem defines Tape-Chg TURING_1:def_2_:_ for T being TuringStr for t being Tape of T for h being Integer for s being Symbol of T holds Tape-Chg (t,h,s) = t +* (h .--> s); definition let T be TuringStr ; mode All-State of T is Element of [: the FStates of T,INT,(Funcs (INT, the Symbols of T)):]; mode Tran-Source of T is Element of [: the FStates of T, the Symbols of T:]; mode Tran-Goal of T is Element of [: the FStates of T, the Symbols of T,{(- 1),0,1}:]; end; definition let T be TuringStr ; let g be Tran-Goal of T; func offset g -> Integer equals :: TURING_1:def 3 g `3_3 ; coherence g `3_3 is Integer by ENUMSET1:def_1; end; :: deftheorem defines offset TURING_1:def_3_:_ for T being TuringStr for g being Tran-Goal of T holds offset g = g `3_3 ; definition let T be TuringStr ; let s be All-State of T; func Head s -> Integer equals :: TURING_1:def 4 s `2_3 ; coherence s `2_3 is Integer ; end; :: deftheorem defines Head TURING_1:def_4_:_ for T being TuringStr for s being All-State of T holds Head s = s `2_3 ; definition let T be TuringStr ; let s be All-State of T; func TRAN s -> Tran-Goal of T equals :: TURING_1:def 5 the Tran of T . [(s `1_3),((s `3_3) . (Head s))]; correctness coherence the Tran of T . [(s `1_3),((s `3_3) . (Head s))] is Tran-Goal of T; proof reconsider x = Head s as Element of INT ; the Tran of T . [(s `1_3),((s `3_3) . x)] is Tran-Goal of T ; hence the Tran of T . [(s `1_3),((s `3_3) . (Head s))] is Tran-Goal of T ; ::_thesis: verum end; end; :: deftheorem defines TRAN TURING_1:def_5_:_ for T being TuringStr for s being All-State of T holds TRAN s = the Tran of T . [(s `1_3),((s `3_3) . (Head s))]; definition let T be TuringStr ; let s be All-State of T; func Following s -> All-State of T equals :Def6: :: TURING_1:def 6 [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] if s `1_3 <> the AcceptS of T otherwise s; correctness coherence ( ( s `1_3 <> the AcceptS of T implies [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] is All-State of T ) & ( not s `1_3 <> the AcceptS of T implies s is All-State of T ) ); consistency for b1 being All-State of T holds verum; proof (Head s) + (offset (TRAN s)) in INT by INT_1:def_2; hence ( ( s `1_3 <> the AcceptS of T implies [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] is All-State of T ) & ( not s `1_3 <> the AcceptS of T implies s is All-State of T ) & ( for b1 being All-State of T holds verum ) ) by MCART_1:69; ::_thesis: verum end; end; :: deftheorem Def6 defines Following TURING_1:def_6_:_ for T being TuringStr for s being All-State of T holds ( ( s `1_3 <> the AcceptS of T implies Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] ) & ( not s `1_3 <> the AcceptS of T implies Following s = s ) ); definition let T be TuringStr ; let s be All-State of T; func Computation s -> Function of NAT,[: the FStates of T,INT,(Funcs (INT, the Symbols of T)):] means :Def7: :: TURING_1:def 7 ( it . 0 = s & ( for i being Nat holds it . (i + 1) = Following (it . i) ) ); existence ex b1 being Function of NAT,[: the FStates of T,INT,(Funcs (INT, the Symbols of T)):] st ( b1 . 0 = s & ( for i being Nat holds b1 . (i + 1) = Following (b1 . i) ) ) proof deffunc H1( set , All-State of T) -> All-State of T = Following $2; consider f being Function of NAT,[: the FStates of T,INT,(Funcs (INT, the Symbols of T)):] such that A1: ( f . 0 = s & ( for n being Nat holds f . (n + 1) = H1(n,f . n) ) ) from NAT_1:sch_12(); take f ; ::_thesis: ( f . 0 = s & ( for i being Nat holds f . (i + 1) = Following (f . i) ) ) thus ( f . 0 = s & ( for i being Nat holds f . (i + 1) = Following (f . i) ) ) by A1; ::_thesis: verum end; uniqueness for b1, b2 being Function of NAT,[: the FStates of T,INT,(Funcs (INT, the Symbols of T)):] st b1 . 0 = s & ( for i being Nat holds b1 . (i + 1) = Following (b1 . i) ) & b2 . 0 = s & ( for i being Nat holds b2 . (i + 1) = Following (b2 . i) ) holds b1 = b2 proof deffunc H1( set , All-State of T) -> All-State of T = Following $2; let F1, F2 be Function of NAT,[: the FStates of T,INT,(Funcs (INT, the Symbols of T)):]; ::_thesis: ( F1 . 0 = s & ( for i being Nat holds F1 . (i + 1) = Following (F1 . i) ) & F2 . 0 = s & ( for i being Nat holds F2 . (i + 1) = Following (F2 . i) ) implies F1 = F2 ) assume that A2: F1 . 0 = s and A3: for i being Nat holds F1 . (i + 1) = Following (F1 . i) and A4: F2 . 0 = s and A5: for i being Nat holds F2 . (i + 1) = Following (F2 . i) ; ::_thesis: F1 = F2 A6: for i being Nat holds F1 . (i + 1) = H1(i,F1 . i) by A3; A7: for i being Nat holds F2 . (i + 1) = H1(i,F2 . i) by A5; A8: F2 . 0 = s by A4; A9: F1 . 0 = s by A2; thus F1 = F2 from NAT_1:sch_16(A9, A6, A8, A7); ::_thesis: verum end; end; :: deftheorem Def7 defines Computation TURING_1:def_7_:_ for T being TuringStr for s being All-State of T for b3 being Function of NAT,[: the FStates of T,INT,(Funcs (INT, the Symbols of T)):] holds ( b3 = Computation s iff ( b3 . 0 = s & ( for i being Nat holds b3 . (i + 1) = Following (b3 . i) ) ) ); theorem :: TURING_1:6 for T being TuringStr for s being All-State of T st s `1_3 = the AcceptS of T holds s = Following s by Def6; theorem :: TURING_1:7 for T being TuringStr for s being All-State of T holds (Computation s) . 0 = s by Def7; theorem :: TURING_1:8 for k being Element of NAT for T being TuringStr for s being All-State of T holds (Computation s) . (k + 1) = Following ((Computation s) . k) by Def7; theorem Th9: :: TURING_1:9 for T being TuringStr for s being All-State of T holds (Computation s) . 1 = Following s proof let T be TuringStr ; ::_thesis: for s being All-State of T holds (Computation s) . 1 = Following s let s be All-State of T; ::_thesis: (Computation s) . 1 = Following s (Computation s) . (0 + 1) = Following ((Computation s) . 0) by Def7 .= Following s by Def7 ; hence (Computation s) . 1 = Following s ; ::_thesis: verum end; theorem Th10: :: TURING_1:10 for i, k being Element of NAT for T being TuringStr for s being All-State of T holds (Computation s) . (i + k) = (Computation ((Computation s) . i)) . k proof let i, k be Element of NAT ; ::_thesis: for T being TuringStr for s being All-State of T holds (Computation s) . (i + k) = (Computation ((Computation s) . i)) . k let T be TuringStr ; ::_thesis: for s being All-State of T holds (Computation s) . (i + k) = (Computation ((Computation s) . i)) . k let s be All-State of T; ::_thesis: (Computation s) . (i + k) = (Computation ((Computation s) . i)) . k defpred S1[ Element of NAT ] means (Computation s) . (i + $1) = (Computation ((Computation s) . i)) . $1; A1: for k being Element of NAT st S1[k] holds S1[k + 1] proof let k be Element of NAT ; ::_thesis: ( S1[k] implies S1[k + 1] ) assume A2: (Computation s) . (i + k) = (Computation ((Computation s) . i)) . k ; ::_thesis: S1[k + 1] thus (Computation s) . (i + (k + 1)) = (Computation s) . ((i + k) + 1) .= Following ((Computation s) . (i + k)) by Def7 .= (Computation ((Computation s) . i)) . (k + 1) by A2, Def7 ; ::_thesis: verum end; A3: S1[ 0 ] by Def7; for k being Element of NAT holds S1[k] from NAT_1:sch_1(A3, A1); hence (Computation s) . (i + k) = (Computation ((Computation s) . i)) . k ; ::_thesis: verum end; theorem Th11: :: TURING_1:11 for i, j being Element of NAT for T being TuringStr for s being All-State of T st i <= j & Following ((Computation s) . i) = (Computation s) . i holds (Computation s) . j = (Computation s) . i proof let i, j be Element of NAT ; ::_thesis: for T being TuringStr for s being All-State of T st i <= j & Following ((Computation s) . i) = (Computation s) . i holds (Computation s) . j = (Computation s) . i let T be TuringStr ; ::_thesis: for s being All-State of T st i <= j & Following ((Computation s) . i) = (Computation s) . i holds (Computation s) . j = (Computation s) . i let s be All-State of T; ::_thesis: ( i <= j & Following ((Computation s) . i) = (Computation s) . i implies (Computation s) . j = (Computation s) . i ) assume that A1: i <= j and A2: Following ((Computation s) . i) = (Computation s) . i ; ::_thesis: (Computation s) . j = (Computation s) . i consider k being Nat such that A3: j = i + k by A1, NAT_1:10; defpred S1[ Element of NAT ] means (Computation s) . (i + $1) = (Computation s) . i; A4: for k being Element of NAT st S1[k] holds S1[k + 1] proof let k be Element of NAT ; ::_thesis: ( S1[k] implies S1[k + 1] ) assume A5: (Computation s) . (i + k) = (Computation s) . i ; ::_thesis: S1[k + 1] thus (Computation s) . (i + (k + 1)) = (Computation s) . ((i + k) + 1) .= (Computation s) . i by A2, A5, Def7 ; ::_thesis: verum end; A6: S1[ 0 ] ; A7: for k being Element of NAT holds S1[k] from NAT_1:sch_1(A6, A4); k in NAT by ORDINAL1:def_12; hence (Computation s) . j = (Computation s) . i by A3, A7; ::_thesis: verum end; theorem Th12: :: TURING_1:12 for i, j being Element of NAT for T being TuringStr for s being All-State of T st i <= j & ((Computation s) . i) `1_3 = the AcceptS of T holds (Computation s) . j = (Computation s) . i proof let i, j be Element of NAT ; ::_thesis: for T being TuringStr for s being All-State of T st i <= j & ((Computation s) . i) `1_3 = the AcceptS of T holds (Computation s) . j = (Computation s) . i let T be TuringStr ; ::_thesis: for s being All-State of T st i <= j & ((Computation s) . i) `1_3 = the AcceptS of T holds (Computation s) . j = (Computation s) . i let s be All-State of T; ::_thesis: ( i <= j & ((Computation s) . i) `1_3 = the AcceptS of T implies (Computation s) . j = (Computation s) . i ) assume that A1: i <= j and A2: ((Computation s) . i) `1_3 = the AcceptS of T ; ::_thesis: (Computation s) . j = (Computation s) . i Following ((Computation s) . i) = (Computation s) . i by A2, Def6; hence (Computation s) . j = (Computation s) . i by A1, Th11; ::_thesis: verum end; definition let T be TuringStr ; let s be All-State of T; attrs is Accept-Halt means :Def8: :: TURING_1:def 8 ex k being Element of NAT st ((Computation s) . k) `1_3 = the AcceptS of T; end; :: deftheorem Def8 defines Accept-Halt TURING_1:def_8_:_ for T being TuringStr for s being All-State of T holds ( s is Accept-Halt iff ex k being Element of NAT st ((Computation s) . k) `1_3 = the AcceptS of T ); definition let T be TuringStr ; let s be All-State of T; assume A1: s is Accept-Halt ; func Result s -> All-State of T means :Def9: :: TURING_1:def 9 ex k being Element of NAT st ( it = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ); uniqueness for b1, b2 being All-State of T st ex k being Element of NAT st ( b1 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ) & ex k being Element of NAT st ( b2 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ) holds b1 = b2 proof let s1, s2 be All-State of T; ::_thesis: ( ex k being Element of NAT st ( s1 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ) & ex k being Element of NAT st ( s2 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ) implies s1 = s2 ) given k1 being Element of NAT such that A1: ( s1 = (Computation s) . k1 & ((Computation s) . k1) `1_3 = the AcceptS of T ) ; ::_thesis: ( for k being Element of NAT holds ( not s2 = (Computation s) . k or not ((Computation s) . k) `1_3 = the AcceptS of T ) or s1 = s2 ) given k2 being Element of NAT such that A2: ( s2 = (Computation s) . k2 & ((Computation s) . k2) `1_3 = the AcceptS of T ) ; ::_thesis: s1 = s2 ( k1 <= k2 or k2 <= k1 ) ; hence s1 = s2 by A1, A2, Th12; ::_thesis: verum end; correctness existence ex b1 being All-State of T ex k being Element of NAT st ( b1 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ); proof ex k being Element of NAT st ((Computation s) . k) `1_3 = the AcceptS of T by A1, Def8; hence ex b1 being All-State of T ex k being Element of NAT st ( b1 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ) ; ::_thesis: verum end; end; :: deftheorem Def9 defines Result TURING_1:def_9_:_ for T being TuringStr for s being All-State of T st s is Accept-Halt holds for b3 being All-State of T holds ( b3 = Result s iff ex k being Element of NAT st ( b3 = (Computation s) . k & ((Computation s) . k) `1_3 = the AcceptS of T ) ); theorem Th13: :: TURING_1:13 for T being TuringStr for s being All-State of T st s is Accept-Halt holds ex k being Element of NAT st ( ((Computation s) . k) `1_3 = the AcceptS of T & Result s = (Computation s) . k & ( for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T ) ) proof let T be TuringStr ; ::_thesis: for s being All-State of T st s is Accept-Halt holds ex k being Element of NAT st ( ((Computation s) . k) `1_3 = the AcceptS of T & Result s = (Computation s) . k & ( for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T ) ) let s be All-State of T; ::_thesis: ( s is Accept-Halt implies ex k being Element of NAT st ( ((Computation s) . k) `1_3 = the AcceptS of T & Result s = (Computation s) . k & ( for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T ) ) ) defpred S1[ Nat] means ((Computation s) . $1) `1_3 = the AcceptS of T; assume A1: s is Accept-Halt ; ::_thesis: ex k being Element of NAT st ( ((Computation s) . k) `1_3 = the AcceptS of T & Result s = (Computation s) . k & ( for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T ) ) then ex k being Element of NAT st ((Computation s) . k) `1_3 = the AcceptS of T by Def8; then A2: ex k being Nat st S1[k] ; consider k being Nat such that A3: ( S1[k] & ( for n being Nat st S1[n] holds k <= n ) ) from NAT_1:sch_5(A2); reconsider k = k as Element of NAT by ORDINAL1:def_12; take k ; ::_thesis: ( ((Computation s) . k) `1_3 = the AcceptS of T & Result s = (Computation s) . k & ( for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T ) ) thus S1[k] by A3; ::_thesis: ( Result s = (Computation s) . k & ( for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T ) ) thus Result s = (Computation s) . k by A1, A3, Def9; ::_thesis: for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T thus for i being Element of NAT st i < k holds ((Computation s) . i) `1_3 <> the AcceptS of T by A3; ::_thesis: verum end; definition let A, B be non empty set ; let y be set ; assume A1: y in B ; func id (A,B,y) -> Function of A,[:A,B:] means :: TURING_1:def 10 for x being Element of A holds it . x = [x,y]; existence ex b1 being Function of A,[:A,B:] st for x being Element of A holds b1 . x = [x,y] proof reconsider yy = y as Element of B by A1; deffunc H1( Element of A) -> Element of [:A,B:] = [$1,yy]; consider f being Function of A,[:A,B:] such that A1: for x being Element of A holds f . x = H1(x) from FUNCT_2:sch_4(); take f ; ::_thesis: for x being Element of A holds f . x = [x,y] thus for x being Element of A holds f . x = [x,y] by A1; ::_thesis: verum end; uniqueness for b1, b2 being Function of A,[:A,B:] st ( for x being Element of A holds b1 . x = [x,y] ) & ( for x being Element of A holds b2 . x = [x,y] ) holds b1 = b2 proof deffunc H1( Element of A) -> set = [$1,y]; thus for f1, f2 being Function of A,[:A,B:] st ( for x being Element of A holds f1 . x = H1(x) ) & ( for x being Element of A holds f2 . x = H1(x) ) holds f1 = f2 from BINOP_2:sch_1(); ::_thesis: verum end; end; :: deftheorem defines id TURING_1:def_10_:_ for A, B being non empty set for y being set st y in B holds for b4 being Function of A,[:A,B:] holds ( b4 = id (A,B,y) iff for x being Element of A holds b4 . x = [x,y] ); definition func Sum_Tran -> Function of [:(SegM 5),{0,1}:],[:(SegM 5),{0,1},{(- 1),0,1}:] equals :: TURING_1:def 11 (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) +* ([4,0] .--> [5,0,0]); coherence (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) +* ([4,0] .--> [5,0,0]) is Function of [:(SegM 5),{0,1}:],[:(SegM 5),{0,1},{(- 1),0,1}:] proof reconsider p0 = 0 , p1 = 1, p2 = 2, p3 = 3, p4 = 4, p5 = 5 as Element of SegM 5 by Th1; set A = [:(SegM 5),{0,1}:]; set B = {(- 1),0,1}; set C = [:(SegM 5),{0,1},{(- 1),0,1}:]; reconsider b0 = 0 , b1 = 1 as Element of {0,1} by TARSKI:def_2; reconsider L = - 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; reconsider h = 0 , R = 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; [:(SegM 5),{0,1},{(- 1),0,1}:] = [:[:(SegM 5),{0,1}:],{(- 1),0,1}:] by ZFMISC_1:def_3; then reconsider OP = id ([:(SegM 5),{0,1}:],{(- 1),0,1},h) as Function of [:(SegM 5),{0,1}:],[:(SegM 5),{0,1},{(- 1),0,1}:] ; (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) +* ([4,0] .--> [5,0,0]) = ((((((((OP +* ([p0,b0] .--> [p0,b0,R])) +* ([p0,b1] .--> [p1,b0,R])) +* ([p1,b1] .--> [p1,b1,R])) +* ([p1,b0] .--> [p2,b1,R])) +* ([p2,b1] .--> [p2,b1,R])) +* ([p2,b0] .--> [p3,b0,L])) +* ([p3,b1] .--> [p4,b0,L])) +* ([p4,b1] .--> [p4,b1,L])) +* ([p4,b0] .--> [p5,b0,h]) ; hence (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) +* ([4,0] .--> [5,0,0]) is Function of [:(SegM 5),{0,1}:],[:(SegM 5),{0,1},{(- 1),0,1}:] ; ::_thesis: verum end; end; :: deftheorem defines Sum_Tran TURING_1:def_11_:_ Sum_Tran = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) +* ([4,0] .--> [5,0,0]); theorem Th14: :: TURING_1:14 ( Sum_Tran . [0,0] = [0,0,1] & Sum_Tran . [0,1] = [1,0,1] & Sum_Tran . [1,1] = [1,1,1] & Sum_Tran . [1,0] = [2,1,1] & Sum_Tran . [2,1] = [2,1,1] & Sum_Tran . [2,0] = [3,0,(- 1)] & Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) proof set x = [0,1]; set x1 = [0,0]; set p1 = [0,0] .--> [0,0,1]; set p2 = [0,1] .--> [1,0,1]; set p3 = [1,1] .--> [1,1,1]; set p4 = [1,0] .--> [2,1,1]; set p5 = [2,1] .--> [2,1,1]; set p6 = [2,0] .--> [3,0,(- 1)]; set p7 = [3,1] .--> [4,0,(- 1)]; set p8 = [4,1] .--> [4,1,(- 1)]; set f = id ([:(SegM 5),{0,1}:],{(- 1),0,1},0); thus Sum_Tran . [0,0] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [0,0] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [0,0] by Th2 .= (((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [0,0] by Th2 .= ((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) . [0,0] by Th2 .= (((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [0,0] by Th2 .= ((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) . [0,0] by Th2 .= (((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) . [0,0] by Th2 .= ((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) . [0,0] by Th3 .= [0,0,1] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [0,1] = [1,0,1] & Sum_Tran . [1,1] = [1,1,1] & Sum_Tran . [1,0] = [2,1,1] & Sum_Tran . [2,1] = [2,1,1] & Sum_Tran . [2,0] = [3,0,(- 1)] & Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) thus Sum_Tran . [0,1] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [0,1] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [0,1] by Th2 .= (((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [0,1] by Th2 .= ((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) . [0,1] by Th2 .= (((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [0,1] by Th2 .= ((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) . [0,1] by Th2 .= (((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) . [0,1] by Th2 .= [1,0,1] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [1,1] = [1,1,1] & Sum_Tran . [1,0] = [2,1,1] & Sum_Tran . [2,1] = [2,1,1] & Sum_Tran . [2,0] = [3,0,(- 1)] & Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) set x = [1,1]; thus Sum_Tran . [1,1] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [1,1] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [1,1] by Th2 .= (((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [1,1] by Th2 .= ((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) . [1,1] by Th2 .= (((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [1,1] by Th2 .= ((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) . [1,1] by Th3 .= [1,1,1] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [1,0] = [2,1,1] & Sum_Tran . [2,1] = [2,1,1] & Sum_Tran . [2,0] = [3,0,(- 1)] & Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) set x = [1,0]; thus Sum_Tran . [1,0] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [1,0] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [1,0] by Th2 .= (((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [1,0] by Th2 .= ((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) . [1,0] by Th2 .= (((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [1,0] by Th2 .= [2,1,1] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [2,1] = [2,1,1] & Sum_Tran . [2,0] = [3,0,(- 1)] & Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) set x = [2,1]; thus Sum_Tran . [2,1] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [2,1] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [2,1] by Th2 .= (((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [2,1] by Th2 .= ((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) . [2,1] by Th3 .= [2,1,1] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [2,0] = [3,0,(- 1)] & Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) set x = [2,0]; thus Sum_Tran . [2,0] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [2,0] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [2,0] by Th2 .= (((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [2,0] by Th2 .= [3,0,(- 1)] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [3,1] = [4,0,(- 1)] & Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) set x = [3,1]; thus Sum_Tran . [3,1] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [3,1] by Th2 .= ((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) . [3,1] by Th2 .= [4,0,(- 1)] by FUNCT_7:94 ; ::_thesis: ( Sum_Tran . [4,1] = [4,1,(- 1)] & Sum_Tran . [4,0] = [5,0,0] ) set x = [4,1]; thus Sum_Tran . [4,1] = (((((((((id ([:(SegM 5),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [0,0,1])) +* ([0,1] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,0,(- 1)])) +* ([4,1] .--> [4,1,(- 1)])) . [4,1] by Th3 .= [4,1,(- 1)] by FUNCT_7:94 ; ::_thesis: Sum_Tran . [4,0] = [5,0,0] thus Sum_Tran . [4,0] = [5,0,0] by FUNCT_7:94; ::_thesis: verum end; definition let T be TuringStr ; let t be Tape of T; let i, j be Integer; predt is_1_between i,j means :Def12: :: TURING_1:def 12 ( t . i = 0 & t . j = 0 & ( for k being Integer st i < k & k < j holds t . k = 1 ) ); end; :: deftheorem Def12 defines is_1_between TURING_1:def_12_:_ for T being TuringStr for t being Tape of T for i, j being Integer holds ( t is_1_between i,j iff ( t . i = 0 & t . j = 0 & ( for k being Integer st i < k & k < j holds t . k = 1 ) ) ); definition let f be FinSequence of NAT ; let T be TuringStr ; let t be Tape of T; predt storeData f means :Def13: :: TURING_1:def 13 for i being Element of NAT st 1 <= i & i < len f holds t is_1_between (Sum (Prefix (f,i))) + (2 * (i - 1)),(Sum (Prefix (f,(i + 1)))) + (2 * i); end; :: deftheorem Def13 defines storeData TURING_1:def_13_:_ for f being FinSequence of NAT for T being TuringStr for t being Tape of T holds ( t storeData f iff for i being Element of NAT st 1 <= i & i < len f holds t is_1_between (Sum (Prefix (f,i))) + (2 * (i - 1)),(Sum (Prefix (f,(i + 1)))) + (2 * i) ); theorem Th15: :: TURING_1:15 for T being TuringStr for t being Tape of T for s, n being Element of NAT st t storeData <*s,n*> holds t is_1_between s,(s + n) + 2 proof let T be TuringStr ; ::_thesis: for t being Tape of T for s, n being Element of NAT st t storeData <*s,n*> holds t is_1_between s,(s + n) + 2 let t be Tape of T; ::_thesis: for s, n being Element of NAT st t storeData <*s,n*> holds t is_1_between s,(s + n) + 2 let s, n be Element of NAT ; ::_thesis: ( t storeData <*s,n*> implies t is_1_between s,(s + n) + 2 ) set f = <*s,n*>; assume A1: t storeData <*s,n*> ; ::_thesis: t is_1_between s,(s + n) + 2 A2: len <*s,n*> = 2 by FINSEQ_1:44; ( (Sum (Prefix (<*s,n*>,1))) + (2 * (1 - 1)) = s & (Sum (Prefix (<*s,n*>,(1 + 1)))) + (2 * 1) = (s + n) + 2 ) by Th4; hence t is_1_between s,(s + n) + 2 by A1, A2, Def13; ::_thesis: verum end; theorem Th16: :: TURING_1:16 for T being TuringStr for t being Tape of T for s, n being Element of NAT st t is_1_between s,(s + n) + 2 holds t storeData <*s,n*> proof let T be TuringStr ; ::_thesis: for t being Tape of T for s, n being Element of NAT st t is_1_between s,(s + n) + 2 holds t storeData <*s,n*> let t be Tape of T; ::_thesis: for s, n being Element of NAT st t is_1_between s,(s + n) + 2 holds t storeData <*s,n*> let s, n be Element of NAT ; ::_thesis: ( t is_1_between s,(s + n) + 2 implies t storeData <*s,n*> ) set f = <*s,n*>; assume A1: t is_1_between s,(s + n) + 2 ; ::_thesis: t storeData <*s,n*> A2: (Sum (Prefix (<*s,n*>,(1 + 1)))) + (2 * 1) = (s + n) + 2 by Th4; now__::_thesis:_for_i_being_Element_of_NAT_st_1_<=_i_&_i_<_len_<*s,n*>_holds_ t_is_1_between_(Sum_(Prefix_(<*s,n*>,i)))_+_(2_*_(i_-_1)),(Sum_(Prefix_(<*s,n*>,(i_+_1))))_+_(2_*_i) let i be Element of NAT ; ::_thesis: ( 1 <= i & i < len <*s,n*> implies t is_1_between (Sum (Prefix (<*s,n*>,i))) + (2 * (i - 1)),(Sum (Prefix (<*s,n*>,(i + 1)))) + (2 * i) ) assume that A3: 1 <= i and A4: i < len <*s,n*> ; ::_thesis: t is_1_between (Sum (Prefix (<*s,n*>,i))) + (2 * (i - 1)),(Sum (Prefix (<*s,n*>,(i + 1)))) + (2 * i) len <*s,n*> = 2 by FINSEQ_1:44; then i + 1 <= 1 + 1 by A4, INT_1:7; then i <= 1 by XREAL_1:6; then i = 1 by A3, XXREAL_0:1; hence t is_1_between (Sum (Prefix (<*s,n*>,i))) + (2 * (i - 1)),(Sum (Prefix (<*s,n*>,(i + 1)))) + (2 * i) by A1, A2, Th4; ::_thesis: verum end; hence t storeData <*s,n*> by Def13; ::_thesis: verum end; theorem Th17: :: TURING_1:17 for T being TuringStr for t being Tape of T for s, n being Element of NAT st t storeData <*s,n*> holds ( t . s = 0 & t . ((s + n) + 2) = 0 & ( for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 ) ) proof let T be TuringStr ; ::_thesis: for t being Tape of T for s, n being Element of NAT st t storeData <*s,n*> holds ( t . s = 0 & t . ((s + n) + 2) = 0 & ( for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 ) ) let t be Tape of T; ::_thesis: for s, n being Element of NAT st t storeData <*s,n*> holds ( t . s = 0 & t . ((s + n) + 2) = 0 & ( for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 ) ) let s, n be Element of NAT ; ::_thesis: ( t storeData <*s,n*> implies ( t . s = 0 & t . ((s + n) + 2) = 0 & ( for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 ) ) ) assume t storeData <*s,n*> ; ::_thesis: ( t . s = 0 & t . ((s + n) + 2) = 0 & ( for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 ) ) then A1: t is_1_between s,(s + n) + 2 by Th15; hence ( t . s = 0 & t . ((s + n) + 2) = 0 ) by Def12; ::_thesis: for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 thus for i being Integer st s < i & i < (s + n) + 2 holds t . i = 1 by A1, Def12; ::_thesis: verum end; theorem Th18: :: TURING_1:18 for T being TuringStr for t being Tape of T for s, n1, n2 being Element of NAT st t storeData <*s,n1,n2*> holds ( t is_1_between s,(s + n1) + 2 & t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ) proof let T be TuringStr ; ::_thesis: for t being Tape of T for s, n1, n2 being Element of NAT st t storeData <*s,n1,n2*> holds ( t is_1_between s,(s + n1) + 2 & t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ) let t be Tape of T; ::_thesis: for s, n1, n2 being Element of NAT st t storeData <*s,n1,n2*> holds ( t is_1_between s,(s + n1) + 2 & t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ) let s, n1, n2 be Element of NAT ; ::_thesis: ( t storeData <*s,n1,n2*> implies ( t is_1_between s,(s + n1) + 2 & t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ) ) set f = <*s,n1,n2*>; assume A1: t storeData <*s,n1,n2*> ; ::_thesis: ( t is_1_between s,(s + n1) + 2 & t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ) A2: len <*s,n1,n2*> = 3 by FINSEQ_1:45; ( (Sum (Prefix (<*s,n1,n2*>,1))) + (2 * (1 - 1)) = s & (Sum (Prefix (<*s,n1,n2*>,(1 + 1)))) + (2 * 1) = (s + n1) + 2 ) by Th5; hence t is_1_between s,(s + n1) + 2 by A1, A2, Def13; ::_thesis: t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ( (Sum (Prefix (<*s,n1,n2*>,2))) + (2 * (2 - 1)) = (s + n1) + 2 & (Sum (Prefix (<*s,n1,n2*>,(2 + 1)))) + (2 * 2) = ((s + n1) + n2) + 4 ) by Th5; hence t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 by A1, A2, Def13; ::_thesis: verum end; theorem Th19: :: TURING_1:19 for T being TuringStr for t being Tape of T for s, n1, n2 being Element of NAT st t storeData <*s,n1,n2*> holds ( t . s = 0 & t . ((s + n1) + 2) = 0 & t . (((s + n1) + n2) + 4) = 0 & ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) proof let T be TuringStr ; ::_thesis: for t being Tape of T for s, n1, n2 being Element of NAT st t storeData <*s,n1,n2*> holds ( t . s = 0 & t . ((s + n1) + 2) = 0 & t . (((s + n1) + n2) + 4) = 0 & ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) let t be Tape of T; ::_thesis: for s, n1, n2 being Element of NAT st t storeData <*s,n1,n2*> holds ( t . s = 0 & t . ((s + n1) + 2) = 0 & t . (((s + n1) + n2) + 4) = 0 & ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) let s, n1, n2 be Element of NAT ; ::_thesis: ( t storeData <*s,n1,n2*> implies ( t . s = 0 & t . ((s + n1) + 2) = 0 & t . (((s + n1) + n2) + 4) = 0 & ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) ) assume t storeData <*s,n1,n2*> ; ::_thesis: ( t . s = 0 & t . ((s + n1) + 2) = 0 & t . (((s + n1) + n2) + 4) = 0 & ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) then A1: ( t is_1_between s,(s + n1) + 2 & t is_1_between (s + n1) + 2,((s + n1) + n2) + 4 ) by Th18; hence ( t . s = 0 & t . ((s + n1) + 2) = 0 & t . (((s + n1) + n2) + 4) = 0 ) by Def12; ::_thesis: ( ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) thus ( ( for i being Integer st s < i & i < (s + n1) + 2 holds t . i = 1 ) & ( for i being Integer st (s + n1) + 2 < i & i < ((s + n1) + n2) + 4 holds t . i = 1 ) ) by A1, Def12; ::_thesis: verum end; theorem Th20: :: TURING_1:20 for f being FinSequence of NAT for s being Element of NAT st len f >= 1 holds ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) ) proof let f be FinSequence of NAT ; ::_thesis: for s being Element of NAT st len f >= 1 holds ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) ) let s be Element of NAT ; ::_thesis: ( len f >= 1 implies ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) ) ) set g = <*s*>; set h = <*s*> ^ f; reconsider x1 = s as Element of INT by INT_1:def_2; reconsider x2 = f /. 1 as Element of INT by INT_1:def_2; assume A1: len f >= 1 ; ::_thesis: ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) ) then consider n being Nat such that A2: len f = 1 + n by NAT_1:10; A3: len <*s*> = 1 by FINSEQ_1:39; then Seg 1 = dom <*s*> by FINSEQ_1:def_3; hence Sum (Prefix ((<*s*> ^ f),1)) = Sum <*x1*> by FINSEQ_1:21 .= s by FINSOP_1:11 ; ::_thesis: Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) len (<*s*> ^ f) = 1 + (len f) by A3, FINSEQ_1:22 .= 2 + n by A2 ; then consider p2, q2 being FinSequence of NAT such that A4: len p2 = 2 and len q2 = n and A5: <*s*> ^ f = p2 ^ q2 by FINSEQ_2:23; f /. 1 = f . 1 by A1, FINSEQ_4:15 .= (<*s*> ^ f) . (1 + 1) by A1, A3, FINSEQ_7:3 ; then A6: p2 . 2 = f /. 1 by A4, A5, FINSEQ_1:64; Seg 2 = dom p2 by A4, FINSEQ_1:def_3; then A7: p2 = Prefix ((<*s*> ^ f),2) by A5, FINSEQ_1:21; (<*s*> ^ f) . 1 = s by FINSEQ_1:41; then p2 . 1 = s by A4, A5, FINSEQ_1:64; hence Sum (Prefix ((<*s*> ^ f),2)) = Sum <*x1,x2*> by A4, A7, A6, FINSEQ_1:44 .= s + (f /. 1) by RVSUM_1:77 ; ::_thesis: verum end; theorem Th21: :: TURING_1:21 for f being FinSequence of NAT for s being Element of NAT st len f >= 3 holds ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) & Sum (Prefix ((<*s*> ^ f),3)) = (s + (f /. 1)) + (f /. 2) & Sum (Prefix ((<*s*> ^ f),4)) = ((s + (f /. 1)) + (f /. 2)) + (f /. 3) ) proof let f be FinSequence of NAT ; ::_thesis: for s being Element of NAT st len f >= 3 holds ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) & Sum (Prefix ((<*s*> ^ f),3)) = (s + (f /. 1)) + (f /. 2) & Sum (Prefix ((<*s*> ^ f),4)) = ((s + (f /. 1)) + (f /. 2)) + (f /. 3) ) let s be Element of NAT ; ::_thesis: ( len f >= 3 implies ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) & Sum (Prefix ((<*s*> ^ f),3)) = (s + (f /. 1)) + (f /. 2) & Sum (Prefix ((<*s*> ^ f),4)) = ((s + (f /. 1)) + (f /. 2)) + (f /. 3) ) ) set g = <*s*>; set h = <*s*> ^ f; reconsider x1 = s as Element of INT by INT_1:def_2; reconsider x2 = f /. 1 as Element of INT by INT_1:def_2; reconsider x3 = f /. 2 as Element of INT by INT_1:def_2; reconsider x4 = f /. 3 as Element of INT by INT_1:def_2; assume A1: len f >= 3 ; ::_thesis: ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) & Sum (Prefix ((<*s*> ^ f),3)) = (s + (f /. 1)) + (f /. 2) & Sum (Prefix ((<*s*> ^ f),4)) = ((s + (f /. 1)) + (f /. 2)) + (f /. 3) ) then consider n being Nat such that A2: len f = 3 + n by NAT_1:10; reconsider n = n as Element of NAT by ORDINAL1:def_12; A3: len <*s*> = 1 by FINSEQ_1:39; then A4: len (<*s*> ^ f) = 1 + (len f) by FINSEQ_1:22 .= 4 + n by A2 ; then consider p4, q4 being FinSequence of NAT such that A5: len p4 = 4 and len q4 = n and A6: <*s*> ^ f = p4 ^ q4 by FINSEQ_2:23; f /. 3 = f . 3 by A1, FINSEQ_4:15 .= (<*s*> ^ f) . (1 + 3) by A1, A3, FINSEQ_7:3 ; then A7: p4 . 4 = f /. 3 by A5, A6, FINSEQ_1:64; Seg 4 = dom p4 by A5, FINSEQ_1:def_3; then A8: p4 = Prefix ((<*s*> ^ f),4) by A6, FINSEQ_1:21; A9: 1 <= len f by A1, XXREAL_0:2; hence ( Sum (Prefix ((<*s*> ^ f),1)) = s & Sum (Prefix ((<*s*> ^ f),2)) = s + (f /. 1) ) by Th20; ::_thesis: ( Sum (Prefix ((<*s*> ^ f),3)) = (s + (f /. 1)) + (f /. 2) & Sum (Prefix ((<*s*> ^ f),4)) = ((s + (f /. 1)) + (f /. 2)) + (f /. 3) ) len (<*s*> ^ f) = 3 + (1 + n) by A4; then consider p3, q3 being FinSequence of NAT such that A10: len p3 = 3 and len q3 = 1 + n and A11: <*s*> ^ f = p3 ^ q3 by FINSEQ_2:23; A12: f /. 1 = f . 1 by A9, FINSEQ_4:15 .= (<*s*> ^ f) . (1 + 1) by A9, A3, FINSEQ_7:3 ; then A13: p4 . 2 = f /. 1 by A5, A6, FINSEQ_1:64; A14: 2 <= len f by A1, XXREAL_0:2; then A15: f /. 2 = f . 2 by FINSEQ_4:15 .= (<*s*> ^ f) . (1 + 2) by A3, A14, FINSEQ_7:3 ; then A16: p4 . 3 = f /. 2 by A5, A6, FINSEQ_1:64; A17: p3 . 2 = f /. 1 by A12, A10, A11, FINSEQ_1:64; Seg 3 = dom p3 by A10, FINSEQ_1:def_3; then A18: p3 = Prefix ((<*s*> ^ f),3) by A11, FINSEQ_1:21; A19: p3 . 3 = f /. 2 by A15, A10, A11, FINSEQ_1:64; A20: (<*s*> ^ f) . 1 = s by FINSEQ_1:41; then p3 . 1 = s by A10, A11, FINSEQ_1:64; then p3 = <*s,(f /. 1),(f /. 2)*> by A10, A17, A19, FINSEQ_1:45; hence Sum (Prefix ((<*s*> ^ f),3)) = (s + (f /. 1)) + (f /. 2) by A18, RVSUM_1:78; ::_thesis: Sum (Prefix ((<*s*> ^ f),4)) = ((s + (f /. 1)) + (f /. 2)) + (f /. 3) p4 . 1 = s by A20, A5, A6, FINSEQ_1:64; then p4 = <*s,(f /. 1),(f /. 2),(f /. 3)*> by A5, A13, A16, A7, FINSEQ_4:76; hence Sum (Prefix ((<*s*> ^ f),4)) = ((x1 + x2) + x3) + x4 by A8, RVSUM_1:142 .= ((s + (f /. 1)) + (f /. 2)) + (f /. 3) ; ::_thesis: verum end; theorem Th22: :: TURING_1:22 for T being TuringStr for t being Tape of T for s being Element of NAT for f being FinSequence of NAT st len f >= 1 & t storeData <*s*> ^ f holds t is_1_between s,(s + (f /. 1)) + 2 proof let T be TuringStr ; ::_thesis: for t being Tape of T for s being Element of NAT for f being FinSequence of NAT st len f >= 1 & t storeData <*s*> ^ f holds t is_1_between s,(s + (f /. 1)) + 2 let t be Tape of T; ::_thesis: for s being Element of NAT for f being FinSequence of NAT st len f >= 1 & t storeData <*s*> ^ f holds t is_1_between s,(s + (f /. 1)) + 2 let s be Element of NAT ; ::_thesis: for f being FinSequence of NAT st len f >= 1 & t storeData <*s*> ^ f holds t is_1_between s,(s + (f /. 1)) + 2 let f be FinSequence of NAT ; ::_thesis: ( len f >= 1 & t storeData <*s*> ^ f implies t is_1_between s,(s + (f /. 1)) + 2 ) set g = <*s*> ^ f; assume that A1: len f >= 1 and A2: t storeData <*s*> ^ f ; ::_thesis: t is_1_between s,(s + (f /. 1)) + 2 len <*s*> = 1 by FINSEQ_1:39; then len (<*s*> ^ f) = 1 + (len f) by FINSEQ_1:22; then len (<*s*> ^ f) >= 1 + 1 by A1, XREAL_1:7; then A3: 1 < len (<*s*> ^ f) by XXREAL_0:2; ( (Sum (Prefix ((<*s*> ^ f),1))) + (2 * (1 - 1)) = s & (Sum (Prefix ((<*s*> ^ f),(1 + 1)))) + (2 * 1) = (s + (f /. 1)) + 2 ) by A1, Th20; hence t is_1_between s,(s + (f /. 1)) + 2 by A2, A3, Def13; ::_thesis: verum end; theorem Th23: :: TURING_1:23 for T being TuringStr for t being Tape of T for s being Element of NAT for f being FinSequence of NAT st len f >= 3 & t storeData <*s*> ^ f holds ( t is_1_between s,(s + (f /. 1)) + 2 & t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) proof let T be TuringStr ; ::_thesis: for t being Tape of T for s being Element of NAT for f being FinSequence of NAT st len f >= 3 & t storeData <*s*> ^ f holds ( t is_1_between s,(s + (f /. 1)) + 2 & t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) let t be Tape of T; ::_thesis: for s being Element of NAT for f being FinSequence of NAT st len f >= 3 & t storeData <*s*> ^ f holds ( t is_1_between s,(s + (f /. 1)) + 2 & t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) let s be Element of NAT ; ::_thesis: for f being FinSequence of NAT st len f >= 3 & t storeData <*s*> ^ f holds ( t is_1_between s,(s + (f /. 1)) + 2 & t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) let f be FinSequence of NAT ; ::_thesis: ( len f >= 3 & t storeData <*s*> ^ f implies ( t is_1_between s,(s + (f /. 1)) + 2 & t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) ) set g = <*s*> ^ f; assume that A1: len f >= 3 and A2: t storeData <*s*> ^ f ; ::_thesis: ( t is_1_between s,(s + (f /. 1)) + 2 & t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) thus t is_1_between s,(s + (f /. 1)) + 2 by A1, A2, Th22, XXREAL_0:2; ::_thesis: ( t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 & t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) len <*s*> = 1 by FINSEQ_1:39; then len (<*s*> ^ f) = 1 + (len f) by FINSEQ_1:22; then A3: len (<*s*> ^ f) >= 3 + 1 by A1, XREAL_1:7; then A4: 2 < len (<*s*> ^ f) by XXREAL_0:2; ( (Sum (Prefix ((<*s*> ^ f),2))) + (2 * (2 - 1)) = (s + (f /. 1)) + 2 & (Sum (Prefix ((<*s*> ^ f),(2 + 1)))) + (2 * 2) = ((s + (f /. 1)) + (f /. 2)) + 4 ) by A1, Th21; hence t is_1_between (s + (f /. 1)) + 2,((s + (f /. 1)) + (f /. 2)) + 4 by A2, A4, Def13; ::_thesis: t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 A5: 3 < len (<*s*> ^ f) by A3, XXREAL_0:2; ( (Sum (Prefix ((<*s*> ^ f),3))) + (2 * (3 - 1)) = ((s + (f /. 1)) + (f /. 2)) + 4 & (Sum (Prefix ((<*s*> ^ f),(3 + 1)))) + (2 * 3) = (((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 ) by A1, Th21; hence t is_1_between ((s + (f /. 1)) + (f /. 2)) + 4,(((s + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 by A2, A5, Def13; ::_thesis: verum end; begin definition func SumTuring -> strict TuringStr means :Def14: :: TURING_1:def 14 ( the Symbols of it = {0,1} & the FStates of it = SegM 5 & the Tran of it = Sum_Tran & the InitS of it = 0 & the AcceptS of it = 5 ); existence ex b1 being strict TuringStr st ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 5 & the Tran of b1 = Sum_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 5 ) proof set St = SegM 5; reconsider p0 = 0 , qF = 5 as Element of SegM 5 by Th1; set Sym = {0,1}; take TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) ; ::_thesis: ( the Symbols of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = SegM 5 & the Tran of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = Sum_Tran & the InitS of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = 5 ) thus ( the Symbols of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = SegM 5 & the Tran of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = Sum_Tran & the InitS of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 5),Sum_Tran,p0,qF #) = 5 ) ; ::_thesis: verum end; uniqueness for b1, b2 being strict TuringStr st the Symbols of b1 = {0,1} & the FStates of b1 = SegM 5 & the Tran of b1 = Sum_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 5 & the Symbols of b2 = {0,1} & the FStates of b2 = SegM 5 & the Tran of b2 = Sum_Tran & the InitS of b2 = 0 & the AcceptS of b2 = 5 holds b1 = b2 ; end; :: deftheorem Def14 defines SumTuring TURING_1:def_14_:_ for b1 being strict TuringStr holds ( b1 = SumTuring iff ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 5 & the Tran of b1 = Sum_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 5 ) ); Lm1: for n being Element of NAT st n <= 5 holds n is State of SumTuring proof let n be Element of NAT ; ::_thesis: ( n <= 5 implies n is State of SumTuring ) assume A1: n <= 5 ; ::_thesis: n is State of SumTuring the FStates of SumTuring = SegM 5 by Def14; hence n is State of SumTuring by A1, Th1; ::_thesis: verum end; theorem Th24: :: TURING_1:24 for T being TuringStr for t being Tape of T for h being Integer for s being Symbol of T st t . h = s holds Tape-Chg (t,h,s) = t proof let T be TuringStr ; ::_thesis: for t being Tape of T for h being Integer for s being Symbol of T st t . h = s holds Tape-Chg (t,h,s) = t let t be Tape of T; ::_thesis: for h being Integer for s being Symbol of T st t . h = s holds Tape-Chg (t,h,s) = t let h be Integer; ::_thesis: for s being Symbol of T st t . h = s holds Tape-Chg (t,h,s) = t let s be Symbol of T; ::_thesis: ( t . h = s implies Tape-Chg (t,h,s) = t ) ex f being Function st ( t = f & dom f = INT & rng f c= the Symbols of T ) by FUNCT_2:def_2; then A1: h in dom t by INT_1:def_2; assume t . h = s ; ::_thesis: Tape-Chg (t,h,s) = t hence Tape-Chg (t,h,s) = t by A1, FUNCT_7:96; ::_thesis: verum end; Lm2: ( 0 in the Symbols of SumTuring & 1 in the Symbols of SumTuring ) proof ( 0 in {0,1} & 1 in {0,1} ) by TARSKI:def_2; hence ( 0 in the Symbols of SumTuring & 1 in the Symbols of SumTuring ) by Def14; ::_thesis: verum end; theorem Th25: :: TURING_1:25 for T being TuringStr for s being All-State of T for p, h, t being set st s = [p,h,t] & p <> the AcceptS of T holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] proof let T be TuringStr ; ::_thesis: for s being All-State of T for p, h, t being set st s = [p,h,t] & p <> the AcceptS of T holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] let s be All-State of T; ::_thesis: for p, h, t being set st s = [p,h,t] & p <> the AcceptS of T holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] let p, h, t be set ; ::_thesis: ( s = [p,h,t] & p <> the AcceptS of T implies Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] ) assume that A1: s = [p,h,t] and A2: p <> the AcceptS of T ; ::_thesis: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] s `1_3 = p by A1, MCART_1:64; hence Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] by A2, Def6; ::_thesis: verum end; Lm3: for s being All-State of SumTuring for p, h, t being set st s = [p,h,t] & p <> 5 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] proof let s be All-State of SumTuring; ::_thesis: for p, h, t being set st s = [p,h,t] & p <> 5 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] let p, h, t be set ; ::_thesis: ( s = [p,h,t] & p <> 5 implies Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] ) assume A1: ( s = [p,h,t] & p <> 5 ) ; ::_thesis: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] 5 = the AcceptS of SumTuring by Def14; hence Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] by A1, Th25; ::_thesis: verum end; theorem Th26: :: TURING_1:26 for T being TuringStr for t being Tape of T for h being Integer for s being Symbol of T for i being set holds ( (Tape-Chg (t,h,s)) . h = s & ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) ) proof let tm be TuringStr ; ::_thesis: for t being Tape of tm for h being Integer for s being Symbol of tm for i being set holds ( (Tape-Chg (t,h,s)) . h = s & ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) ) let t be Tape of tm; ::_thesis: for h being Integer for s being Symbol of tm for i being set holds ( (Tape-Chg (t,h,s)) . h = s & ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) ) let h be Integer; ::_thesis: for s being Symbol of tm for i being set holds ( (Tape-Chg (t,h,s)) . h = s & ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) ) let s be Symbol of tm; ::_thesis: for i being set holds ( (Tape-Chg (t,h,s)) . h = s & ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) ) let i be set ; ::_thesis: ( (Tape-Chg (t,h,s)) . h = s & ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) ) set t1 = Tape-Chg (t,h,s); set p = h .--> s; thus (Tape-Chg (t,h,s)) . h = s by FUNCT_7:94; ::_thesis: ( i <> h implies (Tape-Chg (t,h,s)) . i = t . i ) A1: dom (h .--> s) = {h} by FUNCOP_1:13; assume i <> h ; ::_thesis: (Tape-Chg (t,h,s)) . i = t . i then not i in dom (h .--> s) by A1, TARSKI:def_1; hence (Tape-Chg (t,h,s)) . i = t . i by FUNCT_4:11; ::_thesis: verum end; Lm4: for tm being TuringStr for s being All-State of tm for p being State of tm for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds (Computation s) . m = [p,(d + m),t] proof let tm be TuringStr ; ::_thesis: for s being All-State of tm for p being State of tm for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds (Computation s) . m = [p,(d + m),t] let s be All-State of tm; ::_thesis: for p being State of tm for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds (Computation s) . m = [p,(d + m),t] let p be State of tm; ::_thesis: for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds (Computation s) . m = [p,(d + m),t] let h be Element of INT ; ::_thesis: for t being Tape of tm for m, d being Element of NAT st d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds (Computation s) . m = [p,(d + m),t] let t be Tape of tm; ::_thesis: for m, d being Element of NAT st d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds (Computation s) . m = [p,(d + m),t] let m, d be Element of NAT ; ::_thesis: ( d = h & 1 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,1,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) implies (Computation s) . m = [p,(d + m),t] ) assume that A1: d = h and A2: 1 is Symbol of tm and A3: s = [p,h,t] and A4: the Tran of tm . [p,1] = [p,1,1] and A5: p <> the AcceptS of tm and A6: for i being Integer st d <= i & i < d + m holds t . i = 1 ; ::_thesis: (Computation s) . m = [p,(d + m),t] defpred S1[ Element of NAT ] means ( $1 <= m implies (Computation s) . $1 = [p,(d + $1),t] ); A7: for k being Element of NAT st S1[k] holds S1[k + 1] proof let k be Element of NAT ; ::_thesis: ( S1[k] implies S1[k + 1] ) assume A8: S1[k] ; ::_thesis: S1[k + 1] now__::_thesis:_(_k_+_1_<=_m_implies_(Computation_s)_._(k_+_1)_=_[p,(d_+_(k_+_1)),t]_) reconsider T = 1 as Symbol of tm by A2; set dk = d + k; reconsider ik = d + k as Element of INT by INT_1:def_2; set sk = [p,ik,t]; reconsider tt = [p,ik,t] `3_3 as Tape of tm ; assume A9: k + 1 <= m ; ::_thesis: (Computation s) . (k + 1) = [p,(d + (k + 1)),t] then k < m by NAT_1:13; then d + k < d + m by XREAL_1:8; then A10: t . ik = 1 by A6, NAT_1:11; A11: TRAN [p,ik,t] = the Tran of tm . [p,(tt . (Head [p,ik,t]))] .= the Tran of tm . [p,(t . (Head [p,ik,t]))] .= [p,1,1] by A4, A10 ; then A12: offset (TRAN [p,ik,t]) = 1 by MCART_1:64; A13: Tape-Chg (([p,ik,t] `3_3),(Head [p,ik,t]),((TRAN [p,ik,t]) `2_3)) = Tape-Chg (t,(Head [p,ik,t]),((TRAN [p,ik,t]) `2_3)) .= Tape-Chg (t,(d + k),((TRAN [p,ik,t]) `2_3)) .= Tape-Chg (t,(d + k),T) by A11, MCART_1:64 .= t by A10, Th24 ; thus (Computation s) . (k + 1) = Following [p,ik,t] by A8, A9, Def7, NAT_1:13 .= [((TRAN [p,ik,t]) `1_3),((Head [p,ik,t]) + (offset (TRAN [p,ik,t]))),t] by A5, A13, Th25 .= [p,((Head [p,ik,t]) + (offset (TRAN [p,ik,t]))),t] by A11, MCART_1:64 .= [p,((d + k) + 1),t] by A12 .= [p,(d + (k + 1)),t] ; ::_thesis: verum end; hence S1[k + 1] ; ::_thesis: verum end; A14: S1[ 0 ] by A1, A3, Def7; for k being Element of NAT holds S1[k] from NAT_1:sch_1(A14, A7); hence (Computation s) . m = [p,(d + m),t] ; ::_thesis: verum end; theorem Th27: :: TURING_1:27 for s being All-State of SumTuring for t being Tape of SumTuring for head, n1, n2 being Element of NAT st s = [0,head,t] & t storeData <*head,n1,n2*> holds ( s is Accept-Halt & (Result s) `2_3 = 1 + head & (Result s) `3_3 storeData <*(1 + head),(n1 + n2)*> ) proof reconsider F = 0 as Symbol of SumTuring by Lm2; let s be All-State of SumTuring; ::_thesis: for t being Tape of SumTuring for head, n1, n2 being Element of NAT st s = [0,head,t] & t storeData <*head,n1,n2*> holds ( s is Accept-Halt & (Result s) `2_3 = 1 + head & (Result s) `3_3 storeData <*(1 + head),(n1 + n2)*> ) let t be Tape of SumTuring; ::_thesis: for head, n1, n2 being Element of NAT st s = [0,head,t] & t storeData <*head,n1,n2*> holds ( s is Accept-Halt & (Result s) `2_3 = 1 + head & (Result s) `3_3 storeData <*(1 + head),(n1 + n2)*> ) let h, n1, n2 be Element of NAT ; ::_thesis: ( s = [0,h,t] & t storeData <*h,n1,n2*> implies ( s is Accept-Halt & (Result s) `2_3 = 1 + h & (Result s) `3_3 storeData <*(1 + h),(n1 + n2)*> ) ) assume that A1: s = [0,h,t] and A2: t storeData <*h,n1,n2*> ; ::_thesis: ( s is Accept-Halt & (Result s) `2_3 = 1 + h & (Result s) `3_3 storeData <*(1 + h),(n1 + n2)*> ) A3: t . ((h + n1) + 2) = 0 by A2, Th19; set j3 = (((h + n1) + n2) + 4) - 1; reconsider h1 = h + 1 as Element of INT by INT_1:def_2; A4: h < h1 by XREAL_1:29; set t1 = Tape-Chg (t,h1,F); A5: ((h + 1) + 1) + n1 = (h + n1) + 2 ; reconsider p4 = 4 as State of SumTuring by Lm1; reconsider m3 = (((h + n1) + n2) + 4) - 1 as Element of INT by INT_1:def_2; set j2 = ((((h + n1) + n2) + 4) - 1) - 1; reconsider m2 = ((((h + n1) + n2) + 4) - 1) - 1 as Element of INT by INT_1:def_2; set j1 = (n1 + n2) + 1; set Rs = (Computation s) . ((((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) + (((n1 + n2) + 1) + 1)); reconsider p2 = 2 as State of SumTuring by Lm1; reconsider i2 = h1 + 1 as Element of INT by INT_1:def_2; reconsider nk = (h1 + 1) + n1 as Element of INT by INT_1:def_2; set i3 = (((h + 1) + 1) + n1) + 1; reconsider n3 = (((h + 1) + 1) + n1) + 1 as Element of INT by INT_1:def_2; A6: (((((h + n1) + n2) + 4) - 1) - 1) - 1 = h + ((n1 + n2) + 1) ; reconsider T = 1 as Symbol of SumTuring by Lm2; set t2 = Tape-Chg ((Tape-Chg (t,h1,F)),nk,T); A7: ( h1 + 1 <= ((h + 1) + 1) + n1 & h1 < h1 + 1 ) by NAT_1:11, XREAL_1:29; set i4 = ((h + n1) + n2) + 4; reconsider p0 = 0 as State of SumTuring by Lm1; set s1 = [p0,h1,t]; A8: t . h = 0 by A2, Th19; h <= h + n1 by NAT_1:11; then A9: h + 2 <= (h + n1) + 2 by XREAL_1:7; A10: t . (((h + n1) + n2) + 4) = 0 by A2, Th19; h <= h + (n1 + n2) by NAT_1:11; then A11: h + 4 <= ((h + n1) + n2) + 4 by XREAL_1:7; then A12: ( h1 < h + 3 & (h + 4) - 1 <= (((h + n1) + n2) + 4) - 1 ) by XREAL_1:8, XREAL_1:9; A13: h1 < h + 2 by XREAL_1:8; then A14: h1 < (h + n1) + 2 by A9, XXREAL_0:2; A15: t . h = 0 by A2, Th19; A16: ( (Tape-Chg (t,h1,F)) . h = 0 & (Tape-Chg (t,h1,F)) . ((h + n1) + 2) = 0 & (Tape-Chg (t,h1,F)) . (((h + n1) + n2) + 4) = 0 & ( for i being Integer st h1 < i & i < ((h + 1) + 1) + n1 holds (Tape-Chg (t,h1,F)) . i = 1 ) & ( for i being Integer st (h + n1) + 2 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg (t,h1,F)) . i = 1 ) ) proof thus (Tape-Chg (t,h1,F)) . h = 0 by A15, A4, Th26; ::_thesis: ( (Tape-Chg (t,h1,F)) . ((h + n1) + 2) = 0 & (Tape-Chg (t,h1,F)) . (((h + n1) + n2) + 4) = 0 & ( for i being Integer st h1 < i & i < ((h + 1) + 1) + n1 holds (Tape-Chg (t,h1,F)) . i = 1 ) & ( for i being Integer st (h + n1) + 2 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg (t,h1,F)) . i = 1 ) ) thus (Tape-Chg (t,h1,F)) . ((h + n1) + 2) = 0 by A3, A9, A13, Th26; ::_thesis: ( (Tape-Chg (t,h1,F)) . (((h + n1) + n2) + 4) = 0 & ( for i being Integer st h1 < i & i < ((h + 1) + 1) + n1 holds (Tape-Chg (t,h1,F)) . i = 1 ) & ( for i being Integer st (h + n1) + 2 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg (t,h1,F)) . i = 1 ) ) h1 < h + 4 by XREAL_1:8; hence (Tape-Chg (t,h1,F)) . (((h + n1) + n2) + 4) = 0 by A10, A11, Th26; ::_thesis: ( ( for i being Integer st h1 < i & i < ((h + 1) + 1) + n1 holds (Tape-Chg (t,h1,F)) . i = 1 ) & ( for i being Integer st (h + n1) + 2 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg (t,h1,F)) . i = 1 ) ) hereby ::_thesis: for i being Integer st (h + n1) + 2 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg (t,h1,F)) . i = 1 let i be Integer; ::_thesis: ( h1 < i & i < ((h + 1) + 1) + n1 implies (Tape-Chg (t,h1,F)) . i = 1 ) assume that A17: h1 < i and A18: i < ((h + 1) + 1) + n1 ; ::_thesis: (Tape-Chg (t,h1,F)) . i = 1 A19: h < i by A4, A17, XXREAL_0:2; thus (Tape-Chg (t,h1,F)) . i = t . i by A17, Th26 .= 1 by A2, A5, A18, A19, Th19 ; ::_thesis: verum end; hereby ::_thesis: verum let i be Integer; ::_thesis: ( (h + n1) + 2 < i & i < ((h + n1) + n2) + 4 implies (Tape-Chg (t,h1,F)) . i = 1 ) assume that A20: (h + n1) + 2 < i and A21: i < ((h + n1) + n2) + 4 ; ::_thesis: (Tape-Chg (t,h1,F)) . i = 1 thus (Tape-Chg (t,h1,F)) . i = t . i by A14, A20, Th26 .= 1 by A2, A20, A21, Th19 ; ::_thesis: verum end; end; A22: for i being Integer st (h + 1) + 1 <= i & i < ((h + 1) + 1) + n1 holds (Tape-Chg (t,h1,F)) . i = 1 proof let i be Integer; ::_thesis: ( (h + 1) + 1 <= i & i < ((h + 1) + 1) + n1 implies (Tape-Chg (t,h1,F)) . i = 1 ) assume that A23: (h + 1) + 1 <= i and A24: i < ((h + 1) + 1) + n1 ; ::_thesis: (Tape-Chg (t,h1,F)) . i = 1 h1 < h1 + 1 by XREAL_1:29; then h1 < i by A23, XXREAL_0:2; hence (Tape-Chg (t,h1,F)) . i = 1 by A16, A24; ::_thesis: verum end; set t3 = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F); A25: (Tape-Chg (t,h1,F)) . h1 = 0 by Th26; A26: ( (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . h1 = 0 & (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . (((h + n1) + n2) + 4) = 0 & ( for i being Integer st h1 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 ) ) proof thus (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . h1 = 0 by A25, A7, Th26; ::_thesis: ( (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . (((h + n1) + n2) + 4) = 0 & ( for i being Integer st h1 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 ) ) h + n1 <= (h + n1) + n2 by NAT_1:11; then A27: ((h + 1) + 1) + n1 <= ((h + n1) + n2) + 2 by A5, XREAL_1:7; ((h + n1) + n2) + 2 < ((h + n1) + n2) + 4 by XREAL_1:8; hence (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . (((h + n1) + n2) + 4) = 0 by A16, A27, Th26; ::_thesis: for i being Integer st h1 < i & i < ((h + n1) + n2) + 4 holds (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 hereby ::_thesis: verum let i be Integer; ::_thesis: ( h1 < i & i < ((h + n1) + n2) + 4 implies (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . b1 = 1 ) assume that A28: h1 < i and A29: i < ((h + n1) + n2) + 4 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . b1 = 1 percases ( i < ((h + 1) + 1) + n1 or i = ((h + 1) + 1) + n1 or i > ((h + 1) + 1) + n1 ) by XXREAL_0:1; supposeA30: i < ((h + 1) + 1) + n1 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . b1 = 1 hence (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = (Tape-Chg (t,h1,F)) . i by Th26 .= 1 by A16, A28, A30 ; ::_thesis: verum end; suppose i = ((h + 1) + 1) + n1 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . b1 = 1 hence (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 by Th26; ::_thesis: verum end; supposeA31: i > ((h + 1) + 1) + n1 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . b1 = 1 hence (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = (Tape-Chg (t,h1,F)) . i by Th26 .= 1 by A16, A29, A31 ; ::_thesis: verum end; end; end; end; A32: ( (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . h1 = 0 & (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . ((((h + n1) + n2) + 4) - 1) = 0 & ( for i being Integer st h1 < i & i < (((h + n1) + n2) + 4) - 1 holds (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . i = 1 ) ) proof thus (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . h1 = 0 by A26, A12, Th26; ::_thesis: ( (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . ((((h + n1) + n2) + 4) - 1) = 0 & ( for i being Integer st h1 < i & i < (((h + n1) + n2) + 4) - 1 holds (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . i = 1 ) ) thus (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . ((((h + n1) + n2) + 4) - 1) = 0 by Th26; ::_thesis: for i being Integer st h1 < i & i < (((h + n1) + n2) + 4) - 1 holds (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . i = 1 hereby ::_thesis: verum let i be Integer; ::_thesis: ( h1 < i & i < (((h + n1) + n2) + 4) - 1 implies (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . i = 1 ) assume that A33: h1 < i and A34: i < (((h + n1) + n2) + 4) - 1 ; ::_thesis: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . i = 1 A35: i < ((h + n1) + n2) + 4 by A34, XREAL_1:146, XXREAL_0:2; thus (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . i = (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i by A34, Th26 .= 1 by A26, A33, A35 ; ::_thesis: verum end; end; then A36: Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F) is_1_between h1,(h1 + (n1 + n2)) + 2 by Def12; reconsider p3 = 3 as State of SumTuring by Lm1; set sm = [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]; reconsider n4 = ((h + n1) + n2) + 4 as Element of INT by INT_1:def_2; set sp2 = [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]; set sp3 = [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]; reconsider p1 = 1 as State of SumTuring by Lm1; set s2 = [p1,i2,(Tape-Chg (t,h1,F))]; set sn = [p1,nk,(Tape-Chg (t,h1,F))]; reconsider sn3 = [p1,nk,(Tape-Chg (t,h1,F))] `3_3 as Tape of SumTuring ; A37: TRAN [p1,nk,(Tape-Chg (t,h1,F))] = Sum_Tran . [([p1,nk,(Tape-Chg (t,h1,F))] `1_3),(sn3 . (Head [p1,nk,(Tape-Chg (t,h1,F))]))] by Def14 .= Sum_Tran . [p1,(sn3 . (Head [p1,nk,(Tape-Chg (t,h1,F))]))] .= Sum_Tran . [p1,((Tape-Chg (t,h1,F)) . (Head [p1,nk,(Tape-Chg (t,h1,F))]))] .= [2,1,1] by A16, Th14 ; then A38: offset (TRAN [p1,nk,(Tape-Chg (t,h1,F))]) = 1 by MCART_1:64; reconsider sn3 = [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] `3_3 as Tape of SumTuring ; A39: TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] = Sum_Tran . [([p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] `1_3),(sn3 . (Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))] by Def14 .= Sum_Tran . [p2,(sn3 . (Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))] .= Sum_Tran . [p2,((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . (Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))] .= [3,0,(- 1)] by A26, Th14 ; then A40: offset (TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) = - 1 by MCART_1:64; Tape-Chg (([p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] `3_3),(Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]),((TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),(Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]),((TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),(((h + n1) + n2) + 4),((TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),(((h + n1) + n2) + 4),F) by A39, MCART_1:64 .= Tape-Chg ((Tape-Chg (t,h1,F)),nk,T) by A26, Th24 ; then A41: Following [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] = [((TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `1_3),((Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) + (offset (TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))),(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by Lm3 .= [3,((Head [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) + (offset (TRAN [p2,n4,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))),(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by A39, MCART_1:64 .= [3,((((h + n1) + n2) + 4) - 1),(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by A40 ; Tape-Chg (([p1,nk,(Tape-Chg (t,h1,F))] `3_3),(Head [p1,nk,(Tape-Chg (t,h1,F))]),((TRAN [p1,nk,(Tape-Chg (t,h1,F))]) `2_3)) = Tape-Chg ((Tape-Chg (t,h1,F)),(Head [p1,nk,(Tape-Chg (t,h1,F))]),((TRAN [p1,nk,(Tape-Chg (t,h1,F))]) `2_3)) .= Tape-Chg ((Tape-Chg (t,h1,F)),nk,((TRAN [p1,nk,(Tape-Chg (t,h1,F))]) `2_3)) .= Tape-Chg ((Tape-Chg (t,h1,F)),nk,T) by A37, MCART_1:64 ; then A42: Following [p1,nk,(Tape-Chg (t,h1,F))] = [((TRAN [p1,nk,(Tape-Chg (t,h1,F))]) `1_3),((Head [p1,nk,(Tape-Chg (t,h1,F))]) + (offset (TRAN [p1,nk,(Tape-Chg (t,h1,F))]))),(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by Lm3 .= [2,((Head [p1,nk,(Tape-Chg (t,h1,F))]) + (offset (TRAN [p1,nk,(Tape-Chg (t,h1,F))]))),(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by A37, MCART_1:64 .= [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by A38 ; reconsider s3 = s `3_3 as Tape of SumTuring ; A43: TRAN s = Sum_Tran . [(s `1_3),(s3 . (Head s))] by Def14 .= Sum_Tran . [0,(s3 . (Head s))] by A1, MCART_1:64 .= Sum_Tran . [0,(t . (Head s))] by A1, MCART_1:64 .= Sum_Tran . [0,(t . h)] by A1, MCART_1:64 .= [0,0,1] by A2, Th14, Th19 ; then A44: offset (TRAN s) = 1 by MCART_1:64; A45: h1 < (h1 + 1) + n1 by A7, XXREAL_0:2; A46: for i being Integer st (((h + 1) + 1) + n1) + 1 <= i & i < ((((h + 1) + 1) + n1) + 1) + (n2 + 1) holds (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 proof let i be Integer; ::_thesis: ( (((h + 1) + 1) + n1) + 1 <= i & i < ((((h + 1) + 1) + n1) + 1) + (n2 + 1) implies (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 ) assume that A47: (((h + 1) + 1) + n1) + 1 <= i and A48: i < ((((h + 1) + 1) + n1) + 1) + (n2 + 1) ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 nk < (((h + 1) + 1) + n1) + 1 by XREAL_1:29; then h1 < (((h + 1) + 1) + n1) + 1 by A45, XXREAL_0:2; then h1 < i by A47, XXREAL_0:2; hence (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . i = 1 by A26, A48; ::_thesis: verum end; set sp5 = [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]; set sp4 = [p4,m2,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]; defpred S1[ Element of NAT ] means ( h + $1 < ((((h + n1) + n2) + 4) - 1) - 1 implies (Computation [p4,m2,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) . $1 = [4,((((((h + n1) + n2) + 4) - 1) - 1) - $1),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] ); ( the Tran of SumTuring . [p2,1] = [p2,1,1] & p2 <> the AcceptS of SumTuring ) by Def14, Th14; then A49: (Computation [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) . (n2 + 1) = [2,(((h + n1) + n2) + 4),(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] by A46, Lm4; h1 < (((h + n1) + n2) + 4) - 1 by A12, XXREAL_0:2; then A50: (Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . ((((h + n1) + n2) + 4) - 1) = 1 by A26, XREAL_1:146; reconsider sn3 = [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] `3_3 as Tape of SumTuring ; A51: TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] = Sum_Tran . [([p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] `1_3),(sn3 . (Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))] by Def14 .= Sum_Tran . [p3,(sn3 . (Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))] .= Sum_Tran . [p3,((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)) . (Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))] .= [4,0,(- 1)] by A50, Th14 ; then A52: offset (TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) = - 1 by MCART_1:64; A53: for k being Element of NAT st S1[k] holds S1[k + 1] proof let k be Element of NAT ; ::_thesis: ( S1[k] implies S1[k + 1] ) assume A54: S1[k] ; ::_thesis: S1[k + 1] now__::_thesis:_(_h_+_(k_+_1)_<_((((h_+_n1)_+_n2)_+_4)_-_1)_-_1_implies_(Computation_[p4,m2,(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,F)),nk,T)),((((h_+_n1)_+_n2)_+_4)_-_1),F))])_._(k_+_1)_=_[4,((((((h_+_n1)_+_n2)_+_4)_-_1)_-_1)_-_(k_+_1)),(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,F)),nk,T)),((((h_+_n1)_+_n2)_+_4)_-_1),F))]_) reconsider ik = (((((h + n1) + n2) + 4) - 1) - 1) - k as Element of INT by INT_1:def_2; set k3 = (((((h + n1) + n2) + 4) - 1) - 1) - k; set sk = [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]; reconsider tt = [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] `3_3 as Tape of SumTuring ; assume A55: h + (k + 1) < ((((h + n1) + n2) + 4) - 1) - 1 ; ::_thesis: (Computation [p4,m2,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) . (k + 1) = [4,((((((h + n1) + n2) + 4) - 1) - 1) - (k + 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] then h1 + k < (((((h + n1) + n2) + 4) - 1) - 1) + 0 ; then A56: h1 - 0 < (((((h + n1) + n2) + 4) - 1) - 1) - k by XREAL_1:21; h1 >= 0 by NAT_1:2; then reconsider ii = (((((h + n1) + n2) + 4) - 1) - 1) - k as Element of NAT by A56, INT_1:3, XXREAL_0:2; ((((h + n1) + n2) + 4) - 1) - 1 <= (((((h + n1) + n2) + 4) - 1) - 1) + k by INT_1:6; then (((((h + n1) + n2) + 4) - 1) - 1) - k <= ((((h + n1) + n2) + 4) - 1) - 1 by XREAL_1:20; then (((((h + n1) + n2) + 4) - 1) - 1) - k < (((h + n1) + n2) + 4) - 1 by XREAL_1:146, XXREAL_0:2; then A57: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . ii = 1 by A32, A56; A58: TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] = Sum_Tran . [([p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] `1_3),(tt . (Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))] by Def14 .= Sum_Tran . [p4,(tt . (Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))] .= Sum_Tran . [p4,((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . (Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))] .= [4,1,(- 1)] by A57, Th14 ; then A59: offset (TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) = - 1 by MCART_1:64; A60: Tape-Chg (([p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] `3_3),(Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]),((TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)),(Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]),((TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)),((((((h + n1) + n2) + 4) - 1) - 1) - k),((TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)),((((((h + n1) + n2) + 4) - 1) - 1) - k),T) by A58, MCART_1:64 .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F) by A57, Th24 ; h + k < (h + k) + 1 by XREAL_1:29; hence (Computation [p4,m2,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) . (k + 1) = Following [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A54, A55, Def7, XXREAL_0:2 .= [((TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `1_3),((Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) + (offset (TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A60, Lm3 .= [4,((Head [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) + (offset (TRAN [p4,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A58, MCART_1:64 .= [4,(((((((h + n1) + n2) + 4) - 1) - 1) - k) + (- 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A59 .= [4,((((((h + n1) + n2) + 4) - 1) - 1) - (k + 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] ; ::_thesis: verum end; hence S1[k + 1] ; ::_thesis: verum end; A61: S1[ 0 ] by Def7; for k being Element of NAT holds S1[k] from NAT_1:sch_1(A61, A53); then A62: (Computation [p4,m2,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) . ((n1 + n2) + 1) = [4,((((((h + n1) + n2) + 4) - 1) - 1) - ((n1 + n2) + 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A6, XREAL_1:146 .= [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] ; reconsider s3 = [p0,h1,t] `3_3 as Tape of SumTuring ; A63: TRAN [p0,h1,t] = Sum_Tran . [([p0,h1,t] `1_3),(s3 . (Head [p0,h1,t]))] by Def14 .= Sum_Tran . [p0,(s3 . (Head [p0,h1,t]))] .= Sum_Tran . [p0,(t . (Head [p0,h1,t]))] .= Sum_Tran . [0,(t . h1)] .= [1,0,1] by A2, A4, A14, Th14, Th19 ; then A64: offset (TRAN [p0,h1,t]) = 1 by MCART_1:64; Tape-Chg (([p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] `3_3),(Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]),((TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),(Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]),((TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),((TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F) by A51, MCART_1:64 ; then A65: Following [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))] = [((TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) `1_3),((Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) + (offset (TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by Lm3 .= [4,((Head [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]) + (offset (TRAN [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A51, MCART_1:64 .= [p4,m2,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A52 ; A66: now__::_thesis:_Following_[p4,h1,(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,F)),nk,T)),((((h_+_n1)_+_n2)_+_4)_-_1),F))]_=_[5,(h1_+_0),(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,F)),nk,T)),((((h_+_n1)_+_n2)_+_4)_-_1),F))] reconsider tt = [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] `3_3 as Tape of SumTuring ; A67: TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] = Sum_Tran . [([p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] `1_3),(tt . (Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))] by Def14 .= Sum_Tran . [4,(tt . (Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))] .= Sum_Tran . [4,((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)) . (Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))] .= [5,0,0] by A32, Th14 ; then A68: offset (TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) = 0 by MCART_1:64; Tape-Chg (([p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] `3_3),(Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]),((TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)),(Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]),((TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)),h1,((TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F)),h1,F) by A67, MCART_1:64 .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F) by A32, Th24 ; hence Following [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] = [((TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) `1_3),((Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) + (offset (TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by Lm3 .= [5,((Head [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]) + (offset (TRAN [p4,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A67, MCART_1:64 .= [5,(h1 + 0),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A68 ; ::_thesis: verum end; Tape-Chg (([p0,h1,t] `3_3),(Head [p0,h1,t]),((TRAN [p0,h1,t]) `2_3)) = Tape-Chg (t,(Head [p0,h1,t]),((TRAN [p0,h1,t]) `2_3)) .= Tape-Chg (t,h1,((TRAN [p0,h1,t]) `2_3)) .= Tape-Chg (t,h1,F) by A63, MCART_1:64 ; then A69: Following [p0,h1,t] = [((TRAN [p0,h1,t]) `1_3),((Head [p0,h1,t]) + (offset (TRAN [p0,h1,t]))),(Tape-Chg (t,h1,F))] by Lm3 .= [1,((Head [p0,h1,t]) + (offset (TRAN [p0,h1,t]))),(Tape-Chg (t,h1,F))] by A63, MCART_1:64 .= [p1,i2,(Tape-Chg (t,h1,F))] by A64 ; Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)) = Tape-Chg (t,(Head s),((TRAN s) `2_3)) by A1, MCART_1:64 .= Tape-Chg (t,h,((TRAN s) `2_3)) by A1, MCART_1:64 .= Tape-Chg (t,h,F) by A43, MCART_1:64 .= t by A8, Th24 ; then A70: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),t] by A1, Lm3 .= [0,((Head s) + (offset (TRAN s))),t] by A43, MCART_1:64 .= [p0,h1,t] by A1, A44, MCART_1:64 ; (Computation s) . (1 + 1) = Following ((Computation s) . 1) by Def7 .= [p1,i2,(Tape-Chg (t,h1,F))] by A70, A69, Th9 ; then (Computation s) . (((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) = (Computation [p1,i2,(Tape-Chg (t,h1,F))]) . ((((n1 + 1) + (n2 + 1)) + 1) + 1) by Th10; then (Computation s) . (((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) = Following ((Computation [p1,i2,(Tape-Chg (t,h1,F))]) . (((n1 + 1) + (n2 + 1)) + 1)) by Def7 .= Following (Following ((Computation [p1,i2,(Tape-Chg (t,h1,F))]) . ((n1 + 1) + (n2 + 1)))) by Def7 .= Following (Following ((Computation ((Computation [p1,i2,(Tape-Chg (t,h1,F))]) . (n1 + 1))) . (n2 + 1))) by Th10 ; then A71: (Computation s) . ((((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) + (((n1 + n2) + 1) + 1)) = (Computation (Following (Following ((Computation ((Computation [p1,i2,(Tape-Chg (t,h1,F))]) . (n1 + 1))) . (n2 + 1))))) . (((n1 + n2) + 1) + 1) by Th10 .= (Computation (Following (Following ((Computation (Following ((Computation [p1,i2,(Tape-Chg (t,h1,F))]) . n1))) . (n2 + 1))))) . (((n1 + n2) + 1) + 1) by Def7 ; ( the Tran of SumTuring . [p1,1] = [p1,1,1] & p1 <> the AcceptS of SumTuring ) by Def14, Th14; then (Computation s) . ((((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) + (((n1 + n2) + 1) + 1)) = (Computation (Following [p3,m3,(Tape-Chg ((Tape-Chg (t,h1,F)),nk,T))])) . (((n1 + n2) + 1) + 1) by A22, A42, A49, A41, A71, Lm4; then A72: (Computation s) . ((((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) + (((n1 + n2) + 1) + 1)) = [5,h1,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F))] by A65, A62, A66, Def7; then A73: ((Computation s) . ((((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) + (((n1 + n2) + 1) + 1))) `1_3 = 5 by MCART_1:64 .= the AcceptS of SumTuring by Def14 ; hence s is Accept-Halt by Def8; ::_thesis: ( (Result s) `2_3 = 1 + h & (Result s) `3_3 storeData <*(1 + h),(n1 + n2)*> ) then A74: Result s = (Computation s) . ((((((n1 + 1) + (n2 + 1)) + 1) + 1) + (1 + 1)) + (((n1 + n2) + 1) + 1)) by A73, Def9; hence (Result s) `2_3 = 1 + h by A72, MCART_1:64; ::_thesis: (Result s) `3_3 storeData <*(1 + h),(n1 + n2)*> (Result s) `3_3 = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,F)),nk,T)),((((h + n1) + n2) + 4) - 1),F) by A72, A74, MCART_1:64; hence (Result s) `3_3 storeData <*(1 + h),(n1 + n2)*> by A36, Th16; ::_thesis: verum end; definition let T be TuringStr ; let F be Function; predT computes F means :Def15: :: TURING_1:def 15 for s being All-State of T for t being Tape of T for a being Element of NAT for x being FinSequence of NAT st x in dom F & s = [ the InitS of T,a,t] & t storeData <*a*> ^ x holds ( s is Accept-Halt & ex b, y being Element of NAT st ( (Result s) `2_3 = b & y = F . x & (Result s) `3_3 storeData <*b*> ^ <*y*> ) ); end; :: deftheorem Def15 defines computes TURING_1:def_15_:_ for T being TuringStr for F being Function holds ( T computes F iff for s being All-State of T for t being Tape of T for a being Element of NAT for x being FinSequence of NAT st x in dom F & s = [ the InitS of T,a,t] & t storeData <*a*> ^ x holds ( s is Accept-Halt & ex b, y being Element of NAT st ( (Result s) `2_3 = b & y = F . x & (Result s) `3_3 storeData <*b*> ^ <*y*> ) ) ); theorem Th28: :: TURING_1:28 dom [+] c= 2 -tuples_on NAT proof arity (1 proj 1) = 1 by COMPUT_1:37; then dom [+] c= (1 + 1) -tuples_on NAT by COMPUT_1:56; hence dom [+] c= 2 -tuples_on NAT ; ::_thesis: verum end; theorem :: TURING_1:29 SumTuring computes [+] proof now__::_thesis:_for_s_being_All-State_of_SumTuring for_t_being_Tape_of_SumTuring for_h1_being_Element_of_NAT_ for_x_being_FinSequence_of_NAT_st_x_in_dom_[+]_&_s_=_[_the_InitS_of_SumTuring,h1,t]_&_t_storeData_<*h1*>_^_x_holds_ (_s_is_Accept-Halt_&_ex_h2,_y_being_Element_of_NAT_st_ (_(Result_s)_`2_3_=_h2_&_y_=_[+]_._x_&_(Result_s)_`3_3_storeData_<*h2*>_^_<*y*>_)_) let s be All-State of SumTuring; ::_thesis: for t being Tape of SumTuring for h1 being Element of NAT for x being FinSequence of NAT st x in dom [+] & s = [ the InitS of SumTuring,h1,t] & t storeData <*h1*> ^ x holds ( s is Accept-Halt & ex h2, y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let t be Tape of SumTuring; ::_thesis: for h1 being Element of NAT for x being FinSequence of NAT st x in dom [+] & s = [ the InitS of SumTuring,h1,t] & t storeData <*h1*> ^ x holds ( s is Accept-Halt & ex h2, y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let h1 be Element of NAT ; ::_thesis: for x being FinSequence of NAT st x in dom [+] & s = [ the InitS of SumTuring,h1,t] & t storeData <*h1*> ^ x holds ( s is Accept-Halt & ex h2, y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let x be FinSequence of NAT ; ::_thesis: ( x in dom [+] & s = [ the InitS of SumTuring,h1,t] & t storeData <*h1*> ^ x implies ( s is Accept-Halt & ex h2, y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) ) assume that A1: x in dom [+] and A2: s = [ the InitS of SumTuring,h1,t] and A3: t storeData <*h1*> ^ x ; ::_thesis: ( s is Accept-Halt & ex h2, y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) x is Tuple of 2, NAT by A1, Th28, FINSEQ_2:131; then consider i, j being Element of NAT such that A4: x = <*i,j*> by FINSEQ_2:100; A5: s = [0,h1,t] by A2, Def14; A6: <*h1*> ^ x = <*h1,i,j*> by A4, FINSEQ_1:43; hence s is Accept-Halt by A3, A5, Th27; ::_thesis: ex h2, y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take h2 = 1 + h1; ::_thesis: ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take y = i + j; ::_thesis: ( (Result s) `2_3 = h2 & y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) t storeData <*h1,i,j*> by A3, A4, FINSEQ_1:43; hence (Result s) `2_3 = h2 by A5, Th27; ::_thesis: ( y = [+] . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus y = [+] . x by A4, COMPUT_1:85; ::_thesis: (Result s) `3_3 storeData <*h2*> ^ <*y*> (Result s) `3_3 storeData <*(1 + h1),(i + j)*> by A3, A5, A6, Th27; hence (Result s) `3_3 storeData <*h2*> ^ <*y*> ; ::_thesis: verum end; hence SumTuring computes [+] by Def15; ::_thesis: verum end; begin definition func Succ_Tran -> Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] equals :: TURING_1:def 16 (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) +* ([3,0] .--> [4,0,0]); coherence (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) +* ([3,0] .--> [4,0,0]) is Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] proof reconsider p0 = 0 , p1 = 1, p2 = 2, p3 = 3, p4 = 4 as Element of SegM 4 by Th1; set A = [:(SegM 4),{0,1}:]; set B = {(- 1),0,1}; set C = [:(SegM 4),{0,1},{(- 1),0,1}:]; reconsider b0 = 0 , b1 = 1 as Element of {0,1} by TARSKI:def_2; reconsider L = - 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; reconsider h = 0 , R = 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; [:(SegM 4),{0,1},{(- 1),0,1}:] = [:[:(SegM 4),{0,1}:],{(- 1),0,1}:] by ZFMISC_1:def_3; then reconsider OP = id ([:(SegM 4),{0,1}:],{(- 1),0,1},h) as Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] ; (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) +* ([3,0] .--> [4,0,0]) = ((((((OP +* ([p0,b0] .--> [p1,b0,R])) +* ([p1,b1] .--> [p1,b1,R])) +* ([p1,b0] .--> [p2,b1,R])) +* ([p2,b0] .--> [p3,b0,L])) +* ([p2,b1] .--> [p3,b0,L])) +* ([p3,b1] .--> [p3,b1,L])) +* ([p3,b0] .--> [p4,b0,h]) ; hence (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) +* ([3,0] .--> [4,0,0]) is Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] ; ::_thesis: verum end; end; :: deftheorem defines Succ_Tran TURING_1:def_16_:_ Succ_Tran = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) +* ([3,0] .--> [4,0,0]); theorem Th30: :: TURING_1:30 ( Succ_Tran . [0,0] = [1,0,1] & Succ_Tran . [1,1] = [1,1,1] & Succ_Tran . [1,0] = [2,1,1] & Succ_Tran . [2,0] = [3,0,(- 1)] & Succ_Tran . [2,1] = [3,0,(- 1)] & Succ_Tran . [3,1] = [3,1,(- 1)] & Succ_Tran . [3,0] = [4,0,0] ) proof set x = [1,1]; set x1 = [0,0]; set p1 = [0,0] .--> [1,0,1]; set p2 = [1,1] .--> [1,1,1]; set p3 = [1,0] .--> [2,1,1]; set p4 = [2,0] .--> [3,0,(- 1)]; set p5 = [2,1] .--> [3,0,(- 1)]; set p6 = [3,1] .--> [3,1,(- 1)]; set f = id ([:(SegM 4),{0,1}:],{(- 1),0,1},0); thus Succ_Tran . [0,0] = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) . [0,0] by Th2 .= ((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [0,0] by Th2 .= (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [0,0] by Th2 .= ((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [0,0] by Th2 .= (((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) . [0,0] by Th2 .= ((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) . [0,0] by Th3 .= [1,0,1] by FUNCT_7:94 ; ::_thesis: ( Succ_Tran . [1,1] = [1,1,1] & Succ_Tran . [1,0] = [2,1,1] & Succ_Tran . [2,0] = [3,0,(- 1)] & Succ_Tran . [2,1] = [3,0,(- 1)] & Succ_Tran . [3,1] = [3,1,(- 1)] & Succ_Tran . [3,0] = [4,0,0] ) thus Succ_Tran . [1,1] = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) . [1,1] by Th2 .= ((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [1,1] by Th2 .= (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [1,1] by Th2 .= ((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [1,1] by Th2 .= (((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) . [1,1] by Th3 .= [1,1,1] by FUNCT_7:94 ; ::_thesis: ( Succ_Tran . [1,0] = [2,1,1] & Succ_Tran . [2,0] = [3,0,(- 1)] & Succ_Tran . [2,1] = [3,0,(- 1)] & Succ_Tran . [3,1] = [3,1,(- 1)] & Succ_Tran . [3,0] = [4,0,0] ) set x = [1,0]; thus Succ_Tran . [1,0] = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) . [1,0] by Th2 .= ((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [1,0] by Th2 .= (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [1,0] by Th2 .= ((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) . [1,0] by Th2 .= [2,1,1] by FUNCT_7:94 ; ::_thesis: ( Succ_Tran . [2,0] = [3,0,(- 1)] & Succ_Tran . [2,1] = [3,0,(- 1)] & Succ_Tran . [3,1] = [3,1,(- 1)] & Succ_Tran . [3,0] = [4,0,0] ) set x = [2,0]; thus Succ_Tran . [2,0] = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) . [2,0] by Th2 .= ((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [2,0] by Th2 .= (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [2,0] by Th3 .= [3,0,(- 1)] by FUNCT_7:94 ; ::_thesis: ( Succ_Tran . [2,1] = [3,0,(- 1)] & Succ_Tran . [3,1] = [3,1,(- 1)] & Succ_Tran . [3,0] = [4,0,0] ) set x = [2,1]; thus Succ_Tran . [2,1] = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) . [2,1] by Th2 .= ((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [2,1] by Th2 .= [3,0,(- 1)] by FUNCT_7:94 ; ::_thesis: ( Succ_Tran . [3,1] = [3,1,(- 1)] & Succ_Tran . [3,0] = [4,0,0] ) set x = [3,1]; thus Succ_Tran . [3,1] = (((((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,1,1])) +* ([1,0] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [3,1,(- 1)])) . [3,1] by Th3 .= [3,1,(- 1)] by FUNCT_7:94 ; ::_thesis: Succ_Tran . [3,0] = [4,0,0] thus Succ_Tran . [3,0] = [4,0,0] by FUNCT_7:94; ::_thesis: verum end; definition func SuccTuring -> strict TuringStr means :Def17: :: TURING_1:def 17 ( the Symbols of it = {0,1} & the FStates of it = SegM 4 & the Tran of it = Succ_Tran & the InitS of it = 0 & the AcceptS of it = 4 ); existence ex b1 being strict TuringStr st ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 4 & the Tran of b1 = Succ_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 4 ) proof set St = SegM 4; reconsider p0 = 0 , qF = 4 as Element of SegM 4 by Th1; set Sym = {0,1}; take TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) ; ::_thesis: ( the Symbols of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = SegM 4 & the Tran of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = Succ_Tran & the InitS of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = 4 ) thus ( the Symbols of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = SegM 4 & the Tran of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = Succ_Tran & the InitS of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 4),Succ_Tran,p0,qF #) = 4 ) ; ::_thesis: verum end; uniqueness for b1, b2 being strict TuringStr st the Symbols of b1 = {0,1} & the FStates of b1 = SegM 4 & the Tran of b1 = Succ_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 4 & the Symbols of b2 = {0,1} & the FStates of b2 = SegM 4 & the Tran of b2 = Succ_Tran & the InitS of b2 = 0 & the AcceptS of b2 = 4 holds b1 = b2 ; end; :: deftheorem Def17 defines SuccTuring TURING_1:def_17_:_ for b1 being strict TuringStr holds ( b1 = SuccTuring iff ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 4 & the Tran of b1 = Succ_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 4 ) ); Lm5: for n being Element of NAT st n <= 4 holds n is State of SuccTuring proof let n be Element of NAT ; ::_thesis: ( n <= 4 implies n is State of SuccTuring ) assume A1: n <= 4 ; ::_thesis: n is State of SuccTuring the FStates of SuccTuring = SegM 4 by Def17; hence n is State of SuccTuring by A1, Th1; ::_thesis: verum end; Lm6: ( 0 in the Symbols of SuccTuring & 1 in the Symbols of SuccTuring ) proof ( 0 in {0,1} & 1 in {0,1} ) by TARSKI:def_2; hence ( 0 in the Symbols of SuccTuring & 1 in the Symbols of SuccTuring ) by Def17; ::_thesis: verum end; Lm7: for s being All-State of SuccTuring for p, h, t being set st s = [p,h,t] & p <> 4 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] proof let s be All-State of SuccTuring; ::_thesis: for p, h, t being set st s = [p,h,t] & p <> 4 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] let p, h, t be set ; ::_thesis: ( s = [p,h,t] & p <> 4 implies Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] ) assume A1: ( s = [p,h,t] & p <> 4 ) ; ::_thesis: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] 4 = the AcceptS of SuccTuring by Def17; hence Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] by A1, Th25; ::_thesis: verum end; theorem Th31: :: TURING_1:31 for s being All-State of SuccTuring for t being Tape of SuccTuring for head, n being Element of NAT st s = [0,head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,(n + 1)*> ) proof reconsider F = 0 as Symbol of SuccTuring by Lm6; let s be All-State of SuccTuring; ::_thesis: for t being Tape of SuccTuring for head, n being Element of NAT st s = [0,head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,(n + 1)*> ) let t be Tape of SuccTuring; ::_thesis: for head, n being Element of NAT st s = [0,head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,(n + 1)*> ) let h, n be Element of NAT ; ::_thesis: ( s = [0,h,t] & t storeData <*h,n*> implies ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,(n + 1)*> ) ) assume that A1: s = [0,h,t] and A2: t storeData <*h,n*> ; ::_thesis: ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,(n + 1)*> ) A3: t . h = 0 by A2, Th17; set i3 = (((h + 1) + 1) + n) + 1; reconsider h1 = h + 1 as Element of INT by INT_1:def_2; reconsider p1 = 1 as State of SuccTuring by Lm5; A4: (h1 + 1) + n < (((h + 1) + 1) + n) + 1 by XREAL_1:29; h <= h + n by NAT_1:11; then A5: h + 2 <= (h + n) + 2 by XREAL_1:7; A6: h1 < h + 2 by XREAL_1:8; then A7: h1 < (h + n) + 2 by A5, XXREAL_0:2; reconsider p2 = 2 as State of SuccTuring by Lm5; reconsider i2 = h1 + 1 as Element of INT by INT_1:def_2; reconsider nk = (h1 + 1) + n as Element of INT by INT_1:def_2; reconsider hh = h as Element of INT by INT_1:def_2; reconsider n3 = (((h + 1) + 1) + n) + 1 as Element of INT by INT_1:def_2; reconsider T = 1 as Symbol of SuccTuring by Lm6; set t1 = Tape-Chg (t,h1,T); A8: h < h1 by XREAL_1:29; A9: t . ((h + n) + 2) = 0 by A2, Th17; A10: ( (Tape-Chg (t,h1,T)) . h = 0 & (Tape-Chg (t,h1,T)) . ((h + n) + 2) = 0 & ( for i being Integer st h < i & i < (h + n) + 2 holds (Tape-Chg (t,h1,T)) . i = 1 ) ) proof thus (Tape-Chg (t,h1,T)) . h = 0 by A3, A8, Th26; ::_thesis: ( (Tape-Chg (t,h1,T)) . ((h + n) + 2) = 0 & ( for i being Integer st h < i & i < (h + n) + 2 holds (Tape-Chg (t,h1,T)) . i = 1 ) ) thus (Tape-Chg (t,h1,T)) . ((h + n) + 2) = 0 by A9, A5, A6, Th26; ::_thesis: for i being Integer st h < i & i < (h + n) + 2 holds (Tape-Chg (t,h1,T)) . i = 1 hereby ::_thesis: verum let i be Integer; ::_thesis: ( h < i & i < (h + n) + 2 implies (Tape-Chg (t,h1,T)) . b1 = 1 ) assume A11: ( h < i & i < (h + n) + 2 ) ; ::_thesis: (Tape-Chg (t,h1,T)) . b1 = 1 percases ( h1 = i or h1 <> i ) ; suppose h1 = i ; ::_thesis: (Tape-Chg (t,h1,T)) . b1 = 1 hence (Tape-Chg (t,h1,T)) . i = 1 by Th26; ::_thesis: verum end; suppose h1 <> i ; ::_thesis: (Tape-Chg (t,h1,T)) . b1 = 1 hence (Tape-Chg (t,h1,T)) . i = t . i by Th26 .= 1 by A2, A11, Th17 ; ::_thesis: verum end; end; end; end; A12: for i being Integer st (h + 1) + 1 <= i & i < ((h + 1) + 1) + n holds (Tape-Chg (t,h1,T)) . i = 1 proof let i be Integer; ::_thesis: ( (h + 1) + 1 <= i & i < ((h + 1) + 1) + n implies (Tape-Chg (t,h1,T)) . i = 1 ) assume that A13: (h + 1) + 1 <= i and A14: i < ((h + 1) + 1) + n ; ::_thesis: (Tape-Chg (t,h1,T)) . i = 1 h1 < h1 + 1 by XREAL_1:29; then h1 < i by A13, XXREAL_0:2; then h < i by A8, XXREAL_0:2; hence (Tape-Chg (t,h1,T)) . i = 1 by A10, A14; ::_thesis: verum end; reconsider s3 = s `3_3 as Tape of SuccTuring ; A15: TRAN s = Succ_Tran . [(s `1_3),(s3 . (Head s))] by Def17 .= Succ_Tran . [0,(s3 . (Head s))] by A1, MCART_1:64 .= Succ_Tran . [0,(t . (Head s))] by A1, MCART_1:64 .= [1,0,1] by A1, A3, Th30, MCART_1:64 ; then A16: offset (TRAN s) = 1 by MCART_1:64; set s1 = [p1,h1,t]; reconsider s3 = [p1,h1,t] `3_3 as Tape of SuccTuring ; Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)) = Tape-Chg (t,(Head s),((TRAN s) `2_3)) by A1, MCART_1:64 .= Tape-Chg (t,h,((TRAN s) `2_3)) by A1, MCART_1:64 .= Tape-Chg (t,h,F) by A15, MCART_1:64 .= t by A3, Th24 ; then A17: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),t] by A1, Lm7 .= [1,((Head s) + (offset (TRAN s))),t] by A15, MCART_1:64 .= [p1,h1,t] by A1, A16, MCART_1:64 ; A18: TRAN [p1,h1,t] = Succ_Tran . [([p1,h1,t] `1_3),(s3 . (Head [p1,h1,t]))] by Def17 .= Succ_Tran . [p1,(s3 . (Head [p1,h1,t]))] .= Succ_Tran . [p1,(t . (Head [p1,h1,t]))] .= Succ_Tran . [1,(t . h1)] .= [1,1,1] by A2, A8, A7, Th17, Th30 ; then A19: offset (TRAN [p1,h1,t]) = 1 by MCART_1:64; reconsider p1 = 1 as State of SuccTuring by Lm5; set s2 = [p1,i2,(Tape-Chg (t,h1,T))]; Tape-Chg (([p1,h1,t] `3_3),(Head [p1,h1,t]),((TRAN [p1,h1,t]) `2_3)) = Tape-Chg (t,(Head [p1,h1,t]),((TRAN [p1,h1,t]) `2_3)) .= Tape-Chg (t,h1,((TRAN [p1,h1,t]) `2_3)) .= Tape-Chg (t,h1,T) by A18, MCART_1:64 ; then A20: Following [p1,h1,t] = [((TRAN [p1,h1,t]) `1_3),((Head [p1,h1,t]) + (offset (TRAN [p1,h1,t]))),(Tape-Chg (t,h1,T))] by Lm7 .= [1,((Head [p1,h1,t]) + (offset (TRAN [p1,h1,t]))),(Tape-Chg (t,h1,T))] by A18, MCART_1:64 .= [p1,i2,(Tape-Chg (t,h1,T))] by A19 ; reconsider p3 = 3 as State of SuccTuring by Lm5; set sn = [p1,nk,(Tape-Chg (t,h1,T))]; set t2 = Tape-Chg ((Tape-Chg (t,h1,T)),nk,T); set t3 = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F); ( the Tran of SuccTuring . [p1,1] = [p1,1,1] & p1 <> the AcceptS of SuccTuring ) by Def17, Th30; then A21: (Computation [p1,i2,(Tape-Chg (t,h1,T))]) . n = [p1,(((h + 1) + 1) + n),(Tape-Chg (t,h1,T))] by A12, Lm4; ( h1 + 1 <= ((h + 1) + 1) + n & h1 < h1 + 1 ) by NAT_1:11, XREAL_1:29; then A22: h1 < (h1 + 1) + n by XXREAL_0:2; A23: ( (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . h = 0 & ( for i being Integer st h < i & i <= (h + n) + 2 holds (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . i = 1 ) ) proof thus (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . h = 0 by A8, A10, A22, Th26; ::_thesis: for i being Integer st h < i & i <= (h + n) + 2 holds (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . i = 1 hereby ::_thesis: verum let i be Integer; ::_thesis: ( h < i & i <= (h + n) + 2 implies (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . b1 = 1 ) assume that A24: h < i and A25: i <= (h + n) + 2 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . b1 = 1 percases ( i <> (h + n) + 2 or i = (h + n) + 2 ) ; supposeA26: i <> (h + n) + 2 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . b1 = 1 then A27: i < (h + n) + 2 by A25, XXREAL_0:1; thus (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . i = (Tape-Chg (t,h1,T)) . i by A26, Th26 .= 1 by A10, A24, A27 ; ::_thesis: verum end; suppose i = (h + n) + 2 ; ::_thesis: (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . b1 = 1 hence (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . i = 1 by Th26; ::_thesis: verum end; end; end; end; set sp3 = [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]; set sm = [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]; reconsider sm3 = [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] `3_3 as Tape of SuccTuring ; A28: the Symbols of SuccTuring = {0,1} by Def17; A29: now__::_thesis:_Succ_Tran_._[2,((Tape-Chg_((Tape-Chg_(t,h1,T)),nk,T))_._n3)]_=_[p3,0,(-_1)] percases ( (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3 = 1 or (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3 = 0 ) by A28, TARSKI:def_2; suppose (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3 = 1 ; ::_thesis: Succ_Tran . [2,((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3)] = [p3,0,(- 1)] hence Succ_Tran . [2,((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3)] = [p3,0,(- 1)] by Th30; ::_thesis: verum end; suppose (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3 = 0 ; ::_thesis: Succ_Tran . [2,((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3)] = [p3,0,(- 1)] hence Succ_Tran . [2,((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . n3)] = [p3,0,(- 1)] by Th30; ::_thesis: verum end; end; end; A30: TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] = Succ_Tran . [([p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] `1_3),(sm3 . (Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]))] by Def17 .= Succ_Tran . [2,(sm3 . (Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]))] .= Succ_Tran . [2,((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . (Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]))] .= [p3,0,(- 1)] by A29 ; then A31: offset (TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) = - 1 by MCART_1:64; set j1 = (1 + 1) + n; set sp5 = [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]; defpred S1[ Element of NAT ] means ( h + $1 <= nk implies (Computation [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) . $1 = [3,(nk - $1),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] ); reconsider sn3 = [p1,nk,(Tape-Chg (t,h1,T))] `3_3 as Tape of SuccTuring ; A32: h + ((1 + 1) + n) = nk ; set Rs = (Computation s) . ((1 + 1) + (((n + 1) + 1) + (((1 + 1) + n) + 1))); A33: TRAN [p1,nk,(Tape-Chg (t,h1,T))] = Succ_Tran . [([p1,nk,(Tape-Chg (t,h1,T))] `1_3),(sn3 . (Head [p1,nk,(Tape-Chg (t,h1,T))]))] by Def17 .= Succ_Tran . [p1,(sn3 . (Head [p1,nk,(Tape-Chg (t,h1,T))]))] .= Succ_Tran . [p1,((Tape-Chg (t,h1,T)) . (Head [p1,nk,(Tape-Chg (t,h1,T))]))] .= [2,1,1] by A10, Th30 ; then A34: offset (TRAN [p1,nk,(Tape-Chg (t,h1,T))]) = 1 by MCART_1:64; A35: h < (h1 + 1) + n by A8, A22, XXREAL_0:2; A36: ( (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . h = 0 & (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . ((h + (n + 1)) + 2) = 0 & ( for k being Integer st h < k & k < (h + (n + 1)) + 2 holds (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . k = 1 ) ) proof thus (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . h = 0 by A35, A23, A4, Th26; ::_thesis: ( (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . ((h + (n + 1)) + 2) = 0 & ( for k being Integer st h < k & k < (h + (n + 1)) + 2 holds (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . k = 1 ) ) thus (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . ((h + (n + 1)) + 2) = 0 by Th26; ::_thesis: for k being Integer st h < k & k < (h + (n + 1)) + 2 holds (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . k = 1 hereby ::_thesis: verum let i be Integer; ::_thesis: ( h < i & i < (h + (n + 1)) + 2 implies (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . i = 1 ) assume that A37: h < i and A38: i < (h + (n + 1)) + 2 ; ::_thesis: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . i = 1 i + 1 <= (h + (n + 1)) + 2 by A38, INT_1:7; then A39: i <= ((h + (n + 1)) + 2) - 1 by XREAL_1:19; thus (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . i = (Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)) . i by A38, Th26 .= 1 by A23, A37, A39 ; ::_thesis: verum end; end; then A40: Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F) is_1_between h,(h + (n + 1)) + 2 by Def12; Tape-Chg (([p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] `3_3),(Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]),((TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),(Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]),((TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,((TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F) by A30, MCART_1:64 ; then A41: Following [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] = [((TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) `1_3),((Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) + (offset (TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by Lm7 .= [p3,((Head [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]) + (offset (TRAN [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A30, MCART_1:64 .= [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A31 ; Tape-Chg (([p1,nk,(Tape-Chg (t,h1,T))] `3_3),(Head [p1,nk,(Tape-Chg (t,h1,T))]),((TRAN [p1,nk,(Tape-Chg (t,h1,T))]) `2_3)) = Tape-Chg ((Tape-Chg (t,h1,T)),(Head [p1,nk,(Tape-Chg (t,h1,T))]),((TRAN [p1,nk,(Tape-Chg (t,h1,T))]) `2_3)) .= Tape-Chg ((Tape-Chg (t,h1,T)),nk,((TRAN [p1,nk,(Tape-Chg (t,h1,T))]) `2_3)) .= Tape-Chg ((Tape-Chg (t,h1,T)),nk,T) by A33, MCART_1:64 ; then A42: Following [p1,nk,(Tape-Chg (t,h1,T))] = [((TRAN [p1,nk,(Tape-Chg (t,h1,T))]) `1_3),((Head [p1,nk,(Tape-Chg (t,h1,T))]) + (offset (TRAN [p1,nk,(Tape-Chg (t,h1,T))]))),(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] by Lm7 .= [2,((Head [p1,nk,(Tape-Chg (t,h1,T))]) + (offset (TRAN [p1,nk,(Tape-Chg (t,h1,T))]))),(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] by A33, MCART_1:64 .= [p2,n3,(Tape-Chg ((Tape-Chg (t,h1,T)),nk,T))] by A34 ; A43: for k being Element of NAT st S1[k] holds S1[k + 1] proof let k be Element of NAT ; ::_thesis: ( S1[k] implies S1[k + 1] ) assume A44: S1[k] ; ::_thesis: S1[k + 1] now__::_thesis:_(_h_+_(k_+_1)_<=_nk_implies_(Computation_[p3,nk,(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,T)),nk,T)),n3,F))])_._(k_+_1)_=_[3,(nk_-_(k_+_1)),(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,T)),nk,T)),n3,F))]_) reconsider ik = nk - k as Element of INT by INT_1:def_2; set k3 = nk - k; A45: h + k < (h + k) + 1 by XREAL_1:29; set sk = [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]; reconsider tt = [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] `3_3 as Tape of SuccTuring ; nk <= nk + k by INT_1:6; then A46: nk - k <= nk by XREAL_1:20; assume A47: h + (k + 1) <= nk ; ::_thesis: (Computation [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) . (k + 1) = [3,(nk - (k + 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] then h + k < nk + 0 by A45, XXREAL_0:2; then A48: h - 0 < nk - k by XREAL_1:21; h >= 0 by NAT_1:2; then reconsider ii = nk - k as Element of NAT by A48, INT_1:3, XXREAL_0:2; (h + n) + 2 < ((h + n) + 2) + 1 by XREAL_1:29; then ii < (h + (n + 1)) + 2 by A46, XXREAL_0:2; then A49: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . ii = 1 by A36, A48; A50: TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] = Succ_Tran . [([p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] `1_3),(tt . (Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))] by Def17 .= Succ_Tran . [p3,(tt . (Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))] .= Succ_Tran . [p3,((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . (Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))] .= [3,1,(- 1)] by A49, Th30 ; then A51: offset (TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) = - 1 by MCART_1:64; A52: Tape-Chg (([p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] `3_3),(Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]),((TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)),(Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]),((TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)),(nk - k),((TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)),(nk - k),T) by A50, MCART_1:64 .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F) by A49, Th24 ; hereby ::_thesis: verum thus (Computation [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) . (k + 1) = Following [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A44, A47, A45, Def7, XXREAL_0:2 .= [((TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `1_3),((Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) + (offset (TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A52, Lm7 .= [3,((Head [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) + (offset (TRAN [p3,ik,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A50, MCART_1:64 .= [3,((nk - k) + (- 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A51 .= [3,(nk - (k + 1)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] ; ::_thesis: verum end; end; hence S1[k + 1] ; ::_thesis: verum end; A53: S1[ 0 ] by Def7; for k being Element of NAT holds S1[k] from NAT_1:sch_1(A53, A43); then A54: (Computation [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) . ((1 + 1) + n) = [3,(nk - ((1 + 1) + n)),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A32 .= [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] ; A55: now__::_thesis:_Following_[p3,hh,(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,T)),nk,T)),n3,F))]_=_[4,(h_+_0),(Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,T)),nk,T)),n3,F))] reconsider tt = [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] `3_3 as Tape of SuccTuring ; A56: TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] = Succ_Tran . [([p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] `1_3),(tt . (Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))] by Def17 .= Succ_Tran . [3,(tt . (Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))] .= Succ_Tran . [3,((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)) . (Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))] .= [4,0,0] by A36, Th30 ; then A57: offset (TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) = 0 by MCART_1:64; Tape-Chg (([p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] `3_3),(Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]),((TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)),(Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]),((TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)),h,((TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F)),h,F) by A56, MCART_1:64 .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F) by A36, Th24 ; hence Following [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] = [((TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) `1_3),((Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) + (offset (TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by Lm7 .= [4,((Head [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) + (offset (TRAN [p3,hh,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A56, MCART_1:64 .= [4,(h + 0),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A57 ; ::_thesis: verum end; (Computation s) . ((1 + 1) + (((n + 1) + 1) + (((1 + 1) + n) + 1))) = (Computation ((Computation s) . (1 + 1))) . (((n + 1) + 1) + (((1 + 1) + n) + 1)) by Th10 .= (Computation (Following ((Computation s) . 1))) . (((n + 1) + 1) + (((1 + 1) + n) + 1)) by Def7 .= (Computation (Following [p1,h1,t])) . (((n + 1) + 1) + (((1 + 1) + n) + 1)) by A17, Th9 .= (Computation ((Computation [p1,i2,(Tape-Chg (t,h1,T))]) . ((n + 1) + 1))) . (((1 + 1) + n) + 1) by A20, Th10 .= (Computation (Following ((Computation [p1,i2,(Tape-Chg (t,h1,T))]) . (n + 1)))) . (((1 + 1) + n) + 1) by Def7 ; then (Computation s) . ((1 + 1) + (((n + 1) + 1) + (((1 + 1) + n) + 1))) = (Computation [p3,nk,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))]) . (((1 + 1) + n) + 1) by A21, A42, A41, Def7; then A58: (Computation s) . ((1 + 1) + (((n + 1) + 1) + (((1 + 1) + n) + 1))) = [4,h,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F))] by A54, A55, Def7; then A59: ((Computation s) . ((1 + 1) + (((n + 1) + 1) + (((1 + 1) + n) + 1)))) `1_3 = 4 by MCART_1:64 .= the AcceptS of SuccTuring by Def17 ; hence s is Accept-Halt by Def8; ::_thesis: ( (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,(n + 1)*> ) then A60: Result s = (Computation s) . ((1 + 1) + (((n + 1) + 1) + (((1 + 1) + n) + 1))) by A59, Def9; hence (Result s) `2_3 = h by A58, MCART_1:64; ::_thesis: (Result s) `3_3 storeData <*h,(n + 1)*> (Result s) `3_3 = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),nk,T)),n3,F) by A58, A60, MCART_1:64; hence (Result s) `3_3 storeData <*h,(n + 1)*> by A40, Th16; ::_thesis: verum end; theorem :: TURING_1:32 SuccTuring computes 1 succ 1 proof now__::_thesis:_for_s_being_All-State_of_SuccTuring for_t_being_Tape_of_SuccTuring for_h_being_Element_of_NAT_ for_x_being_FinSequence_of_NAT_st_x_in_dom_(1_succ_1)_&_s_=_[_the_InitS_of_SuccTuring,h,t]_&_t_storeData_<*h*>_^_x_holds_ (_s_is_Accept-Halt_&_ex_h2_being_Element_of_NAT_ex_y_being_Element_of_NAT_st_ (_(Result_s)_`2_3_=_h2_&_y_=_(1_succ_1)_._x_&_(Result_s)_`3_3_storeData_<*h2*>_^_<*y*>_)_) set sc = 1 succ 1; let s be All-State of SuccTuring; ::_thesis: for t being Tape of SuccTuring for h being Element of NAT for x being FinSequence of NAT st x in dom (1 succ 1) & s = [ the InitS of SuccTuring,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let t be Tape of SuccTuring; ::_thesis: for h being Element of NAT for x being FinSequence of NAT st x in dom (1 succ 1) & s = [ the InitS of SuccTuring,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let h be Element of NAT ; ::_thesis: for x being FinSequence of NAT st x in dom (1 succ 1) & s = [ the InitS of SuccTuring,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let x be FinSequence of NAT ; ::_thesis: ( x in dom (1 succ 1) & s = [ the InitS of SuccTuring,h,t] & t storeData <*h*> ^ x implies ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) ) assume that A1: x in dom (1 succ 1) and A2: s = [ the InitS of SuccTuring,h,t] and A3: t storeData <*h*> ^ x ; ::_thesis: ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) A4: s = [0,h,t] by A2, Def17; A5: dom (1 succ 1) = 1 -tuples_on NAT by COMPUT_1:def_7; then x is Tuple of 1, NAT by A1, FINSEQ_2:131; then consider i being Element of NAT such that A6: x = <*i*> by FINSEQ_2:97; A7: <*h*> ^ x = <*h,i*> by A6; hence s is Accept-Halt by A3, A4, Th31; ::_thesis: ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take h2 = h; ::_thesis: ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take y = i + 1; ::_thesis: ( (Result s) `2_3 = h2 & y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus (Result s) `2_3 = h2 by A3, A4, A7, Th31; ::_thesis: ( y = (1 succ 1) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus y = (x /. 1) + 1 by A6, FINSEQ_4:16 .= (1 succ 1) . x by A1, A5, COMPUT_1:def_7 ; ::_thesis: (Result s) `3_3 storeData <*h2*> ^ <*y*> (Result s) `3_3 storeData <*h2,(i + 1)*> by A3, A4, A7, Th31; hence (Result s) `3_3 storeData <*h2*> ^ <*y*> ; ::_thesis: verum end; hence SuccTuring computes 1 succ 1 by Def15; ::_thesis: verum end; begin definition func Zero_Tran -> Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] equals :: TURING_1:def 18 (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,1,(- 1)]); coherence (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,1,(- 1)]) is Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] proof reconsider p0 = 0 , p1 = 1, p2 = 2, p3 = 3, p4 = 4 as Element of SegM 4 by Th1; set A = [:(SegM 4),{0,1}:]; set B = {(- 1),0,1}; set C = [:(SegM 4),{0,1},{(- 1),0,1}:]; reconsider b0 = 0 , b1 = 1 as Element of {0,1} by TARSKI:def_2; reconsider L = - 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; reconsider R = 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; [:(SegM 4),{0,1},{(- 1),0,1}:] = [:[:(SegM 4),{0,1}:],{(- 1),0,1}:] by ZFMISC_1:def_3; then reconsider OP = id ([:(SegM 4),{0,1}:],{(- 1),0,1},R) as Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] ; (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,1,(- 1)]) = ((((OP +* ([p0,b0] .--> [p1,b0,R])) +* ([p1,b1] .--> [p2,b1,R])) +* ([p2,b0] .--> [p3,b0,L])) +* ([p2,b1] .--> [p3,b0,L])) +* ([p3,b1] .--> [p4,b1,L]) ; hence (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,1,(- 1)]) is Function of [:(SegM 4),{0,1}:],[:(SegM 4),{0,1},{(- 1),0,1}:] ; ::_thesis: verum end; end; :: deftheorem defines Zero_Tran TURING_1:def_18_:_ Zero_Tran = (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) +* ([3,1] .--> [4,1,(- 1)]); theorem Th33: :: TURING_1:33 ( Zero_Tran . [0,0] = [1,0,1] & Zero_Tran . [1,1] = [2,1,1] & Zero_Tran . [2,0] = [3,0,(- 1)] & Zero_Tran . [2,1] = [3,0,(- 1)] & Zero_Tran . [3,1] = [4,1,(- 1)] ) proof set x = [1,1]; set x1 = [0,0]; set p1 = [0,0] .--> [1,0,1]; set p2 = [1,1] .--> [2,1,1]; set p3 = [2,0] .--> [3,0,(- 1)]; set p4 = [2,1] .--> [3,0,(- 1)]; set f = id ([:(SegM 4),{0,1}:],{(- 1),0,1},1); thus Zero_Tran . [0,0] = (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [0,0] by Th2 .= ((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [0,0] by Th2 .= (((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) . [0,0] by Th2 .= ((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) . [0,0] by Th3 .= [1,0,1] by FUNCT_7:94 ; ::_thesis: ( Zero_Tran . [1,1] = [2,1,1] & Zero_Tran . [2,0] = [3,0,(- 1)] & Zero_Tran . [2,1] = [3,0,(- 1)] & Zero_Tran . [3,1] = [4,1,(- 1)] ) thus Zero_Tran . [1,1] = (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [1,1] by Th2 .= ((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [1,1] by Th2 .= (((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) . [1,1] by Th3 .= [2,1,1] by FUNCT_7:94 ; ::_thesis: ( Zero_Tran . [2,0] = [3,0,(- 1)] & Zero_Tran . [2,1] = [3,0,(- 1)] & Zero_Tran . [3,1] = [4,1,(- 1)] ) set x = [2,0]; thus Zero_Tran . [2,0] = (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [2,0] by Th3 .= ((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) . [2,0] by Th3 .= [3,0,(- 1)] by FUNCT_7:94 ; ::_thesis: ( Zero_Tran . [2,1] = [3,0,(- 1)] & Zero_Tran . [3,1] = [4,1,(- 1)] ) set x = [2,1]; thus Zero_Tran . [2,1] = (((((id ([:(SegM 4),{0,1}:],{(- 1),0,1},1)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [2,1,1])) +* ([2,0] .--> [3,0,(- 1)])) +* ([2,1] .--> [3,0,(- 1)])) . [2,1] by Th2 .= [3,0,(- 1)] by FUNCT_7:94 ; ::_thesis: Zero_Tran . [3,1] = [4,1,(- 1)] thus Zero_Tran . [3,1] = [4,1,(- 1)] by FUNCT_7:94; ::_thesis: verum end; definition func ZeroTuring -> strict TuringStr means :Def19: :: TURING_1:def 19 ( the Symbols of it = {0,1} & the FStates of it = SegM 4 & the Tran of it = Zero_Tran & the InitS of it = 0 & the AcceptS of it = 4 ); existence ex b1 being strict TuringStr st ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 4 & the Tran of b1 = Zero_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 4 ) proof set St = SegM 4; reconsider qF = 4 as Element of SegM 4 by Th1; reconsider p0 = 0 as Element of SegM 4 by Th1; set Sym = {0,1}; take TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) ; ::_thesis: ( the Symbols of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = SegM 4 & the Tran of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = Zero_Tran & the InitS of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = 4 ) thus ( the Symbols of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = SegM 4 & the Tran of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = Zero_Tran & the InitS of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 4),Zero_Tran,p0,qF #) = 4 ) ; ::_thesis: verum end; uniqueness for b1, b2 being strict TuringStr st the Symbols of b1 = {0,1} & the FStates of b1 = SegM 4 & the Tran of b1 = Zero_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 4 & the Symbols of b2 = {0,1} & the FStates of b2 = SegM 4 & the Tran of b2 = Zero_Tran & the InitS of b2 = 0 & the AcceptS of b2 = 4 holds b1 = b2 ; end; :: deftheorem Def19 defines ZeroTuring TURING_1:def_19_:_ for b1 being strict TuringStr holds ( b1 = ZeroTuring iff ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 4 & the Tran of b1 = Zero_Tran & the InitS of b1 = 0 & the AcceptS of b1 = 4 ) ); Lm8: for n being Element of NAT st n <= 4 holds n is State of ZeroTuring proof let n be Element of NAT ; ::_thesis: ( n <= 4 implies n is State of ZeroTuring ) assume A1: n <= 4 ; ::_thesis: n is State of ZeroTuring the FStates of ZeroTuring = SegM 4 by Def19; hence n is State of ZeroTuring by A1, Th1; ::_thesis: verum end; Lm9: ( 0 in the Symbols of ZeroTuring & 1 in the Symbols of ZeroTuring ) proof ( 0 in {0,1} & 1 in {0,1} ) by TARSKI:def_2; hence ( 0 in the Symbols of ZeroTuring & 1 in the Symbols of ZeroTuring ) by Def19; ::_thesis: verum end; Lm10: for s being All-State of ZeroTuring for p, h, t being set st s = [p,h,t] & p <> 4 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] proof let s be All-State of ZeroTuring; ::_thesis: for p, h, t being set st s = [p,h,t] & p <> 4 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] let p, h, t be set ; ::_thesis: ( s = [p,h,t] & p <> 4 implies Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] ) assume A1: ( s = [p,h,t] & p <> 4 ) ; ::_thesis: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] 4 = the AcceptS of ZeroTuring by Def19; hence Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] by A1, Th25; ::_thesis: verum end; theorem Th34: :: TURING_1:34 for s being All-State of ZeroTuring for t being Tape of ZeroTuring for head being Element of NAT for f being FinSequence of NAT st len f >= 1 & s = [0,head,t] & t storeData <*head*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,0*> ) proof reconsider F = 0 as Symbol of ZeroTuring by Lm9; let s be All-State of ZeroTuring; ::_thesis: for t being Tape of ZeroTuring for head being Element of NAT for f being FinSequence of NAT st len f >= 1 & s = [0,head,t] & t storeData <*head*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,0*> ) let t be Tape of ZeroTuring; ::_thesis: for head being Element of NAT for f being FinSequence of NAT st len f >= 1 & s = [0,head,t] & t storeData <*head*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,0*> ) let h be Element of NAT ; ::_thesis: for f being FinSequence of NAT st len f >= 1 & s = [0,h,t] & t storeData <*h*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,0*> ) let f be FinSequence of NAT ; ::_thesis: ( len f >= 1 & s = [0,h,t] & t storeData <*h*> ^ f implies ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,0*> ) ) assume that A1: len f >= 1 and A2: s = [0,h,t] and A3: t storeData <*h*> ^ f ; ::_thesis: ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,0*> ) reconsider s3 = s `3_3 as Tape of ZeroTuring ; reconsider h1 = h + 1 as Element of INT by INT_1:def_2; set m = f /. 1; set n = (h + (f /. 1)) + 2; A4: h < h1 by XREAL_1:29; reconsider p1 = 1 as State of ZeroTuring by Lm8; set s1 = [p1,h1,t]; reconsider i2 = h1 + 1 as Element of INT by INT_1:def_2; A5: h1 < i2 by XREAL_1:29; reconsider T = 1 as Symbol of ZeroTuring by Lm9; set t1 = Tape-Chg (t,h1,T); set t2 = Tape-Chg ((Tape-Chg (t,h1,T)),i2,F); set t3 = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T); A6: t is_1_between h,(h + (f /. 1)) + 2 by A1, A3, Th22; then A7: t . h = 0 by Def12; then (Tape-Chg (t,h1,T)) . h = 0 by A4, Th26; then (Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)) . h = 0 by A4, A5, Th26; then A8: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T)) . h = 0 by A4, Th26; A9: TRAN s = Zero_Tran . [(s `1_3),(s3 . (Head s))] by Def19 .= Zero_Tran . [0,(s3 . (Head s))] by A2, MCART_1:64 .= Zero_Tran . [0,(t . (Head s))] by A2, MCART_1:64 .= [1,0,1] by A2, A7, Th33, MCART_1:64 ; then A10: offset (TRAN s) = 1 by MCART_1:64; set Rs = (Computation s) . (((1 + 1) + 1) + 1); reconsider p3 = 3 as State of ZeroTuring by Lm8; A11: (h + 1) + 1 = (h + 0) + 2 ; A12: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T)) . (h + 1) = 1 by Th26; A13: now__::_thesis:_for_k_being_Integer_st_h_<_k_&_k_<_(h_+_0)_+_2_holds_ (Tape-Chg_((Tape-Chg_((Tape-Chg_(t,h1,T)),i2,F)),h1,T))_._k_=_1 let k be Integer; ::_thesis: ( h < k & k < (h + 0) + 2 implies (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T)) . k = 1 ) assume ( h < k & k < (h + 0) + 2 ) ; ::_thesis: (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T)) . k = 1 then ( h + 1 <= k & k <= h + 1 ) by A11, INT_1:7; hence (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T)) . k = 1 by A12, XXREAL_0:1; ::_thesis: verum end; (Tape-Chg (t,h1,T)) . (h + 1) = 1 by Th26; then A14: (Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)) . (h + 1) = 1 by A5, Th26; set s3 = [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]; reconsider s33 = [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] `3_3 as Tape of ZeroTuring ; A15: TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] = Zero_Tran . [([p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] `1_3),(s33 . (Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]))] by Def19 .= Zero_Tran . [p3,(s33 . (Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]))] .= Zero_Tran . [p3,((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)) . (Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]))] .= [4,1,(- 1)] by A14, Th33 ; then A16: offset (TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) = - 1 by MCART_1:64; reconsider p2 = 2 as State of ZeroTuring by Lm8; reconsider s13 = [p1,h1,t] `3_3 as Tape of ZeroTuring ; h <= h + (f /. 1) by NAT_1:11; then A17: h + 2 <= (h + (f /. 1)) + 2 by XREAL_1:7; h1 < h + 2 by XREAL_1:8; then A18: h1 < (h + (f /. 1)) + 2 by A17, XXREAL_0:2; A19: TRAN [p1,h1,t] = Zero_Tran . [([p1,h1,t] `1_3),(s13 . (Head [p1,h1,t]))] by Def19 .= Zero_Tran . [p1,(s13 . (Head [p1,h1,t]))] .= Zero_Tran . [p1,(t . (Head [p1,h1,t]))] .= Zero_Tran . [1,(t . h1)] .= [2,1,1] by A6, A4, A18, Def12, Th33 ; then A20: offset (TRAN [p1,h1,t]) = 1 by MCART_1:64; A21: now__::_thesis:_Zero_Tran_._[2,((Tape-Chg_(t,h1,T))_._i2)]_=_[3,0,(-_1)] A22: the Symbols of ZeroTuring = {0,1} by Def19; percases ( (Tape-Chg (t,h1,T)) . i2 = 1 or (Tape-Chg (t,h1,T)) . i2 = 0 ) by A22, TARSKI:def_2; suppose (Tape-Chg (t,h1,T)) . i2 = 1 ; ::_thesis: Zero_Tran . [2,((Tape-Chg (t,h1,T)) . i2)] = [3,0,(- 1)] hence Zero_Tran . [2,((Tape-Chg (t,h1,T)) . i2)] = [3,0,(- 1)] by Th33; ::_thesis: verum end; suppose (Tape-Chg (t,h1,T)) . i2 = 0 ; ::_thesis: Zero_Tran . [2,((Tape-Chg (t,h1,T)) . i2)] = [3,0,(- 1)] hence Zero_Tran . [2,((Tape-Chg (t,h1,T)) . i2)] = [3,0,(- 1)] by Th33; ::_thesis: verum end; end; end; set s2 = [p2,i2,(Tape-Chg (t,h1,T))]; reconsider s23 = [p2,i2,(Tape-Chg (t,h1,T))] `3_3 as Tape of ZeroTuring ; A23: TRAN [p2,i2,(Tape-Chg (t,h1,T))] = Zero_Tran . [([p2,i2,(Tape-Chg (t,h1,T))] `1_3),(s23 . (Head [p2,i2,(Tape-Chg (t,h1,T))]))] by Def19 .= Zero_Tran . [p2,(s23 . (Head [p2,i2,(Tape-Chg (t,h1,T))]))] .= Zero_Tran . [p2,((Tape-Chg (t,h1,T)) . (Head [p2,i2,(Tape-Chg (t,h1,T))]))] .= [3,0,(- 1)] by A21 ; then A24: offset (TRAN [p2,i2,(Tape-Chg (t,h1,T))]) = - 1 by MCART_1:64; Tape-Chg (([p2,i2,(Tape-Chg (t,h1,T))] `3_3),(Head [p2,i2,(Tape-Chg (t,h1,T))]),((TRAN [p2,i2,(Tape-Chg (t,h1,T))]) `2_3)) = Tape-Chg ((Tape-Chg (t,h1,T)),(Head [p2,i2,(Tape-Chg (t,h1,T))]),((TRAN [p2,i2,(Tape-Chg (t,h1,T))]) `2_3)) .= Tape-Chg ((Tape-Chg (t,h1,T)),i2,((TRAN [p2,i2,(Tape-Chg (t,h1,T))]) `2_3)) .= Tape-Chg ((Tape-Chg (t,h1,T)),i2,F) by A23, MCART_1:64 ; then A25: Following [p2,i2,(Tape-Chg (t,h1,T))] = [((TRAN [p2,i2,(Tape-Chg (t,h1,T))]) `1_3),((Head [p2,i2,(Tape-Chg (t,h1,T))]) + (offset (TRAN [p2,i2,(Tape-Chg (t,h1,T))]))),(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] by Lm10 .= [3,((Head [p2,i2,(Tape-Chg (t,h1,T))]) + (offset (TRAN [p2,i2,(Tape-Chg (t,h1,T))]))),(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] by A23, MCART_1:64 .= [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] by A24 ; reconsider p3 = 3 as State of ZeroTuring by Lm8; A26: Tape-Chg (([p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] `3_3),(Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]),((TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) `2_3)) = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),(Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]),((TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,((TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) `2_3)) .= Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T) by A15, MCART_1:64 ; set s3 = [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]; A27: Following [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))] = [((TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) `1_3),((Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) + (offset (TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T))] by A26, Lm10 .= [4,((Head [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]) + (offset (TRAN [p3,h1,(Tape-Chg ((Tape-Chg (t,h1,T)),i2,F))]))),(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T))] by A15, MCART_1:64 .= [4,h,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T))] by A16 ; Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)) = Tape-Chg (t,(Head s),((TRAN s) `2_3)) by A2, MCART_1:64 .= Tape-Chg (t,h,((TRAN s) `2_3)) by A2, MCART_1:64 .= Tape-Chg (t,h,F) by A9, MCART_1:64 .= t by A7, Th24 ; then A28: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),t] by A2, Lm10 .= [1,((Head s) + (offset (TRAN s))),t] by A9, MCART_1:64 .= [p1,h1,t] by A2, A10, MCART_1:64 ; Tape-Chg (([p1,h1,t] `3_3),(Head [p1,h1,t]),((TRAN [p1,h1,t]) `2_3)) = Tape-Chg (t,(Head [p1,h1,t]),((TRAN [p1,h1,t]) `2_3)) .= Tape-Chg (t,h1,((TRAN [p1,h1,t]) `2_3)) .= Tape-Chg (t,h1,T) by A19, MCART_1:64 ; then A29: Following [p1,h1,t] = [((TRAN [p1,h1,t]) `1_3),((Head [p1,h1,t]) + (offset (TRAN [p1,h1,t]))),(Tape-Chg (t,h1,T))] by Lm10 .= [2,((Head [p1,h1,t]) + (offset (TRAN [p1,h1,t]))),(Tape-Chg (t,h1,T))] by A19, MCART_1:64 .= [p2,i2,(Tape-Chg (t,h1,T))] by A20 ; A30: (Computation s) . (((1 + 1) + 1) + 1) = Following ((Computation s) . ((1 + 1) + 1)) by Def7 .= Following (Following ((Computation s) . (1 + 1))) by Def7 .= Following (Following (Following ((Computation s) . 1))) by Def7 .= [4,h,(Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T))] by A28, A29, A25, A27, Th9 ; then A31: ((Computation s) . (((1 + 1) + 1) + 1)) `1_3 = 4 by MCART_1:64 .= the AcceptS of ZeroTuring by Def19 ; hence s is Accept-Halt by Def8; ::_thesis: ( (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,0*> ) then A32: Result s = (Computation s) . (((1 + 1) + 1) + 1) by A31, Def9; hence (Result s) `2_3 = h by A30, MCART_1:64; ::_thesis: (Result s) `3_3 storeData <*h,0*> A33: (Result s) `3_3 = Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T) by A30, A32, MCART_1:64; (Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)) . i2 = 0 by Th26; then (Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T)) . i2 = 0 by A5, Th26; then Tape-Chg ((Tape-Chg ((Tape-Chg (t,h1,T)),i2,F)),h1,T) is_1_between h,(h + 0) + 2 by A8, A13, Def12; hence (Result s) `3_3 storeData <*h,0*> by A33, Th16; ::_thesis: verum end; theorem :: TURING_1:35 for n being Element of NAT st n >= 1 holds ZeroTuring computes n const 0 proof let n be Element of NAT ; ::_thesis: ( n >= 1 implies ZeroTuring computes n const 0 ) assume A1: n >= 1 ; ::_thesis: ZeroTuring computes n const 0 now__::_thesis:_for_s_being_All-State_of_ZeroTuring for_t_being_Tape_of_ZeroTuring for_h_being_Element_of_NAT_ for_x_being_FinSequence_of_NAT_st_x_in_dom_(n_const_0)_&_s_=_[_the_InitS_of_ZeroTuring,h,t]_&_t_storeData_<*h*>_^_x_holds_ (_s_is_Accept-Halt_&_ex_h2_being_Element_of_NAT_ex_y_being_Element_of_NAT_st_ (_(Result_s)_`2_3_=_h2_&_y_=_(n_const_0)_._x_&_(Result_s)_`3_3_storeData_<*h2*>_^_<*y*>_)_) set cs = n const 0; let s be All-State of ZeroTuring; ::_thesis: for t being Tape of ZeroTuring for h being Element of NAT for x being FinSequence of NAT st x in dom (n const 0) & s = [ the InitS of ZeroTuring,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let t be Tape of ZeroTuring; ::_thesis: for h being Element of NAT for x being FinSequence of NAT st x in dom (n const 0) & s = [ the InitS of ZeroTuring,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let h be Element of NAT ; ::_thesis: for x being FinSequence of NAT st x in dom (n const 0) & s = [ the InitS of ZeroTuring,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let x be FinSequence of NAT ; ::_thesis: ( x in dom (n const 0) & s = [ the InitS of ZeroTuring,h,t] & t storeData <*h*> ^ x implies ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) ) assume that A2: x in dom (n const 0) and A3: s = [ the InitS of ZeroTuring,h,t] and A4: t storeData <*h*> ^ x ; ::_thesis: ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) arity (n const 0) = n by COMPUT_1:32; then A5: dom (n const 0) c= n -tuples_on NAT by COMPUT_1:21; then x in n -tuples_on NAT by A2; then x in { f where f is Element of NAT * : len f = n } by FINSEQ_2:def_4; then A6: ex f being Element of NAT * st ( x = f & len f = n ) ; A7: s = [0,h,t] by A3, Def19; hence s is Accept-Halt by A1, A4, A6, Th34; ::_thesis: ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take h2 = h; ::_thesis: ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take y = 0 ; ::_thesis: ( (Result s) `2_3 = h2 & y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus (Result s) `2_3 = h2 by A1, A4, A6, A7, Th34; ::_thesis: ( y = (n const 0) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus y = (n const 0) . x by A2, A5, FUNCOP_1:7; ::_thesis: (Result s) `3_3 storeData <*h2*> ^ <*y*> (Result s) `3_3 storeData <*h2,0*> by A1, A4, A6, A7, Th34; hence (Result s) `3_3 storeData <*h2*> ^ <*y*> ; ::_thesis: verum end; hence ZeroTuring computes n const 0 by Def15; ::_thesis: verum end; begin definition func U3(n)Tran -> Function of [:(SegM 3),{0,1}:],[:(SegM 3),{0,1},{(- 1),0,1}:] equals :: TURING_1:def 20 (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) +* ([2,0] .--> [3,0,0]); coherence (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) +* ([2,0] .--> [3,0,0]) is Function of [:(SegM 3),{0,1}:],[:(SegM 3),{0,1},{(- 1),0,1}:] proof reconsider p0 = 0 , p1 = 1, p2 = 2, p3 = 3 as Element of SegM 3 by Th1; set A = [:(SegM 3),{0,1}:]; set B = {(- 1),0,1}; set C = [:(SegM 3),{0,1},{(- 1),0,1}:]; reconsider b0 = 0 , b1 = 1 as Element of {0,1} by TARSKI:def_2; reconsider h = 0 , R = 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; [:(SegM 3),{0,1},{(- 1),0,1}:] = [:[:(SegM 3),{0,1}:],{(- 1),0,1}:] by ZFMISC_1:def_3; then reconsider OP = id ([:(SegM 3),{0,1}:],{(- 1),0,1},h) as Function of [:(SegM 3),{0,1}:],[:(SegM 3),{0,1},{(- 1),0,1}:] ; (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) +* ([2,0] .--> [3,0,0]) = ((((OP +* ([p0,b0] .--> [p1,b0,R])) +* ([p1,b1] .--> [p1,b0,R])) +* ([p1,b0] .--> [p2,b0,R])) +* ([p2,b1] .--> [p2,b0,R])) +* ([p2,b0] .--> [p3,b0,h]) ; hence (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) +* ([2,0] .--> [3,0,0]) is Function of [:(SegM 3),{0,1}:],[:(SegM 3),{0,1},{(- 1),0,1}:] ; ::_thesis: verum end; end; :: deftheorem defines U3(n)Tran TURING_1:def_20_:_ U3(n)Tran = (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) +* ([2,0] .--> [3,0,0]); theorem Th36: :: TURING_1:36 ( U3(n)Tran . [0,0] = [1,0,1] & U3(n)Tran . [1,1] = [1,0,1] & U3(n)Tran . [1,0] = [2,0,1] & U3(n)Tran . [2,1] = [2,0,1] & U3(n)Tran . [2,0] = [3,0,0] ) proof set x = [1,1]; set x1 = [0,0]; set p1 = [0,0] .--> [1,0,1]; set p2 = [1,1] .--> [1,0,1]; set p3 = [1,0] .--> [2,0,1]; set p4 = [2,1] .--> [2,0,1]; set f = id ([:(SegM 3),{0,1}:],{(- 1),0,1},0); thus U3(n)Tran . [0,0] = (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) . [0,0] by Th2 .= ((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) . [0,0] by Th2 .= (((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) . [0,0] by Th2 .= ((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) . [0,0] by Th3 .= [1,0,1] by FUNCT_7:94 ; ::_thesis: ( U3(n)Tran . [1,1] = [1,0,1] & U3(n)Tran . [1,0] = [2,0,1] & U3(n)Tran . [2,1] = [2,0,1] & U3(n)Tran . [2,0] = [3,0,0] ) thus U3(n)Tran . [1,1] = (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) . [1,1] by Th2 .= ((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) . [1,1] by Th2 .= (((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) . [1,1] by Th3 .= [1,0,1] by FUNCT_7:94 ; ::_thesis: ( U3(n)Tran . [1,0] = [2,0,1] & U3(n)Tran . [2,1] = [2,0,1] & U3(n)Tran . [2,0] = [3,0,0] ) set x = [1,0]; thus U3(n)Tran . [1,0] = (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) . [1,0] by Th2 .= ((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) . [1,0] by Th3 .= [2,0,1] by FUNCT_7:94 ; ::_thesis: ( U3(n)Tran . [2,1] = [2,0,1] & U3(n)Tran . [2,0] = [3,0,0] ) set x = [2,1]; thus U3(n)Tran . [2,1] = (((((id ([:(SegM 3),{0,1}:],{(- 1),0,1},0)) +* ([0,0] .--> [1,0,1])) +* ([1,1] .--> [1,0,1])) +* ([1,0] .--> [2,0,1])) +* ([2,1] .--> [2,0,1])) . [2,1] by Th3 .= [2,0,1] by FUNCT_7:94 ; ::_thesis: U3(n)Tran . [2,0] = [3,0,0] thus U3(n)Tran . [2,0] = [3,0,0] by FUNCT_7:94; ::_thesis: verum end; definition func U3(n)Turing -> strict TuringStr means :Def21: :: TURING_1:def 21 ( the Symbols of it = {0,1} & the FStates of it = SegM 3 & the Tran of it = U3(n)Tran & the InitS of it = 0 & the AcceptS of it = 3 ); existence ex b1 being strict TuringStr st ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 3 & the Tran of b1 = U3(n)Tran & the InitS of b1 = 0 & the AcceptS of b1 = 3 ) proof set St = SegM 3; reconsider qF = 3 as Element of SegM 3 by Th1; reconsider p0 = 0 as Element of SegM 3 by Th1; set Sym = {0,1}; take TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) ; ::_thesis: ( the Symbols of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = SegM 3 & the Tran of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = U3(n)Tran & the InitS of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = 3 ) thus ( the Symbols of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = {0,1} & the FStates of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = SegM 3 & the Tran of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = U3(n)Tran & the InitS of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = 0 & the AcceptS of TuringStr(# {0,1},(SegM 3),U3(n)Tran,p0,qF #) = 3 ) ; ::_thesis: verum end; uniqueness for b1, b2 being strict TuringStr st the Symbols of b1 = {0,1} & the FStates of b1 = SegM 3 & the Tran of b1 = U3(n)Tran & the InitS of b1 = 0 & the AcceptS of b1 = 3 & the Symbols of b2 = {0,1} & the FStates of b2 = SegM 3 & the Tran of b2 = U3(n)Tran & the InitS of b2 = 0 & the AcceptS of b2 = 3 holds b1 = b2 ; end; :: deftheorem Def21 defines U3(n)Turing TURING_1:def_21_:_ for b1 being strict TuringStr holds ( b1 = U3(n)Turing iff ( the Symbols of b1 = {0,1} & the FStates of b1 = SegM 3 & the Tran of b1 = U3(n)Tran & the InitS of b1 = 0 & the AcceptS of b1 = 3 ) ); Lm11: for n being Element of NAT st n <= 3 holds n is State of U3(n)Turing proof let n be Element of NAT ; ::_thesis: ( n <= 3 implies n is State of U3(n)Turing ) assume A1: n <= 3 ; ::_thesis: n is State of U3(n)Turing the FStates of U3(n)Turing = SegM 3 by Def21; hence n is State of U3(n)Turing by A1, Th1; ::_thesis: verum end; Lm12: ( 0 in the Symbols of U3(n)Turing & 1 in the Symbols of U3(n)Turing ) proof ( 0 in {0,1} & 1 in {0,1} ) by TARSKI:def_2; hence ( 0 in the Symbols of U3(n)Turing & 1 in the Symbols of U3(n)Turing ) by Def21; ::_thesis: verum end; Lm13: for s being All-State of U3(n)Turing for p, h, t being set st s = [p,h,t] & p <> 3 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] proof let s be All-State of U3(n)Turing; ::_thesis: for p, h, t being set st s = [p,h,t] & p <> 3 holds Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] let p, h, t be set ; ::_thesis: ( s = [p,h,t] & p <> 3 implies Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] ) assume A1: ( s = [p,h,t] & p <> 3 ) ; ::_thesis: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] 3 = the AcceptS of U3(n)Turing by Def21; hence Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),(Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)))] by A1, Th25; ::_thesis: verum end; Lm14: for tm being TuringStr for s being All-State of tm for p being State of tm for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) proof let tm be TuringStr ; ::_thesis: for s being All-State of tm for p being State of tm for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) let s be All-State of tm; ::_thesis: for p being State of tm for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) let p be State of tm; ::_thesis: for h being Element of INT for t being Tape of tm for m, d being Element of NAT st d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) let h be Element of INT ; ::_thesis: for t being Tape of tm for m, d being Element of NAT st d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) let t be Tape of tm; ::_thesis: for m, d being Element of NAT st d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) holds ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) let m, d be Element of NAT ; ::_thesis: ( d = h & 0 is Symbol of tm & s = [p,h,t] & the Tran of tm . [p,1] = [p,0,1] & p <> the AcceptS of tm & ( for i being Integer st d <= i & i < d + m holds t . i = 1 ) implies ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) ) assume that A1: d = h and A2: 0 is Symbol of tm and A3: s = [p,h,t] and A4: the Tran of tm . [p,1] = [p,0,1] and A5: p <> the AcceptS of tm and A6: for i being Integer st d <= i & i < d + m holds t . i = 1 ; ::_thesis: ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) defpred S1[ Element of NAT ] means ( $1 <= m implies ex t1 being Tape of tm st ( (Computation s) . $1 = [p,(d + $1),t1] & ( for i being Integer st d <= i & i < d + $1 holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + $1 ) holds t1 . i = t . i ) ) ); A7: for k being Element of NAT st S1[k] holds S1[k + 1] proof let k be Element of NAT ; ::_thesis: ( S1[k] implies S1[k + 1] ) assume A8: S1[k] ; ::_thesis: S1[k + 1] now__::_thesis:_(_k_+_1_<=_m_implies_ex_t2_being_Tape_of_tm_st_ (_(Computation_s)_._(k_+_1)_=_[p,(d_+_(k_+_1)),t2]_&_(_for_i_being_Integer_st_d_<=_i_&_i_<_d_+_(k_+_1)_holds_ t2_._i_=_0_)_&_(_for_i_being_Integer_st_(_d_>_i_or_i_>=_d_+_(k_+_1)_)_holds_ t2_._i_=_t_._i_)_)_) reconsider F = 0 as Symbol of tm by A2; set dk = d + k; reconsider ik = d + k as Element of INT by INT_1:def_2; assume A9: k + 1 <= m ; ::_thesis: ex t2 being Tape of tm st ( (Computation s) . (k + 1) = [p,(d + (k + 1)),t2] & ( for i being Integer st d <= i & i < d + (k + 1) holds t2 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + (k + 1) ) holds t2 . i = t . i ) ) then consider t1 being Tape of tm such that A10: (Computation s) . k = [p,(d + k),t1] and A11: for i being Integer st d <= i & i < d + k holds t1 . i = 0 and A12: for i being Integer st ( d > i or i >= d + k ) holds t1 . i = t . i by A8, NAT_1:13; k < m by A9, NAT_1:13; then A13: d + k < d + m by XREAL_1:8; A14: t1 . ik = t . ik by A12 .= 1 by A6, A13, NAT_1:11 ; take t2 = Tape-Chg (t1,(d + k),F); ::_thesis: ( (Computation s) . (k + 1) = [p,(d + (k + 1)),t2] & ( for i being Integer st d <= i & i < d + (k + 1) holds t2 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + (k + 1) ) holds t2 . i = t . i ) ) set sk = [p,ik,t1]; reconsider tt = [p,ik,t1] `3_3 as Tape of tm ; A15: TRAN [p,ik,t1] = the Tran of tm . [p,(tt . (Head [p,ik,t1]))] .= the Tran of tm . [p,(t1 . (Head [p,ik,t1]))] .= [p,0,1] by A4, A14 ; then A16: offset (TRAN [p,ik,t1]) = 1 by MCART_1:64; A17: Tape-Chg (([p,ik,t1] `3_3),(Head [p,ik,t1]),((TRAN [p,ik,t1]) `2_3)) = Tape-Chg (t1,(Head [p,ik,t1]),((TRAN [p,ik,t1]) `2_3)) .= Tape-Chg (t1,(d + k),((TRAN [p,ik,t1]) `2_3)) .= t2 by A15, MCART_1:64 ; thus (Computation s) . (k + 1) = Following [p,ik,t1] by A10, Def7 .= [((TRAN [p,ik,t1]) `1_3),((Head [p,ik,t1]) + (offset (TRAN [p,ik,t1]))),t2] by A5, A17, Th25 .= [p,((Head [p,ik,t1]) + (offset (TRAN [p,ik,t1]))),t2] by A15, MCART_1:64 .= [p,((d + k) + 1),t2] by A16 .= [p,(d + (k + 1)),t2] ; ::_thesis: ( ( for i being Integer st d <= i & i < d + (k + 1) holds t2 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + (k + 1) ) holds t2 . i = t . i ) ) hereby ::_thesis: for i being Integer st ( d > i or i >= d + (k + 1) ) holds t2 . i = t . i let i be Integer; ::_thesis: ( d <= i & i < d + (k + 1) implies t2 . b1 = 0 ) assume that A18: d <= i and A19: i < d + (k + 1) ; ::_thesis: t2 . b1 = 0 percases ( i = d + k or i <> d + k ) ; suppose i = d + k ; ::_thesis: t2 . b1 = 0 hence t2 . i = 0 by Th26; ::_thesis: verum end; supposeA20: i <> d + k ; ::_thesis: t2 . b1 = 0 i < (d + k) + 1 by A19; then i <= d + k by INT_1:7; then A21: i < d + k by A20, XXREAL_0:1; thus t2 . i = t1 . i by A20, Th26 .= 0 by A11, A18, A21 ; ::_thesis: verum end; end; end; hereby ::_thesis: verum let i be Integer; ::_thesis: ( ( d > i or i >= d + (k + 1) ) implies t2 . b1 = t . b1 ) assume A22: ( d > i or i >= d + (k + 1) ) ; ::_thesis: t2 . b1 = t . b1 percases ( d > i or i >= d + (k + 1) ) by A22; supposeA23: d > i ; ::_thesis: t2 . b1 = t . b1 d <= d + k by NAT_1:12; hence t2 . i = t1 . i by A23, Th26 .= t . i by A12, A23 ; ::_thesis: verum end; supposeA24: i >= d + (k + 1) ; ::_thesis: t2 . b1 = t . b1 k < k + 1 by NAT_1:13; then A25: d + k < d + (k + 1) by XREAL_1:8; then A26: i > d + k by A24, XXREAL_0:2; thus t2 . i = t1 . i by A24, A25, Th26 .= t . i by A12, A26 ; ::_thesis: verum end; end; end; end; hence S1[k + 1] ; ::_thesis: verum end; A27: S1[ 0 ] proof assume 0 <= m ; ::_thesis: ex t1 being Tape of tm st ( (Computation s) . 0 = [p,(d + 0),t1] & ( for i being Integer st d <= i & i < d + 0 holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + 0 ) holds t1 . i = t . i ) ) take t1 = t; ::_thesis: ( (Computation s) . 0 = [p,(d + 0),t1] & ( for i being Integer st d <= i & i < d + 0 holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + 0 ) holds t1 . i = t . i ) ) thus (Computation s) . 0 = [p,(d + 0),t1] by A1, A3, Def7; ::_thesis: ( ( for i being Integer st d <= i & i < d + 0 holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + 0 ) holds t1 . i = t . i ) ) thus for i being Integer st d <= i & i < d + 0 holds t1 . i = 0 ; ::_thesis: for i being Integer st ( d > i or i >= d + 0 ) holds t1 . i = t . i thus for i being Integer st ( d > i or i >= d + 0 ) holds t1 . i = t . i ; ::_thesis: verum end; for k being Element of NAT holds S1[k] from NAT_1:sch_1(A27, A7); hence ex t1 being Tape of tm st ( (Computation s) . m = [p,(d + m),t1] & ( for i being Integer st d <= i & i < d + m holds t1 . i = 0 ) & ( for i being Integer st ( d > i or i >= d + m ) holds t1 . i = t . i ) ) ; ::_thesis: verum end; theorem Th37: :: TURING_1:37 for s being All-State of U3(n)Turing for t being Tape of U3(n)Turing for head being Element of NAT for f being FinSequence of NAT st len f >= 3 & s = [0,head,t] & t storeData <*head*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = ((head + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((head + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) proof reconsider F = 0 as Symbol of U3(n)Turing by Lm12; let s be All-State of U3(n)Turing; ::_thesis: for t being Tape of U3(n)Turing for head being Element of NAT for f being FinSequence of NAT st len f >= 3 & s = [0,head,t] & t storeData <*head*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = ((head + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((head + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) let t be Tape of U3(n)Turing; ::_thesis: for head being Element of NAT for f being FinSequence of NAT st len f >= 3 & s = [0,head,t] & t storeData <*head*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = ((head + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((head + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) let h be Element of NAT ; ::_thesis: for f being FinSequence of NAT st len f >= 3 & s = [0,h,t] & t storeData <*h*> ^ f holds ( s is Accept-Halt & (Result s) `2_3 = ((h + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((h + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) let f be FinSequence of NAT ; ::_thesis: ( len f >= 3 & s = [0,h,t] & t storeData <*h*> ^ f implies ( s is Accept-Halt & (Result s) `2_3 = ((h + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((h + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) ) assume that A1: len f >= 3 and A2: s = [0,h,t] and A3: t storeData <*h*> ^ f ; ::_thesis: ( s is Accept-Halt & (Result s) `2_3 = ((h + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((h + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) set n1 = (h + (f /. 1)) + 2; set n2 = ((h + (f /. 1)) + (f /. 2)) + 4; set n3 = (((h + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6; reconsider s03 = s `3_3 as Tape of U3(n)Turing ; A4: t is_1_between h,(h + (f /. 1)) + 2 by A1, A3, Th23; then A5: t . h = 0 by Def12; A6: TRAN s = U3(n)Tran . [(s `1_3),(s03 . (Head s))] by Def21 .= U3(n)Tran . [0,(s03 . (Head s))] by A2, MCART_1:64 .= U3(n)Tran . [0,(t . (Head s))] by A2, MCART_1:64 .= [1,0,1] by A2, A5, Th36, MCART_1:64 ; then A7: offset (TRAN s) = 1 by MCART_1:64; reconsider p1 = 1 as State of U3(n)Turing by Lm11; set m1 = (f /. 1) + 1; reconsider h1 = h + 1 as Element of INT by INT_1:def_2; set s1 = [p1,h1,t]; A8: t is_1_between (h + (f /. 1)) + 2,((h + (f /. 1)) + (f /. 2)) + 4 by A1, A3, Th23; then A9: t . (((h + (f /. 1)) + (f /. 2)) + 4) = 0 by Def12; Tape-Chg ((s `3_3),(Head s),((TRAN s) `2_3)) = Tape-Chg (t,(Head s),((TRAN s) `2_3)) by A2, MCART_1:64 .= Tape-Chg (t,h,((TRAN s) `2_3)) by A2, MCART_1:64 .= Tape-Chg (t,h,F) by A6, MCART_1:64 .= t by A5, Th24 ; then A10: Following s = [((TRAN s) `1_3),((Head s) + (offset (TRAN s))),t] by A2, Lm13 .= [1,((Head s) + (offset (TRAN s))),t] by A6, MCART_1:64 .= [p1,h1,t] by A2, A7, MCART_1:64 ; A11: t is_1_between ((h + (f /. 1)) + (f /. 2)) + 4,(((h + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6 by A1, A3, Th23; then A12: t . ((((h + (f /. 1)) + (f /. 2)) + (f /. 3)) + 6) = 0 by Def12; reconsider p2 = 2 as State of U3(n)Turing by Lm11; set s2 = (Computation [p1,h1,t]) . ((f /. 1) + 1); reconsider s23 = ((Computation [p1,h1,t]) . ((f /. 1) + 1)) `3_3 as Tape of U3(n)Turing ; set j1 = ((h + 1) + ((f /. 1) + 1)) + 1; reconsider k1 = ((h + 1) + ((f /. 1) + 1)) + 1 as Element of INT by INT_1:def_2; set m2 = (f /. 2) + 1; set Rs = (Computation s) . ((((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) + 1); set m3 = ((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2; A13: now__::_thesis:_for_i_being_Integer_st_h_+_1_<=_i_&_i_<_(h_+_1)_+_((f_/._1)_+_1)_holds_ t_._i_=_1 let i be Integer; ::_thesis: ( h + 1 <= i & i < (h + 1) + ((f /. 1) + 1) implies t . i = 1 ) assume that A14: h + 1 <= i and A15: i < (h + 1) + ((f /. 1) + 1) ; ::_thesis: t . i = 1 h < h + 1 by XREAL_1:29; then h < i by A14, XXREAL_0:2; hence t . i = 1 by A4, A15, Def12; ::_thesis: verum end; ( the Tran of U3(n)Turing . [p1,1] = [p1,0,1] & p1 <> the AcceptS of U3(n)Turing ) by Def21, Th36; then consider t1 being Tape of U3(n)Turing such that A16: (Computation [p1,h1,t]) . ((f /. 1) + 1) = [p1,((h + 1) + ((f /. 1) + 1)),t1] and for i being Integer st h + 1 <= i & i < (h + 1) + ((f /. 1) + 1) holds t1 . i = 0 and A17: for i being Integer st ( h + 1 > i or i >= (h + 1) + ((f /. 1) + 1) ) holds t1 . i = t . i by A13, Lm12, Lm14; t . ((h + (f /. 1)) + 2) = 0 by A4, Def12; then A18: t1 . ((h + 1) + ((f /. 1) + 1)) = 0 by A17; A19: TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1)) = U3(n)Tran . [(((Computation [p1,h1,t]) . ((f /. 1) + 1)) `1_3),(s23 . (Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))))] by Def21 .= U3(n)Tran . [p1,(s23 . (Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))))] by A16, MCART_1:64 .= U3(n)Tran . [1,(t1 . (Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))))] by A16, MCART_1:64 .= [2,0,1] by A16, A18, Th36, MCART_1:64 ; then A20: offset (TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))) = 1 by MCART_1:64; set s3 = [p2,k1,t1]; Tape-Chg ((((Computation [p1,h1,t]) . ((f /. 1) + 1)) `3_3),(Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))),((TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))) `2_3)) = Tape-Chg (t1,(Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))),((TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))) `2_3)) by A16, MCART_1:64 .= Tape-Chg (t1,((h + 1) + ((f /. 1) + 1)),((TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))) `2_3)) by A16, MCART_1:64 .= Tape-Chg (t1,((h + 1) + ((f /. 1) + 1)),F) by A19, MCART_1:64 .= t1 by A18, Th24 ; then A21: Following ((Computation [p1,h1,t]) . ((f /. 1) + 1)) = [((TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))) `1_3),((Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))) + (offset (TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))))),t1] by A16, Lm13 .= [2,((Head ((Computation [p1,h1,t]) . ((f /. 1) + 1))) + (offset (TRAN ((Computation [p1,h1,t]) . ((f /. 1) + 1))))),t1] by A19, MCART_1:64 .= [p2,k1,t1] by A16, A20, MCART_1:64 ; A22: now__::_thesis:_for_i_being_Integer_st_((h_+_1)_+_((f_/._1)_+_1))_+_1_<=_i_&_i_<_(((h_+_1)_+_((f_/._1)_+_1))_+_1)_+_((f_/._2)_+_1)_holds_ t1_._i_=_1 let i be Integer; ::_thesis: ( ((h + 1) + ((f /. 1) + 1)) + 1 <= i & i < (((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1) implies t1 . i = 1 ) assume that A23: ((h + 1) + ((f /. 1) + 1)) + 1 <= i and A24: i < (((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1) ; ::_thesis: t1 . i = 1 (h + 1) + ((f /. 1) + 1) < ((h + 1) + ((f /. 1) + 1)) + 1 by XREAL_1:29; then A25: (h + 1) + ((f /. 1) + 1) < i by A23, XXREAL_0:2; hence t1 . i = t . i by A17 .= 1 by A8, A24, A25, Def12 ; ::_thesis: verum end; set s4 = (Computation [p2,k1,t1]) . ((f /. 2) + 1); reconsider s43 = ((Computation [p2,k1,t1]) . ((f /. 2) + 1)) `3_3 as Tape of U3(n)Turing ; ( the Tran of U3(n)Turing . [p2,1] = [p2,0,1] & p2 <> the AcceptS of U3(n)Turing ) by Def21, Th36; then consider t2 being Tape of U3(n)Turing such that A26: (Computation [p2,k1,t1]) . ((f /. 2) + 1) = [p2,((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)),t2] and for i being Integer st ((h + 1) + ((f /. 1) + 1)) + 1 <= i & i < (((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1) holds t2 . i = 0 and A27: for i being Integer st ( ((h + 1) + ((f /. 1) + 1)) + 1 > i or i >= (((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1) ) holds t2 . i = t1 . i by A22, Lm12, Lm14; 2 <= (f /. 2) + 4 by NAT_1:12; then A28: (h + (f /. 1)) + 2 <= (h + (f /. 1)) + ((f /. 2) + 4) by XREAL_1:7; A29: now__::_thesis:_for_k_being_Integer_st_((h_+_(f_/._1))_+_(f_/._2))_+_4_<_k_&_k_<_((((h_+_(f_/._1))_+_(f_/._2))_+_4)_+_(f_/._3))_+_2_holds_ t2_._k_=_1 let k be Integer; ::_thesis: ( ((h + (f /. 1)) + (f /. 2)) + 4 < k & k < ((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2 implies t2 . k = 1 ) assume that A30: ((h + (f /. 1)) + (f /. 2)) + 4 < k and A31: k < ((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2 ; ::_thesis: t2 . k = 1 A32: (h + (f /. 1)) + 2 <= k by A28, A30, XXREAL_0:2; thus t2 . k = t1 . k by A27, A30 .= t . k by A17, A32 .= 1 by A11, A30, A31, Def12 ; ::_thesis: verum end; A33: t2 . ((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)) = t1 . ((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)) by A27 .= 0 by A9, A17, A28 ; A34: TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1)) = U3(n)Tran . [(((Computation [p2,k1,t1]) . ((f /. 2) + 1)) `1_3),(s43 . (Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))))] by Def21 .= U3(n)Tran . [p2,(s43 . (Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))))] by A26, MCART_1:64 .= U3(n)Tran . [2,(t2 . (Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))))] by A26, MCART_1:64 .= [3,0,0] by A26, A33, Th36, MCART_1:64 ; then A35: offset (TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) = 0 by MCART_1:64; Tape-Chg ((((Computation [p2,k1,t1]) . ((f /. 2) + 1)) `3_3),(Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))),((TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) `2_3)) = Tape-Chg (t2,(Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))),((TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) `2_3)) by A26, MCART_1:64 .= Tape-Chg (t2,((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)),((TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) `2_3)) by A26, MCART_1:64 .= Tape-Chg (t2,((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)),F) by A34, MCART_1:64 .= t2 by A33, Th24 ; then A36: Following ((Computation [p2,k1,t1]) . ((f /. 2) + 1)) = [((TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) `1_3),((Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) + (offset (TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))))),t2] by A26, Lm13 .= [3,((Head ((Computation [p2,k1,t1]) . ((f /. 2) + 1))) + (offset (TRAN ((Computation [p2,k1,t1]) . ((f /. 2) + 1))))),t2] by A34, MCART_1:64 .= [3,(((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)) + 0),t2] by A26, A35, MCART_1:64 ; (Computation s) . ((((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) + 1) = (Computation ((Computation s) . 1)) . (((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) by Th10 .= (Computation [p1,h1,t]) . (((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) by A10, Th9 .= (Computation ((Computation [p1,h1,t]) . ((f /. 1) + 1))) . ((((f /. 2) + 1) + 1) + 1) by Th10 ; then A37: (Computation s) . ((((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) + 1) = (Computation ((Computation ((Computation [p1,h1,t]) . ((f /. 1) + 1))) . 1)) . (((f /. 2) + 1) + 1) by Th10 .= (Computation [p2,k1,t1]) . (((f /. 2) + 1) + 1) by A21, Th9 .= [3,((((h + 1) + ((f /. 1) + 1)) + 1) + ((f /. 2) + 1)),t2] by A36, Def7 ; then A38: ((Computation s) . ((((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) + 1)) `1_3 = 3 by MCART_1:64 .= the AcceptS of U3(n)Turing by Def21 ; hence s is Accept-Halt by Def8; ::_thesis: ( (Result s) `2_3 = ((h + (f /. 1)) + (f /. 2)) + 4 & (Result s) `3_3 storeData <*(((h + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> ) then A39: Result s = (Computation s) . ((((((f /. 2) + 1) + 1) + 1) + ((f /. 1) + 1)) + 1) by A38, Def9; hence (Result s) `2_3 = ((h + (f /. 1)) + (f /. 2)) + 4 by A37, MCART_1:64; ::_thesis: (Result s) `3_3 storeData <*(((h + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> A40: (Result s) `3_3 = t2 by A37, A39, MCART_1:64; A41: ((h + (f /. 1)) + (f /. 2)) + 4 <= (((h + (f /. 1)) + (f /. 2)) + 4) + ((f /. 3) + 2) by NAT_1:11; then A42: (h + (f /. 1)) + 2 <= ((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2 by A28, XXREAL_0:2; t2 . (((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2) = t1 . (((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2) by A27, A41 .= 0 by A12, A17, A42 ; then t2 is_1_between ((h + (f /. 1)) + (f /. 2)) + 4,((((h + (f /. 1)) + (f /. 2)) + 4) + (f /. 3)) + 2 by A33, A29, Def12; hence (Result s) `3_3 storeData <*(((h + (f /. 1)) + (f /. 2)) + 4),(f /. 3)*> by A40, Th16; ::_thesis: verum end; theorem :: TURING_1:38 for n being Element of NAT st n >= 3 holds U3(n)Turing computes n proj 3 proof let n be Element of NAT ; ::_thesis: ( n >= 3 implies U3(n)Turing computes n proj 3 ) assume A1: n >= 3 ; ::_thesis: U3(n)Turing computes n proj 3 now__::_thesis:_for_s_being_All-State_of_U3(n)Turing for_t_being_Tape_of_U3(n)Turing for_h_being_Element_of_NAT_ for_x_being_FinSequence_of_NAT_st_x_in_dom_(n_proj_3)_&_s_=_[_the_InitS_of_U3(n)Turing,h,t]_&_t_storeData_<*h*>_^_x_holds_ (_s_is_Accept-Halt_&_ex_h2_being_Element_of_NAT_ex_y_being_Element_of_NAT_st_ (_(Result_s)_`2_3_=_h2_&_y_=_(n_proj_3)_._x_&_(Result_s)_`3_3_storeData_<*h2*>_^_<*y*>_)_) set pj = n proj 3; let s be All-State of U3(n)Turing; ::_thesis: for t being Tape of U3(n)Turing for h being Element of NAT for x being FinSequence of NAT st x in dom (n proj 3) & s = [ the InitS of U3(n)Turing,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let t be Tape of U3(n)Turing; ::_thesis: for h being Element of NAT for x being FinSequence of NAT st x in dom (n proj 3) & s = [ the InitS of U3(n)Turing,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let h be Element of NAT ; ::_thesis: for x being FinSequence of NAT st x in dom (n proj 3) & s = [ the InitS of U3(n)Turing,h,t] & t storeData <*h*> ^ x holds ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) let x be FinSequence of NAT ; ::_thesis: ( x in dom (n proj 3) & s = [ the InitS of U3(n)Turing,h,t] & t storeData <*h*> ^ x implies ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) ) assume that A2: x in dom (n proj 3) and A3: s = [ the InitS of U3(n)Turing,h,t] and A4: t storeData <*h*> ^ x ; ::_thesis: ( s is Accept-Halt & ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) ) arity (n proj 3) = n by COMPUT_1:37; then A5: dom (n proj 3) c= n -tuples_on NAT by COMPUT_1:21; then x in n -tuples_on NAT by A2; then x in { f where f is Element of NAT * : len f = n } by FINSEQ_2:def_4; then A6: ex f being Element of NAT * st ( x = f & len f = n ) ; A7: s = [0,h,t] by A3, Def21; hence s is Accept-Halt by A1, A4, A6, Th37; ::_thesis: ex h2 being Element of NAT ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take h2 = ((h + (x /. 1)) + (x /. 2)) + 4; ::_thesis: ex y being Element of NAT st ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) take y = x /. 3; ::_thesis: ( (Result s) `2_3 = h2 & y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus (Result s) `2_3 = h2 by A1, A4, A6, A7, Th37; ::_thesis: ( y = (n proj 3) . x & (Result s) `3_3 storeData <*h2*> ^ <*y*> ) thus y = x . 3 by A1, A6, FINSEQ_4:15 .= (n proj 3) . x by A2, A5, COMPUT_1:38 ; ::_thesis: (Result s) `3_3 storeData <*h2*> ^ <*y*> (Result s) `3_3 storeData <*h2,y*> by A1, A4, A6, A7, Th37; hence (Result s) `3_3 storeData <*h2*> ^ <*y*> ; ::_thesis: verum end; hence U3(n)Turing computes n proj 3 by Def15; ::_thesis: verum end; begin definition let t1, t2 be TuringStr ; func UnionSt (t1,t2) -> non empty finite set equals :: TURING_1:def 22 [: the FStates of t1,{ the InitS of t2}:] \/ [:{ the AcceptS of t1}, the FStates of t2:]; correctness coherence [: the FStates of t1,{ the InitS of t2}:] \/ [:{ the AcceptS of t1}, the FStates of t2:] is non empty finite set ; ; end; :: deftheorem defines UnionSt TURING_1:def_22_:_ for t1, t2 being TuringStr holds UnionSt (t1,t2) = [: the FStates of t1,{ the InitS of t2}:] \/ [:{ the AcceptS of t1}, the FStates of t2:]; theorem Th39: :: TURING_1:39 for t1, t2 being TuringStr holds ( [ the InitS of t1, the InitS of t2] in UnionSt (t1,t2) & [ the AcceptS of t1, the AcceptS of t2] in UnionSt (t1,t2) ) proof let t1, t2 be TuringStr ; ::_thesis: ( [ the InitS of t1, the InitS of t2] in UnionSt (t1,t2) & [ the AcceptS of t1, the AcceptS of t2] in UnionSt (t1,t2) ) set p0 = the InitS of t1; set q0 = the InitS of t2; set p1 = the AcceptS of t1; set q1 = the AcceptS of t2; set A = [: the FStates of t1,{ the InitS of t2}:]; set B = [:{ the AcceptS of t1}, the FStates of t2:]; reconsider q = the InitS of t2 as Element of { the InitS of t2} by TARSKI:def_1; reconsider p = the AcceptS of t1 as Element of { the AcceptS of t1} by TARSKI:def_1; [ the InitS of t1,q] in [: the FStates of t1,{ the InitS of t2}:] ; hence [ the InitS of t1, the InitS of t2] in UnionSt (t1,t2) by XBOOLE_0:def_3; ::_thesis: [ the AcceptS of t1, the AcceptS of t2] in UnionSt (t1,t2) [p, the AcceptS of t2] in [:{ the AcceptS of t1}, the FStates of t2:] ; hence [ the AcceptS of t1, the AcceptS of t2] in UnionSt (t1,t2) by XBOOLE_0:def_3; ::_thesis: verum end; theorem Th40: :: TURING_1:40 for s, t being TuringStr for x being State of s holds [x, the InitS of t] in UnionSt (s,t) proof let s, t be TuringStr ; ::_thesis: for x being State of s holds [x, the InitS of t] in UnionSt (s,t) let x be State of s; ::_thesis: [x, the InitS of t] in UnionSt (s,t) set q0 = the InitS of t; set A = [: the FStates of s,{ the InitS of t}:]; reconsider q = the InitS of t as Element of { the InitS of t} by TARSKI:def_1; [x,q] in [: the FStates of s,{ the InitS of t}:] ; hence [x, the InitS of t] in UnionSt (s,t) by XBOOLE_0:def_3; ::_thesis: verum end; theorem Th41: :: TURING_1:41 for s, t being TuringStr for x being State of t holds [ the AcceptS of s,x] in UnionSt (s,t) proof let s, t be TuringStr ; ::_thesis: for x being State of t holds [ the AcceptS of s,x] in UnionSt (s,t) let x be State of t; ::_thesis: [ the AcceptS of s,x] in UnionSt (s,t) set p1 = the AcceptS of s; set B = [:{ the AcceptS of s}, the FStates of t:]; reconsider p = the AcceptS of s as Element of { the AcceptS of s} by TARSKI:def_1; [p,x] in [:{ the AcceptS of s}, the FStates of t:] ; hence [ the AcceptS of s,x] in UnionSt (s,t) by XBOOLE_0:def_3; ::_thesis: verum end; theorem Th42: :: TURING_1:42 for s, t being TuringStr for x being Element of UnionSt (s,t) ex x1 being State of s ex x2 being State of t st x = [x1,x2] proof let s, t be TuringStr ; ::_thesis: for x being Element of UnionSt (s,t) ex x1 being State of s ex x2 being State of t st x = [x1,x2] let x be Element of UnionSt (s,t); ::_thesis: ex x1 being State of s ex x2 being State of t st x = [x1,x2] set q0 = the InitS of t; set p1 = the AcceptS of s; set A = [: the FStates of s,{ the InitS of t}:]; set B = [:{ the AcceptS of s}, the FStates of t:]; percases ( x in [: the FStates of s,{ the InitS of t}:] or x in [:{ the AcceptS of s}, the FStates of t:] ) by XBOOLE_0:def_3; suppose x in [: the FStates of s,{ the InitS of t}:] ; ::_thesis: ex x1 being State of s ex x2 being State of t st x = [x1,x2] then consider x1 being State of s, x2 being Element of { the InitS of t} such that A1: x = [x1,x2] by DOMAIN_1:1; take x1 ; ::_thesis: ex x2 being State of t st x = [x1,x2] take the InitS of t ; ::_thesis: x = [x1, the InitS of t] thus x = [x1, the InitS of t] by A1, TARSKI:def_1; ::_thesis: verum end; suppose x in [:{ the AcceptS of s}, the FStates of t:] ; ::_thesis: ex x1 being State of s ex x2 being State of t st x = [x1,x2] then consider x1 being Element of { the AcceptS of s}, x2 being State of t such that A2: x = [x1,x2] by DOMAIN_1:1; take the AcceptS of s ; ::_thesis: ex x2 being State of t st x = [ the AcceptS of s,x2] take x2 ; ::_thesis: x = [ the AcceptS of s,x2] thus x = [ the AcceptS of s,x2] by A2, TARSKI:def_1; ::_thesis: verum end; end; end; definition let s, t be TuringStr ; let x be Tran-Goal of s; func FirstTuringTran (s,t,x) -> Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] equals :: TURING_1:def 23 [[(x `1_3), the InitS of t],(x `2_3),(x `3_3)]; coherence [[(x `1_3), the InitS of t],(x `2_3),(x `3_3)] is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] proof reconsider y1 = [(x `1_3), the InitS of t] as Element of UnionSt (s,t) by Th40; set Sym = the Symbols of s \/ the Symbols of t; reconsider y2 = x `2_3 as Element of the Symbols of s \/ the Symbols of t by XBOOLE_0:def_3; [y1,y2,(x `3_3)] in [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ; hence [[(x `1_3), the InitS of t],(x `2_3),(x `3_3)] is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ; ::_thesis: verum end; end; :: deftheorem defines FirstTuringTran TURING_1:def_23_:_ for s, t being TuringStr for x being Tran-Goal of s holds FirstTuringTran (s,t,x) = [[(x `1_3), the InitS of t],(x `2_3),(x `3_3)]; definition let s, t be TuringStr ; let x be Tran-Goal of t; func SecondTuringTran (s,t,x) -> Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] equals :: TURING_1:def 24 [[ the AcceptS of s,(x `1_3)],(x `2_3),(x `3_3)]; coherence [[ the AcceptS of s,(x `1_3)],(x `2_3),(x `3_3)] is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] proof reconsider y1 = [ the AcceptS of s,(x `1_3)] as Element of UnionSt (s,t) by Th41; set Sym = the Symbols of s \/ the Symbols of t; reconsider y2 = x `2_3 as Element of the Symbols of s \/ the Symbols of t by XBOOLE_0:def_3; [y1,y2,(x `3_3)] in [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ; hence [[ the AcceptS of s,(x `1_3)],(x `2_3),(x `3_3)] is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ; ::_thesis: verum end; end; :: deftheorem defines SecondTuringTran TURING_1:def_24_:_ for s, t being TuringStr for x being Tran-Goal of t holds SecondTuringTran (s,t,x) = [[ the AcceptS of s,(x `1_3)],(x `2_3),(x `3_3)]; definition let s, t be TuringStr ; let x be Element of UnionSt (s,t); :: original: `1 redefine funcx `1 -> State of s; coherence x `1 is State of s proof consider x1 being State of s, x2 being State of t such that A1: x = [x1,x2] by Th42; [x1,x2] `1 = x1 ; hence x `1 is State of s by A1; ::_thesis: verum end; :: original: `2 redefine funcx `2 -> State of t; coherence x `2 is State of t proof consider x1 being State of s, x2 being State of t such that A2: x = [x1,x2] by Th42; [x1,x2] `2 = x2 ; hence x `2 is State of t by A2; ::_thesis: verum end; end; definition let s, t be TuringStr ; let x be Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):]; func FirstTuringState x -> State of s equals :: TURING_1:def 25 (x `1) `1 ; correctness coherence (x `1) `1 is State of s; ; func SecondTuringState x -> State of t equals :: TURING_1:def 26 (x `1) `2 ; correctness coherence (x `1) `2 is State of t; ; end; :: deftheorem defines FirstTuringState TURING_1:def_25_:_ for s, t being TuringStr for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds FirstTuringState x = (x `1) `1 ; :: deftheorem defines SecondTuringState TURING_1:def_26_:_ for s, t being TuringStr for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds SecondTuringState x = (x `1) `2 ; definition let X, Y, Z be non empty set ; let x be Element of [:X,(Y \/ Z):]; given u being set , y being Element of Y such that A1: x = [u,y] ; A2: [u,y] `2 = y ; func FirstTuringSymbol x -> Element of Y equals :Def27: :: TURING_1:def 27 x `2 ; coherence x `2 is Element of Y by A1, A2; end; :: deftheorem Def27 defines FirstTuringSymbol TURING_1:def_27_:_ for X, Y, Z being non empty set for x being Element of [:X,(Y \/ Z):] st ex u being set ex y being Element of Y st x = [u,y] holds FirstTuringSymbol x = x `2 ; definition let X, Y, Z be non empty set ; let x be Element of [:X,(Y \/ Z):]; given u being set , z being Element of Z such that A1: x = [u,z] ; A2: [u,z] `2 = z ; func SecondTuringSymbol x -> Element of Z equals :Def28: :: TURING_1:def 28 x `2 ; coherence x `2 is Element of Z by A1, A2; end; :: deftheorem Def28 defines SecondTuringSymbol TURING_1:def_28_:_ for X, Y, Z being non empty set for x being Element of [:X,(Y \/ Z):] st ex u being set ex z being Element of Z st x = [u,z] holds SecondTuringSymbol x = x `2 ; definition let s, t be TuringStr ; let x be Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):]; func Uniontran (s,t,x) -> Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] equals :Def29: :: TURING_1:def 29 FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) if ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) if ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] otherwise [(x `1),(x `2),(- 1)]; consistency for b1 being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] st ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) & ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] holds ( b1 = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) iff b1 = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) proof let w be Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:]; ::_thesis: ( ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) & ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] implies ( w = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) iff w = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) ) thus ( ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) & ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] implies ( w = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) iff w = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) ) ::_thesis: verum proof given p being State of s, y being Symbol of s such that A1: x = [[p, the InitS of t],y] and A2: p <> the AcceptS of s ; ::_thesis: ( for q being State of t for y being Symbol of t holds not x = [[ the AcceptS of s,q],y] or ( w = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) iff w = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) ) given q being State of t, z being Symbol of t such that A3: x = [[ the AcceptS of s,q],z] ; ::_thesis: ( w = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) iff w = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) [p, the InitS of t] = [ the AcceptS of s,q] by A1, A3, XTUPLE_0:1; hence ( w = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) iff w = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) by A2, XTUPLE_0:1; ::_thesis: verum end; end; coherence ( ( ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) implies FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ) & ( ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] implies SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ) & ( ( for p being State of s for y being Symbol of s holds ( not x = [[p, the InitS of t],y] or not p <> the AcceptS of s ) ) & ( for q being State of t for y being Symbol of t holds not x = [[ the AcceptS of s,q],y] ) implies [(x `1),(x `2),(- 1)] is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ) ) proof reconsider l = - 1 as Element of {(- 1),0,1} by ENUMSET1:def_1; [(x `1),(x `2),l] in [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ; hence ( ( ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) implies FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ) & ( ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] implies SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ) & ( ( for p being State of s for y being Symbol of s holds ( not x = [[p, the InitS of t],y] or not p <> the AcceptS of s ) ) & ( for q being State of t for y being Symbol of t holds not x = [[ the AcceptS of s,q],y] ) implies [(x `1),(x `2),(- 1)] is Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] ) ) ; ::_thesis: verum end; end; :: deftheorem Def29 defines Uniontran TURING_1:def_29_:_ for s, t being TuringStr for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds ( ( ex p being State of s ex y being Symbol of s st ( x = [[p, the InitS of t],y] & p <> the AcceptS of s ) implies Uniontran (s,t,x) = FirstTuringTran (s,t,( the Tran of s . [(FirstTuringState x),(FirstTuringSymbol x)])) ) & ( ex q being State of t ex y being Symbol of t st x = [[ the AcceptS of s,q],y] implies Uniontran (s,t,x) = SecondTuringTran (s,t,( the Tran of t . [(SecondTuringState x),(SecondTuringSymbol x)])) ) & ( ( for p being State of s for y being Symbol of s holds ( not x = [[p, the InitS of t],y] or not p <> the AcceptS of s ) ) & ( for q being State of t for y being Symbol of t holds not x = [[ the AcceptS of s,q],y] ) implies Uniontran (s,t,x) = [(x `1),(x `2),(- 1)] ) ); definition let s, t be TuringStr ; func UnionTran (s,t) -> Function of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):],[:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] means :Def30: :: TURING_1:def 30 for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds it . x = Uniontran (s,t,x); existence ex b1 being Function of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):],[:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] st for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds b1 . x = Uniontran (s,t,x) proof set Sm = the Symbols of s \/ the Symbols of t; set X = [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):]; deffunc H1( Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):]) -> Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] = Uniontran (s,t,$1); consider f being Function of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):],[:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] such that A1: for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds f . x = H1(x) from FUNCT_2:sch_4(); take f ; ::_thesis: for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds f . x = Uniontran (s,t,x) thus for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds f . x = Uniontran (s,t,x) by A1; ::_thesis: verum end; uniqueness for b1, b2 being Function of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):],[:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] st ( for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds b1 . x = Uniontran (s,t,x) ) & ( for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds b2 . x = Uniontran (s,t,x) ) holds b1 = b2 proof set Sm = the Symbols of s \/ the Symbols of t; set X = [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):]; let f, g be Function of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):],[:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:]; ::_thesis: ( ( for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds f . x = Uniontran (s,t,x) ) & ( for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds g . x = Uniontran (s,t,x) ) implies f = g ) assume that A2: for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds f . x = Uniontran (s,t,x) and A3: for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds g . x = Uniontran (s,t,x) ; ::_thesis: f = g now__::_thesis:_for_x_being_Element_of_[:(UnionSt_(s,t)),(_the_Symbols_of_s_\/_the_Symbols_of_t):]_holds_f_._x_=_g_._x let x be Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):]; ::_thesis: f . x = g . x thus f . x = Uniontran (s,t,x) by A2 .= g . x by A3 ; ::_thesis: verum end; hence f = g by FUNCT_2:63; ::_thesis: verum end; end; :: deftheorem Def30 defines UnionTran TURING_1:def_30_:_ for s, t being TuringStr for b3 being Function of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):],[:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t),{(- 1),0,1}:] holds ( b3 = UnionTran (s,t) iff for x being Element of [:(UnionSt (s,t)),( the Symbols of s \/ the Symbols of t):] holds b3 . x = Uniontran (s,t,x) ); definition let T1, T2 be TuringStr ; funcT1 ';' T2 -> strict TuringStr means :Def31: :: TURING_1:def 31 ( the Symbols of it = the Symbols of T1 \/ the Symbols of T2 & the FStates of it = UnionSt (T1,T2) & the Tran of it = UnionTran (T1,T2) & the InitS of it = [ the InitS of T1, the InitS of T2] & the AcceptS of it = [ the AcceptS of T1, the AcceptS of T2] ); existence ex b1 being strict TuringStr st ( the Symbols of b1 = the Symbols of T1 \/ the Symbols of T2 & the FStates of b1 = UnionSt (T1,T2) & the Tran of b1 = UnionTran (T1,T2) & the InitS of b1 = [ the InitS of T1, the InitS of T2] & the AcceptS of b1 = [ the AcceptS of T1, the AcceptS of T2] ) proof set St = UnionSt (T1,T2); reconsider q1 = [ the AcceptS of T1, the AcceptS of T2] as Element of UnionSt (T1,T2) by Th39; reconsider p0 = [ the InitS of T1, the InitS of T2] as Element of UnionSt (T1,T2) by Th39; set Sym = the Symbols of T1 \/ the Symbols of T2; take TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) ; ::_thesis: ( the Symbols of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = the Symbols of T1 \/ the Symbols of T2 & the FStates of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = UnionSt (T1,T2) & the Tran of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = UnionTran (T1,T2) & the InitS of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = [ the InitS of T1, the InitS of T2] & the AcceptS of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = [ the AcceptS of T1, the AcceptS of T2] ) thus ( the Symbols of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = the Symbols of T1 \/ the Symbols of T2 & the FStates of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = UnionSt (T1,T2) & the Tran of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = UnionTran (T1,T2) & the InitS of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = [ the InitS of T1, the InitS of T2] & the AcceptS of TuringStr(# ( the Symbols of T1 \/ the Symbols of T2),(UnionSt (T1,T2)),(UnionTran (T1,T2)),p0,q1 #) = [ the AcceptS of T1, the AcceptS of T2] ) ; ::_thesis: verum end; uniqueness for b1, b2 being strict TuringStr st the Symbols of b1 = the Symbols of T1 \/ the Symbols of T2 & the FStates of b1 = UnionSt (T1,T2) & the Tran of b1 = UnionTran (T1,T2) & the InitS of b1 = [ the InitS of T1, the InitS of T2] & the AcceptS of b1 = [ the AcceptS of T1, the AcceptS of T2] & the Symbols of b2 = the Symbols of T1 \/ the Symbols of T2 & the FStates of b2 = UnionSt (T1,T2) & the Tran of b2 = UnionTran (T1,T2) & the InitS of b2 = [ the InitS of T1, the InitS of T2] & the AcceptS of b2 = [ the AcceptS of T1, the AcceptS of T2] holds b1 = b2 ; end; :: deftheorem Def31 defines ';' TURING_1:def_31_:_ for T1, T2 being TuringStr for b3 being strict TuringStr holds ( b3 = T1 ';' T2 iff ( the Symbols of b3 = the Symbols of T1 \/ the Symbols of T2 & the FStates of b3 = UnionSt (T1,T2) & the Tran of b3 = UnionTran (T1,T2) & the InitS of b3 = [ the InitS of T1, the InitS of T2] & the AcceptS of b3 = [ the AcceptS of T1, the AcceptS of T2] ) ); theorem Th43: :: TURING_1:43 for T1, T2 being TuringStr for g being Tran-Goal of T1 for p being State of T1 for y being Symbol of T1 st p <> the AcceptS of T1 & g = the Tran of T1 . [p,y] holds the Tran of (T1 ';' T2) . [[p, the InitS of T2],y] = [[(g `1_3), the InitS of T2],(g `2_3),(g `3_3)] proof let t1, t2 be TuringStr ; ::_thesis: for g being Tran-Goal of t1 for p being State of t1 for y being Symbol of t1 st p <> the AcceptS of t1 & g = the Tran of t1 . [p,y] holds the Tran of (t1 ';' t2) . [[p, the InitS of t2],y] = [[(g `1_3), the InitS of t2],(g `2_3),(g `3_3)] let g be Tran-Goal of t1; ::_thesis: for p being State of t1 for y being Symbol of t1 st p <> the AcceptS of t1 & g = the Tran of t1 . [p,y] holds the Tran of (t1 ';' t2) . [[p, the InitS of t2],y] = [[(g `1_3), the InitS of t2],(g `2_3),(g `3_3)] let p be State of t1; ::_thesis: for y being Symbol of t1 st p <> the AcceptS of t1 & g = the Tran of t1 . [p,y] holds the Tran of (t1 ';' t2) . [[p, the InitS of t2],y] = [[(g `1_3), the InitS of t2],(g `2_3),(g `3_3)] let y be Symbol of t1; ::_thesis: ( p <> the AcceptS of t1 & g = the Tran of t1 . [p,y] implies the Tran of (t1 ';' t2) . [[p, the InitS of t2],y] = [[(g `1_3), the InitS of t2],(g `2_3),(g `3_3)] ) assume that A1: p <> the AcceptS of t1 and A2: g = the Tran of t1 . [p,y] ; ::_thesis: the Tran of (t1 ';' t2) . [[p, the InitS of t2],y] = [[(g `1_3), the InitS of t2],(g `2_3),(g `3_3)] set q0 = the InitS of t2; set x = [[p, the InitS of t2],y]; the InitS of t2 in { the InitS of t2} by TARSKI:def_1; then [p, the InitS of t2] in [: the FStates of t1,{ the InitS of t2}:] by ZFMISC_1:def_2; then A3: [p, the InitS of t2] in [: the FStates of t1,{ the InitS of t2}:] \/ [:{ the AcceptS of t1}, the FStates of t2:] by XBOOLE_0:def_3; y in the Symbols of t1 \/ the Symbols of t2 by XBOOLE_0:def_3; then reconsider xx = [[p, the InitS of t2],y] as Element of [:(UnionSt (t1,t2)),( the Symbols of t1 \/ the Symbols of t2):] by A3, ZFMISC_1:def_2; A4: FirstTuringState xx = ([[p, the InitS of t2],y] `1) `1 .= [p, the InitS of t2] `1 .= p ; A5: FirstTuringSymbol xx = [[p, the InitS of t2],y] `2 by Def27 .= y ; thus the Tran of (t1 ';' t2) . [[p, the InitS of t2],y] = (UnionTran (t1,t2)) . xx by Def31 .= Uniontran (t1,t2,xx) by Def30 .= FirstTuringTran (t1,t2,( the Tran of t1 . [p,y])) by A1, A4, A5, Def29 .= [[(g `1_3), the InitS of t2],(g `2_3),(g `3_3)] by A2 ; ::_thesis: verum end; theorem Th44: :: TURING_1:44 for T1, T2 being TuringStr for g being Tran-Goal of T2 for q being State of T2 for y being Symbol of T2 st g = the Tran of T2 . [q,y] holds the Tran of (T1 ';' T2) . [[ the AcceptS of T1,q],y] = [[ the AcceptS of T1,(g `1_3)],(g `2_3),(g `3_3)] proof let t1, t2 be TuringStr ; ::_thesis: for g being Tran-Goal of t2 for q being State of t2 for y being Symbol of t2 st g = the Tran of t2 . [q,y] holds the Tran of (t1 ';' t2) . [[ the AcceptS of t1,q],y] = [[ the AcceptS of t1,(g `1_3)],(g `2_3),(g `3_3)] let g be Tran-Goal of t2; ::_thesis: for q being State of t2 for y being Symbol of t2 st g = the Tran of t2 . [q,y] holds the Tran of (t1 ';' t2) . [[ the AcceptS of t1,q],y] = [[ the AcceptS of t1,(g `1_3)],(g `2_3),(g `3_3)] let q be State of t2; ::_thesis: for y being Symbol of t2 st g = the Tran of t2 . [q,y] holds the Tran of (t1 ';' t2) . [[ the AcceptS of t1,q],y] = [[ the AcceptS of t1,(g `1_3)],(g `2_3),(g `3_3)] let y be Symbol of t2; ::_thesis: ( g = the Tran of t2 . [q,y] implies the Tran of (t1 ';' t2) . [[ the AcceptS of t1,q],y] = [[ the AcceptS of t1,(g `1_3)],(g `2_3),(g `3_3)] ) assume A1: g = the Tran of t2 . [q,y] ; ::_thesis: the Tran of (t1 ';' t2) . [[ the AcceptS of t1,q],y] = [[ the AcceptS of t1,(g `1_3)],(g `2_3),(g `3_3)] set pF = the AcceptS of t1; set x = [[ the AcceptS of t1,q],y]; the AcceptS of t1 in { the AcceptS of t1} by TARSKI:def_1; then [ the AcceptS of t1,q] in [:{ the AcceptS of t1}, the FStates of t2:] by ZFMISC_1:def_2; then A2: [ the AcceptS of t1,q] in [: the FStates of t1,{ the InitS of t2}:] \/ [:{ the AcceptS of t1}, the FStates of t2:] by XBOOLE_0:def_3; y in the Symbols of t1 \/ the Symbols of t2 by XBOOLE_0:def_3; then reconsider xx = [[ the AcceptS of t1,q],y] as Element of [:(UnionSt (t1,t2)),( the Symbols of t1 \/ the Symbols of t2):] by A2, ZFMISC_1:def_2; A3: SecondTuringState xx = ([[ the AcceptS of t1,q],y] `1) `2 .= q ; A4: SecondTuringSymbol xx = [[ the AcceptS of t1,q],y] `2 by Def28 .= y ; thus the Tran of (t1 ';' t2) . [[ the AcceptS of t1,q],y] = (UnionTran (t1,t2)) . xx by Def31 .= Uniontran (t1,t2,xx) by Def30 .= SecondTuringTran (t1,t2,( the Tran of t2 . [q,y])) by A3, A4, Def29 .= [[ the AcceptS of t1,(g `1_3)],(g `2_3),(g `3_3)] by A1 ; ::_thesis: verum end; theorem Th45: :: TURING_1:45 for T1, T2 being TuringStr for s1 being All-State of T1 for h being Element of NAT for t being Tape of T1 for s2 being All-State of T2 for s3 being All-State of (T1 ';' T2) st s1 is Accept-Halt & s1 = [ the InitS of T1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of T2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (T1 ';' T2),h,t] holds ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) proof let tm1, tm2 be TuringStr ; ::_thesis: for s1 being All-State of tm1 for h being Element of NAT for t being Tape of tm1 for s2 being All-State of tm2 for s3 being All-State of (tm1 ';' tm2) st s1 is Accept-Halt & s1 = [ the InitS of tm1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (tm1 ';' tm2),h,t] holds ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) let s1 be All-State of tm1; ::_thesis: for h being Element of NAT for t being Tape of tm1 for s2 being All-State of tm2 for s3 being All-State of (tm1 ';' tm2) st s1 is Accept-Halt & s1 = [ the InitS of tm1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (tm1 ';' tm2),h,t] holds ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) let h be Element of NAT ; ::_thesis: for t being Tape of tm1 for s2 being All-State of tm2 for s3 being All-State of (tm1 ';' tm2) st s1 is Accept-Halt & s1 = [ the InitS of tm1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (tm1 ';' tm2),h,t] holds ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) let t be Tape of tm1; ::_thesis: for s2 being All-State of tm2 for s3 being All-State of (tm1 ';' tm2) st s1 is Accept-Halt & s1 = [ the InitS of tm1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (tm1 ';' tm2),h,t] holds ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) let s2 be All-State of tm2; ::_thesis: for s3 being All-State of (tm1 ';' tm2) st s1 is Accept-Halt & s1 = [ the InitS of tm1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (tm1 ';' tm2),h,t] holds ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) let s3 be All-State of (tm1 ';' tm2); ::_thesis: ( s1 is Accept-Halt & s1 = [ the InitS of tm1,h,t] & s2 is Accept-Halt & s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] & s3 = [ the InitS of (tm1 ';' tm2),h,t] implies ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) ) set p0 = the InitS of tm1; set q0 = the InitS of tm2; assume that A1: s1 is Accept-Halt and A2: s1 = [ the InitS of tm1,h,t] and A3: s2 is Accept-Halt and A4: s2 = [ the InitS of tm2,((Result s1) `2_3),((Result s1) `3_3)] and A5: s3 = [ the InitS of (tm1 ';' tm2),h,t] ; ::_thesis: ( s3 is Accept-Halt & (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) set pF = the AcceptS of tm1; set qF = the AcceptS of tm2; consider k being Element of NAT such that A6: ((Computation s1) . k) `1_3 = the AcceptS of tm1 and A7: Result s1 = (Computation s1) . k and A8: for i being Element of NAT st i < k holds ((Computation s1) . i) `1_3 <> the AcceptS of tm1 by A1, Th13; defpred S1[ Element of NAT ] means ( $1 <= k implies ( [(((Computation s1) . $1) `1_3), the InitS of tm2] = ((Computation s3) . $1) `1_3 & ((Computation s1) . $1) `2_3 = ((Computation s3) . $1) `2_3 & ((Computation s1) . $1) `3_3 = ((Computation s3) . $1) `3_3 ) ); A9: for i being Element of NAT st S1[i] holds S1[i + 1] proof let i be Element of NAT ; ::_thesis: ( S1[i] implies S1[i + 1] ) assume A10: S1[i] ; ::_thesis: S1[i + 1] now__::_thesis:_(_i_+_1_<=_k_implies_(_[(((Computation_s1)_._(i_+_1))_`1_3),_the_InitS_of_tm2]_=_((Computation_s3)_._(i_+_1))_`1_3_&_((Computation_s1)_._(i_+_1))_`2_3_=_((Computation_s3)_._(i_+_1))_`2_3_&_((Computation_s1)_._(i_+_1))_`3_3_=_((Computation_s3)_._(i_+_1))_`3_3_)_) set s1i1 = (Computation s1) . (i + 1); set s1i = (Computation s1) . i; set s3i1 = (Computation s3) . (i + 1); set s3i = (Computation s3) . i; A11: i < i + 1 by XREAL_1:29; set f = TRAN ((Computation s3) . i); reconsider h = Head ((Computation s1) . i) as Element of INT ; reconsider ss1 = ((Computation s1) . i) `3_3 as Tape of tm1 ; reconsider y = ss1 . h as Symbol of tm1 ; reconsider ss3 = ((Computation s3) . i) `3_3 as Tape of (tm1 ';' tm2) ; set p = ((Computation s1) . i) `1_3 ; set g = TRAN ((Computation s1) . i); assume A12: i + 1 <= k ; ::_thesis: ( [(((Computation s1) . (i + 1)) `1_3), the InitS of tm2] = ((Computation s3) . (i + 1)) `1_3 & ((Computation s1) . (i + 1)) `2_3 = ((Computation s3) . (i + 1)) `2_3 & ((Computation s1) . (i + 1)) `3_3 = ((Computation s3) . (i + 1)) `3_3 ) then A13: i < k by A11, XXREAL_0:2; then A14: ((Computation s1) . i) `1_3 <> the AcceptS of tm1 by A8; A15: ((Computation s3) . i) `1_3 <> the AcceptS of (tm1 ';' tm2) proof assume ((Computation s3) . i) `1_3 = the AcceptS of (tm1 ';' tm2) ; ::_thesis: contradiction then [(((Computation s1) . i) `1_3), the InitS of tm2] = [ the AcceptS of tm1, the AcceptS of tm2] by A10, A12, A11, Def31, XXREAL_0:2; hence contradiction by A14, XTUPLE_0:1; ::_thesis: verum end; A16: TRAN ((Computation s3) . i) = the Tran of (tm1 ';' tm2) . [[(((Computation s1) . i) `1_3), the InitS of tm2],y] by A10, A12, A11, XXREAL_0:2 .= [[((TRAN ((Computation s1) . i)) `1_3), the InitS of tm2],((TRAN ((Computation s1) . i)) `2_3),((TRAN ((Computation s1) . i)) `3_3)] by A8, A13, Th43 ; then A17: (TRAN ((Computation s1) . i)) `2_3 = (TRAN ((Computation s3) . i)) `2_3 by MCART_1:def_6; A18: (Computation s3) . (i + 1) = Following ((Computation s3) . i) by Def7 .= [((TRAN ((Computation s3) . i)) `1_3),((Head ((Computation s3) . i)) + (offset (TRAN ((Computation s3) . i)))),(Tape-Chg (ss3,(Head ((Computation s3) . i)),((TRAN ((Computation s3) . i)) `2_3)))] by A15, Def6 ; A19: (Computation s1) . (i + 1) = Following ((Computation s1) . i) by Def7 .= [((TRAN ((Computation s1) . i)) `1_3),(h + (offset (TRAN ((Computation s1) . i)))),(Tape-Chg (ss1,h,((TRAN ((Computation s1) . i)) `2_3)))] by A14, Def6 ; hence [(((Computation s1) . (i + 1)) `1_3), the InitS of tm2] = [((TRAN ((Computation s1) . i)) `1_3), the InitS of tm2] by MCART_1:def_5 .= (TRAN ((Computation s3) . i)) `1_3 by A16, MCART_1:def_5 .= ((Computation s3) . (i + 1)) `1_3 by A18, MCART_1:def_5 ; ::_thesis: ( ((Computation s1) . (i + 1)) `2_3 = ((Computation s3) . (i + 1)) `2_3 & ((Computation s1) . (i + 1)) `3_3 = ((Computation s3) . (i + 1)) `3_3 ) offset (TRAN ((Computation s1) . i)) = offset (TRAN ((Computation s3) . i)) by A16, MCART_1:def_7; hence ((Computation s1) . (i + 1)) `2_3 = (Head ((Computation s3) . i)) + (offset (TRAN ((Computation s3) . i))) by A10, A12, A11, A19, MCART_1:def_6, XXREAL_0:2 .= ((Computation s3) . (i + 1)) `2_3 by A18, MCART_1:def_6 ; ::_thesis: ((Computation s1) . (i + 1)) `3_3 = ((Computation s3) . (i + 1)) `3_3 thus ((Computation s1) . (i + 1)) `3_3 = ss3 +* (h .--> ((TRAN ((Computation s1) . i)) `2_3)) by A10, A12, A11, A19, MCART_1:def_7, XXREAL_0:2 .= ((Computation s3) . (i + 1)) `3_3 by A10, A12, A11, A17, A18, MCART_1:def_7, XXREAL_0:2 ; ::_thesis: verum end; hence S1[i + 1] ; ::_thesis: verum end; set s1k = (Computation s1) . k; set s3k = (Computation s3) . k; A20: s3 = [[ the InitS of tm1, the InitS of tm2],h,t] by A5, Def31; A21: S1[ 0 ] proof assume 0 <= k ; ::_thesis: ( [(((Computation s1) . 0) `1_3), the InitS of tm2] = ((Computation s3) . 0) `1_3 & ((Computation s1) . 0) `2_3 = ((Computation s3) . 0) `2_3 & ((Computation s1) . 0) `3_3 = ((Computation s3) . 0) `3_3 ) A22: ((Computation s3) . 0) `1_3 = s3 `1_3 by Def7 .= [ the InitS of tm1, the InitS of tm2] by A20, MCART_1:64 ; ((Computation s1) . 0) `1_3 = s1 `1_3 by Def7 .= the InitS of tm1 by A2, MCART_1:64 ; hence [(((Computation s1) . 0) `1_3), the InitS of tm2] = ((Computation s3) . 0) `1_3 by A22; ::_thesis: ( ((Computation s1) . 0) `2_3 = ((Computation s3) . 0) `2_3 & ((Computation s1) . 0) `3_3 = ((Computation s3) . 0) `3_3 ) thus ((Computation s1) . 0) `2_3 = s1 `2_3 by Def7 .= h by A2, MCART_1:64 .= s3 `2_3 by A5, MCART_1:64 .= ((Computation s3) . 0) `2_3 by Def7 ; ::_thesis: ((Computation s1) . 0) `3_3 = ((Computation s3) . 0) `3_3 thus ((Computation s1) . 0) `3_3 = s1 `3_3 by Def7 .= t by A2, MCART_1:64 .= s3 `3_3 by A5, MCART_1:64 .= ((Computation s3) . 0) `3_3 by Def7 ; ::_thesis: verum end; A23: for i being Element of NAT holds S1[i] from NAT_1:sch_1(A21, A9); then A24: ((Computation s1) . k) `2_3 = ((Computation s3) . k) `2_3 ; consider m being Element of NAT such that A25: ((Computation s2) . m) `1_3 = the AcceptS of tm2 and A26: Result s2 = (Computation s2) . m and A27: for i being Element of NAT st i < m holds ((Computation s2) . i) `1_3 <> the AcceptS of tm2 by A3, Th13; defpred S2[ Element of NAT ] means ( $1 <= m implies ( [ the AcceptS of tm1,(((Computation s2) . $1) `1_3)] = ((Computation ((Computation s3) . k)) . $1) `1_3 & ((Computation s2) . $1) `2_3 = ((Computation ((Computation s3) . k)) . $1) `2_3 & ((Computation s2) . $1) `3_3 = ((Computation ((Computation s3) . k)) . $1) `3_3 ) ); A28: for i being Element of NAT st S2[i] holds S2[i + 1] proof let i be Element of NAT ; ::_thesis: ( S2[i] implies S2[i + 1] ) assume A29: S2[i] ; ::_thesis: S2[i + 1] now__::_thesis:_(_i_+_1_<=_m_implies_(_[_the_AcceptS_of_tm1,(((Computation_s2)_._(i_+_1))_`1_3)]_=_((Computation_((Computation_s3)_._k))_._(i_+_1))_`1_3_&_((Computation_s2)_._(i_+_1))_`2_3_=_((Computation_((Computation_s3)_._k))_._(i_+_1))_`2_3_&_((Computation_s2)_._(i_+_1))_`3_3_=_((Computation_((Computation_s3)_._k))_._(i_+_1))_`3_3_)_) set s2i1 = (Computation s2) . (i + 1); set s2i = (Computation s2) . i; set ski1 = (Computation ((Computation s3) . k)) . (i + 1); set ski = (Computation ((Computation s3) . k)) . i; A30: i < i + 1 by XREAL_1:29; reconsider ssk = ((Computation ((Computation s3) . k)) . i) `3_3 as Tape of (tm1 ';' tm2) ; set f = TRAN ((Computation ((Computation s3) . k)) . i); set q = ((Computation s2) . i) `1_3 ; set g = TRAN ((Computation s2) . i); reconsider h = Head ((Computation s2) . i) as Element of INT ; reconsider ss2 = ((Computation s2) . i) `3_3 as Tape of tm2 ; reconsider y = ss2 . h as Symbol of tm2 ; assume A31: i + 1 <= m ; ::_thesis: ( [ the AcceptS of tm1,(((Computation s2) . (i + 1)) `1_3)] = ((Computation ((Computation s3) . k)) . (i + 1)) `1_3 & ((Computation s2) . (i + 1)) `2_3 = ((Computation ((Computation s3) . k)) . (i + 1)) `2_3 & ((Computation s2) . (i + 1)) `3_3 = ((Computation ((Computation s3) . k)) . (i + 1)) `3_3 ) then A32: TRAN ((Computation ((Computation s3) . k)) . i) = the Tran of (tm1 ';' tm2) . [[ the AcceptS of tm1,(((Computation s2) . i) `1_3)],y] by A29, A30, XXREAL_0:2 .= [[ the AcceptS of tm1,((TRAN ((Computation s2) . i)) `1_3)],((TRAN ((Computation s2) . i)) `2_3),((TRAN ((Computation s2) . i)) `3_3)] by Th44 ; then A33: (TRAN ((Computation s2) . i)) `2_3 = (TRAN ((Computation ((Computation s3) . k)) . i)) `2_3 by MCART_1:def_6; i < m by A31, A30, XXREAL_0:2; then A34: ((Computation s2) . i) `1_3 <> the AcceptS of tm2 by A27; A35: ((Computation ((Computation s3) . k)) . i) `1_3 <> the AcceptS of (tm1 ';' tm2) proof assume ((Computation ((Computation s3) . k)) . i) `1_3 = the AcceptS of (tm1 ';' tm2) ; ::_thesis: contradiction then [ the AcceptS of tm1,(((Computation s2) . i) `1_3)] = [ the AcceptS of tm1, the AcceptS of tm2] by A29, A31, A30, Def31, XXREAL_0:2; hence contradiction by A34, XTUPLE_0:1; ::_thesis: verum end; A36: (Computation ((Computation s3) . k)) . (i + 1) = Following ((Computation ((Computation s3) . k)) . i) by Def7 .= [((TRAN ((Computation ((Computation s3) . k)) . i)) `1_3),((Head ((Computation ((Computation s3) . k)) . i)) + (offset (TRAN ((Computation ((Computation s3) . k)) . i)))),(Tape-Chg (ssk,(Head ((Computation ((Computation s3) . k)) . i)),((TRAN ((Computation ((Computation s3) . k)) . i)) `2_3)))] by A35, Def6 ; A37: (Computation s2) . (i + 1) = Following ((Computation s2) . i) by Def7 .= [((TRAN ((Computation s2) . i)) `1_3),(h + (offset (TRAN ((Computation s2) . i)))),(Tape-Chg (ss2,h,((TRAN ((Computation s2) . i)) `2_3)))] by A34, Def6 ; hence [ the AcceptS of tm1,(((Computation s2) . (i + 1)) `1_3)] = [ the AcceptS of tm1,((TRAN ((Computation s2) . i)) `1_3)] by MCART_1:def_5 .= (TRAN ((Computation ((Computation s3) . k)) . i)) `1_3 by A32, MCART_1:def_5 .= ((Computation ((Computation s3) . k)) . (i + 1)) `1_3 by A36, MCART_1:def_5 ; ::_thesis: ( ((Computation s2) . (i + 1)) `2_3 = ((Computation ((Computation s3) . k)) . (i + 1)) `2_3 & ((Computation s2) . (i + 1)) `3_3 = ((Computation ((Computation s3) . k)) . (i + 1)) `3_3 ) offset (TRAN ((Computation s2) . i)) = offset (TRAN ((Computation ((Computation s3) . k)) . i)) by A32, MCART_1:def_7; hence ((Computation s2) . (i + 1)) `2_3 = (Head ((Computation ((Computation s3) . k)) . i)) + (offset (TRAN ((Computation ((Computation s3) . k)) . i))) by A29, A31, A30, A37, MCART_1:def_6, XXREAL_0:2 .= ((Computation ((Computation s3) . k)) . (i + 1)) `2_3 by A36, MCART_1:def_6 ; ::_thesis: ((Computation s2) . (i + 1)) `3_3 = ((Computation ((Computation s3) . k)) . (i + 1)) `3_3 thus ((Computation s2) . (i + 1)) `3_3 = ssk +* (h .--> ((TRAN ((Computation s2) . i)) `2_3)) by A29, A31, A30, A37, MCART_1:def_7, XXREAL_0:2 .= ((Computation ((Computation s3) . k)) . (i + 1)) `3_3 by A29, A31, A30, A33, A36, MCART_1:def_7, XXREAL_0:2 ; ::_thesis: verum end; hence S2[i + 1] ; ::_thesis: verum end; A38: ((Computation s1) . k) `3_3 = ((Computation s3) . k) `3_3 by A23; set s2m = (Computation s2) . m; set skm = (Computation ((Computation s3) . k)) . m; A39: (Computation s3) . (k + m) = (Computation ((Computation s3) . k)) . m by Th10; A40: [(((Computation s1) . k) `1_3), the InitS of tm2] = ((Computation s3) . k) `1_3 by A23; A41: S2[ 0 ] proof assume 0 <= m ; ::_thesis: ( [ the AcceptS of tm1,(((Computation s2) . 0) `1_3)] = ((Computation ((Computation s3) . k)) . 0) `1_3 & ((Computation s2) . 0) `2_3 = ((Computation ((Computation s3) . k)) . 0) `2_3 & ((Computation s2) . 0) `3_3 = ((Computation ((Computation s3) . k)) . 0) `3_3 ) thus [ the AcceptS of tm1,(((Computation s2) . 0) `1_3)] = [ the AcceptS of tm1,(s2 `1_3)] by Def7 .= [ the AcceptS of tm1, the InitS of tm2] by A4, MCART_1:64 .= ((Computation ((Computation s3) . k)) . 0) `1_3 by A6, A40, Def7 ; ::_thesis: ( ((Computation s2) . 0) `2_3 = ((Computation ((Computation s3) . k)) . 0) `2_3 & ((Computation s2) . 0) `3_3 = ((Computation ((Computation s3) . k)) . 0) `3_3 ) thus ((Computation s2) . 0) `2_3 = s2 `2_3 by Def7 .= ((Computation s3) . k) `2_3 by A4, A7, A24, MCART_1:64 .= ((Computation ((Computation s3) . k)) . 0) `2_3 by Def7 ; ::_thesis: ((Computation s2) . 0) `3_3 = ((Computation ((Computation s3) . k)) . 0) `3_3 thus ((Computation s2) . 0) `3_3 = s2 `3_3 by Def7 .= ((Computation s3) . k) `3_3 by A4, A7, A38, MCART_1:64 .= ((Computation ((Computation s3) . k)) . 0) `3_3 by Def7 ; ::_thesis: verum end; A42: for i being Element of NAT holds S2[i] from NAT_1:sch_1(A41, A28); then [ the AcceptS of tm1,(((Computation s2) . m) `1_3)] = ((Computation ((Computation s3) . k)) . m) `1_3 ; then A43: ((Computation s3) . (k + m)) `1_3 = the AcceptS of (tm1 ';' tm2) by A25, A39, Def31; hence A44: s3 is Accept-Halt by Def8; ::_thesis: ( (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) ( ((Computation s2) . m) `2_3 = ((Computation ((Computation s3) . k)) . m) `2_3 & ((Computation s2) . m) `3_3 = ((Computation ((Computation s3) . k)) . m) `3_3 ) by A42; hence ( (Result s3) `2_3 = (Result s2) `2_3 & (Result s3) `3_3 = (Result s2) `3_3 ) by A26, A39, A43, A44, Def9; ::_thesis: verum end; theorem :: TURING_1:46 for tm1, tm2 being TuringStr for t being Tape of tm1 st the Symbols of tm1 = the Symbols of tm2 holds t is Tape of (tm1 ';' tm2) proof let tm1, tm2 be TuringStr ; ::_thesis: for t being Tape of tm1 st the Symbols of tm1 = the Symbols of tm2 holds t is Tape of (tm1 ';' tm2) let t be Tape of tm1; ::_thesis: ( the Symbols of tm1 = the Symbols of tm2 implies t is Tape of (tm1 ';' tm2) ) set S1 = the Symbols of tm1; set S2 = the Symbols of tm2; assume A1: the Symbols of tm1 = the Symbols of tm2 ; ::_thesis: t is Tape of (tm1 ';' tm2) the Symbols of (tm1 ';' tm2) = the Symbols of tm1 \/ the Symbols of tm2 by Def31 .= the Symbols of tm1 by A1 ; hence t is Tape of (tm1 ';' tm2) ; ::_thesis: verum end; theorem :: TURING_1:47 for tm1, tm2 being TuringStr for t being Tape of (tm1 ';' tm2) st the Symbols of tm1 = the Symbols of tm2 holds ( t is Tape of tm1 & t is Tape of tm2 ) proof let tm1, tm2 be TuringStr ; ::_thesis: for t being Tape of (tm1 ';' tm2) st the Symbols of tm1 = the Symbols of tm2 holds ( t is Tape of tm1 & t is Tape of tm2 ) let t be Tape of (tm1 ';' tm2); ::_thesis: ( the Symbols of tm1 = the Symbols of tm2 implies ( t is Tape of tm1 & t is Tape of tm2 ) ) set S1 = the Symbols of tm1; set S2 = the Symbols of tm2; assume A1: the Symbols of tm1 = the Symbols of tm2 ; ::_thesis: ( t is Tape of tm1 & t is Tape of tm2 ) the Symbols of (tm1 ';' tm2) = the Symbols of tm1 \/ the Symbols of tm2 by Def31 .= the Symbols of tm1 by A1 ; hence ( t is Tape of tm1 & t is Tape of tm2 ) by A1; ::_thesis: verum end; theorem Th48: :: TURING_1:48 for f being FinSequence of NAT for tm1, tm2 being TuringStr for t1 being Tape of tm1 for t2 being Tape of tm2 st t1 = t2 & t1 storeData f holds t2 storeData f proof let f be FinSequence of NAT ; ::_thesis: for tm1, tm2 being TuringStr for t1 being Tape of tm1 for t2 being Tape of tm2 st t1 = t2 & t1 storeData f holds t2 storeData f let tm1, tm2 be TuringStr ; ::_thesis: for t1 being Tape of tm1 for t2 being Tape of tm2 st t1 = t2 & t1 storeData f holds t2 storeData f let t1 be Tape of tm1; ::_thesis: for t2 being Tape of tm2 st t1 = t2 & t1 storeData f holds t2 storeData f let t2 be Tape of tm2; ::_thesis: ( t1 = t2 & t1 storeData f implies t2 storeData f ) assume that A1: t1 = t2 and A2: t1 storeData f ; ::_thesis: t2 storeData f now__::_thesis:_for_i_being_Element_of_NAT_st_1_<=_i_&_i_<_len_f_holds_ t2_is_1_between_(Sum_(Prefix_(f,i)))_+_(2_*_(i_-_1)),(Sum_(Prefix_(f,(i_+_1))))_+_(2_*_i) let i be Element of NAT ; ::_thesis: ( 1 <= i & i < len f implies t2 is_1_between (Sum (Prefix (f,i))) + (2 * (i - 1)),(Sum (Prefix (f,(i + 1)))) + (2 * i) ) set m = (Sum (Prefix (f,i))) + (2 * (i - 1)); set n = (Sum (Prefix (f,(i + 1)))) + (2 * i); assume ( 1 <= i & i < len f ) ; ::_thesis: t2 is_1_between (Sum (Prefix (f,i))) + (2 * (i - 1)),(Sum (Prefix (f,(i + 1)))) + (2 * i) then A3: t1 is_1_between (Sum (Prefix (f,i))) + (2 * (i - 1)),(Sum (Prefix (f,(i + 1)))) + (2 * i) by A2, Def13; then A4: for k being Integer st (Sum (Prefix (f,i))) + (2 * (i - 1)) < k & k < (Sum (Prefix (f,(i + 1)))) + (2 * i) holds t1 . k = 1 by Def12; ( t1 . ((Sum (Prefix (f,i))) + (2 * (i - 1))) = 0 & t1 . ((Sum (Prefix (f,(i + 1)))) + (2 * i)) = 0 ) by A3, Def12; hence t2 is_1_between (Sum (Prefix (f,i))) + (2 * (i - 1)),(Sum (Prefix (f,(i + 1)))) + (2 * i) by A1, A4, Def12; ::_thesis: verum end; hence t2 storeData f by Def13; ::_thesis: verum end; Lm15: for s being All-State of ZeroTuring for t being Tape of ZeroTuring for head, n being Element of NAT st s = [0,head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,0*> ) proof let s be All-State of ZeroTuring; ::_thesis: for t being Tape of ZeroTuring for head, n being Element of NAT st s = [0,head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,0*> ) let t be Tape of ZeroTuring; ::_thesis: for head, n being Element of NAT st s = [0,head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,0*> ) let h, n be Element of NAT ; ::_thesis: ( s = [0,h,t] & t storeData <*h,n*> implies ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,0*> ) ) len <*n*> = 1 by FINSEQ_1:39; hence ( s = [0,h,t] & t storeData <*h,n*> implies ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,0*> ) ) by Th34; ::_thesis: verum end; theorem :: TURING_1:49 for s being All-State of (ZeroTuring ';' SuccTuring) for t being Tape of ZeroTuring for head, n being Element of NAT st s = [[0,0],head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,1*> ) proof let s be All-State of (ZeroTuring ';' SuccTuring); ::_thesis: for t being Tape of ZeroTuring for head, n being Element of NAT st s = [[0,0],head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,1*> ) let t be Tape of ZeroTuring; ::_thesis: for head, n being Element of NAT st s = [[0,0],head,t] & t storeData <*head,n*> holds ( s is Accept-Halt & (Result s) `2_3 = head & (Result s) `3_3 storeData <*head,1*> ) let h, n be Element of NAT ; ::_thesis: ( s = [[0,0],h,t] & t storeData <*h,n*> implies ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,1*> ) ) assume that A1: s = [[0,0],h,t] and A2: t storeData <*h,n*> ; ::_thesis: ( s is Accept-Halt & (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,1*> ) reconsider h1 = h as Element of INT by INT_1:def_2; set s1 = [ the InitS of ZeroTuring,h1,t]; A3: 0 = the InitS of ZeroTuring by Def19; then A4: ( [ the InitS of ZeroTuring,h1,t] is Accept-Halt & (Result [ the InitS of ZeroTuring,h1,t]) `2_3 = h ) by A2, Lm15; the Symbols of ZeroTuring = {0,1} by Def19 .= the Symbols of SuccTuring by Def17 ; then reconsider t2 = (Result [ the InitS of ZeroTuring,h1,t]) `3_3 as Tape of SuccTuring ; set s2 = [ the InitS of SuccTuring,h1,t2]; A5: 0 = the InitS of SuccTuring by Def17; then A6: s = [ the InitS of (ZeroTuring ';' SuccTuring),h,t] by A1, A3, Def31; (Result [ the InitS of ZeroTuring,h1,t]) `3_3 storeData <*h,0*> by A2, A3, Lm15; then A7: t2 storeData <*h,0*> by Th48; then A8: (Result [ the InitS of SuccTuring,h1,t2]) `3_3 storeData <*h,(0 + 1)*> by A5, Th31; A9: [ the InitS of SuccTuring,h1,t2] is Accept-Halt by A7, A5, Th31; hence s is Accept-Halt by A4, A6, Th45; ::_thesis: ( (Result s) `2_3 = h & (Result s) `3_3 storeData <*h,1*> ) (Result [ the InitS of SuccTuring,h1,t2]) `2_3 = h by A7, A5, Th31; hence (Result s) `2_3 = h by A4, A9, A6, Th45; ::_thesis: (Result s) `3_3 storeData <*h,1*> (Result s) `3_3 = (Result [ the InitS of SuccTuring,h1,t2]) `3_3 by A4, A9, A6, Th45; hence (Result s) `3_3 storeData <*h,1*> by A8, Th48; ::_thesis: verum end;