A unified theory of interconnection network structure