Formalising Adaptation Patterns for Autonomic Ensembles