Let me start out with the question that prompts this:
Original Problem: Let $X$ be a compact topological space, and let $f : X \to \Bbb R$ be an upper semi-continuous function. Show that $f$ attains its supremum.
I'm fine with proving this by myself for the most part, at least for now. The proof I'm writing goes along this route:
- Prove that the image of $f$ is bounded above. (Easily done by contradiction with a specific cover.)
- From the least upper bound property of $\Bbb R$, it follows that $\alpha := \sup_{x \in X} f(x)$ exists.
- Show that $f(x) = \alpha$ at some point.
My actual question is tied somewhat to the second bullet point.
We should also verify that the argument of the supremum is itself a nonempty set. This is trivially obvious in most cases, but what if $X = \varnothing$? After all...
We can define a topology $\tau_\varnothing$ on $\varnothing$: it would be the set $\{\varnothing\}$. It is closed under union and intersection, contains $\varnothing$, and contains the original set (also $\varnothing$).
$\varnothing$ is a compact topological space. This follows readily since the only cover for it is itself, essentially. (Or you could look at it from the viewpoint that any topological space $X$ where $|X| \in \Bbb Z_{\ge 0}$ is compact, just make your subcover match one to one with the elements of $X$.)
We can say there exist functions $f : \varnothing \to A$ for any set $A$ without difficulty; in fact, such functions are unique, ensuring that $\varnothing$ is the initial object in $\mathbf{Set}$.
We define $f$ to be upper semicontinuous if $f^{-1}(-\infty,r)$ is open $\forall r \in \Bbb R$. If $X = \varnothing$, there isn't an issue there, for the preimages are always $\varnothing$, which is in $\tau_\varnothing$ and thus open.
From these, I think it is fine to say that the unique function $f : \varnothing \to \Bbb R$ is an upper semi-continuous function from a compact space.
However, would it be right to say that $f$ attains its supremum? There exists no $x \in \varnothing$ for which $f(x) = \alpha$ (or any real number). In fact we typically say $\sup \varnothing = -\infty$, which definitely would not be attained by a function with codomain $\Bbb R$.
Is there some sort of vacuous logic argument I'm missing here? (I'm terrible with that stuff myself - perhaps it should be phrased instead as there exists no $x \in \varnothing$ for which $f(x) \ne \alpha$?) Or perhaps I overlooked something when outlining the premises above? Thanks for your thoughts on the matter!