
theorem Th144:
  for G3, G4 being _Graph, V1, V2 being set
  for G1 being addVertices of G3,V1, G2 being addVertices of G4,V2
  for F0 being PGraphMapping of G3,G4, f being one-to-one Function
  st dom f = V1 \ the_Vertices_of G3 & rng f = V2 \ the_Vertices_of G4
  ex F being PGraphMapping of G1, G2 st F = [F0_V +* f, F0_E] &
    (F0 is non empty  implies F is non empty) &
    (F0 is total implies F is total) &
    (F0 is onto implies F is onto) &
    (F0 is one-to-one implies F is one-to-one) &
    (F0 is directed implies F is directed) &
    (F0 is semi-continuous implies F is semi-continuous) &
    (F0 is continuous implies F is continuous) &
    (F0 is semi-Dcontinuous implies F is semi-Dcontinuous) &
    (F0 is Dcontinuous implies F is Dcontinuous)
proof
  let G3, G4 be _Graph, V1, V2 be set;
  let G1 be addVertices of G3,V1, G2 be addVertices of G4,V2;
  let F0 be PGraphMapping of G3,G4, f be one-to-one Function;
  assume A1: dom f = V1 \ the_Vertices_of G3 & rng f = V2 \ the_Vertices_of G4;
  :: construct F
  set h = F0_V +* f;
  A2: dom h = dom F0_V \/ (V1 \ the_Vertices_of G3) by A1, FUNCT_4:def 1;
  dom h c= the_Vertices_of G3 \/ V1 by A2, XBOOLE_1:13;
  then A3: dom h c= the_Vertices_of G1 by GLIB_006:def 10;
  rng F0_V \/ rng f c= the_Vertices_of G4 \/ V2 by A1, XBOOLE_1:13;
  then A4: rng F0_V \/ rng f c= the_Vertices_of G2 by GLIB_006:def 10;
  rng h c= rng F0_V \/ rng f by FUNCT_4:17;
  then rng h c= the_Vertices_of G2 by A4, XBOOLE_1:1;
  then reconsider h as PartFunc of the_Vertices_of G1, the_Vertices_of G2
    by A3, RELSET_1:4;
  the_Edges_of G1 = the_Edges_of G3 & the_Edges_of G2 = the_Edges_of G4
    by GLIB_006:def 10;
  then reconsider g = F0_E as PartFunc of the_Edges_of G1, the_Edges_of G2;
  A5: dom f /\ the_Vertices_of G3 = {} by A1, XBOOLE_1:79, XBOOLE_0:def 7;
  dom F0_V /\ dom f c= dom f /\ the_Vertices_of G3 by XBOOLE_1:26;
  then A6: dom F0_V misses dom f by A5, XBOOLE_1:3, XBOOLE_0:def 7;
  A7: rng f /\ the_Vertices_of G4 = {} by A1, XBOOLE_1:79, XBOOLE_0:def 7;
  rng F0_V /\ rng f c= rng f /\ the_Vertices_of G4 by XBOOLE_1:26;
  then A8: rng F0_V misses rng f by A7, XBOOLE_1:3, XBOOLE_0:def 7;
  A9: dom h /\ the_Vertices_of G3
     = (dom F0_V \/ dom f) /\ the_Vertices_of G3 by FUNCT_4:def 1
    .= (dom F0_V /\ the_Vertices_of G3) \/ (dom f /\ the_Vertices_of G3)
      by XBOOLE_1:23
    .= dom F0_V by A5, XBOOLE_1:28;
  now
    hereby
      let e be object;
      assume A10: e in dom g;
      (the_Source_of G1).e = (the_Source_of G3).e &
        (the_Target_of G1).e = (the_Target_of G3).e by GLIB_006:def 10;
      then A11: (the_Source_of G1).e in dom F0_V &
        (the_Target_of G1).e in dom F0_V by A10, Th5;
      dom F0_V c= dom h by FUNCT_4:10;
      hence (the_Source_of G1).e in dom h &
        (the_Target_of G1).e in dom h by A11;
    end;
    let e,v,w be object;
    assume A12: e in dom g & v in dom h & w in dom h & e Joins v,w,G1;
    A13: e Joins v,w,G3 by A12, GLIB_009:41;
    then A14: v in the_Vertices_of G3 & w in the_Vertices_of G3 by GLIB_000:13;
    then v in dom F0_V & w in dom F0_V by A12, A9, XBOOLE_0:def 4;
    then F0_E.e Joins F0_V.v,F0_V.w,G4 by A12, A13, Th4;
    then A15: g.e Joins F0_V.v,F0_V.w,G2 by GLIB_009:41;
    not v in dom f & not w in dom f by A1, A14, XBOOLE_0:def 5;
    then h.v = F0_V.v & h.w = F0_V.w by FUNCT_4:11;
    hence g.e Joins h.v,h.w,G2 by A15;
  end;
  then reconsider F = [h,g] as PGraphMapping of G1, G2 by Th8;
  take F;
  thus F = [F0_V +* f, F0_E];
  :: show properties
  thus F0 is non empty implies F is non empty by FUNCT_4:10, XBOOLE_1:3;
  thus F0 is total implies F is total
  proof
    assume F0 is total;
    then A16: dom F0_V = the_Vertices_of G3 & dom F0_E = the_Edges_of G3;
    then dom h = the_Vertices_of G3 \/ (V1 \ the_Vertices_of G3)
        by A1, FUNCT_4:def 1
      .= the_Vertices_of G3 \/ V1 by XBOOLE_1:39
      .= the_Vertices_of G1 by GLIB_006:def 10;
    hence thesis by A16, GLIB_006:def 10;
  end;
  thus F0 is onto implies F is onto
  proof
    assume F0 is onto;
    then A17: rng F0_V = the_Vertices_of G4 & rng F0_E = the_Edges_of G4;
    rng h = rng F0_V \/ rng f by A6, NECKLACE:6
      .= the_Vertices_of G4 \/ V2 by A1, A17, XBOOLE_1:39
      .= the_Vertices_of G2 by GLIB_006:def 10;
    hence thesis by A17, GLIB_006:def 10;
  end;
  thus F0 is one-to-one implies F is one-to-one by A8, FUNCT_4:92;
  thus F0 is directed implies F is directed
  proof
    assume A18: F0 is directed;
    now
      let e,v,w be object;
      assume A19: e in dom g & v in dom h & w in dom h & e DJoins v,w,G1;
      A20: e DJoins v,w,G3 by A19, GLIB_009:41;
      then e Joins v,w,G3 by GLIB_000:16;
      then A21: v in the_Vertices_of G3 & w in the_Vertices_of G3
        by GLIB_000:13;
      then v in dom F0_V & w in dom F0_V by A19, A9, XBOOLE_0:def 4;
      then F0_E.e DJoins F0_V.v,F0_V.w,G4 by A18, A19, A20;
      then A22: g.e DJoins F0_V.v,F0_V.w,G2 by GLIB_009:41;
      not v in dom f & not w in dom f by A1, A21, XBOOLE_0:def 5;
      then h.v = F0_V.v & h.w = F0_V.w by FUNCT_4:11;
      hence g.e DJoins h.v,h.w,G2 by A22;
    end;
    hence thesis;
  end;
  thus F0 is semi-continuous implies F is semi-continuous
  proof
    assume A23: F0 is semi-continuous;
    now
      let e,v,w be object;
      assume A24: e in dom g & v in dom h & w in dom h & g.e Joins h.v,h.w,G2;
      then A25: F0_E.e Joins h.v,h.w,G4 by GLIB_009:41;
      then h.v in the_Vertices_of G4 & h.w in the_Vertices_of G4
        by GLIB_000:13;
      then A26: not h.v in rng f & not h.w in rng f by A7, XBOOLE_0:def 4;
      A27: not v in dom f & not w in dom f
      proof
        assume v in dom f or w in dom f;
        then per cases;
        suppose v in dom f;
          then f.v in rng f & h.v = f.v by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A26;
        end;
        suppose w in dom f;
          then f.w in rng f & h.w = f.w by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A26;
        end;
      end;
      v in dom F0_V \/ dom f & w in dom F0_V \/ dom f by A24, FUNCT_4:def 1;
      then A28: v in dom F0_V & w in dom F0_V by A27, XBOOLE_0:def 3;
      F0_V.v = h.v & F0_V.w = h.w by A27, FUNCT_4:11;
      then F0_E.e Joins F0_V.v,F0_V.w,G4 by A25;
      then A29: e Joins v,w,G3 by A23, A24, A28;
      v is set & w is set by TARSKI:1;
      hence e Joins v,w,G1 by A29, GLIB_009:41;
    end;
    hence thesis;
  end;
  thus F0 is continuous implies F is continuous
  proof
    assume A30: F0 is continuous;
    now
      let e9,v,w be object;
      assume A31: v in dom h & w in dom h & e9 Joins h.v,h.w,G2;
      then A32: e9 Joins h.v,h.w,G4 by GLIB_009:41;
      then h.v in the_Vertices_of G4 & h.w in the_Vertices_of G4
        by GLIB_000:13;
      then A33: not h.v in rng f & not h.w in rng f by A7, XBOOLE_0:def 4;
      A34: not v in dom f & not w in dom f
      proof
        assume v in dom f or w in dom f;
        then per cases;
        suppose v in dom f;
          then f.v in rng f & h.v = f.v by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A33;
        end;
        suppose w in dom f;
          then f.w in rng f & h.w = f.w by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A33;
        end;
      end;
      v in dom F0_V \/ dom f & w in dom F0_V \/ dom f by A31, FUNCT_4:def 1;
      then A35: v in dom F0_V & w in dom F0_V by A34, XBOOLE_0:def 3;
      F0_V.v = h.v & F0_V.w = h.w by A34, FUNCT_4:11;
      then consider e being object such that
        A36: e Joins v,w,G3 & e in dom F_E & F_E.e = e9 by A30, A32, A35;
      take e;
      v is set & w is set by TARSKI:1;
      hence e Joins v,w,G1 by A36, GLIB_009:41;
      thus e in dom g & g.e = e9 by A36;
    end;
    hence thesis;
  end;
  thus F0 is semi-Dcontinuous implies F is semi-Dcontinuous
  proof
    assume A37: F0 is semi-Dcontinuous;
    now
      let e,v,w be object;
      assume A38: e in dom g & v in dom h & w in dom h & g.e DJoins h.v,h.w,G2;
      then A39: F0_E.e DJoins h.v,h.w,G4 by GLIB_009:41;
      then F0_E.e Joins h.v,h.w,G4 by GLIB_000:16;
      then h.v in the_Vertices_of G4 & h.w in the_Vertices_of G4
        by GLIB_000:13;
      then A40: not h.v in rng f & not h.w in rng f by A7, XBOOLE_0:def 4;
      A41: not v in dom f & not w in dom f
      proof
        assume v in dom f or w in dom f;
        then per cases;
        suppose v in dom f;
          then f.v in rng f & h.v = f.v by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A40;
        end;
        suppose w in dom f;
          then f.w in rng f & h.w = f.w by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A40;
        end;
      end;
      v in dom F0_V \/ dom f & w in dom F0_V \/ dom f by A38, FUNCT_4:def 1;
      then A42: v in dom F0_V & w in dom F0_V by A41, XBOOLE_0:def 3;
      F0_V.v = h.v & F0_V.w = h.w by A41, FUNCT_4:11;
      then F0_E.e DJoins F0_V.v,F0_V.w,G4 by A39;
      then A43: e DJoins v,w,G3 by A37, A38, A42;
      v is set & w is set by TARSKI:1;
      hence e DJoins v,w,G1 by A43, GLIB_009:41;
    end;
    hence thesis;
  end;
  thus F0 is Dcontinuous implies F is Dcontinuous
  proof
    assume A44: F0 is Dcontinuous;
    now
      let e9,v,w be object;
      assume A45: v in dom h & w in dom h & e9 DJoins h.v,h.w,G2;
      then A46: e9 DJoins h.v,h.w,G4 by GLIB_009:41;
      then e9 Joins h.v,h.w,G4 by GLIB_000:16;
      then h.v in the_Vertices_of G4 & h.w in the_Vertices_of G4
        by GLIB_000:13;
      then A47: not h.v in rng f & not h.w in rng f by A7, XBOOLE_0:def 4;
      A48: not v in dom f & not w in dom f
      proof
        assume v in dom f or w in dom f;
        then per cases;
        suppose v in dom f;
          then f.v in rng f & h.v = f.v by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A47;
        end;
        suppose w in dom f;
          then f.w in rng f & h.w = f.w by FUNCT_1:3, FUNCT_4:13;
          hence contradiction by A47;
        end;
      end;
      v in dom F0_V \/ dom f & w in dom F0_V \/ dom f by A45, FUNCT_4:def 1;
      then A49: v in dom F0_V & w in dom F0_V by A48, XBOOLE_0:def 3;
      F0_V.v = h.v & F0_V.w = h.w by A48, FUNCT_4:11;
      then consider e being object such that
        A50: e DJoins v,w,G3 & e in dom F_E & F_E.e = e9 by A44, A46, A49;
      take e;
      v is set & w is set by TARSKI:1;
      hence e DJoins v,w,G1 by A50, GLIB_009:41;
      thus e in dom g & g.e = e9 by A50;
    end;
    hence thesis;
  end;
end;
