reserve X for set;

theorem Th8:
  for S being SigmaField of X holds for N, G being sequence of
S holds ex F being sequence of S st F.0 = N.0 & for n being Nat
  holds F.(n+1) = N.(n+1) \ G.n
proof
  let S be SigmaField of X;
  let N, G be sequence of S;
  defpred P[set,set,set] means for A,B being Element of S,c being Nat
   holds (c = $1 & A = $2 & B = $3 implies B = (N.(c+1)) \ G.c);
A1: for c being Nat for A being Element of S ex B being Element
  of S st P[c,A,B]
  proof
    let c be Nat;
    let A be Element of S;
    consider B being set such that
A2: B = N.(c+1) \ G.c;
    reconsider B as Element of S by A2;
    take B;
    thus thesis by A2;
  end;
  consider F being sequence of S such that
A3: F.0 = N.0 & for n being Nat holds P[n,F.n,F.(n+1)] from
  RECDEF_1:sch 2(A1);
  for n being Nat holds F.(n + 1) = N.(n+1) \ G.n
  proof
    let n be Nat;
    for a,b being Element of S,s being Nat st s = n & a = F.n &
    b = F.(n+1) holds b = N.(s+1) \ G.s by A3;
    hence thesis;
  end;
  hence thesis by A3;
end;
