We generalize proper coloring of gain graphs to totally frustrated states,
where each vertex takes a value in a set of `qualities' or `spins' that is
permuted by the gain group. (An example is the Potts model.) The number of
totally frustrated states satisfies the usual deletion-contraction law but is
matroidal only for standard coloring, where the group action is trivial or
nearly regular. One can generalize chromatic polynomials by constructing spin
sets with repeated transitive components.Comment: 14 pages, 2 figure