Introduction


  1. Romans' Divide et Impera vs. Computer Science's Divide and Conquer.

    Romans divided their enemy by fomenting internal fights within the enemy groups (e.g., ethnic groups). When the enemy was exhausted by the internal turmoils, either the Romans attacked and destroyed the enemy's weak defenses or, more often, they engaged in the dispute as peace maker. In this way, the Romans could lead their own legions among enemy lines so to control the territory and the enemy animosities.

    Most importantly, peace was so desperately needed that the Romans were often welcome, even as rulers, and they did not need to engage in any real battle; they needed mostly to control, to protect and to build.

    We may say that the divide et impera worked like magic, avoiding the battle and therefore the loss of personnel and legionaires.

    In computer science, we are familiar with the definition of divide and conquer algorithms (e.g., bitonic sort, quick sort, matrix multiply). In a divide and conquer algorithm, A large problem is divided into a determined number of small, and more manageable, sub-problems. If the sub-problem size is small enough that we can solve it with the given resources, we just solve it; otherwise, we divide it in smaller problems. When each sub problem is solved, the solutions are combined to achieve the final solution.

    Here, we are bound to solve each small problem; in other words, we have to work solving the small sub-problems.

    This project proposes a novel approach in modeling the art of the divide, so that a compiler can have a tool in optimizing recursive divide and conquer algorithms.