Why is the class equation written the way it's written (i.e. with the $|Z(G)|$ term) The conjugacy class equation is a nice relation for finite groups, usually stated something like this (taken from Dummit and Foote):

Let $G$ be a finite group and let $g_1, \cdots, g_r$ be representatives of the distinct conjugacy classes of $G$ not contained in the center $Z(G)$ of $G$. Then
  $$|G| = |Z(G)| + \sum_{i=1}^r|G:C_G(g_i)|.$$

My question is, why do people bother to separate out the elements in the center? The expression $|G:C_G(g)|$ is still well-defined for $g \in Z(G)$: if $g$ commutes with everything then $C_G(g)$ is the whole group, so it'll still contribute $1$ to the total sum. The extra $Z(G)$ term serves only to make the equation longer and more confusing (see this question for another example of what I'm talking about, and why I'd like to avoid it).
Presumably this is just a historical artifact, but if I were to teach this in a class myself I'd want to know 1) if I'm missing any obvious "advantage" to this formulation (so as to be able to pass this on to my students) and 2) any historical details that led this to be written the way it is (context is always illuminating). Your thoughts on either of these would be greatly appreciated.
 A: The class equation is a special case of an appliation of the Orbit-Stabilizer Theorem for an arbitrary action. If the finite group $G$ acts on the finite group $X$, and we let $\mathcal{O}_1,\ldots,\mathcal{O}_k$ be the orbits of the action, then of course
$$|X| = \sum_{i=1}^k |\mathcal{O}_i|$$
and by the Orbit-Stabilizer Theorem, of $x_i$ is an element of $\mathcal{O}_i$, then $|\mathcal{O}_i| = [G:\mathrm{Stab}_G(x_i)]$, the index of the stabilizer of $x_i$.
But when you are working with general actions, singleton orbits are “silly”; you just have the trivial action $g\cdot x= x$ for all $g\in G$. For the action of $G$ on $X$, what really matters, what really gives you information about $G$, are the orbits with more than one element. So it makes sense to divide $X$ into two: $X_0$, consisting of all elements that are fixed pointwise by every element of $G$, and $X_1$, the complement of $X_0$ in $X$. If we re-order the orbits so that $X_1=\mathcal{O}_1\cup\cdots\mathcal{O}_m = X_1$, and $\mathcal{O}_{m+1},\ldots,\mathcal{O}_k$ are the singleton orbits, then
$$|X| = |X_0|+|X_1| = |X_0| + \sum_{i=1}^m[G:\mathrm{Stab}_G(x_i)],$$
and we separate the $X_0$ because that’s the part of $X$ where the action is trivial. 
If we take this general framework to the case where $X=G$ and the action is conjugation, $X_0$ corresponds to $Z(G)$. So separating out the $Z(G)$ makes this fit into the more general framework in which we separate out the part of the set where the action is trivial.
Of course, it just so happens to be useful for the class equation. For example, it makes it obvious that the center of a finite $p$-group is nontrivial, since both $G$ and the sum are congruent to $0$ modulo $p$. 
A: All the elements of the center have centralizer equal to the whole group, so index $1$.  Thus the order of the center appears.  All the other elements of the group have centralizers with index greater than $1$.
Here is an example of how it can be useful (read the comments):  https://math.stackexchange.com/a/3629245/403337
