reserve s for set,
  i,j for natural Number,
  k for Nat,
  x,x1,x2,x3 for Real,
  r,r1,r2,r3,r4 for Real,
  F,F1,F2,F3 for real-valued FinSequence,
  R,R1,R2 for Element of i-tuples_on REAL;

theorem Th84:
  (for i be Nat st i in dom F holds 0 <= F.i) implies 0 <= Sum F
proof
  reconsider F1 = F as FinSequence of REAL by Lm2;
  set i = len F;
  set R1 = i|-> In(0,REAL);
  reconsider R2 = F1 as Element of i-tuples_on REAL by FINSEQ_2:92;
A1: Seg len F = dom F by FINSEQ_1:def 3;
  assume
A2: for i be Nat st i in dom F holds 0 <= F.i;
  for j be Nat st j in Seg i holds R1.j <= R2.j
   proof let j be Nat;
    assume
A3:    j in Seg i;
     R1.j = In(0,REAL);
    hence  thesis by A2,A1,A3;
   end;
  then Sum R1 <= Sum R2 by Th82;
  hence thesis by Th81;
end;
