Group Structure of Gauge Theories