Compositional adaptation is one of the two general approaches to implementing software adaptation. This approach exchanges algorithmic or structural system components with others that improve a program's fit to its current environment. With compositional adaptation, an application can adopt new algorithms for addressing concerns that were unforeseen during development. This flexibility not only supports tuning of program variables or strategy selection but also allows dynamic recomposition of the software during execution.