reserve p,P,P1,P2 for Instruction-Sequence of SCM+FSA;
reserve s, S for State of SCM+FSA,
  I, J for Program of SCM+FSA,
  Ig for good Program of SCM+FSA,
  i for good sequential Instruction of SCM+FSA,
  j for sequential Instruction of SCM+FSA,
  a, b for Int-Location,
  f for FinSeq-Location;

theorem Th2: :: SCMFSA6B:27
 for I,J being really-closed Program of SCM+FSA holds
  I is_halting_on Initialized S,P & J is_halting_on IExec(I,P,S),P
  implies
   I ";" J is_halting_on Initialized S,P
proof let I,J be really-closed Program of SCM+FSA;
  assume that
A1: I is_halting_on Initialized S,P and
A2: J is_halting_on IExec(I,P,S),P;
  set s = Initialize Initialized S,
      p = P +* (I ";" J);
A3:  I ";" J c= p by FUNCT_4:25;
   Directed I c= I ";" J by SCMFSA6A:16;
   then Directed I c= p by A3,XBOOLE_1:1;
   then
A4: p +*  Directed I = p by FUNCT_4:98;
A5: DataPart Initialized S = DataPart s by MEMSTR_0:79;
  then
A6: I is_halting_on s,p by A1,SCMFSA8B:5;
  then
A7: p+*I halts_on Initialize s;
  set s1 = Initialize s,
      p1 = p +* I;
A8: (Initialized S).intloc 0 = 1 by SCMFSA_M:9;
  then s.intloc 0 = 1 by A5,SCMFSA_M:2;
  then
A9: s1 = Initialized s by SCMFSA_M:18;
  set JAt = Start-At(0,SCM+FSA);
  set s3 = Initialize Comput(p1,s1,LifeSpan(p1,s1)),
      p3 = p1 +* J;
A10: J c= p3 by FUNCT_4:25;
  set m3 = LifeSpan(p3,s3);
 DataPart IExec(I,P,S) = DataPart IExec(I,P,Initialized S)
by SCMFSA8C:3
    .= DataPart IExec(I,p,s) by A1,A5,A8,SCMFSA8C:20
    .= DataPart(Result(p+*I,Initialized s)) by SCMFSA6B:def 1
    .= DataPart Result(p+*I,Initialized s)
    .= DataPart Comput(p1,s1,LifeSpan(p1,s1)) by A9,A7,EXTPRO_1:23;
  then
   J is_halting_on Comput(p1,s1,LifeSpan(p1,s1)),p1 by A2,SCMFSA8B:5;
  then
A11: p3 halts_on s3;
A12: Reloc(J,card I) c= I ";" J by SCMFSA6A:38;
  set m1 = LifeSpan(p1,s1);
  set s4 = Comput(p,s,m1+1),
      p4 = p;
A13: Reloc(J,card I) c= p by A3,A12,XBOOLE_1:1;
  reconsider m = m1 + 1 + m3 as Element of NAT by ORDINAL1:def 12;
  reconsider kk = DataPart JAt as Function;
A14: DataPart s3 = (DataPart Comput(p1,s1,m1)) +* kk by FUNCT_4:71;
  take m;
     IC Comput(p,s,m) in NAT;
  hence IC Comput(p,s,m) in dom p by PARTFUN1:def 2;
A15: IC s4 =  card I by A6,A4,SCMFSA8A:22;
A16: Comput(p,s,m1+1+m3)
 = Comput(p,Comput(p,s,m1+1),m3) by EXTPRO_1:4;
  DataPart JAt = {} by MEMSTR_0:20;
  then DataPart Comput(p1,s1,m1) = DataPart s3 by A14,FUNCT_4:98,XBOOLE_1:2;
  then DataPart s4 = DataPart s3 by A6,A4,SCMFSA8A:22;
  then
  IncAddr(CurInstr(p3,Comput(p3,s3,m3)),card I)
  = CurInstr(p,Comput(p,s4,m3))  by A15,A13,A10,SCMFSA8C:16;
  then
  IncAddr(CurInstr(p3,Comput(p3,s3,m3)),card I)
   = CurInstr(p,Comput(p,s,m1+1+m3))
   by A16;
  then CurInstr(p,Comput(p,s,m))
   = IncAddr (halt SCM+FSA,card I) by A11,EXTPRO_1:def 15
    .= halt SCM+FSA by COMPOS_0:4;
 hence thesis;
end;
