$f:X \to Y$ be a closed and open mapping , $g$ be a real valued continuous function on $X$ bounded on every fibre of $f$ Let $f:X \to Y$ be a closed and open mapping , where $X,Y$ are topological spaces . If $g :X \to \mathbb R$ is a continuous function such that for every $y \in Y$ , the set $g \Big( f^{-1}(\{y\}) \Big)$ is bounded, then how to show that the function $h : Y \to \mathbb R $ as $h(y):=\sup g \Big( f^{-1}(\{y\}) \Big) , \forall y \in Y$ is continuous ?  
 A: For any function $f:X\to Y$ between sets, there is a function 
$$\begin{align}
f_\forall:\mathcal P(X) & \to \mathcal P(Y) \\
  A & \mapsto \{y\mid f^{-1}(y)\subseteq A\}
\end{align}
$$
Note that $f_\forall(A)=Y\setminus f(X\setminus A)$.
If $X$ and $Y$ are spaces and $f$ is a closed (open) map, then $f_\forall$ preserves open (closed) sets. If $f$ is an open closed map, then for any open set $U\subseteq X$, the sets $f(U)$ and $f_\forall(U)$ are open in $Y$, and so is the set $f^{-1}(f(U))$, the saturation of $U$, as well as $f^{-1}(f_\forall(U))\subseteq U$, which we can think of as the largest saturated subset of $U$.
Take any point $y_0\in Y$ and let $s=h(y_0)=\sup_{f(x)=y_0}g(x)$. Assume $\varepsilon>0$. Then there is an $x_0\in f^{-1}(y_0)$ such that $s-g(x_0)<\varepsilon$. Since $g$ is continuous, there is an open $U$ such that $x_0\in U$ and $g(U)\subseteq (s-ε,s+ε)$. Then $f(U)$ is an open neighborhood of $y_0$ in $Y$. Since any fiber of a point $y$ in $f(U)$ contains a point in $U$ whose image lies in $g(U)$, we have $\sup_{f(x)=y}g(x)\in(s-ε,\infty)$, and thus $h(f(U))\subseteq(s-ε,\infty)$.
Let $V=g^{-1}((-\infty,s+ε))$. Then $f^{-1}(y_0)\subseteq V$, so $f_\forall(V)$ is an open neighborhood of $y_0$. Now $g(f^{-1}(f_\forall(V)))$ is a subset of $(-\infty,s+ε)$. That means that $h(f_\forall(V))$ is bounded above by $s+ε$.
Now $f(U)\cap f_\forall(V)$ is a neighborhood of $y_0$ and $h(f(U)\cap f_\forall(V))\subseteq (s-ε,s+ε)$, which means that $h$ is continuous.
