We present a novel definition of an algorithm and its corresponding algorithm language called CoLweb. The merit of CoLweb [1] is that it makes algorithm design so versatile. That is, it forces us to a high-level, proof-carrying, distributed-style approach to algorithm design for both non-distributed computing and distributed one. We argue that this approach simplifies algorithm design. In addition, it unifies other approaches including recursive logical/functional algorithms, imperative algorithms, object-oriented imperative algorithms, neural-nets, interaction nets, proof-carrying code, etc. As an application, we refine Horn clause definitions into two kinds: blind-univerally-quantified (BUQ) ones and parallel-universally-quantified (PUQ) ones. BUQ definitions corresponds to the traditional ones such as those in Prolog where knowledgebase is $not$ expanding and its proof procedure is based on the backward chaining. On the other hand, in PUQ definitions, knowledgebase is $expanding$ and its proof procedure leads to forward chaining and {\it automatic memoization}.
翻译:我们提出了一种算法的新定义及其对应的算法语言,称为CoLweb。CoLweb[1]的优势在于它使算法设计变得极其灵活。也就是说,它促使我们采用一种高层次、携带证明、分布式风格的方法来设计算法,既适用于非分布式计算,也适用于分布式计算。我们认为这种方法简化了算法设计。此外,它统一了其他方法,包括递归逻辑/函数式算法、命令式算法、面向对象命令式算法、神经网络、交互网、携带证明的代码等。作为应用,我们将Horn子句定义细化为两种类型:盲全称量化(BUQ)和并行全称量化(PUQ)。BUQ定义对应于传统定义,例如Prolog中的定义,其中知识库$不$扩展,其证明过程基于反向链。另一方面,在PUQ定义中,知识库$正在扩展$,其证明过程导致前向链和{\it自动记忆化}。