5 . Formal analysis of the algorithm
In this section we prove that deploymentPlanner defined in Algorithm 1 terminates and it is sound and complete, i.e.,
it produces a correct deployment plan if and only if it exists. Moreover, we prove that it runs in polynomial time w.r.t. the
size of the description of the universe of component types and the component type-state target pair.
To prove the termination of deploymentPlanner we rely on the following lemma stating that, in presence of circularities
blocking the topological visit of the abstract plan, there exists a node that has only incoming arcs. This is the node
chosen to start the duplication phase that will rearrange the plan ensuring that the selected node becomes visitable after
duplication.