File: petscsectiontypes.h

package info (click to toggle)
petsc 3.24.3%2Bdfsg1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 524,208 kB
  • sloc: ansic: 762,913; cpp: 52,575; python: 39,566; f90: 17,688; javascript: 3,493; makefile: 3,217; sh: 1,512; xml: 619; objc: 445; java: 13; csh: 1
file content (52 lines) | stat: -rw-r--r-- 2,824 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#pragma once

/* MANSEC = Vec */
/* SUBMANSEC = PetscSection */

/*S
  PetscSection - Mapping from integers in a designated range to contiguous sets of integers.

  The range of a `PetscSection` is in the space of
  contiguous sets of integers. These ranges are frequently interpreted as domains of other array-like objects,
  especially other `PetscSection`, `Vec`s, and `IS`s. The domain is set with `PetscSectionSetChart()` and does not need to
  start at 0. For each point in the domain of a `PetscSection`, the output set is represented through an offset and a
  count, which are set using `PetscSectionSetOffset()` and `PetscSectionSetDof()` respectively. Lookup is typically using
  accessors or routines like `VecGetValuesSection()`.

  The `PetscSection` object and methods are intended to be used in the PETSc `Vec` and `Mat` implementations. The indices returned by the `PetscSection`
  are appropriate for the kind of `Vec` it is associated with. For example, if the vector being indexed is a local vector, we call the section a
  local section. If the section indexes a global vector, we call it a global section. For parallel vectors, like global vectors, we use negative
  indices to indicate dofs owned by other processes.

  Level: beginner

.seealso: [PetscSection](ch_petscsection), `PetscSectionCreate()`, `PetscSectionDestroy()`, `PetscSectionSym`
S*/
typedef struct _p_PetscSection *PetscSection;

/*S
  PetscSectionSym - Symmetries of the data referenced by a `PetscSection`.

  Often the order of data index by a `PetscSection` is meaningful, and describes additional structure, such as points on a
  line, grid, or lattice.  If the data is accessed from a different "orientation", then the image of the data under
  access then undergoes a symmetry transformation.  A `PetscSectionSym` specifies these symmetries.  The types of
  symmetries that can be specified are of the form R * P, where R is a diagonal matrix of scalars, and P is a permutation.

  Level: developer

.seealso: [PetscSection](ch_petscsection), `PetscSection`, `PetscSectionSymCreate()`, `PetscSectionSymDestroy()`, `PetscSectionSetSym()`, `PetscSectionGetSym()`, `PetscSectionSetFieldSym()`,
          `PetscSectionGetFieldSym()`, `PetscSectionGetSymPoints()`, `PetscSectionSymType`, `PetscSectionSymSetType()`, `PetscSectionSymGetType()`
S*/
typedef struct _p_PetscSectionSym *PetscSectionSym;

/*J
  PetscSectionSymType - String with the name of a `PetscSectionSym` type.

  Level: developer

  Note:
  `PetscSectionSym` has no default implementation, but is used by `DM` in `PetscSectionSymCreateLabel()`.

.seealso: [PetscSection](ch_petscsection), `PetscSectionSymSetType()`, `PetscSectionSymGetType()`, `PetscSectionSym`, `PetscSectionSymCreate()`, `PetscSectionSymRegister()`
J*/
typedef const char *PetscSectionSymType;