Figure 7: The combined algorithm.