arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1803.01190physics.comp-phastro-ph.GA
收藏

N体问题在GPU上并行实现的新特征

New features of parallel implementation of N-body problems on GPU

S. S. Khrapov, S. A. Khoperskov, A. V. Khoperskov

摘要:

本文主要研究直接$N$体方法~(粒子-粒子算法)的并行实现以及在银河系动力学模拟中的多GPU应用。混合OpenMP-CUDA技术的应用被认为是具有多个粒子$N \sim 10^5 ÷10^7$的模型。通过对引力不稳定星系的$N$体模拟,研究了不同图形处理器~(K20,K40,K80)对算法的并行化效率。通过比较单、双浮点精度~(SP和DP),重点考察了模拟的并行性能和数值解的精度。我们发现,双精度模拟比在Nvidia Tesla K系列处理器上执行的单精度运行慢约$1.7$倍。我们还指出,在非轴对称引力$N$ -体系统的演化中,应用单精度运算会导致不正确的结果。特别是,它导致了显着的数量,甚至质量扭曲的星系盘的演变。例如,在单精度数的$10^4$积分时间步长之后,具有$N = 2^{20}$的系统的总能量、动量和角动量分别以$10^{-3}$、$10^{-2}$和$10^{-3}$的精度守恒,与双精度模拟相比,这些值分别为$10^{-5}$、$10^{-15}$和$10^{-13}$。我们的估计证据支持使用具有双精度数字的二阶精度方案,因为它比具有单精度数字的四阶方案更有效。

英文摘要:

This paper focuses on the parallel implementation of a direct $N$-body method~(particle-particle algorithm) and the application of multiple GPUs for galactic dynamics simulations. Application of a hybrid OpenMP-CUDA technology is considered for models with a number of particles $N \sim 10^5 ÷10^7$. By means of $N$-body simulations of gravitationally unstable stellar galactic we have investigated the algorithms parallelization efficiency for various Nvidia Tesla graphics processors~(K20, K40, K80). Particular attention was paid to the parallel performance of simulations and accuracy of the numerical solution by comparing single and double floating-point precisions~(SP and DP). We showed that the double-precision simulations are slower by a factor of~$1.7$ than the single-precision runs performed on Nvidia Tesla K-Series processors. We also claim that application of the single-precision operations leads to incorrect result in the evolution of the non-axisymmetric gravitating $N$-body systems. In particular, it leads to significant quantitative and even qualitative distortions in the galactic disk evolution. For instance, after $10^4$ integration time steps for the single-precision numbers the total energy, momentum, and angular momentum of a system with $N = 2^{20}$ conserve with accuracy of $10^{-3}$, $10^{-2}$ and $10^{-3}$ respectively, in comparison to the double-precision simulations these values are $10^{-5}$, $10^{-15}$ and $10^{-13}$, respectively. Our estimations evidence in favour of usage of the second-order accuracy schemes with double-precision numbers since it is more efficient than in the fourth-order schemes with single-precision numbers.

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

↑