reserve N for with_zero set;
reserve N for with_zero set;
reserve x,y,z,A,B for set,
  f,g,h for Function,
  i,j,k for Nat;
reserve S for IC-Ins-separated non empty
     with_non-empty_values AMI-Struct over N,
  s for State of S;
reserve N for non empty with_zero set,
 S for IC-Ins-separated non empty with_non-empty_values AMI-Struct over N,
  s for State of S;
reserve n for Nat;

theorem Th9:
  for S being IC-Ins-separated non empty with_non-empty_values
       AMI-Struct over N
  for l being Nat, I being Instruction of S
  for P being NAT-defined (the InstructionsF of S)-valued Function
   st l .--> I c= P
  for s being State of S st IC S .--> l c= s
   holds CurInstr(P,s) = I
proof
  let S be IC-Ins-separated non empty with_non-empty_values AMI-Struct over N;
  let l be Nat, I be Instruction of S;
  let P be NAT-defined (the InstructionsF of S)-valued Function such that
A1: l .--> I c= P;
  let s be State of S such that
A2: IC S .--> l c= s;
  IC S in dom(IC S .--> l) by TARSKI:def 1;
  then
A3: IC s = (IC S .--> l).IC S by A2,GRFUNC_1:2
     .= l by FUNCOP_1:72;
A4: IC s in dom(l.--> I) by A3,TARSKI:def 1;
  dom(l.--> I) c= dom P by A1,RELAT_1:11;
 hence CurInstr(P,s) = P.IC s by A4,PARTFUN1:def 6
   .= (l .--> I).IC s by A4,A1,GRFUNC_1:2
   .= I by A3,FUNCOP_1:72;
end;
