
theorem Th35:
  for S being TopSpace,T being non empty TopSpace, K being prebasis of T
  for f being Function of S,T holds
  f is continuous iff for A being Subset of T st A in K holds f"A` is closed
proof
  let S be TopSpace,T be non empty TopSpace,
  BB be prebasis of T, f be Function of S,T;
A1: BB c= the topology of T by TOPS_2:64;
  hereby
    assume
A2: f is continuous;
    let A be Subset of T;
    assume A in BB;
    then A is open by A1;
    then A` is closed by TOPS_1:4;
    hence f"A` is closed by A2;
  end;
  assume
A3: for A being Subset of T st A in BB holds f"A` is closed;
  reconsider C = FinMeetCl BB as Basis of T by Th23;
  now
    let A be Subset of T;
    assume A in C;
    then consider Y being Subset-Family of T such that
A4: Y c= BB and
A5: Y is finite and
A6: A = Intersect Y by CANTOR_1:def 3;
    reconsider Y as Subset-Family of T;
    reconsider CY = COMPLEMENT Y as Subset-Family of T;
    defpred P[set] means $1 in Y;
    deffunc F(Subset of T) = $1`;
A7: f"A` = f"union CY by A6,YELLOW_8:7
      .= f"union {F(a) where a is Subset of T: P[a]} by Th3
      .= union {f"F(y) where y is Subset of T: P[y]} from ABC;
    set X = {f"y` where y is Subset of T: y in Y};
    X c= bool the carrier of S
    proof
      let x be object;
      assume x in X;
      then ex y being Subset of T st x = f"y` & y in Y;
      hence thesis;
    end;
    then reconsider X as Subset-Family of S;
    reconsider X as Subset-Family of S;
A8: X is closed
    proof
      let a be Subset of S;
      assume a in X;
      then ex y being Subset of T st a = f"y` & y in Y;
      hence thesis by A3,A4;
    end;
A9: Y is finite by A5;
    deffunc F(Subset of T) = f"$1`;
    {F(y) where y is Subset of T: y in Y} is finite from FRAENKEL:sch 21(
    A9);
    hence f"A` is closed by A7,A8,TOPS_2:21;
  end;
  hence thesis by Th33;
end;
