Fortran interface layer of the framework for developing particle simulator FDPS
Fortran interface layer of the framework for developing particle simulator FDPS
复制标题
粒子模拟器FDPS开发框架的Fortran接口层
DOI:
10.1093/pasj/psy062
复制
发表时间:
2018
影响因子:
2.3
通讯作者:
Makino Junichiro
中科院分区:
文献类型:
--
作者:
Namekata Daisuke ;Iwasawa Masaki ;Nitadori Keigo ;Tanikawa Ataru ;Muranushi Takayuki ;Wang Long ;Hosono Natsuki ;Nomura Kentaro ;Makino Junichiro
Numerical simulations based on particle methods have been widely used in various fields including astrophysics. To date, various versions of simulation software have been developed by individual researchers or research groups in each field, through a huge amount of time and effort, even though the numerical algorithms used are very similar. To improve the situation, we have developed a framework, called FDPS (Framework for Developing Particle Simulators), which enables researchers to develop massively parallel particle simulation codes for arbitrary particle methods easily. Until version 3.0, FDPS provided an API (application programming interface) for the C++ programming language only. This limitation comes from the fact that FDPS is developed using the template feature in C++, which is essential to support arbitrary data types of particle. However, there are many researchers who use Fortran to develop their codes. Thus, the previous versions of FDPS require such people to invest much time to learn C++. This is inefficient. To cope with this problem, we developed a Fortran interface layer in FDPS, which provides API for Fortran. In order to support arbitrary data types of particle in Fortran, we design the Fortran interface layer as follows. Based on a given derived data type in Fortran representing particle, aPythonscript provided by us automatically generates a library that manipulates the C++ core part of FDPS. This library is seen as a Fortran module providing an API of FDPS from the Fortran side and uses C programs internally to interoperate Fortran with C++. In this way, we have overcome several technical issues when emulating a ‘template’ in Fortran. Using the Fortran interface, users can develop all parts of their codes in Fortran. We show that the overhead of the Fortran interface part is sufficiently small and a code written in Fortran shows a performance practically identical to the one written in C++.
登录
查看更多内容
DOI:
--
发表时间:
--
期刊:
影响因子:
--
作者:
通讯作者:
--
DOI:
10.3847/2041-8213/aa6256
发表时间:
2017
期刊:
The Astrophysical Journal Letters
影响因子:
--
作者:
S. Michikoshi;E. Kokubo
通讯作者:
E. Kokubo
影响因子:
2.3
作者:
Iwasawa, Masaki;Tanikawa, Ataru;Makino, Junichiro
通讯作者:
Makino, Junichiro
影响因子:
3.2
作者:
H. Salo
通讯作者:
H. Salo
影响因子:
2.3
作者:
Hosono Natsuki;Iwasawa Masaki;Tanikawa Ataru;Nitadori Keigo;Muranushi Takayuki;Makino Junichiro
通讯作者:
Makino Junichiro