petsc-3.7.1 2016-05-15
Report Typos and Errors

ISRestoreIndices

Restores an index set to a usable state after a call to ISGetIndices().

Synopsis

#include "petscis.h" 
PetscErrorCode  ISRestoreIndices(IS is,const PetscInt *ptr[])
Not Collective Many br

Input Parameters

is - the index set Many br
ptr - the pointer obtained by ISGetIndices() Many br

Fortran Note

This routine is used differently from Fortran Many br
   IS          is
   integer     is_array(1)
   PetscOffset i_is
   int         ierr
      call ISGetIndices(is,is_array,i_is,ierr)

  Access first local entry in list
     value = is_array(i_is + 1)

     ...... other code
      call ISRestoreIndices(is,is_array,i_is,ierr)

See the Fortran chapter of the users manual and Many brpetsc/src/is/examples/[tutorials,tests] for details. Many br

Many br

Note

This routine zeros out ptr. This is to prevent accidental us of the array after it has been restored. Many br

See Also

ISGetIndices(), ISRestoreIndicesF90()

Level:intermediate
Location:
src/vec/is/is/interface/index.c
Index of all IS routines
Table of Contents for all manual pages
Index of all manual pages src/vec/is/is/examples/tutorials/ex1.c.html
src/vec/is/is/examples/tutorials/ex2.c.html
src/vec/is/is/examples/tutorials/ex3.c.html
src/vec/is/is/examples/tutorials/ex1f.F.html
src/vec/is/is/examples/tutorials/ex2f.F.html
src/snes/examples/tutorials/ex77.c.html
src/ts/examples/tutorials/ex11.c.html