xref: /petsc/include/petscis.h (revision 821d827fc62fb75803bf259d7b170b804a4e043f)
1*821d827fSBarry Smith /* $Id: is.h,v 1.24 1996/04/16 04:48:03 bsmith Exp bsmith $ */
22eac72dbSBarry Smith 
32eac72dbSBarry Smith /*
4f26ada1bSBarry Smith       An index set is essentially a subset of the integers. They are used
5f26ada1bSBarry Smith    for defining scatters and gathers.
62eac72dbSBarry Smith */
72eac72dbSBarry Smith #if !defined(__IS_PACKAGE)
82eac72dbSBarry Smith #define __IS_PACKAGE
92eac72dbSBarry Smith #include "petsc.h"
102eac72dbSBarry Smith 
11*821d827fSBarry Smith typedef enum {IS_SEQ=0, IS_STRIDE_SEQ=1} ISType;
124b0e389bSBarry Smith 
139e25ed09SBarry Smith #define IS_COOKIE PETSC_COOKIE+2
14f0479e8cSBarry Smith 
152eac72dbSBarry Smith typedef struct _IS* IS;
162eac72dbSBarry Smith 
17de7da479SBarry Smith extern int   ISCreateSeq(MPI_Comm,int,int *,IS *);
18de7da479SBarry Smith extern int   ISCreateStrideSeq(MPI_Comm,int,int,int,IS *);
194b0e389bSBarry Smith 
204b0e389bSBarry Smith extern int   ISDestroy(IS);
214b0e389bSBarry Smith 
2220563c6bSBarry Smith extern int   ISStrideGetInfo(IS,int *,int*);
232eac72dbSBarry Smith 
24aabeff55SBarry Smith extern int   ISSetPermutation(IS);
2577c4ece6SBarry Smith extern int   ISPermutation(IS,PetscTruth*);
2608480c60SBarry Smith extern int   ISSetIdentity(IS);
2777c4ece6SBarry Smith extern int   ISIdentity(IS,PetscTruth*);
2808480c60SBarry Smith 
29aabeff55SBarry Smith extern int   ISGetIndices(IS,int **);
30aabeff55SBarry Smith extern int   ISRestoreIndices(IS,int **);
31aabeff55SBarry Smith extern int   ISGetSize(IS,int *);
32aabeff55SBarry Smith extern int   ISInvertPermutation(IS,IS*);
33aabeff55SBarry Smith extern int   ISView(IS,Viewer);
3477c4ece6SBarry Smith extern int   ISEqual(IS, IS, PetscTruth *);
350f453280SSatish Balay extern int   ISSort(IS);
3677c4ece6SBarry Smith extern int   ISSorted(IS, PetscTruth *);
372eac72dbSBarry Smith #endif
38