
theorem Th15:
  for A,B,x being set st B <> {} holds rng((id A)+*(B --> x)) = (A \ B) \/ {x}
proof
  let A,B,x be set;
  set f = ((id A)+*(B --> x));
  assume B <> {};
  then
A1: rng (B --> x)={x} by FUNCOP_1:8;
  thus rng((id A)+*(B --> x)) c= (A \ B) \/ {x}
  proof
    let y be object;
    assume y in rng f;
    then consider x1 being object such that
A2: x1 in dom f and
A3: y = f.x1 by FUNCT_1:def 3;
A4: x1 in dom (id A) \/ dom (B --> x) by A2,FUNCT_4:def 1;
    per cases;
    suppose
      x1 in dom (B --> x);
      then f.x1 = (B --> x).x1 & (B --> x).x1 = x by A4,FUNCOP_1:7
,FUNCT_4:def 1;
      then y in {x} by A3,TARSKI:def 1;
      hence thesis by XBOOLE_0:def 3;
    end;
    suppose
A5:   not x1 in dom (B --> x);
      then
A6:   f.x1 = (id A).x1 by A4,FUNCT_4:def 1;
A7:   x1 in dom (id A) by A4,A5,XBOOLE_0:def 3;
      not x1 in B by A5,FUNCOP_1:13;
      then x1 in A \ B by A7,XBOOLE_0:def 5;
      then x1 in (A \ B) \/ {x} by XBOOLE_0:def 3;
      hence thesis by A3,A6,A7,FUNCT_1:18;
    end;
  end;
  let y be object;
  (id A).:(A \ B)=A \ B by Th13;
  then (id A).:(dom(id A) \ B)=A \ B;
  then
A8: (id A).:(dom(id A) \ dom( B --> x))=A \ B by FUNCOP_1:13;
  assume y in (A \ B) \/ {x};
  hence thesis by A1,A8,Th12;
end;
