
theorem XSF:
  for f be XFinSequence of REAL holds Sum XFS2FS f = Sum f
  proof
    let f be XFinSequence of REAL;
    per cases;
    suppose
      f is non empty; then
      reconsider k = len f as non zero Nat;
      reconsider n = k - 1 as Nat;
      reconsider g = Sequel f as Real_Sequence by RSC;
      Sum (XFS2FS f) = Sum (Shift (g|Segm(n+1),1))
      .= (Partial_Sums g).n by DBLSEQ_2:49
      .= Sum (g|(n+1)) by AFINSQ_2:56;
      hence thesis;
    end;
    suppose
      f is empty; then
      Sum f = 0 & Sum (XFS2FS f) = 0;
      hence thesis;
    end;
  end;
