FISH: A THREE-DIMENSIONAL PARALLEL MAGNETOHYDRODYNAMICS CODE FOR ASTROPHYSICAL APPLICATIONS

FISH is a fast and simple ideal magnetohydrodynamics code that scales to ~10,000 processes for a Cartesian computational domain of ~10003 cells. The simplicity of FISH has been achieved by the rigorous application of the operator splitting technique, while second-order accuracy is maintained by the symmetric ordering of the operators. Between directional sweeps, the three-dimensional data are rotated in memory so that the sweep is always performed in a cache-efficient way along the direction of contiguous memory. Hence, the code only requires a one-dimensional description of the conservation equations to be solved. This approach also enables an elegant novel parallelization of the code that is based on persistent communications with MPI for cubic domain decomposition on machines with distributed memory. This scheme is then combined with an additional OpenMP parallelization of different sweeps that can take advantage of clusters of shared memory. We document the detailed implementation of a second-order total variation diminishing advection scheme based on flux reconstruction. The magnetic fields are evolved by a constrained transport scheme. We show that the subtraction of a simple estimate of the hydrostatic gradient from the total gradients can significantly reduce the dissipation of the advection scheme in simulations of gravitationally bound hydrostatic objects. Through its simplicity and efficiency, FISH is as well suited for hydrodynamics classes as for large-scale astrophysical simulations on high-performance computer clusters. In preparation for the release of a public version, we demonstrate the performance of FISH in a suite of astrophysically orientated test cases.

[1]  Manuel Torrilhon,et al.  Constraint-Preserving Upwind Methods for Multidimensional Advection Equations , 2004, SIAM J. Numer. Anal..

[2]  Ue-Li Pen,et al.  A FREE, FAST, SIMPLE, AND EFFICIENT TOTAL VARIATION DIMINISHING MAGNETOHYDRODYNAMIC CODE , 2003 .

[3]  D. Balsara,et al.  A Staggered Mesh Algorithm Using High Order Godunov Fluxes to Ensure Solenoidal Magnetic Fields in Magnetohydrodynamic Simulations , 1999 .

[4]  Dinshaw S. Balsara,et al.  Notes on the Eigensystem of Magnetohydrodynamics , 1996, SIAM J. Appl. Math..

[5]  Paul R. Woodward,et al.  A Simple Finite Difference Scheme for Multidimensional Magnetohydrodynamical Equations , 1998 .

[6]  Ue-Li Pen,et al.  A High-Resolution Adaptive Moving Mesh Hydrodynamic Algorithm , 1997, astro-ph/9704258.

[7]  R. Fox,et al.  Classical Electrodynamics, 3rd ed. , 1999 .

[8]  T. Mouschovias,et al.  Magnetic braking of an aligned rotator during star formation: An exact, time-dependent solution , 1980 .

[9]  J. Brackbill,et al.  The Effect of Nonzero ∇ · B on the numerical solution of the magnetohydrodynamic equations☆ , 1980 .

[10]  H. Poincaré,et al.  Les Méthodes nouvelles de la Mécanique céleste and An Introduction to the Study of Stellar Structure , 1958 .

[11]  G. Tóth The ∇·B=0 Constraint in Shock-Capturing Magnetohydrodynamics Codes , 2000 .

[12]  Romain Teyssier,et al.  Kinematic dynamos using constrained transport with high order Godunov schemes and adaptive mesh refinement , 2006, J. Comput. Phys..

[13]  Astrophysics,et al.  The Fate of Nonradiative Magnetized Accretion Flows: Magnetically Frustrated Convection , 2003, astro-ph/0304227.

[14]  A. Ferrari,et al.  PLUTO: A Numerical Code for Computational Astrophysics , 2007, astro-ph/0701854.

[15]  J. Stone,et al.  An unsplit Godunov method for ideal MHD via constrained transport , 2005, astro-ph/0501557.

[16]  Randall J. LeVeque,et al.  A class of approximate Riemann solvers and their relation to relaxation schemes , 2001 .

[17]  B. Fryxell,et al.  FLASH: An Adaptive Mesh Hydrodynamics Code for Modeling Astrophysical Thermonuclear Flashes , 2000 .

[18]  J. Hawley,et al.  Simulation of magnetohydrodynamic flows: A Constrained transport method , 1988 .

[19]  M. Vinokur,et al.  An analysis of finite-difference and finite-volume formulations of conservation laws , 1986 .

[20]  A. Caceres,et al.  Mapping Initial Hydrostatic Models in Godunov Codes , 2002 .

[21]  G. Bryan,et al.  Introducing Enzo, an AMR Cosmology Application , 2004, astro-ph/0403044.

[22]  Michael L. Norman,et al.  Numerical simulations of protostellar jets with nonequilibrium cooling. II: Models of pulsed jets , 1993 .

[23]  A. Gautschy,et al.  Computational methods for astrophysical fluid flow , 1998 .

[24]  L. Landau,et al.  Lehrbuch der theoretischen Physik , 2007 .

[25]  T. Fischer,et al.  THE ISOTROPIC DIFFUSION SOURCE APPROXIMATION FOR SUPERNOVA NEUTRINO TRANSPORT , 2007, 0711.2929.

[26]  Z. Xin,et al.  The relaxation schemes for systems of conservation laws in arbitrary space dimensions , 1995 .

[27]  R. LeVeque Numerical methods for conservation laws , 1990 .

[28]  James M. Stone,et al.  An unsplit Godunov method for ideal MHD via constrained transport in three dimensions , 2007, J. Comput. Phys..

[29]  E. Toro Riemann Solvers and Numerical Methods for Fluid Dynamics , 1997 .

[30]  The angular momentum problem and magnetic braking during star formation: Exact solutions for an aligned and a perpendicular rotator , 1980 .

[31]  Dongwook Lee,et al.  An unsplit staggered mesh scheme for multidimensional magnetohydrodynamics , 2009, J. Comput. Phys..

[32]  M. Liebendörfer,et al.  Gravitational waves from 3D MHD core collapse simulations , 2007, 0709.0168.

[33]  P. Colella,et al.  THE PLUTO CODE FOR ADAPTIVE MESH COMPUTATIONS IN ASTROPHYSICAL FLUID DYNAMICS , 2011, 1110.0740.

[34]  P. Teuben,et al.  Athena: A New Code for Astrophysical MHD , 2008, 0804.0402.

[35]  P. Londrillo,et al.  On the divergence-free condition in Godunov-type schemes for ideal magnetohydrodynamics: the upwind constrained transport method , 2004 .

[36]  Susana Serna,et al.  A characteristic-based nonconvex entropy-fix upwind scheme for the ideal magnetohydrodynamic equations , 2009, J. Comput. Phys..

[37]  V. G. Weirs,et al.  On Validating an Astrophysical Simulation Code , 2002, astro-ph/0206251.

[38]  James A. Rossmanith,et al.  An Unstaggered, High-Resolution Constrained Transport Method for Magnetohydrodynamic Flows , 2006, SIAM J. Sci. Comput..

[39]  N. Risebro,et al.  STABLE UPWIND SCHEMES FOR THE MAGNETIC INDUCTION EQUATION , 2009 .

[40]  Michael L. Norman,et al.  Numerical Simulations of Protostellar Jets with Nonequilibrium Cooling. I. Method and Two-dimensional Results , 1993 .

[41]  R. Teyssier Cosmological hydrodynamics with adaptive mesh refinement - A new high resolution code called RAMSES , 2001, astro-ph/0111367.

[42]  R. Courant,et al.  Über die partiellen Differenzengleichungen der mathematischen Physik , 1928 .

[43]  G. Strang On the Construction and Comparison of Difference Schemes , 1968 .