arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2209.06105physics.flu-dynphysics.comp-ph
收藏

基于OpenFOAM的计算流体动力学浮点精度研究

On floating point precision in computational fluid dynamics using OpenFOAM

F. Brogi, S. Bnà, G. Boga, G. Amati, T. Esposti Ongaro, M. Cerminara

摘要:

由于现代集群机器的计算能力,数值模拟可以提供前所未有的细节水平,对流体力学的新见解。然而,充分利用这种硬件仍然具有挑战性,因为数据通信仍然是达到峰值性能的重要瓶颈。降低浮点精度是减少数据移动和提高大多数应用程序计算速度的一种简单有效的方法。然而,需要特别注意确保计算解的质量和收敛性,特别是在处理复杂的流体模拟时。在这项工作中,我们分析的影响,减少(单和混合相比,双)精度的计算性能和准确性的计算流体动力学。使用开源库OpenFOAM,我们认为不可压缩,可压缩,和多相流体求解器的测试在层流和湍流的制度,并在存在冲击波的流动的相关基准。计算增益和变化的可扩展性的应用程序在降低精度进行了讨论。特别是,一个特设的理论模型的强缩放允许我们解释和理解所观察到的行为,作为浮点精度和硬件细节的函数。最后,我们展示了如何降低精度可以显着加快混合CPU-GPU实现,最近提供给OpenFOAM最终用户,这仅仅依赖于硬件供应商开发的GPU线性代数求解器。

英文摘要:

Thanks to the computational power of modern cluster machines, numerical simulations can provide, with an unprecedented level of details, new insights into fluid mechanics. However, taking full advantage of this hardware remains challenging since data communication remains a significant bottleneck to reaching peak performances. Reducing floating point precision is a simple and effective way to reduce data movement and improve the computational speed of most applications. Nevertheless, special care needs to be taken to ensure the quality and convergence of computed solutions, especially when dealing with complex fluid simulations. In this work, we analyse the impact of reduced (single and mixed compared to double) precision on computational performance and accuracy for computational fluid dynamics. Using the open source library OpenFOAM, we consider incompressible, compressible, and multiphase fluid solvers for testing on relevant benchmarks for flows in the laminar and turbulent regime and in the presence of shock waves. Computational gain and changes in the scalability of applications in reduced precision are also discussed. In particular, an ad hoc theoretical model for the strong scaling allows us to interpret and understand the observed behaviors, as a function of floating point precision and hardware specifics. Finally, we show how reduced precision can significantly speed up a hybrid CPU-GPU implementation, made available to OpenFOAM end-users recently, that simply relies on a GPU linear algebra solver developed by hardware vendors.

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

↑