Recommendations for using the Ghost-fluid Method in Amroc
Dynamic Mesh Adaptivity
Some care must be taken when using the ghost-fluid method in combination with dynamic mesh adaptivity. A key component of the Berger-Collela idea is a spatial interpolation operation that is used to construct boundary condition values at internal coarse-fine interfaces, but also to intialize cells in newly refined areas. When the internal ghost-fluid boundary is not a-priori refined up to highest AMR level, the number of internal cells filled with GFM values (parameter BoundaryWidth) must be chosen with respect to the interpolation stencil. The following graphic depicts a situation in which the internal boundary (gray dots) gets dynamically refined one level more and only one internal GFM cell (blue-green) is used in combination with a linear interpolation operation:
Values from cells marked red, which are not guranteed to be physical meaningful, are used in the interpolation operation and corrupt the flow in the interior.
A user has the following options to circumvent this situation:
- Use the flagging criterion RefinePhi{} to ensure the refinement of all internal boundaries up to the highest level.
- Set BoundaryWidth for all internal boundaries not fully refined to a value greater or equal [Radius of interpolation stencil]+1. For the currently available interpolation operators in
vtf/amroc/clawpack/src/?d/operators
the following choices would be valid:
Simple injection from coarse grid cell | prolong?_copy.f | BoundaryWidth>=1 |
min-max preserving linear interpolation | prolong?.f | BoundaryWidth>=2 |
Locally conservative linear interpolation with min-max violations | prolong?_lin.f | BoundaryWidth>=2 |
Locally conservative quadratic interpolation with min-max violations | prolong?_quad.f | BoundaryWidth>=3 |
In principle, it would be possible to circumvent the above problem by using the interpolation/extrapolation operation that is used to construct the GFM values also for the AMR interpolation. This choice appears to be most consistent and automatically would eliminate all later ambiguities that might arise from interpolating from the GFM ghost cells. The Amroc infrastructure is flexible enough to implement this idea easily, but the very limited performance of the currently available C++ code in tools/numerical/interpolation
rules out this possibility. RalfDeiterding - 09 Aug 2005