|
PISM, A Parallel Ice Sheet Model 2.3.0-79cae578d committed by Constantine Khrulev on 2026-03-22
|
◆ eikonal_equation()
Find an approximate solution of the Eikonal equation on a given domain. To specify the problem, the input field (mask) should be filled with
For example, to compute distances from the grounding line within ice shelves, fill generic ice shelf locations with zeros, set neighbors of the grounding line to 1, and the rest of the grid with -1 or some other negative number. Implementation details: The algorithm starts with mask defined above, then loops over the whole process-local domain one time. This loop is used to construct a queue containing cells which still need to be labeled, consisting initially only of cells neighboring the wave front. A second loop over the queue then updates each cell based on the minimum non-zero label of its neighbors and for each updated cell adds its non-updated neighbors to the queue. After the queue is empty the ghosts are updated and a check is made on the domain borders to check if a) still unlabeled cells now have labeled neighbors, or b) if the label of some neighbor has changed to a smaller value. If this is the case, the queue is once more filled with these new cells and the process repeats. Definition at line 886 of file PicoGeometry.cc. References pism::array::Scalar::as_int(), pism::GlobalMax(), pism::array::Array::grid(), pism::array::Array2D< T >::star(), and pism::array::Array::update_ghosts(). Referenced by pism::ocean::PicoGeometry::compute_distances_cf(), and pism::ocean::PicoGeometry::compute_distances_gl(). |