Abstract
The new era of multimessenger astrophysics requires the capability of studying different aspects of the evolution of compact objects. In particular, the merger of neutron star binaries is a strong source of gravitational waves and electromagnetic radiation, from radio to γ-rays, as demonstrated by the detection of GW170817 and its electromagnetic counterparts. In order to understand the physical mechanisms involved in such systems, it is necessary to employ fully general relativistic magnetohydrodynamic (GRMHD) simulations able to include the effects of a composition and temperature dependent equation of state describing neutron star matter as well as neutrino emission and reabsorption. Here, we present our new code named Spritz that solves the GRMHD equations in 3D Cartesian coordinates and on a dynamical spacetime. The code can support tabulated equations of state, taking into account finite temperature effects and allowing for the inclusion of neutrino radiation. In this first paper, we present the general features of the code and a series of tests performed in special and general relativity to assess the robustness of the basic GRMHD algorithms implemented. Among these tests, we also present the first comparison between a non-staggered and a staggered formulation of the vector potential evolution, which is used to guarantee the divergence-less character of the magnetic field.