xref: /petsc/include/petscistypes.h (revision d5b43468fb8780a8feea140ccd6fa3e6a50411cc)
1 #ifndef PETSCISTYPES_H
2 #define PETSCISTYPES_H
3 
4 /* SUBMANSEC = IS */
5 
6 /*S
7      IS - Abstract PETSc object that used for efficient indexing
8 
9    Level: beginner
10 
11 .seealso: `ISCreateGeneral()`, `ISCreateBlock()`, `ISCreateStride()`, `ISGetIndices()`, `ISDestroy()`
12 S*/
13 typedef struct _p_IS *IS;
14 
15 /*S
16    ISLocalToGlobalMapping - mappings from an arbitrary
17       local ordering from 0 to n-1 to a global PETSc ordering
18       used by a vector or matrix.
19 
20    Level: intermediate
21 
22    Notes:
23    Mapping from local to global is scalable; but global
24    to local may not be if the range of global values represented locally
25    is very large.
26 
27    `ISLocalToGlobalMapping` is actually a private object; it is included
28    here for the inline function `ISLocalToGlobalMappingApply()` to allow it to be inlined since
29    it is used so often.
30 
31 .seealso: `ISLocalToGlobalMappingCreate()`, `ISLocalToGlobalMappingApply()`, `ISLocalToGlobalMappingDestroy()`
32 S*/
33 typedef struct _p_ISLocalToGlobalMapping *ISLocalToGlobalMapping;
34 
35 /*S
36      ISColoring - sets of IS's that define a coloring of something, such as a graph defined by a sparse matrix
37 
38    Level: intermediate
39 
40     Notes:
41     One should not access the *is records below directly because they may not yet
42     have been created. One should use `ISColoringGetIS()` to make sure they are
43     created when needed.
44 
45     When the coloring type is `IS_COLORING_LOCAL` the coloring is in the local ordering of the unknowns.
46     That is the matching the local (ghosted) vector; a local to global mapping must be applied to map
47     them to the global ordering.
48 
49     Developer Note:
50     This is not a `PetscObject`
51 
52 .seealso: `ISColoringCreate()`, `ISColoringGetIS()`, `ISColoringView()`
53 S*/
54 typedef struct _n_ISColoring *ISColoring;
55 
56 /*S
57      PetscLayout - defines layout of vectors and matrices across processes (which rows are owned by which processes)
58 
59    Level: developer
60 
61 .seealso: `PetscLayoutCreate()`, `PetscLayoutDestroy()`
62 S*/
63 typedef struct _n_PetscLayout *PetscLayout;
64 
65 #endif
66