Weight enumerator
= Weight enumerator
{title2=$W_C(s,t)$}
The homogeneous <weight enumerator> of a length-$n$ <linear code> $C$ is the <polynomial>
$$
W_C(s,t)=\sum_{x\in C}s^{\operatorname{wt}(x)}t^{n-\operatorname{wt}(x)}.
$$
Its coefficients count words of each <Hamming weight>. In this convention $W_C(1,1)=|C|$; some references interchange $s,t$.