Block-Structured AMR
- Block-structured AMR is a method that uses a hierarchy of rectangular blocks to adaptively refine regions for efficient PDE solving.
- It leverages error estimation, clustering, and regridding to dynamically adjust mesh resolution and optimize computational resources.
- The approach integrates subcycling and synchronization techniques for stable time-stepping and flux correction across grid interfaces.
Block-structured Adaptive Mesh Refinement (AMR) is a computational strategy that enables localized mesh refinement in regions of interest for the efficient solution of partial differential equations (PDEs) in high-performance scientific computing. The block-structured AMR approach, originally formulated by Berger and Colella, organizes the computational domain as a hierarchy of logically rectangular, non-overlapping “blocks,” “patches,” or “boxes,” wherein each block contains a regular grid of cells at a uniform resolution. This methodology underpins the design and performance of many leading multiphysics codes and AMR frameworks, including BoxLib, AMReX, Chombo, FLASH, Nyx, and Parthenon.
1. AMR Grid Hierarchy, Data Structures, and Refinement
Block-structured AMR decomposes the solution domain into a hierarchy of levels, indexed by (Zhang et al., 2016, Liu et al., 2024). Each level consists of a union of disjoint, axis-aligned rectangular blocks, with cells on level having uniform spacing , where is the integer refinement ratio (typically ). There is no strict one-to-one parent–child relationship; finer blocks may overlap with multiple coarser blocks, allowing aggregation of data into large boxes and reducing AMR overhead.
Each block's data is stored in a structure such as FArrayBox or terms equivalent in other frameworks, which contains the floating-point field data for the block as a contiguous array with optional ghost or halo cell layers for stencil-based updates (Zhang et al., 2016, Zhang et al., 2020). Multiple blocks on the same level are managed collectively in a container such as MultiFab (BoxLib/AMReX), or MeshBlockData (Parthenon), with a DistributionMapping to assign blocks to computational ranks.
Refinement proceeds via:
- Error estimation/tagging: Each block tags cells based on problem-specific error indicators (e.g., , , vorticity, user-specified regions) above a threshold to indicate the need for finer resolution.
- Clustering/regridding: Tagged cells are consolidated into rectangular blocks using clustering algorithms (e.g., Berger–Rigoutsos). Constraints on the maximum grid size per block (max_grid_size) are applied to optimize parallel decomposition and memory locality.
- Nesting: Proper nesting ensures that all fine cells are covered by at least one layer of coarser parent cells. Blocks can be dynamically refined or coarsened, with the hierarchy updated at intervals determined by the regridding frequency (Liu et al., 2024, Zeng, 2023).
2. Numerical Algorithms: Time Stepping, Subcycling, and Synchronization
In block-structured AMR, each level advances the PDE solution over its region using finite-difference or finite-volume discretizations. Time integration can use explicit schemes (e.g., Godunov–type, Runge–Kutta) or implicit methods for stiff terms. Two major strategies for temporal refinement are employed:
- Subcycling in time: Each level can use its own time step for stability (e.g., CFL-limited time steps), so that finer levels perform 0 substeps per coarse step (Liu et al., 2024, Almgren et al., 2013, Mignone et al., 2011). An explicit recursive advance pattern is used, often in a V-cycle or F-cycle structure.
- Non-subcycling (synchronous stepping): All levels use the same time step—this can simplify synchronization at the cost of increased computational work on coarse grids (Zeng, 2023).
After time-stepping, synchronization operations include:
- Averaging ("restricting"): Fine grid values are averaged down to update their parent coarse grid cells.
- Prolongation ("interpolating"): Coarse grid data is interpolated to populate new or ghost fine grid cells.
- Refluxing: Flux mismatch at coarse–fine interfaces is corrected to ensure conservation by incorporating fine-grid fluxes into