DM Examples

DM objects are used to manage communication between the algebraic structures in PETSc (Vec and Mat) and mesh data structures in PDE-based (or other) simulations. See, for example, DMDACreate().

Beginner - Basic usage
DMADDAGetCorners DMDAInterpolationType DMMeshAssembleVectorComplete
DMADDAGetGhostCorners DMDALocalInfo DMMeshCreate
DMADDAGetMatrixNS DMDASetUniformCoordinates DMMeshCreateExodus
DMADDAMatSetValues DMDAStencilType DMMeshCreatePCICE
DMCartesianCreate DMDA_STENCIL_BOX DMMeshExodusGetInfo
DMCompositeGetNumberDM DMDA_STENCIL_STAR DMMeshGetDimension
DMCreate DMGetGlobalVector DMMeshGetLabelIds
DMCreateGlobalVector DMGetLocalVector DMMeshGetLabelSize
DMCreateLocalVector DMGetMatrix DMMeshGetMaximumDegree
DMDABoundaryType DMGlobalToLocalBegin DMMeshGetStratum
DMDACreate1d DMGlobalToLocalEnd DMMeshGetStratumSize
DMDACreate2d DMIGACreate DMMeshRestrictVector
DMDACreate3d DMIGAGetBasisData DMRestoreGlobalVector
DMDAElementType DMIGAGetLocalInfo DMRestoreLocalVector
DMDAGetBoundingBox DMIGAGetNumQuadraturePoints PetscViewerBinaryMatlabDestroy
DMDAGetCorners DMIGAGetPolynomialOrder PetscViewerBinaryMatlabOpen
DMDAGetGhostCorners DMLocalToGlobalBegin SAMappingSetSizes
DMDAGetInfo DMLocalToGlobalEnd SectionIntView
DMDAGetLocalBoundingBox DMMeshAssembleMatrix SectionRealView
DMDAGetLocalInfo DMMeshAssembleVector
Intermediate - Setting options for algorithms and data structures
BCSectionGetArray DMDASetFieldName DMMeshGetCone
BCSectionRealCreate DMDASetGhostedCoordinates DMMeshGetCoordinates
BCSectionRealGetArray DMDASetInterpolationType DMMeshGetElements
DMADDACreate DMDASetLocalAdicFunction DMMeshGetSectionInt
DMCompositeGetLocalISs DMDASetLocalAdicFunctioni DMMeshGetSectionReal
DMConvert DMDASetLocalAdicFunctionib DMMeshGetVertexSectionInt
DMDACoor2d DMDASetLocalAdicMFFunction DMMeshGetVertexSectionReal
DMDACoor3d DMDASetLocalAdicMFFunctioni DMMeshHasSectionInt
DMDAForEachPointBegin2d DMDASetLocalAdicMFFunctionib DMMeshHasSectionReal
DMDAForEachPointEnd2d DMDASetLocalFunction DMMeshRefine
DMDAFormFunctionLocal DMDASetLocalFunctioni DMMeshSetSectionInt
DMDAFormFunctionLocalGhost DMDASetLocalFunctionib DMMeshSetSectionReal
DMDAFormjacobianLocal DMDASetLocalJacobian DMMeshSetupSection
DMDAGetAO DMDASetNumProcs DMSetApplicationContext
DMDAGetCoordinateDA DMDASetOwnershipRanges DMSetInitialGuess
DMDAGetCoordinates DMDASetRefinementFactor DMSetType
DMDAGetElementType DMDASetSizes DMSetVecType
DMDAGetElements DMDASetStencilType MATHYPRESSTRUCT
DMDAGetFieldName DMDASetStencilWidth MATHYPRESTRUCT
DMDAGetGhostedCoordinates DMDAVecGetArray MatCreateSeqUSFFT
DMDAGetGlobalIndices DMDAVecGetArrayDOF MatSetDM
DMDAGetGlobalIndicesF90 DMDAVecRestoreArray MatSetValuesTopology
DMDAGetInterpolationType DMDAVecRestoreArrayDOF PetscViewerBinaryMatlabOutputBag
DMDAGetLocalFunction DMGetAggregates PetscViewerBinaryMatlabOutputVec
DMDAGetLocalJacobian DMGetApplicationContext PetscViewerBinaryMatlabOutputVecDA
DMDAGetNeighbors DMGetBlockSize SAMappingPullback
DMDAGetOwnershipRanges DMGetLocalToGlobalMapping SAMappingPushforward
DMDAGetReducedDA DMGetLocalToGlobalMappingBlock SectionGetArray
DMDAGetRefinementFactor DMGetType SectionIntDistribute
DMDALocalToLocalBegin DMIGAGetFieldName SectionIntRestrictClosure
DMDALocalToLocalEnd DMIGASetFieldName SectionIntSet
DMDANaturalToGlobalEnd DMIGAVecGetArray SectionIntUpdateClosure
DMDARestoreElements DMIGAVecRestoreArray SectionRealAXPY
DMDASetBoundaryType DMLoad SectionRealDistribute
DMDASetCoordinates DMMeshDistribute SectionRealNorm
DMDASetDim DMMeshGenerate SectionRealRestrictClosure
DMDASetDof DMMeshGetCellSectionInt SectionRealSet
DMDASetElementType DMMeshGetCellSectionReal SectionRealUpdateClosure
Advanced - Setting more advanced options and customization
DMCartesianGetMesh DMDANaturalToGlobalBegin SectionIntCreate
DMCartesianSetMesh DMDARestoreAdicArray SectionIntDestroy
DMCompositeAddArray DMDARestoreAdicMFArray SectionIntGetBundle
DMCompositeAddDM DMDARestoreArray SectionIntGetFiberDimension
DMCompositeCreate DMMeshCreateGlobalRealVector SectionIntGetFibration
DMCompositeGather DMMeshCreateGlobalScatter SectionIntGetSection
DMCompositeGetAccess DMMeshCreateMatrix SectionIntGetSize
DMCompositeGetEntries DMMeshCreateVector SectionIntRestrict
DMCompositeGetGlobalISs DMMeshGetGlobalScatter SectionIntSetBundle
DMCompositeGetISLocalToGlobalMappings DMMeshGetMesh SectionIntSetFiberDimension
DMCompositeGetLocalVectors DMMeshLoad SectionIntSetFiberDimensionField
DMCompositeRestoreAccess DMMeshSetMesh SectionIntSetSection
DMCompositeRestoreLocalVectors DMRegister SectionIntUpdate
DMCompositeScatter DMRegisterAll SectionIntZero
DMCompositeSetCoupling DMRegisterDestroy SectionRealAddSpace
DMDAComputeJacobian1 DMSetOptionsPrefix SectionRealAllocate
DMDAComputeJacobian1WithAdic DMSlicedCreate SectionRealClear
DMDACreate DMSlicedGetGlobalIndices SectionRealComplete
DMDACreatePF DMSlicedSetBlockFills SectionRealCreate
DMDAFormFunction DMSlicedSetGhosts SectionRealCreateLocalVector
DMDAFormFunction1 DMSlicedSetPreallocation SectionRealDestroy
DMDAFormFunctioni1 PCICERenumberBoundary SectionRealDuplicate
DMDAFormFunctionib1 SAMappingBin SectionRealGetBundle
DMDAGetAdicArray SAMappingBinLocal SectionRealGetFiberDimension
DMDAGetAdicMFArray SAMappingBinSplit SectionRealGetFibration
DMDAGetAdicMFArrayb SAMappingBinSplitLocal SectionRealGetSection
DMDAGetArray SAMappingMap SectionRealGetSize
DMDAGetProcessorSubset SAMappingMapLocal SectionRealRestrict
DMDAGetProcessorSubsets SAMappingMapSplit SectionRealSetBundle
DMDAGlobalToNaturalAllCreate SAMappingMapSplitLocal SectionRealSetFiberDimension
DMDAGlobalToNaturalBegin SAMappingRegister SectionRealSetFiberDimensionField
DMDAGlobalToNaturalEnd SAMappingSetUp SectionRealSetSection
DMDAMultiplyByJacobian1WithAD SectionIntAddSpace SectionRealToVec
DMDAMultiplyByJacobian1WithAdic SectionIntAllocate SectionRealUpdate
DMDAMultiplyByJacobian1WithAdifor SectionIntClear SectionRealZero
DMDANaturalAllToGlobalCreate SectionIntComplete
Developer - Interfaces intended primarily for library developers, not for typical applications programmers
ADDAHCiter DMDASetBlockFills DMMeshSetMaxDof
ADDAHCiterStartup DMDASetGetMatrix DMRefine
DMADDASetRefinement DMDestroy DMRefineHierarchy
DMClearGlobalVectors DMGetColoring DMSetFromOptions
DMCoarsen DMGetInjection DMSetMatrixPreallocateOnly
DMCoarsenHierarchy DMGetInterpolation DMSetUp
DMComputeFunction DMGetInterpolationScale DMView
DMComputeJacobian DMGetRefineLevel SAMappingFinalizePackage
DMComputeJacobianDefault DMHasFunction SAMappingInitializePackage
DMDACreateNaturalVector DMHasInitialGuess SAMappingRegisterAll
DMDAGetScatter DMHasJacobian SAMappingRegisterDestroy
No deprecated routines

Table of Contents