 reserve i,j,n,k,l for Nat;
 reserve T,S,X,Y,Z for Subset of MC-wff;
 reserve p,q,r,t,F,H,G for Element of MC-wff;
 reserve s,U,V for MC-formula;
reserve f,g for FinSequence of [:MC-wff,Proof_Step_Kinds_IPC:];

theorem
  p in CnIPC(X) implies ex Y st Y c= X & Y is finite & p in CnIPC(Y)
proof
  assume p in CnIPC(X);
  then consider f such that
A1: f is_a_proof_wrt_IPC X and
A2: Effect_IPC(f) = p by Th16;
A3: f <> {} by A1;
 consider A being set such that
A4: A is finite and
A5: A c= MC-wff and
A6: rng f c= [:A,Proof_Step_Kinds_IPC:] by FINSEQ_1:def 4,FINSET_1:14;
  reconsider Z=A as Subset of MC-wff by A5;
  take Y = Z /\ X;
  thus Y c= X by XBOOLE_1:17;
  thus Y is finite by A4;
  1 <= n & n <= len f implies f,n is_a_correct_step_wrt_IPC Y
  proof
    assume
A7: 1 <= n & n <= len f; then
A8: f,n is_a_correct_step_wrt_IPC X by A1;
    (f.n)`2 = 0 or ... or  (f.n)`2 = 10 by A7,Th3;
    then per cases;
    case (f.n)`2 = 0; then
A9:  (f.n)`1 in X by A8,Def3;
      n in Seg(len f) by A7,FINSEQ_1:1; then
      n in dom f by FINSEQ_1:def 3; then
      f.n in rng f by FUNCT_1:def 3; then
      (f.n)`1 in A by A6,MCART_1:10;
      hence thesis by A9,XBOOLE_0:def 4;
    end;
    case (f.n)`2 = 1;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 2;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 3;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 4;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 5;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 6;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 7;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 8;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 9;
      hence thesis by A8,Def3;
    end;
    case (f.n)`2 = 10;
      hence thesis by A8,Def3;
    end;
  end; then
  f is_a_proof_wrt_IPC Y by A3; then
  p in {q: ex f st f is_a_proof_wrt_IPC Y & Effect_IPC(f) = q} by A2;
  hence thesis by Th15;
end;
