Is a semicontinuous real function Borel measurable?

Let $f(x,u): [0,1]^2 \mapsto \mathbb{R}$ be a continuous function.

[Q] Is $g(x) = \inf_{u\in [0,1]} f(x,u)$ always Borel measurable? If not, can one find a counter-example?

Note that, for any $c$, we have $$(x: g(x) < c) = \text{Proj}_x ((x,u): f(x,u) < c),$$ where $\text{Proj}_x$ is a projection operator to $x$-axis. In the context of measurable selection theorem, the projection of Borel set $((x,u): f(x,u) < c)$ of $\mathbb{R}^2$ is not necessarily a Borel set of $\mathbb{R}$. But, I can not find a counter-example.

If there exists a proper counter-example, then it also implies that a semicontinuous real function is not necessarily Borel measurable.

Thanks.

-
Do you have an example where $g$ is not continues –  Rami Mar 10 '12 at 5:27
If you think I answered your question, please accept it as the answer officially. Thanks! –  GH from MO Mar 11 '12 at 8:01

We have that $g(x) = \inf_{u\in [0,1]\cap\mathbb{Q}} f(x,u)$, because $f(x,u)$ is continuous. This shows immediately that $g(x)$ is Borel, in fact Baire-1 because it is the pointwise limit of continuous functions (since $\mathbb{Q}$ is countable).

In general, any upper semi-continuous function $g(x)$ is Borel, in fact Baire-1. To see this, note first that each level set $\{x:g(x)\geq c\}$ is closed, hence $\{x:g(x)>c\}$ is an $F_\sigma$-set, $\{x:a<g(x)<b\}$ is the intersection of two $F_\sigma$'s which is $F_\sigma$, hence the inverse image of any open set is a countable union of $F_\sigma$'s which is $F_\sigma$.

-
GH. thanks for your answer. –  kenneth Mar 11 '12 at 4:32

I think that the answer is positive:

It is enough to show that the set $( x | g(x) < c )$ is Borel. as you saed it is an image under $Proj_x$ of an open set $U$. divide $[0,1]^2$ to a union of its interior $(0,1)^2$ and the boundary. Correspondingly divide $U$ into $U_0:= (0,1)^2 \cap U$ and its complement $Z$. it is enough to show the the image of each of them under $Proj_X$ is Borel. Which is evident.

-
In-fact the division of $U$ into 2 sets is unnecessary and the image of $U$ is just open. This dose not prove continuity yet since it is not enough to check continuity on sets like this. –  Rami Mar 10 '12 at 5:23
I did not explained why it is enough to show that $(x|g(x) < c)$ is Borel. I now understand that is probably the point that you where interested in. But it is explained in the answer of GH so there is no point to repeat it –  Rami Mar 10 '12 at 5:32

I think every (lower) semicontinuous function $f:X \to \mathbb{R}$ is Borel measurable, since you have the following characterization: for every $a \in \mathbb{R}$ the set $$f^{-1}((-\infty, a])$$ is closed in the topology that you are considering in $X$.

Since you only have to check the measurability property for a generating class of the Borelians in $\mathbb{R}$ you are done.

-