# Is there a nodeless graph?

Standard definition of graph says that it is an ordered pair G=(N,L) where N is set of nodes and L is set of lines which connect the nodes.

From what I've read, the set L can be empty, but can set N be empty too?

I'm mainly asking this because for my exam, I found numerous problems that go like this: Graph X is given. How many subgraphs with property Y exist? Often the number depends on the definition of graph.

• @Rahul: no. The empty graph is not connected for the same reason that $1$ is not prime: because you want a graph to have a unique decomposition into connected components, and uniqueness is impossible if you call the empty graph connected. (From the perspective of the nLab article the correct definition is "there exists a path between any pair of vertices, and there exists at least one such pair.") – Qiaochu Yuan Jun 8 '11 at 14:17
• @Qiaochu: well, I'm thinking about it. For one thing, I want $\operatorname{Spec} R$ to be connected iff $R$ has no nontrivial idempotents, but I know what you're going to say: we should distinguish between rings which have $2$ idempotents and rings which have only $1$ idempotent! Also: the definition of connectedness via continuous functions to $\{0,1\}$ makes the empty space connected (although again you could redefine a "constant function" here). I also want arbitrary products of connected spaces to be connected... – Pete L. Clark Jun 8 '11 at 14:31
• @Pete: arbitrary products of connected spaces are connected either way! I'm not sure what you mean by the definition of connectedness via continuous functions to $\{ 0, 1 \}$, but this is the same issue as the idempotents: you want there to be no non-constant functions, as well as two trivial constant functions (another example of the nLab's "existence and uniqueness" observation). – Qiaochu Yuan Jun 8 '11 at 14:44