As you have seen, different texts define their terms somewhat differently, but the most common definitions are as follows:
- If $(X,d)$ is a metric space (or a pseudometric space), then the open ball of radius $r > 0$ about the point $x \in X$ is the set of all $y \in X$ such that $d(x, y) < r$.
- If $(X,d)$ is a metric space (or a pseudometric space), then a set $U \subseteq X$ is open iff for each $x \in U$ there is an $r > 0$ such that the open ball about $x$ of radius $r$ is a subset of $U$.
- An open neighborhood of a point $x$ in a metric space (or, in fact, any topological space) is any open set containing $x$.
- A neighborhood of a point $x$ in a metric space (or any topological space) is any subset of the space including, as a subset, an open neighborhood of $x$.
Beware: the notations used for open balls vary radically among texts, with almost all imaginable permutations of where the point goes, where the radius goes, and (in some cases) where the name of the metric goes.
The following books explicitly take the position that $\operatorname{diam}\varnothing =0$:
- C. Kuratowski, Topology, vol.I
- M. H. A. Newman, Elements of the topology of plane sets of points
The following books explicitly take the position that $\operatorname{diam}\varnothing =-\infty$:
- G. F. Simmons, Introduction to topology and modern analysis
- M. Ó. Searcóid, Metric spaces
(I never heard of either of these before Google Books search brought them up.)
The following books explicitly restrict the definition of diameter to nonempty sets:
- W. Rudin, Principles of mathematical analysis
- H. L. Royden, Real analysis.
- K. Falconer, Fractal geometry
It seems that W. Sierpiński, General topology, belongs to the second or third category, because the author says on page 110: "Thus the diameter of every non-empty set contained in a metric space is a uniquely defined real non-negative number, finite or infinite". But it's not very clear what Sierpiński's intention was when writing this.
Many books do nothing of the above: they define the diameter of a set as supremum of pairwise distances, and offer no further details.
If you allow the diameter of the empty set to be $−\infty$, does it lead to problems?
The definition of Hausdorff measure would become awkward. For example, the 1-dimensional measure involves the infimum of $\sum \operatorname{diam} U_i$ over certain families of sets. If $\operatorname{diam}\varnothing =-\infty$, we'd be able to make the infimum $-\infty$ by throwing in the empty set. (Note that the Wikipedia article explicitly says that $\operatorname{diam}\varnothing =0$). One can try to fix this by requiring $U_i$ to be nonempty, but then the measure of empty space becomes a special case (and the measure of $\varnothing$ definitely needs to be $0$).
Another issue is the inequality
$$
\operatorname{diam}(A\cup B)\le \operatorname{diam}A+\operatorname{diam}B+\operatorname{dist}(A,B)
$$
which should hold for all $A,B$. Suppose $B$ is empty but $A$ is not. The right-hand side becomes undefined due to presence of
$\operatorname{diam}\varnothing =-\infty$ and $\operatorname{dist}(A,\varnothing)=+\infty$. (And the latter definitely needs to be $+\infty$.)
Third issue: if one applies a metric transform, i.e., replaces metric $d$ with $\varphi(d)$ where $\varphi $ is an increasing concave function, the diameters of sets should transform accordingly. With $-\infty$ in the mix, one is led to awkward conventions ($\sqrt{-\infty}=-\infty$?).
That said, I can imagine some arguments in favor of $\operatorname{diam}\varnothing =-\infty$. One is that the following statement becomes true:
In a complete metric space, each decreasing sequence of closed sets $C_n$ with $\operatorname{diam}C_n\to 0$ has nonempty intersection.
(quoted from S. Willard, General topology). If $\operatorname{diam}\varnothing =0$, the above is false without additional requirement that $C_n$ are nonempty.
That said, it's probably best to put nonempty there. The absence of nonempty leads to wrong statements in a number of books, e.g., "if $N$ is compact, there exist $x,y\in N$ such that $\rho(x,y)=\operatorname{diam}N$". (G.T. Whyburn, Analytic topology).
Summary.
- It's safer to keep $\operatorname{diam}$ nonnegative, because it may appear in formulas that need nonnegative inputs.
- If the validity of what you write depends on the interpretation of $\operatorname{diam}\varnothing$, consider changing the statement.
Best Answer
You can always let an element do two jobs at once in this sense unless you’re checking a statement that explicitly rules out the possibility, and here you are not. Here, for instance, you have to check a requirement that $d(x,z)\le d(x,y)+d(y,z)$ whenever $x,y,z\in X$; there is no implication here that $x,y$, and $z$ must be distinct points. Indeed, the triangle inequality must hold whether they are distinct of not. The same goes for the other clauses of the definition.