
theorem Th73:
  for X be non empty set, S be SigmaField of X, M be sigma_Measure
of S, B be Element of S, f be PartFunc of X,ExtREAL st f is_simple_func_in S &
  M.B=0 & f is nonnegative holds integral'(M,f|B) = 0
proof
  let X be non empty set;
  let S be SigmaField of X;
  let M be sigma_Measure of S;
  let B be Element of S;
  let f be PartFunc of X,ExtREAL;
  assume that
A1: f is_simple_func_in S and
A2: M.B=0 and
A3: f is nonnegative;
  set A = dom f;
  set g = f|(A/\B);
  for x be object st x in dom g holds 0 <= g.x
  proof
    let x be object;
    assume
A5: x in dom g;
    0 <= f.x by A3,SUPINF_2:51;
    hence thesis by A5,FUNCT_1:47;
  end; then
a4: g is nonnegative by SUPINF_2:52;
A6: ex G be Finite_Sep_Sequence of S st (dom g = union rng G & for n be Nat,
  x,y be Element of X st n in dom G & x in G.n & y in G.n holds g.x = g.y)
  proof
    consider F be Finite_Sep_Sequence of S such that
A7: dom f = union rng F and
A8: for n be Nat, x,y be Element of X st n in dom F & x in F.n & y in
    F. n holds f.x = f.y by A1,MESFUNC2:def 4;
    deffunc G(Nat) = F.$1 /\ (A/\ B);
    reconsider A as Element of S by A7,MESFUNC2:31;
    reconsider A2 = A/\B as Element of S;
    consider G be FinSequence such that
A9: len G = len F & for n be Nat st n in dom G holds G.n = G(n) from
    FINSEQ_1:sch 2;
A10: dom F = Seg len F by FINSEQ_1:def 3;
    dom G = Seg len F by A9,FINSEQ_1:def 3;
    then
A11: for i be Nat st i in dom F holds G.i = F.i /\ A2 by A9,A10;
    dom G = Seg len F by A9,FINSEQ_1:def 3;
    then
A12: dom G = dom F by FINSEQ_1:def 3;
    then reconsider G as Finite_Sep_Sequence of S by A11,Th35;
    take G;
    for i be Nat st i in dom G holds G.i = A2 /\ F.i by A9;
    then
A13: union rng G = A2 /\ dom f by A7,A12,MESFUNC3:6
      .= dom g by RELAT_1:61;
    for i be Nat, x,y be Element of X st i in dom G & x in G.i & y in G.i
    holds g.x = g.y
    proof
      let i be Nat;
      let x,y be Element of X;
      assume that
A14:  i in dom G and
A15:  x in G.i and
A16:  y in G.i;
A17:  G.i = F.i /\ A2 by A9,A14;
      then
A18:  y in F.i by A16,XBOOLE_0:def 4;
A19:  G.i in rng G by A14,FUNCT_1:3;
      then x in dom g by A13,A15,TARSKI:def 4;
      then
A20:  g.x = f.x by FUNCT_1:47;
      y in dom g by A13,A16,A19,TARSKI:def 4;
      then
A21:  g.y = f.y by FUNCT_1:47;
      x in F.i by A15,A17,XBOOLE_0:def 4;
      hence thesis by A8,A12,A14,A18,A20,A21;
    end;
    hence thesis by A13;
  end;
  dom(f|(A/\B)) = A/\(A/\B) by RELAT_1:61;
  then
A22: dom(f|(A/\B)) = (A/\A)/\B by XBOOLE_1:16;
  then
A23: dom(f|(A/\B)) = dom(f|B) by RELAT_1:61;
  for x be object st x in dom(f|(A/\B)) holds (f|(A/\B)).x = (f|B).x
  proof
    let x be object;
    assume
A24: x in dom(f|(A/\B));
    then (f|(A/\B)).x = f.x by FUNCT_1:47;
    hence thesis by A23,A24,FUNCT_1:47;
  end;
  then
A25: f|(A/\B) = f|B by A23,FUNCT_1:2;
  f is real-valued by A1,MESFUNC2:def 4;
  then
A26: g is_simple_func_in S by A6,MESFUNC2:def 4;
  now
    per cases;
    suppose
      dom g = {};
      hence thesis by A23,Def14;
    end;
    suppose
A27:  dom g <> {};
      consider F be Finite_Sep_Sequence of S, a,x be FinSequence of ExtREAL
      such that
A28:  F,a are_Re-presentation_of g and
      a.1 =0 and
      for n be Nat st 2 <= n & n in dom a holds 0 < a.n & a.n < +infty and
A29:  dom x = dom F and
A30:  for n be Nat st n in dom x holds x.n=a.n*(M*F).n and
A31:  integral(M,g)=Sum(x) by A26,MESFUNC3:def 2,a4;
A32:  for n be Nat st n in dom F holds M.(F.n) = 0
      proof
        reconsider BB=B as measure_zero of M by A2,MEASURE1:def 7;
        let n be Nat;
A33:    dom g c= B by A22,XBOOLE_1:17;
        assume
A34:    n in dom F;
        then F.n in rng F by FUNCT_1:3;
        then reconsider FF=F.n as Element of S;
        for v be object st v in F.n holds v in union rng F
        proof
          let v be object;
          assume
A35:      v in F.n;
          F.n in rng F by A34,FUNCT_1:3;
          hence thesis by A35,TARSKI:def 4;
        end;
        then
A36:    F.n c= union rng F;
        union rng F = dom g by A28,MESFUNC3:def 1;
        then FF c= BB by A36,A33;
        then F.n is measure_zero of M by MEASURE1:36;
        hence thesis by MEASURE1:def 7;
      end;
A37:  for n be Nat st n in dom x holds x.n = 0
      proof
        let n be Nat;
        assume
A38:    n in dom x;
        then M.(F.n) = 0 by A29,A32;
        then (M*F).n = 0 by A29,A38,FUNCT_1:13;
        then a.n*(M*F).n = 0;
        hence thesis by A30,A38;
      end;
      Sum(x) = 0
      proof
        consider sumx be sequence of ExtREAL such that
A39:    Sum(x) = sumx.(len x) and
A40:    sumx.0 = 0 and
A41:    for i be Nat st i < len x holds sumx.(i+1)=sumx.i
        + x.(i +1) by EXTREAL1:def 2;
        now
          defpred P[Nat] means $1 <= len x implies sumx.$1 = 0;
          assume x <> {};
A42:      for k be Nat st P[k] holds P[k+1]
          proof
            let k be Nat;
            assume
A43:        P[k];
            assume
A44:        k+1 <= len x;
            reconsider k as Element of NAT by ORDINAL1:def 12;
            1 <= k+1 by NAT_1:11;
           then k+1 in Seg(len x) by A44;
            then k+1 in dom x by FINSEQ_1:def 3;
            then
A45:        x.(k+1) = 0 by A37;
            k < len x by A44,NAT_1:13;
            then sumx.(k+1) = sumx.k + x.(k+1) by A41;
            hence thesis by A43,A44,A45,NAT_1:13;
          end;
A46:      P[ 0 ] by A40;
          for i be Nat holds P[i] from NAT_1:sch 2(A46,A42);
          hence thesis by A39;
        end;
        hence thesis by A39,A40,CARD_1:27;
      end;
      hence thesis by A25,A27,A31,Def14;
    end;
  end;
  hence thesis;
end;
