ParticleGridMapper.jl
interpolates particle data onto either a Cartesian (uniform) grid or an adaptive mesh refinement (AMR) grid where each cell contains no more than one particle. The AMR grid can be trimmed with a user-defined maximum level of refinement. Three differnt interpolation schemes are supported: nearest grid point (NGP), smoothed-particle hydrodynamics (SPH), and Meshless finite mass (MFM). It is multi-threading parallel.
The AMR grid can be further refined to achieve the so-called "2:1 balance" where the refinement levels of neighboring cells differ by no greater than a factor of two, which leads to a smoothed transition of refinement.
- examples/example_cloud.jl demonstrates the usage of five different interpolation schemes: (1) Cartesian mesh with NGP; (2) Cartesian mesh with SPH; (3) NGP on an adaptive mesh; (4) SPH on an adaptive mesh; (5) MFM on an adaptive mesh. It then generates the following plot:
- examples/gadget2radmcAMR.jl demonstrates how to generate an adaptive mesh from a Gadget snapshot (format 3) and some axillary files required for radiative transfer calculations for CO rotational line emission using the RADMC-3D code. An illustration of such calculations from Hu et al. 2022:
Chia-Yu Hu @ Max Planck Institute for Extraterrestrial Physics (cyhu.astro@gmail.com)