Actual source code: dmforestimpl.h

petsc-3.10.5 2019-03-28
Report Typos and Errors
  1: #if !defined(_FORESTIMPL_H)
  2: #define _FORESTIMPL_H

  4:  #include <petscmat.h>
  5:  #include <petscdmforest.h>
  6:  #include <petscbt.h>
  7:  #include <petsc/private/dmimpl.h>

  9: typedef struct {
 10:   PetscInt                   refct;
 11:   void                       *data;
 12:   PetscErrorCode             (*clearadaptivityforest)(DM);
 13:   PetscErrorCode             (*getadaptivitysuccess)(DM,PetscBool*);
 14:   PetscErrorCode             (*transfervec)(DM,Vec,DM,Vec,PetscBool,PetscReal);
 15:   PetscErrorCode             (*createcellchart)(DM,PetscInt*,PetscInt*);
 16:   PetscErrorCode             (*createcellsf)(DM,PetscSF*);
 17:   PetscErrorCode             (*destroy)(DM);
 18:   PetscErrorCode             (*ftemplate)(DM,DM);
 19:   PetscBool                  setfromoptionscalled;
 20:   PetscBool                  computeAdaptSF;
 21:   PetscErrorCode             (*mapcoordinates)(DM,PetscInt,PetscInt,const PetscReal[],PetscReal[],void*);
 22:   void                       *mapcoordinatesctx;
 23:   DMForestTopology           topology;
 24:   DM                         base;
 25:   DM                         adapt;
 26:   DMAdaptFlag                adaptPurpose;
 27:   PetscInt                   adjDim;
 28:   PetscInt                   overlap;
 29:   PetscInt                   minRefinement;
 30:   PetscInt                   maxRefinement;
 31:   PetscInt                   initRefinement;
 32:   PetscInt                   cStart;
 33:   PetscInt                   cEnd;
 34:   PetscSF                    cellSF;
 35:   PetscSF                    preCoarseToFine;
 36:   PetscSF                    coarseToPreFine;
 37:   DMLabel                    adaptLabel;
 38:   DMForestAdaptivityStrategy adaptStrategy;
 39:   PetscInt                   gradeFactor;
 40:   PetscReal                  *cellWeights;
 41:   PetscCopyMode              cellWeightsCopyMode;
 42:   PetscReal                  weightsFactor;
 43:   PetscReal                  weightCapacity;
 44: } DM_Forest;

 46: PETSC_EXTERN PetscErrorCode DMCreate_Forest(DM);
 47: PETSC_EXTERN PetscErrorCode DMClone_Forest(DM,DM*);
 48: PETSC_EXTERN PetscErrorCode DMSetFromOptions_Forest(PetscOptionItems*,DM);

 50: #endif /* _FORESTIMPL_H */