Global MHD Simulation Code of Earth's Magnetosphere Using HPF/JA

    Tatsuki Ogino

    Solar-Terrestrial Environment Laboratory, Nagoya University

    We have been able to execute a 3-dimensional global magnetohydrodynamic (MHD) simulation of the interaction between the solar wind and Earth's magnetosphere on a variety of computers using a fully vectorized MHD code. Among the computers we have used are: CRAY Y-MP, Fujitsu VP-2600, Hitachi S820, and NEC SX-3. This flexibility to use many different computers allowed us to work together with many scientists executing our computer simulation. However, as vector parallel and massive parallel supercomputers have come into the simulation community, a number of different approaches are now being used. Many simulation scientists have lost their common language and are forced to speak new dialects. We strongly hope to recover a common language in the supercomputer world. Recent candidates for this common language appear to be High Performance Fortran (HPF) and Message Passing Interface (MPI). We have looked forward to the time when we could use these compilers in supercomputers.

    From this June, we have had the opportunity to use HPF/JA (an extended version of HPF by JAHPF) with a supercomputer, the Fujitsu VPP5000/56 in the Computer Center of Nagoya University. We immediately began to rewrite our 3-dimensional MHD simulation code of Earth's magnetosphere from VPP Fortran to HPF/JA. The MHD code was fully vectorized and fully parallelized in VPP Fortran. We successfully rewrote the code from VPP Fortran to HPF/JA in three weeks, and then needed an additional two weeks to perform final verification of the calculation results. The performance of the HPF MHD code was almost comparable to that of the VPP Fortran in a typical simulation using a large number (56) of Processing Elements (PEs) . Thus we have obtained the following conclusion: the fluid and MHD codes that are fully vectorized and fully parallelized in VPP Fortran can be relatively easily rewritten to HPF/JA, and a code in HPF/JA can be expected to achieve comparable performance as to one written in VPP Fortran.

    The 3-dimensional global MHD simulation code of Earth's magnetosphere solves the MHD and Maxwell's equations in 3-dimensional Cartesian coordinates (x, y, z) as an initial and boundary value problem using a modified leap-frog method. The MHD quantities are distributed in the z direction. The quantities in the neighboring grids can be calculated by the HPF/JA instruction sentences "shadow" and "reflect" when they exist in another PE. Unnecessary communication among PEs can be completely stopped by the instructions "independent, new," and "on home, local." Moreover, the lump transmission of data is used in the calculation of the boundary conditions by the instruction "asynchronous." It was not necessary to change the fundamental structure of the MHD code in the rewriting procedure. This was a big advantage to rewriting the MHD code from VPP Fortran to HPF/JA.

    Based on this experience, I anticipate that we will not have great difficulty to rewrite programs from VPP Fortran to HPF/JA, and that we can expect almost comparable performance on the Fujitsu VPP5000. The maximum performance of the 3-dimensional MHD code was over 230 Gflops for 32 PEs and over 400 Gflops for 56 PEs. We hope that the MHD code rewritten in HPF/JA can be executed on other supercomputers such as the Hitachi SR8000 and the NEC SX-5 in the near future. We have made available a part of the boundary condition in the HPF/JA MHD code and a test program of the 3-dimensional wave equation at the following web address:
    http://gedas.stelab.nagoya-u.ac.jp/simulation/hpfja/hpf01.html.