1a4963045SJacob Faibussowitsch #pragma once 2012bc364SMatthew G. Knepley 3012bc364SMatthew G. Knepley #include <petscdmplex.h> 4012bc364SMatthew G. Knepley #include <petscdmplextransformtypes.h> 5012bc364SMatthew G. Knepley 6012bc364SMatthew G. Knepley PETSC_EXTERN PetscClassId DMPLEXTRANSFORM_CLASSID; 7012bc364SMatthew G. Knepley 8c369401fSMatthew G. Knepley /*J 9c369401fSMatthew G. Knepley DMPlexTransformType - String with the name of a PETSc DMPlexTransform type 10c369401fSMatthew G. Knepley 11c369401fSMatthew G. Knepley Level: beginner 12c369401fSMatthew G. Knepley 13c369401fSMatthew G. Knepley Note: 14c369401fSMatthew G. Knepley [](plex_transform_table) for a table of available matrix types 15c369401fSMatthew G. Knepley 16c369401fSMatthew G. Knepley .seealso: [](plex_transform_table), [](ch_unstructured), `DMPlexTransformCreate()`, `DMPlexTransform`, `DMPlexTransformRegister()` 17c369401fSMatthew G. Knepley J*/ 18012bc364SMatthew G. Knepley typedef const char *DMPlexTransformType; 19012bc364SMatthew G. Knepley #define DMPLEXREFINEREGULAR "refine_regular" 20012bc364SMatthew G. Knepley #define DMPLEXREFINEALFELD "refine_alfeld" 21012bc364SMatthew G. Knepley #define DMPLEXREFINEPOWELLSABIN "refine_powell_sabin" 22012bc364SMatthew G. Knepley #define DMPLEXREFINEBOUNDARYLAYER "refine_boundary_layer" 23012bc364SMatthew G. Knepley #define DMPLEXREFINESBR "refine_sbr" 24012bc364SMatthew G. Knepley #define DMPLEXREFINETOBOX "refine_tobox" 25012bc364SMatthew G. Knepley #define DMPLEXREFINETOSIMPLEX "refine_tosimplex" 26a12d352dSMatthew G. Knepley #define DMPLEXREFINE1D "refine_1d" 27012bc364SMatthew G. Knepley #define DMPLEXEXTRUDE "extrude" 28eaabba2dSMatthew G. Knepley #define DMPLEXCOHESIVEEXTRUDE "cohesive_extrude" 29012bc364SMatthew G. Knepley #define DMPLEXTRANSFORMFILTER "transform_filter" 30012bc364SMatthew G. Knepley 31012bc364SMatthew G. Knepley PETSC_EXTERN PetscFunctionList DMPlexTransformList; 32012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCreate(MPI_Comm, DMPlexTransform *); 33012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetType(DMPlexTransform, DMPlexTransformType); 34012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetType(DMPlexTransform, DMPlexTransformType *); 35012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformRegister(const char[], PetscErrorCode (*)(DMPlexTransform)); 36012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformRegisterAll(void); 37012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformRegisterDestroy(void); 38012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetFromOptions(DMPlexTransform); 39012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetUp(DMPlexTransform); 40012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformView(DMPlexTransform, PetscViewer); 41012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformDestroy(DMPlexTransform *); 42012bc364SMatthew G. Knepley 43d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexGetTransformType(DM, DMPlexTransformType *); 44d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexSetTransformType(DM, DMPlexTransformType); 45d410b0cfSMatthew G. Knepley 46012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetDM(DMPlexTransform, DM *); 47012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetDM(DMPlexTransform, DM); 48d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetDimensions(DMPlexTransform, DM, DM); 499f4ada15SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetChart(DMPlexTransform, PetscInt *, PetscInt *); 509f4ada15SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetCellType(DMPlexTransform, PetscInt, DMPolytopeType *); 512827ebadSStefano Zampini PETSC_EXTERN PetscErrorCode DMPlexTransformGetCellTypeStratum(DMPlexTransform, DMPolytopeType, PetscInt *, PetscInt *); 529f4ada15SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetDepth(DMPlexTransform, PetscInt *); 539f4ada15SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetDepthStratum(DMPlexTransform, PetscInt, PetscInt *, PetscInt *); 54012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetActive(DMPlexTransform, DMLabel *); 55012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetActive(DMPlexTransform, DMLabel); 56*1cbae99dSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetTransformTypes(DMPlexTransform, DMLabel *); 57*1cbae99dSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetTransformTypes(DMPlexTransform, DMLabel); 58a4d5e7b4SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetMatchStrata(DMPlexTransform, PetscBool *); 59a4d5e7b4SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformSetMatchStrata(DMPlexTransform, PetscBool); 60a4d5e7b4SMatthew G. Knepley 61012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetTargetPoint(DMPlexTransform, DMPolytopeType, DMPolytopeType, PetscInt, PetscInt, PetscInt *); 62012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetSourcePoint(DMPlexTransform, PetscInt, DMPolytopeType *, DMPolytopeType *, PetscInt *, PetscInt *); 63012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCellTransform(DMPlexTransform, DMPolytopeType, PetscInt, PetscInt *, PetscInt *, DMPolytopeType *[], PetscInt *[], PetscInt *[], PetscInt *[]); 64012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCellTransformIdentity(DMPlexTransform, DMPolytopeType, PetscInt, PetscInt *, PetscInt *, DMPolytopeType *[], PetscInt *[], PetscInt *[], PetscInt *[]); 65012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetSubcellOrientationIdentity(DMPlexTransform, DMPolytopeType, PetscInt, PetscInt, DMPolytopeType, PetscInt, PetscInt, PetscInt *, PetscInt *); 66012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetSubcellOrientation(DMPlexTransform, DMPolytopeType, PetscInt, PetscInt, DMPolytopeType, PetscInt, PetscInt, PetscInt *, PetscInt *); 67d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformMapCoordinates(DMPlexTransform, DMPolytopeType, DMPolytopeType, PetscInt, PetscInt, PetscInt, PetscInt, const PetscScalar[], PetscScalar[]); 68012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCreateDiscLabels(DMPlexTransform, DM); 69012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformApply(DMPlexTransform, DM, DM *); 709f4ada15SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetConeSize(DMPlexTransform, PetscInt, PetscInt *); 71012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetCone(DMPlexTransform, PetscInt, const PetscInt *[], const PetscInt *[]); 72012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetConeOriented(DMPlexTransform, PetscInt, PetscInt, const PetscInt *[], const PetscInt *[]); 73012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformRestoreCone(DMPlexTransform, PetscInt, const PetscInt *[], const PetscInt *[]); 74012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetCellVertices(DMPlexTransform, DMPolytopeType, PetscInt *, PetscScalar *[]); 75012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformGetSubcellVertices(DMPlexTransform, DMPolytopeType, DMPolytopeType, PetscInt, PetscInt *[]); 769fe9e680SJoe Wallwork PETSC_EXTERN PetscErrorCode DMPlexTransformAdaptLabel(DM, Vec, DMLabel, DMLabel, DM *); 77012bc364SMatthew G. Knepley 78012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexRefineRegularGetAffineTransforms(DMPlexTransform, DMPolytopeType, PetscInt *, PetscReal *[], PetscReal *[], PetscReal *[]); 79012bc364SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexRefineRegularGetAffineFaceTransforms(DMPlexTransform, DMPolytopeType, PetscInt *, PetscReal *[], PetscReal *[], PetscReal *[], PetscReal *[]); 80012bc364SMatthew G. Knepley 81d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeGetLayers(DMPlexTransform, PetscInt *); 82d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetLayers(DMPlexTransform, PetscInt); 83d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeGetThickness(DMPlexTransform, PetscReal *); 84d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetThickness(DMPlexTransform, PetscReal); 85d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeGetTensor(DMPlexTransform, PetscBool *); 86d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetTensor(DMPlexTransform, PetscBool); 87d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeGetSymmetric(DMPlexTransform, PetscBool *); 88d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetSymmetric(DMPlexTransform, PetscBool); 891fcf445aSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeGetPeriodic(DMPlexTransform, PetscBool *); 901fcf445aSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetPeriodic(DMPlexTransform, PetscBool); 9170ca1fe2SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeGetNormal(DMPlexTransform, PetscReal[]); 92d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetNormal(DMPlexTransform, const PetscReal[]); 9370ca1fe2SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetNormalFunction(DMPlexTransform, PetscErrorCode (*)(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar[], void *)); 94d410b0cfSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformExtrudeSetThicknesses(DMPlexTransform, PetscInt, const PetscReal[]); 95d410b0cfSMatthew G. Knepley 96eaabba2dSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCohesiveExtrudeGetTensor(DMPlexTransform, PetscBool *); 97eaabba2dSMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCohesiveExtrudeSetTensor(DMPlexTransform, PetscBool); 982b987297SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCohesiveExtrudeGetWidth(DMPlexTransform, PetscReal *); 992b987297SMatthew G. Knepley PETSC_EXTERN PetscErrorCode DMPlexTransformCohesiveExtrudeSetWidth(DMPlexTransform, PetscReal); 100eaabba2dSMatthew G. Knepley 1010528010dSStefano Zampini PETSC_EXTERN PetscErrorCode DMPlexCreateEphemeral(DMPlexTransform, const char[], DM *); 102