Let be a -ary alphabet and let . Consider the space of words of length as a metric space with the Hamming distance. Then, given any word and integer radius , the solid sphere has volume given by the formula