ISRestorePointRange#

Destroys the traversal description

Synopsis#

#include "petscis.h"  
PetscErrorCode ISRestorePointRange(IS pointIS, PetscInt *pStart, PetscInt *pEnd, const PetscInt **points)

Not collective

Input Parameters#

  • pointIS - The IS object

  • pStart - The first index, from ISGetPointRange()

  • pEnd - One past the last index, from ISGetPointRange()

  • points - The indices, from ISGetPointRange()

Notes#

If the IS contains contiguous indices in an ISSTRIDE, then the indices are contained in [pStart, pEnd) and points = NULL. Otherwise, pStart = 0, pEnd = numIndices, and points is an array of the indices. This supports the following pattern

ISGetPointRange(is, &pStart, &pEnd, &points);
for (p = pStart; p < pEnd; ++p) {
const PetscInt point = points ? points[p] : p;
}
ISRestorePointRange(is, &pstart, &pEnd, &points);

See Also#

ISGetPointRange(), ISGetPointSubrange(), ISGetIndices(), ISCreateStride()

Level#

intermediate

Location#

src/vec/is/utils/isltog.c


Edit on GitLab

Index of all IS routines
Table of Contents for all manual pages
Index of all manual pages