arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1407.3189math.NAcs.MScs.NA
收藏

一种使用C++和Boost库的现代电阻磁流体动力学求解器

A modern resistive magnetohydrodynamics solver using C++ and the Boost library

University of Innsbruck(因斯布鲁克大学)

Lukas Einkemmer

AI总结:

本文介绍了一个基于C++的电阻磁流体动力学求解器,通过分离数值方法与物理模型,实现边界条件和计算域管理的模块化,提升性能并保持代码可读性和扩展性。

摘要:

本文描述了我们C++实现的电阻磁流体动力学求解器。开发的框架使数值方法和物理模型的代码与边界条件处理和计算域管理分离。特别地,这允许使用仅在域内定义的有限差分Stencil,边界条件自动处理。我们将详细讨论此设计及其他考虑因素及其对性能的影响。此外,我们提供了开发代码的文档,并证明可以实现与Fortran相当的性能,同时保持代码的最大可读性和扩展性。

英文摘要:

In this paper we describe the implementation of our C++ resistive magnetohydrodynamics solver. The framework developed facilitates the separation of the code implementing the specific numerical method and the physical model, on the one hand, from the handling of boundary conditions and the management of the computational domain, on the other hand. In particular, this will allow us to use finite difference stencils which are only defined in the interior of the domain (the boundary conditions are handled automatically). We will discuss this and other design considerations and their impact on performance in some detail. In addition, we provide a documentation of the code developed and demonstrate that a performance comparable to Fortran can be achieved, while still maintaining a maximum of code readability and extensibility.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑