Actual source code: ex4.c

petsc-3.4.2 2013-07-02
  2: static char help[] = "Tests ISToGeneral().\n\n";

  4: #include <petscis.h>

  8: int main(int argc,char **argv)
  9: {
 11:   PetscInt       step = 2;
 12:   IS             is;

 14:   PetscInitialize(&argc,&argv,(char*)0,help);

 16:   PetscOptionsGetInt(NULL,"-step",&step,NULL);
 17:   ISCreateStride(PETSC_COMM_SELF,10,0,step,&is);

 19:   ISToGeneral(is);

 21:   ISDestroy(&is);

 23:   PetscFinalize();
 24:   return 0;
 25: }