Figure 39:
The general solution algorithm.