Many of the most fundamental laws of nature can be formulated as partial differential equations (PDEs). Understanding these equations is, therefore, of exceptional importance for many branches of modern science and engineering. However, since the general solution of many PDEs is unknown, the efficient approximate solution of these equations is one of humanity's greatest challenges. While multigrid represents one of the most effective methods for solving PDEs numerically, in many cases, the design of an efficient or at least working multigrid solver is an open problem. This thesis demonstrates that grammar-guided genetic programming, an evolutionary program synthesis technique, can discover multigrid methods of unprecedented structure that achieve a high degree of efficiency and generalization. For this purpose, we develop a novel context-free grammar that enables the automated generation of multigrid methods in a symbolically-manipulable formal language, based on which we can apply the same multigrid-based solver to problems of different sizes without having to adapt its internal structure. Treating the automated design of an efficient multigrid method as a program synthesis task allows us to find novel sequences of multigrid operations, including the combination of different smoothing and coarse-grid correction steps on each level of the discretization hierarchy. To prove the feasibility of this approach, we present its implementation in the form of the Python framework EvoStencils, which is freely available as open-source software. This implementation comprises all steps from representing the algorithmic sequence of a multigrid method in the form of a directed acyclic graph of Python objects to its automatic generation and optimization using the capabilities of the code generation framework ExaStencils and the evolutionary computation library DEAP.
翻译:许多最基本的自然定律可以表示为偏微分方程(PDE)。因此,理解这些方程对现代科学和工程的诸多分支具有极其重要的意义。然而,由于许多偏微分方程的通解未知,高效近似求解这些方程是人类面临的最大挑战之一。虽然多重网格是数值求解偏微分方程最有效的方法之一,但在许多情况下,设计高效甚至可用的多重网格求解器仍是一个未解难题。本论文证明,语法引导的遗传编程——一种进化程序综合技术——能够发现具有前所未有结构的多重网格方法,并实现高效率与强泛化能力。为此,我们开发了一种新型上下文无关语法,支持在可符号操作的规范语言中自动生成多重网格方法,从而使同一多重网格求解器无需调整内部结构即可应用于不同规模的问题。将高效多重网格方法的自动设计视为程序综合任务,使我们能够发现多重网格操作的新型序列,包括在离散化层次每一层上结合不同的平滑和粗网格校正步骤。为证明该方法的可行性,我们以Python框架EvoStencils形式实现了该方法,该框架作为开源软件免费提供。该实现涵盖了从将多重网格方法的算法序列表示为Python对象的有向无环图,到利用代码生成框架ExaStencils与进化计算库DEAP自动生成及优化该序列的全过程。