PISM, A Parallel Ice Sheet Model  stable v2.0.4 committed by Constantine Khrulev on 2022-05-25 12:02:27 -0800

◆ range()

std::array< double, 2 > pism::IceModelVec::range ( ) const

Result: min <- min(v[j]), max <- max(v[j]).

PETSc manual correctly says "VecMin and VecMax are collective on Vec" but GlobalMax,GlobalMin are needed, when m_impl->ghosted==true, to get correct values because Vecs created with DACreateLocalVector() are of type VECSEQ and not VECMPI. See src/trypetsc/localVecMax.c.

Definition at line 193 of file iceModelVec.cc.

References pism::IceModelVec::Impl::ghosted, pism::GlobalMax(), pism::GlobalMin(), pism::IceModelVec::Impl::grid, m_impl, pism::max(), pism::min(), PISM_CHK, and vec().

Referenced by pism::IceModel::bootstrap_2d(), pism::ocean::PicoGeometry::compute_box_mask(), pism::IceModel::regrid(), and pism::ocean::relabel().