Discretization (PetscFE, PetscDS, PetscSpace, PetscDualSpace, PetscFV) - Low-level Interface
These classes describe finite-element and finite-volume discretizations on a DMPlex:
- PetscSpace: the approximation space (polynomials of a given degree, tensor/sum spaces)
- PetscDualSpace: the dual space that defines the degrees of freedom (Lagrange nodes, ...)
- PetscFE: a finite element = space + dual space + quadrature; attached to a DM field
- PetscDS: the discrete system: residual/Jacobian point functions, boundary conditions and constants for all fields of a DM (see DMPlex for the Julia callback helpers)
- PetscFV and PetscLimiter: finite-volume discretizations and slope limiters
- PetscConvEst: convergence-rate estimation by mesh refinement
Basic Usage
using PETSc, MPI
MPI.Init()
petsclib = PETSc.getlib()
PETSc.initialize(petsclib)
dim, ncomp, simplex = 2, 1, LibPETSc.PETSC_TRUE
# P2 Lagrange element with a quadrature order chosen by PETSc (qorder = -1 -> PETSC_DETERMINE)
fe = LibPETSc.PetscFECreateLagrange(petsclib, MPI.COMM_SELF, dim, ncomp, simplex, 2, -1)
LibPETSc.PetscObjectSetName(petsclib, fe, "velocity")
nb = LibPETSc.PetscFEGetDimension(petsclib, fe) # basis functions per cell
sp = LibPETSc.PetscFEGetBasisSpace(petsclib, fe) # owned by the FE
deg = LibPETSc.PetscSpaceGetDegree(petsclib, sp) # (degree, maxdegree)
LibPETSc.PetscFEDestroy(petsclib, fe)
PETSc.finalize(petsclib)Elements are attached to a DM with DMSetField / DMCreateDS; the high-level helpers PETSc.fe_create_default, PETSc.set_field! and PETSc.create_ds! on the DMPlex page wrap this workflow.
Function Reference
PetscFE
PETSc.LibPETSc.PetscFECompositeGetMapping — Method
numSubelements::PetscInt,v0::Ptr{PetscReal},jac::Ptr{PetscReal},invjac::Ptr{PetscReal} = PetscFECompositeGetMapping(petsclib::PetscLibType, fem::PetscFE)Returns the mappings from the reference element to each subelement
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameters:
numSubelements- The number of sub elementsv0- The affine transformation for each element, an array of length dim * Nc. PassNULLto ignore.jac- The Jacobian for each element, an array of length dim^2 * Nc. PassNULLto ignore.invjac- The inverse of the Jacobian, an array of length dim^2 * Nc. PassNULLto ignore.
Level: intermediate
See also: PetscFE, PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFECompositeGetMapping
PETSc.LibPETSc.PetscFEComputeTabulation — Method
PetscFEComputeTabulation(petsclib::PetscLibType, fem::PetscFE, npoints::PetscInt, points::Vector{PetscReal}, K::PetscInt, T::PetscTabulation)Tabulates the basis functions, and perhaps derivatives, at the points provided.
Not Collective
Input Parameters:
fem- ThePetscFEobjectnpoints- The number of tabulation pointspoints- The tabulation point coordinatesK- The number of derivatives calculatedT- An existing tabulation object with enough allocated space, created withPetscFECreateTabulation()
Output Parameter:
T- The basis function values and derivatives at tabulation points
Level: intermediate
See also: PetscTabulation, PetscFEGetCellTabulation(), PetscTabulationDestroy(), PetscFECreateTabulation()
External Links
- PETSc Manual:
FE/PetscFEComputeTabulation
PETSc.LibPETSc.PetscFECopyQuadrature — Method
PetscFECopyQuadrature(petsclib::PetscLibType, sfe::PetscFE, tfe::PetscFE)Copy both volumetric and surface quadrature to a new PetscFE
Not Collective
Input Parameters:
sfe- ThePetscFEsource for the quadraturestfe- ThePetscFEtarget for the quadratures
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscQuadrature, PetscFECreate(), PetscFESetQuadrature(), PetscFESetFaceQuadrature()
External Links
- PETSc Manual:
FE/PetscFECopyQuadrature
PETSc.LibPETSc.PetscFECreate — Method
fem::PetscFE = PetscFECreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscFE object. The type can then be set with PetscFESetType().
Collective
Input Parameter:
comm- The communicator for thePetscFEobject
Output Parameter:
fem- ThePetscFEobject
Level: beginner
See also: PetscFE, PetscFEType, PetscFESetType(), PetscFECreateDefault(), PETSCFEGALERKIN
External Links
- PETSc Manual:
FE/PetscFECreate
PETSc.LibPETSc.PetscFECreateBrokenElement — Method
dgfe::PetscFE = PetscFECreateBrokenElement(petsclib::PetscLibType, cgfe::PetscFE)Create a discontinuous version of the input PetscFE
Collective
Input Parameters:
cgfe- The continuousPetscFEobject
Output Parameter:
dgfe- The discontinuousPetscFEobject
Level: advanced
See also: PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate(), PetscFECreateLagrange(), PetscFECreateLagrangeByCell(), PetscDualSpaceLagrangeSetContinuity()
External Links
- PETSc Manual:
FE/PetscFECreateBrokenElement
PETSc.LibPETSc.PetscFECreateByCell — Method
fem::PetscFE = PetscFECreateByCell(petsclib::PetscLibType, comm::MPI_Comm, dim::PetscInt, Nc::PetscInt, ct::DMPolytopeType, prefix::String, qorder::PetscInt)Create a PetscFE for basic FEM computation
Collective
Input Parameters:
comm- The MPI commdim- The spatial dimensionNc- The number of componentsct- The celltype of the reference cellprefix- The options prefix, orNULLqorder- The quadrature order orPETSC_DETERMINEto usePetscSpacepolynomial degree
Output Parameter:
fem- ThePetscFEobject
Level: beginner
See also: PetscFE, PetscFECreateDefault(), PetscFECreateLagrange(), PetscSpaceSetFromOptions(), PetscDualSpaceSetFromOptions(), PetscFESetFromOptions(), PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate(), DMPolytopeType
External Links
- PETSc Manual:
FE/PetscFECreateByCell
PETSc.LibPETSc.PetscFECreateCellGeometry — Method
cgeom::PetscFEGeom = PetscFECreateCellGeometry(petsclib::PetscLibType, fe::PetscFE, quad::PetscQuadrature)Populates the arrays in a PetscFEGeom for a single reference cell of a PetscFE.
Not Collective
Input Parameters:
fe- thePetscFEwhose dual-spaceDMprovides the reference cellquad- the quadrature at which to evaluate the geometry, orNULLto use thePetscFE's own quadrature
Output Parameter:
cgeom- thePetscFEGeompopulated with reference-cell coordinates, Jacobians, inverse Jacobians, and their determinants
Level: developer
See also: PetscFE, PetscFEGeom, PetscFEDestroyCellGeometry(), PetscFEGetQuadrature(), DMPlexComputeCellGeometryFEM()
External Links
- PETSc Manual:
FE/PetscFECreateCellGeometry
PETSc.LibPETSc.PetscFECreateDefault — Method
fem::PetscFE = PetscFECreateDefault(petsclib::PetscLibType, comm::MPI_Comm, dim::PetscInt, Nc::PetscInt, isSimplex::PetscBool, prefix::String, qorder::PetscInt)Create a PetscFE for basic FEM computation
Collective
Input Parameters:
comm- The MPI commdim- The spatial dimensionNc- The number of componentsisSimplex- Flag for simplex reference cell, otherwise its a tensor productprefix- The options prefix, orNULLqorder- The quadrature order orPETSC_DETERMINEto usePetscSpacepolynomial degree
Output Parameter:
fem- ThePetscFEobject
Level: beginner
See also: PetscFE, PetscFECreateLagrange(), PetscFECreateByCell(), PetscSpaceSetFromOptions(), PetscDualSpaceSetFromOptions(), PetscFESetFromOptions(), PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
FE/PetscFECreateDefault
PETSc.LibPETSc.PetscFECreateFromSpaces — Method
fem::PetscFE = PetscFECreateFromSpaces(petsclib::PetscLibType, P::PetscSpace, Q::PetscDualSpace, M_q::PetscQuadrature, fq::PetscQuadrature)Create a PetscFE from the basis and dual spaces
Collective
Input Parameters:
P- The basis spaceQ- The dual spaceq- The cell quadraturefq- The face quadrature
Output Parameter:
fem- ThePetscFEobject
Level: beginner
See also: PetscFE, PetscSpace, PetscDualSpace, PetscQuadrature, PetscFECreateLagrangeByCell(), PetscFECreateDefault(), PetscFECreateByCell(), PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
FE/PetscFECreateFromSpaces
PETSc.LibPETSc.PetscFECreateHeightTrace — Method
trFE::PetscFE = PetscFECreateHeightTrace(petsclib::PetscLibType, fe::PetscFE, height::PetscInt)Create the trace PetscFE for the first mesh point of the given height stratum.
Not Collective
Input Parameters:
fe- thePetscFEobjectheight- the height of the stratum whose first point is used to construct the trace element
Output Parameter:
trFE- the tracePetscFE, orNULLif the requested height stratum is empty
Level: developer
See also: PetscFE, PetscFECreatePointTrace(), PetscFEGetHeightSubspace(), DMPlexGetHeightStratum()
External Links
- PETSc Manual:
FE/PetscFECreateHeightTrace
PETSc.LibPETSc.PetscFECreateLagrange — Method
fem::PetscFE = PetscFECreateLagrange(petsclib::PetscLibType, comm::MPI_Comm, dim::PetscInt, Nc::PetscInt, isSimplex::PetscBool, k::PetscInt, qorder::PetscInt)Create a PetscFE for the basic Lagrange space of degree k
Collective
Input Parameters:
comm- The MPI commdim- The spatial dimensionNc- The number of componentsisSimplex- Flag for simplex reference cell, otherwise its a tensor productk- The degree of the spaceqorder- The quadrature order orPETSC_DETERMINEto usePetscSpacepolynomial degree
Output Parameter:
fem- ThePetscFEobject
Level: beginner
See also: PetscFE, PetscFECreateLagrangeByCell(), PetscFECreateDefault(), PetscFECreateByCell(), PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
FE/PetscFECreateLagrange
PETSc.LibPETSc.PetscFECreateLagrangeByCell — Method
fem::PetscFE = PetscFECreateLagrangeByCell(petsclib::PetscLibType, comm::MPI_Comm, dim::PetscInt, Nc::PetscInt, ct::DMPolytopeType, k::PetscInt, qorder::PetscInt)Create a PetscFE for the basic Lagrange space of degree k
Collective
Input Parameters:
comm- The MPI commdim- The spatial dimensionNc- The number of componentsct- The celltype of the reference cellk- The degree of the spaceqorder- The quadrature order orPETSC_DETERMINEto usePetscSpacepolynomial degree
Output Parameter:
fem- ThePetscFEobject
Level: beginner
See also: PetscFE, PetscFECreateLagrange(), PetscFECreateDefault(), PetscFECreateByCell(), PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate(), DMPolytopeType
External Links
- PETSc Manual:
FE/PetscFECreateLagrangeByCell
PETSc.LibPETSc.PetscFECreateTabulation — Method
T::PetscTabulation = PetscFECreateTabulation(petsclib::PetscLibType, fem::PetscFE, nrepl::PetscInt, npoints::PetscInt, points::Vector{PetscReal}, K::PetscInt)Creates a PetscTabulation object to hold the basis functions, and perhaps derivatives, at the points provided.
Not Collective
Input Parameters:
fem- ThePetscFEobjectnrepl- The number of replicasnpoints- The number of tabulation points in a replicapoints- The tabulation point coordinatesK- The number of derivatives calculated
Output Parameter:
T- ThePetscTabulationto hold the basis function values and derivatives at tabulation points
Level: intermediate
See also: PetscTabulation, PetscFEGetCellTabulation(), PetscTabulationDestroy(), PetscFEComputeTabulation()
External Links
- PETSc Manual:
FE/PetscFECreateTabulation
PETSc.LibPETSc.PetscFECreateVector — Method
vector_fe::PetscFE = PetscFECreateVector(petsclib::PetscLibType, scalar_fe::PetscFE, num_copies::PetscInt, interleave_basis::PetscBool, interleave_components::PetscBool)Create a vector-valued PetscFE from multiple copies of an underlying PetscFE.
Collective
Input Parameters:
scalar_fe- aPetscFEfinite elementnum_copies- a positive integerinterleave_basis- ifPETSC_TRUE, the firstnum_copiesbasis vectors
of the output finite element will be copies of the first basis vector of scalar_fe, and so on for the other basis vectors; otherwise all of the first-copy basis vectors will come first, followed by all of the second-copy, and so on.
interleave_components- ifPETSC_TRUE, the firstnum_copiescomponents
of the output finite element will be copies of the first component of scalar_fe, and so on for the other components; otherwise all of the first-copy components will come first, followed by all of the second-copy, and so on.
Output Parameter:
vector_fe- aPetscFEof typePETSCFEVECTORthat represent a discretization space withnum_copiescopies ofscalar_fe
Level: intermediate
See also: PetscFE, PetscFEType, PetscFECreate(), PetscFESetType(), PETSCFEBASIC, PETSCFEVECTOR
External Links
- PETSc Manual:
FE/PetscFECreateVector
PETSc.LibPETSc.PetscFEDestroy — Method
PetscFEDestroy(petsclib::PetscLibType, fem::Union{PetscFE, Ref{PetscFE}})Destroys a PetscFE object
Collective
Input Parameter:
fem- thePetscFEobject to destroy
Level: beginner
See also: PetscFE, PetscFEView()
External Links
- PETSc Manual:
FE/PetscFEDestroy
PETSc.LibPETSc.PetscFEDestroyCellGeometry — Method
PetscFEDestroyCellGeometry(petsclib::PetscLibType, fe::PetscFE, cgeom::Vector{PetscFEGeom})Free the arrays inside a PetscFEGeom allocated by PetscFECreateCellGeometry().
Not Collective
Input Parameters:
fe- thePetscFE(unused, kept for API symmetry withPetscFECreateCellGeometry())cgeom- thePetscFEGeomwhose owned arrays should be freed
Level: developer
See also: PetscFE, PetscFEGeom, PetscFECreateCellGeometry()
External Links
- PETSc Manual:
FE/PetscFEDestroyCellGeometry
PETSc.LibPETSc.PetscFEExpandFaceQuadrature — Method
efq::PetscQuadrature = PetscFEExpandFaceQuadrature(petsclib::PetscLibType, fe::PetscFE, fq::PetscQuadrature)Expand a face quadrature into a cell quadrature by mapping the face quadrature points and weights through each face of the cell reference geometry.
Not Collective
Input Parameters:
fe- thePetscFEobject whose cell geometry defines the facesfq- the face quadrature to expand
Output Parameter:
efq- the expanded quadrature covering all faces of the cell
Level: developer
See also: PetscFE, PetscQuadrature, PetscFECreateFaceQuadrature(), PetscFEGetQuadrature()
External Links
- PETSc Manual:
FE/PetscFEExpandFaceQuadrature
PETSc.LibPETSc.PetscFEFinalizePackage — Method
PetscFEFinalizePackage(petsclib::PetscLibType)This function finalizes everything in the PetscFE package. It is called from PetscFinalize().
Level: developer
See also: PetscInitialize()
External Links
- PETSc Manual:
DM/PetscFEFinalizePackage
PETSc.LibPETSc.PetscFEGeomComplete — Method
PetscFEGeomComplete(petsclib::PetscLibType, geom::Vector{PetscFEGeom})Calculate derived quantities from a base geometry specification
Input Parameter:
geom-PetscFEGeomobject
Level: intermediate
See also: PetscFEGeom, PetscFEGeomCreate()
External Links
- PETSc Manual:
FE/PetscFEGeomComplete
PETSc.LibPETSc.PetscFEGeomCreate — Method
geom::Ptr{PetscFEGeom} = PetscFEGeomCreate(petsclib::PetscLibType, quad::PetscQuadrature, numCells::PetscInt, dimEmbed::PetscInt, mode::PetscFEGeomMode)Create a PetscFEGeom object to manage geometry for a group of cells
Input Parameters:
quad- APetscQuadraturedetermining the tabulationnumCells- The number of cells in the groupdimEmbed- The coordinate dimensionmode- Type of geometry data to store
Output Parameter:
geom- ThePetscFEGeomobject, which is a struct not aPetscObject
Level: beginner
See also: PetscFEGeom, PetscQuadrature, PetscFEGeomDestroy(), PetscFEGeomComplete()
External Links
- PETSc Manual:
FE/PetscFEGeomCreate
PETSc.LibPETSc.PetscFEGeomDestroy — Method
PetscFEGeomDestroy(petsclib::PetscLibType, geom::PetscFEGeom)Destroy a PetscFEGeom object
Input Parameter:
geom-PetscFEGeomobject
Level: beginner
See also: PetscFEGeom, PetscFEGeomCreate()
External Links
- PETSc Manual:
FE/PetscFEGeomDestroy
PETSc.LibPETSc.PetscFEGeomGetCellPoint — Method
pgeom::PetscFEGeom = PetscFEGeomGetCellPoint(petsclib::PetscLibType, geom::Vector{PetscFEGeom}, c::PetscInt, p::PetscInt)Get the cell geometry for cell c at point p as a PetscFEGeom
Input Parameters:
geom-PetscFEGeomobjectc- The cellp- The point
Output Parameter:
pgeom- The cell geometry of cellcat pointp
Level: intermediate
See also: PetscFEGeom, PetscFEGeomMode, PetscFEGeomRestoreChunk(), PetscFEGeomCreate()
External Links
- PETSc Manual:
FE/PetscFEGeomGetCellPoint
PETSc.LibPETSc.PetscFEGeomGetChunk — Method
chunkGeom::Ptr{PetscFEGeom} = PetscFEGeomGetChunk(petsclib::PetscLibType, geom::Vector{PetscFEGeom}, cStart::PetscInt, cEnd::PetscInt)Get a chunk of cells in the group as a PetscFEGeom
Input Parameters:
geom-PetscFEGeomobjectcStart- The first cell in the chunkcEnd- The first cell not in the chunk
Output Parameter:
chunkGeom- an array of cells of lengthcEnd-cStart
Level: intermediate
See also: PetscFEGeom, PetscFEGeomRestoreChunk(), PetscFEGeomCreate()
External Links
- PETSc Manual:
FE/PetscFEGeomGetChunk
PETSc.LibPETSc.PetscFEGeomGetPoint — Method
pgeom::PetscFEGeom = PetscFEGeomGetPoint(petsclib::PetscLibType, geom::Vector{PetscFEGeom}, c::PetscInt, p::PetscInt, pcoords::Vector{PetscReal})Get the geometry for cell c at point p as a PetscFEGeom
Input Parameters:
geom-PetscFEGeomobjectc- The cellp- The pointpcoords- The reference coordinates of pointp, orNULL
Output Parameter:
pgeom- The geometry of cellcat pointp
Level: intermediate
See also: PetscFEGeom, PetscFEGeomRestoreChunk(), PetscFEGeomCreate()
External Links
- PETSc Manual:
FE/PetscFEGeomGetPoint
PETSc.LibPETSc.PetscFEGeomRestoreChunk — Method
PetscFEGeomRestoreChunk(petsclib::PetscLibType, geom::Vector{PetscFEGeom}, cStart::PetscInt, cEnd::PetscInt, chunkGeom::PetscFEGeom)Restore the chunk obtained with PetscFEGeomCreateChunk()
Input Parameters:
geom-PetscFEGeomobjectcStart- The first cell in the chunkcEnd- The first cell not in the chunkchunkGeom- The chunk of cells
Level: intermediate
See also: PetscFEGeom, PetscFEGeomGetChunk(), PetscFEGeomCreate()
External Links
- PETSc Manual:
FE/PetscFEGeomRestoreChunk
PETSc.LibPETSc.PetscFEGetBasisSpace — Method
sp::PetscSpace = PetscFEGetBasisSpace(petsclib::PetscLibType, fem::PetscFE)Returns the PetscSpace used for the approximation of the solution for the PetscFE
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
sp- ThePetscSpaceobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEGetBasisSpace
PETSc.LibPETSc.PetscFEGetCellTabulation — Method
T::PetscTabulation = PetscFEGetCellTabulation(petsclib::PetscLibType, fem::PetscFE, k::PetscInt)Returns the tabulation of the basis functions at the quadrature points on the reference cell
Not Collective
Input Parameters:
fem- ThePetscFEobjectk- The highest derivative we need to tabulate, very often 1
Output Parameter:
T- The basis function values and derivatives at quadrature points
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscTabulation, PetscFECreateTabulation(), PetscTabulationDestroy()
External Links
- PETSc Manual:
FE/PetscFEGetCellTabulation
PETSc.LibPETSc.PetscFEGetDimension — Method
dim::PetscInt = PetscFEGetDimension(petsclib::PetscLibType, fem::PetscFE)Get the dimension of the finite element space on a cell
Not Collective
Input Parameter:
fem- ThePetscFE
Output Parameter:
dim- The dimension
Level: intermediate
See also: PetscFE, PetscFECreate(), PetscSpaceGetDimension(), PetscDualSpaceGetDimension()
External Links
- PETSc Manual:
FE/PetscFEGetDimension
PETSc.LibPETSc.PetscFEGetDualSpace — Method
sp::PetscDualSpace = PetscFEGetDualSpace(petsclib::PetscLibType, fem::PetscFE)Returns the PetscDualSpace used to define the inner product for a PetscFE
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
sp- ThePetscDualSpaceobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEGetDualSpace
PETSc.LibPETSc.PetscFEGetFaceCentroidTabulation — Method
Tc::PetscTabulation = PetscFEGetFaceCentroidTabulation(petsclib::PetscLibType, fem::PetscFE)Returns the tabulation of the basis functions at the face centroid points
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
Tc- The basis function values at face centroid points
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscTabulation, PetscFEGetFaceTabulation(), PetscFEGetCellTabulation(), PetscFECreateTabulation(), PetscTabulationDestroy()
External Links
- PETSc Manual:
FE/PetscFEGetFaceCentroidTabulation
PETSc.LibPETSc.PetscFEGetFaceQuadrature — Method
q::PetscQuadrature = PetscFEGetFaceQuadrature(petsclib::PetscLibType, fem::PetscFE)Returns the PetscQuadrature used to calculate inner products on faces
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
q- ThePetscQuadratureobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscQuadrature, PetscFECreate(), PetscFESetQuadrature(), PetscFESetFaceQuadrature()
External Links
- PETSc Manual:
FE/PetscFEGetFaceQuadrature
PETSc.LibPETSc.PetscFEGetFaceTabulation — Method
Tf::PetscTabulation = PetscFEGetFaceTabulation(petsclib::PetscLibType, fem::PetscFE, k::PetscInt)Returns the tabulation of the basis functions at the face quadrature points for each face of the reference cell
Not Collective
Input Parameters:
fem- ThePetscFEobjectk- The highest derivative we need to tabulate, very often 1
Output Parameter:
Tf- The basis function values and derivatives at face quadrature points
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscTabulation, PetscFEGetCellTabulation(), PetscFECreateTabulation(), PetscTabulationDestroy()
External Links
- PETSc Manual:
FE/PetscFEGetFaceTabulation
PETSc.LibPETSc.PetscFEGetHeightSubspace — Method
subfe::PetscFE = PetscFEGetHeightSubspace(petsclib::PetscLibType, fe::PetscFE, height::PetscInt)Get the subspace of this space for a mesh point of a given height
Input Parameters:
fe- The finite element spaceheight- The height of theDMPLEXpoint
Output Parameter:
subfe- The subspace of thisPetscFEspace
Level: advanced
See also: PetscFECreateDefault()
External Links
- PETSc Manual:
FE/PetscFEGetHeightSubspace
PETSc.LibPETSc.PetscFEGetNumComponents — Method
comp::PetscInt = PetscFEGetNumComponents(petsclib::PetscLibType, fem::PetscFE)Returns the number of components in the element
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
comp- The number of field components
Level: intermediate
See also: PetscFE, PetscFECreate(), PetscFEGetSpatialDimension()
External Links
- PETSc Manual:
FE/PetscFEGetNumComponents
PETSc.LibPETSc.PetscFEGetNumDof — Method
numDof::Vector{PetscInt} = PetscFEGetNumDof(petsclib::PetscLibType, fem::PetscFE)Returns the number of dofs (dual basis vectors) associated to mesh points on the reference cell of a given dimension
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
numDof- Array of lengthdimwith the number of dofs in each dimension
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEGetNumDof
PETSc.LibPETSc.PetscFEGetQuadrature — Method
q::PetscQuadrature = PetscFEGetQuadrature(petsclib::PetscLibType, fem::PetscFE)Returns the PetscQuadrature used to calculate inner products
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
q- ThePetscQuadratureobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscQuadrature, PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEGetQuadrature
PETSc.LibPETSc.PetscFEGetSpatialDimension — Method
dim::PetscInt = PetscFEGetSpatialDimension(petsclib::PetscLibType, fem::PetscFE)Returns the spatial dimension of the element
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameter:
dim- The spatial dimension
Level: intermediate
See also: PetscFE, PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEGetSpatialDimension
PETSc.LibPETSc.PetscFEGetTileSizes — Method
blockSize::PetscInt,numBlocks::PetscInt,batchSize::PetscInt,numBatches::PetscInt = PetscFEGetTileSizes(petsclib::PetscLibType, fem::PetscFE)Returns the tile sizes for evaluation
Not Collective
Input Parameter:
fem- ThePetscFEobject
Output Parameters:
blockSize- The number of elements in a block, passNULLif not needednumBlocks- The number of blocks in a batch, passNULLif not neededbatchSize- The number of elements in a batch, passNULLif not needednumBatches- The number of batches in a chunk, passNULLif not needed
Level: intermediate
See also: PetscFE, PetscFECreate(), PetscFESetTileSizes()
External Links
- PETSc Manual:
FE/PetscFEGetTileSizes
PETSc.LibPETSc.PetscFEGetType — Method
name::String = PetscFEGetType(petsclib::PetscLibType, fem::PetscFE)Gets the PetscFEType (as a string) from the PetscFE object.
Not Collective
Input Parameter:
fem- ThePetscFE
Output Parameter:
name- ThePetscFETypename
Level: intermediate
See also: PetscFEType, PetscFE, PetscFESetType(), PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEGetType
PETSc.LibPETSc.PetscFEInitializePackage — Method
PetscFEInitializePackage(petsclib::PetscLibType)This function initializes everything in the PetscFE package. It is called from PetscDLLibraryRegister() when using dynamic libraries, and on the first call to PetscSpaceCreate() when using static libraries.
Level: developer
See also: PetscInitialize()
External Links
- PETSc Manual:
DM/PetscFEInitializePackage
PETSc.LibPETSc.PetscFEIntegrate — Method
PetscFEIntegrate(petsclib::PetscLibType, prob::PetscDS, field::PetscInt, Ne::PetscInt, cgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, probAux::PetscDS, coefficientsAux::Vector{PetscScalar}, integral::Vector{PetscScalar})Produce the integral for the given field for a chunk of elements by quadrature integration
Not Collective
Input Parameters:
prob- ThePetscDSspecifying the discretizations and continuum functionsfield- The field being integratedNe- The number of elements in the chunkcgeom- The cell geometry for each cell in the chunkcoefficients- The array of FEM basis coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elements
Output Parameter:
integral- the integral for this field
Level: intermediate
See also: PetscFE, PetscDS, PetscFEIntegrateResidual(), PetscFEIntegrateBd()
External Links
- PETSc Manual:
FE/PetscFEIntegrate
PETSc.LibPETSc.PetscFEIntegrateBd — Method
PetscFEIntegrateBd(petsclib::PetscLibType, prob::PetscDS, field::PetscInt, noname::Ptr{Cvoid})Produce the integral for the given field for a chunk of elements by quadrature integration
Not Collective
Input Parameters:
prob- ThePetscDSspecifying the discretizations and continuum functionsfield- The field being integratedobj_func- The function to be integratedNe- The number of elements in the chunkgeom- The face geometry for each face in the chunkcoefficients- The array of FEM basis coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elements
Output Parameter:
integral- the integral for this field
Level: intermediate
See also: PetscFE, PetscDS, PetscFEIntegrateResidual(), PetscFEIntegrate()
External Links
- PETSc Manual:
FE/PetscFEIntegrateBd
PETSc.LibPETSc.PetscFEIntegrateBdJacobian — Method
PetscFEIntegrateBdJacobian(petsclib::PetscLibType, ds::PetscDS, wf::PetscWeakForm, jtype::PetscFEJacobianType, key::PetscFormKey, Ne::PetscInt, fgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, coefficients_t::Vector{PetscScalar}, probAux::PetscDS, coefficientsAux::Vector{PetscScalar}, t::PetscReal, u_tshift::PetscReal, elemMat::Vector{PetscScalar})Produce the boundary element Jacobian for a chunk of elements by quadrature integration
Not Collective
Input Parameters:
ds- ThePetscDSspecifying the discretizations and continuum functionswf- The PetscWeakForm holding the pointwise functionsjtype- The type of matrix pointwise functions that should be usedkey- The (label+value, fieldI*Nf + fieldJ) being integratedNe- The number of elements in the chunkfgeom- The face geometry for each cell in the chunkcoefficients- The array of FEM basis coefficients for the elements for the Jacobian evaluation pointcoefficients_t- The array of FEM basis time derivative coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elementst- The timeu_tshift- A multiplier for the dF/du_t term (as opposed to the dF/du term)
Output Parameter:
elemMat- the element matrices for the Jacobian from each element
Level: intermediate
See also: PetscFEIntegrateJacobian(), PetscFEIntegrateResidual()
External Links
- PETSc Manual:
FE/PetscFEIntegrateBdJacobian
PETSc.LibPETSc.PetscFEIntegrateBdResidual — Method
PetscFEIntegrateBdResidual(petsclib::PetscLibType, ds::PetscDS, wf::PetscWeakForm, key::PetscFormKey, Ne::PetscInt, fgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, coefficients_t::Vector{PetscScalar}, probAux::PetscDS, coefficientsAux::Vector{PetscScalar}, t::PetscReal, elemVec::Vector{PetscScalar})Produce the element residual vector for a chunk of elements by quadrature integration over a boundary
Not Collective
Input Parameters:
ds- ThePetscDSspecifying the discretizations and continuum functionswf- The PetscWeakForm object holding the pointwise functionskey- The (label+value, field) being integratedNe- The number of elements in the chunkfgeom- The face geometry for each cell in the chunkcoefficients- The array of FEM basis coefficients for the elementscoefficients_t- The array of FEM basis time derivative coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elementst- The time
Output Parameter:
elemVec- the element residual vectors from each element
Level: intermediate
See also: PetscFEIntegrateResidual()
External Links
- PETSc Manual:
FE/PetscFEIntegrateBdResidual
PETSc.LibPETSc.PetscFEIntegrateHybridJacobian — Method
PetscFEIntegrateHybridJacobian(petsclib::PetscLibType, ds::PetscDS, dsIn::PetscDS, jtype::PetscFEJacobianType, key::PetscFormKey, s::PetscInt, Ne::PetscInt, fgeom::Vector{PetscFEGeom}, cgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, coefficients_t::Vector{PetscScalar}, probAux::PetscDS, coefficientsAux::Vector{PetscScalar}, t::PetscReal, u_tshift::PetscReal, elemMat::Vector{PetscScalar})Produce the boundary element Jacobian for a chunk of hybrid elements by quadrature integration
Not Collective
Input Parameters:
ds- ThePetscDSspecifying the discretizations and continuum functions for the outputdsIn- ThePetscDSspecifying the discretizations and continuum functions for the inputjtype- The type of matrix pointwise functions that should be usedkey- The (label+value, fieldI*Nf + fieldJ) being integrateds- The side of the cell being integrated, 0 for negative and 1 for positiveNe- The number of elements in the chunkfgeom- The face geometry for each cell in the chunkcgeom- The cell geometry for each neighbor cell in the chunkcoefficients- The array of FEM basis coefficients for the elements for the Jacobian evaluation pointcoefficients_t- The array of FEM basis time derivative coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elementst- The timeu_tshift- A multiplier for the dF/du_t term (as opposed to the dF/du term)
Output Parameter:
elemMat- the element matrices for the Jacobian from each element
Level: developer
See also: PetscFEIntegrateJacobian(), PetscFEIntegrateResidual()
External Links
- PETSc Manual:
FE/PetscFEIntegrateHybridJacobian
PETSc.LibPETSc.PetscFEIntegrateHybridResidual — Method
PetscFEIntegrateHybridResidual(petsclib::PetscLibType, ds::PetscDS, dsIn::PetscDS, key::PetscFormKey, s::PetscInt, Ne::PetscInt, fgeom::Vector{PetscFEGeom}, cgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, coefficients_t::Vector{PetscScalar}, probAux::PetscDS, coefficientsAux::Vector{PetscScalar}, t::PetscReal, elemVec::Vector{PetscScalar})Produce the element residual vector for a chunk of hybrid element faces by quadrature integration
Not Collective
Input Parameters:
ds- ThePetscDSspecifying the discretizations and continuum functionsdsIn- ThePetscDSspecifying the discretizations and continuum functions for inputkey- The (label+value, field) being integrateds- The side of the cell being integrated, 0 for negative and 1 for positiveNe- The number of elements in the chunkfgeom- The face geometry for each cell in the chunkcgeom- The cell geometry for each neighbor cell in the chunkcoefficients- The array of FEM basis coefficients for the elementscoefficients_t- The array of FEM basis time derivative coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elementst- The time
Output Parameter:
elemVec- the element residual vectors from each element
Level: developer
See also: PetscFEIntegrateResidual()
External Links
- PETSc Manual:
FE/PetscFEIntegrateHybridResidual
PETSc.LibPETSc.PetscFEIntegrateJacobian — Method
PetscFEIntegrateJacobian(petsclib::PetscLibType, rds::PetscDS, cds::PetscDS, jtype::PetscFEJacobianType, key::PetscFormKey, Ne::PetscInt, cgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, coefficients_t::Vector{PetscScalar}, dsAux::PetscDS, coefficientsAux::Vector{PetscScalar}, t::PetscReal, u_tshift::PetscReal, elemMat::Vector{PetscScalar})Produce the element Jacobian for a chunk of elements by quadrature integration
Not Collective
Input Parameters:
rds- ThePetscDSspecifying the row discretizations and continuum functionscds- ThePetscDSspecifying the column discretizationsjtype- The type of matrix pointwise functions that should be usedkey- The (label+value, fieldI*Nf + fieldJ) being integratedNe- The number of elements in the chunkcgeom- The cell geometry for each cell in the chunkcoefficients- The array of FEM basis coefficients for the elements for the Jacobian evaluation pointcoefficients_t- The array of FEM basis time derivative coefficients for the elementsdsAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elementst- The timeu_tshift- A multiplier for the dF/du_t term (as opposed to the dF/du term)
Output Parameter:
elemMat- the element matrices for the Jacobian from each element
Level: intermediate
See also: PetscFEIntegrateResidual()
External Links
- PETSc Manual:
FE/PetscFEIntegrateJacobian
PETSc.LibPETSc.PetscFEIntegrateResidual — Method
PetscFEIntegrateResidual(petsclib::PetscLibType, ds::PetscDS, key::PetscFormKey, Ne::PetscInt, cgeom::Vector{PetscFEGeom}, coefficients::Vector{PetscScalar}, coefficients_t::Vector{PetscScalar}, probAux::PetscDS, coefficientsAux::Vector{PetscScalar}, t::PetscReal, elemVec::Vector{PetscScalar})Produce the element residual vector for a chunk of elements by quadrature integration
Not Collective
Input Parameters:
ds- ThePetscDSspecifying the discretizations and continuum functionskey- The (label+value, field) being integratedNe- The number of elements in the chunkcgeom- The cell geometry for each cell in the chunkcoefficients- The array of FEM basis coefficients for the elementscoefficients_t- The array of FEM basis time derivative coefficients for the elementsprobAux- ThePetscDSspecifying the auxiliary discretizationscoefficientsAux- The array of FEM auxiliary basis coefficients for the elementst- The time
Output Parameter:
elemVec- the element residual vectors from each element
Level: intermediate
See also: PetscFEIntegrateBdResidual()
External Links
- PETSc Manual:
FE/PetscFEIntegrateResidual
PETSc.LibPETSc.PetscFELimitDegree — Method
newfe::PetscFE = PetscFELimitDegree(petsclib::PetscLibType, fe::PetscFE, minDegree::PetscInt, maxDegree::PetscInt)Copy a PetscFE but limit the degree to be in the given range
Collective
Input Parameters:
fe- ThePetscFEminDegree- The minimum degree, orPETSC_DETERMINEfor no limitmaxDegree- The maximum degree, orPETSC_DETERMINEfor no limit
Output Parameter:
newfe- ThePetscFEobject
Level: advanced
See also: PetscFECreateLagrange(), PetscFECreateDefault(), PetscFECreateByCell(), PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
FE/PetscFELimitDegree
PETSc.LibPETSc.PetscFEOpenCLGetRealType — Method
realType::PetscDataType = PetscFEOpenCLGetRealType(petsclib::PetscLibType, fem::PetscFE)Get the scalar type for running on the OpenCL accelerator
Input Parameter:
fem- ThePetscFE
Output Parameter:
realType- The scalar type
Level: developer
See also: PetscFE, PetscFEOpenCLSetRealType()
External Links
- PETSc Manual:
FE/PetscFEOpenCLGetRealType
PETSc.LibPETSc.PetscFEOpenCLSetRealType — Method
PetscFEOpenCLSetRealType(petsclib::PetscLibType, fem::PetscFE, realType::PetscDataType)Set the scalar type for running on the OpenCL accelerator
Input Parameters:
fem- ThePetscFErealType- The scalar type
Level: developer
See also: PetscFE, PetscFEOpenCLGetRealType()
External Links
- PETSc Manual:
FE/PetscFEOpenCLSetRealType
PETSc.LibPETSc.PetscFEPushforward — Method
PetscFEPushforward(petsclib::PetscLibType, fe::PetscFE, fegeom::Vector{PetscFEGeom}, Nv::PetscInt, vals::Vector{PetscScalar})Map the reference element function to real space
Input Parameters:
fe- ThePetscFEfegeom- The cell geometryNv- The number of function valuesvals- The function values
Output Parameter:
vals- The transformed function values
Level: advanced
See also: PetscFE, PetscFEGeom, PetscDualSpace, PetscDualSpacePushforward()
External Links
- PETSc Manual:
FE/PetscFEPushforward
PETSc.LibPETSc.PetscFEPushforwardGradient — Method
PetscFEPushforwardGradient(petsclib::PetscLibType, fe::PetscFE, fegeom::Vector{PetscFEGeom}, Nv::PetscInt, vals::Vector{PetscScalar})Map the reference element function gradient to real space
Input Parameters:
fe- ThePetscFEfegeom- The cell geometryNv- The number of function gradient valuesvals- The function gradient values
Output Parameter:
vals- The transformed function gradient values
Level: advanced
See also: PetscFE, PetscFEGeom, PetscDualSpace, PetscFEPushforward(), PetscDualSpacePushforwardGradient(), PetscDualSpacePushforward()
External Links
- PETSc Manual:
FE/PetscFEPushforwardGradient
PETSc.LibPETSc.PetscFEPushforwardHessian — Method
PetscFEPushforwardHessian(petsclib::PetscLibType, fe::PetscFE, fegeom::Vector{PetscFEGeom}, Nv::PetscInt, vals::Vector{PetscScalar})Map the reference element function Hessian to real space
Input Parameters:
fe- ThePetscFEfegeom- The cell geometryNv- The number of function Hessian valuesvals- The function Hessian values
Output Parameter:
vals- The transformed function Hessian values
Level: advanced
See also: PetscFE, PetscFEGeom, PetscDualSpace, PetscFEPushforward(), PetscDualSpacePushforwardHessian(), PetscDualSpacePushforward()
External Links
- PETSc Manual:
FE/PetscFEPushforwardHessian
PETSc.LibPETSc.PetscFERefine — Method
feRef::PetscFE = PetscFERefine(petsclib::PetscLibType, fe::PetscFE)Create a "refined" PetscFE object that refines the reference cell into smaller copies.
Collective
Input Parameter:
fe- The initialPetscFE
Output Parameter:
feRef- The refinedPetscFE
Level: advanced
See also: PetscFEType, PetscFECreate(), PetscFESetType()
External Links
- PETSc Manual:
FE/PetscFERefine
PETSc.LibPETSc.PetscFERegister — Method
PetscFERegister(petsclib::PetscLibType, sname::String, fnc::external)Adds a new PetscFEType
Not Collective, No Fortran Support
Input Parameters:
sname- The name of a new user-defined creation routinefunction- The creation routine
See also: PetscFE, PetscFEType, PetscFERegisterAll(), PetscFERegisterDestroy()
External Links
- PETSc Manual:
FE/PetscFERegister
PETSc.LibPETSc.PetscFESetBasisSpace — Method
PetscFESetBasisSpace(petsclib::PetscLibType, fem::PetscFE, sp::PetscSpace)Sets the PetscSpace used for the approximation of the solution
Not Collective
Input Parameters:
fem- ThePetscFEobjectsp- ThePetscSpaceobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscFECreate(), PetscFESetDualSpace()
External Links
- PETSc Manual:
FE/PetscFESetBasisSpace
PETSc.LibPETSc.PetscFESetDualSpace — Method
PetscFESetDualSpace(petsclib::PetscLibType, fem::PetscFE, sp::PetscDualSpace)Sets the PetscDualSpace used to define the inner product
Not Collective
Input Parameters:
fem- ThePetscFEobjectsp- ThePetscDualSpaceobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscFECreate(), PetscFESetBasisSpace()
External Links
- PETSc Manual:
FE/PetscFESetDualSpace
PETSc.LibPETSc.PetscFESetFaceQuadrature — Method
PetscFESetFaceQuadrature(petsclib::PetscLibType, fem::PetscFE, q::PetscQuadrature)Sets the PetscQuadrature used to calculate inner products on faces
Not Collective
Input Parameters:
fem- ThePetscFEobjectq- ThePetscQuadratureobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscQuadrature, PetscFECreate(), PetscFESetQuadrature()
External Links
- PETSc Manual:
FE/PetscFESetFaceQuadrature
PETSc.LibPETSc.PetscFESetFromOptions — Method
PetscFESetFromOptions(petsclib::PetscLibType, fem::PetscFE)sets parameters in a PetscFE from the options database
Collective
Input Parameter:
fem- thePetscFEobject to set options for
Options Database Keys:
-petscfe_num_blocks nblocks- the number of cell blocks to integrate concurrently-petscfe_num_batches nbatches- the number of cell batches to integrate serially
Level: intermediate
See also: PetscFE, PetscFEView()
External Links
- PETSc Manual:
FE/PetscFESetFromOptions
PETSc.LibPETSc.PetscFESetName — Method
PetscFESetName(petsclib::PetscLibType, fe::PetscFE, name::String)Names the PetscFE and its subobjects
Not Collective
Input Parameters:
fe- ThePetscFEname- The name
Level: intermediate
See also: PetscFECreate(), PetscSpaceCreate(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
FE/PetscFESetName
PETSc.LibPETSc.PetscFESetNumComponents — Method
PetscFESetNumComponents(petsclib::PetscLibType, fem::PetscFE, comp::PetscInt)Sets the number of field components in the element
Not Collective
Input Parameters:
fem- ThePetscFEobjectcomp- The number of field components
Level: intermediate
See also: PetscFE, PetscFECreate(), PetscFEGetSpatialDimension(), PetscFEGetNumComponents()
External Links
- PETSc Manual:
FE/PetscFESetNumComponents
PETSc.LibPETSc.PetscFESetQuadrature — Method
PetscFESetQuadrature(petsclib::PetscLibType, fem::PetscFE, q::PetscQuadrature)Sets the PetscQuadrature used to calculate inner products
Not Collective
Input Parameters:
fem- ThePetscFEobjectq- ThePetscQuadratureobject
Level: intermediate
See also: PetscFE, PetscSpace, PetscDualSpace, PetscQuadrature, PetscFECreate(), PetscFEGetFaceQuadrature()
External Links
- PETSc Manual:
FE/PetscFESetQuadrature
PETSc.LibPETSc.PetscFESetTileSizes — Method
PetscFESetTileSizes(petsclib::PetscLibType, fem::PetscFE, blockSize::PetscInt, numBlocks::PetscInt, batchSize::PetscInt, numBatches::PetscInt)Sets the tile sizes for evaluation
Not Collective
Input Parameters:
fem- ThePetscFEobjectblockSize- The number of elements in a blocknumBlocks- The number of blocks in a batchbatchSize- The number of elements in a batchnumBatches- The number of batches in a chunk
Level: intermediate
See also: PetscFE, PetscFECreate(), PetscFEGetTileSizes()
External Links
- PETSc Manual:
FE/PetscFESetTileSizes
PETSc.LibPETSc.PetscFESetType — Method
PetscFESetType(petsclib::PetscLibType, fem::PetscFE, name::String)Builds a particular PetscFE
Collective
Input Parameters:
fem- ThePetscFEobjectname- The kind of FEM space
Options Database Key:
-petscfe_type (basic|opencl|composite|vector)- Sets thePetscFEType
Level: intermediate
See also: PetscFEType, PetscFE, PetscFEGetType(), PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFESetType
PETSc.LibPETSc.PetscFESetUp — Method
PetscFESetUp(petsclib::PetscLibType, fem::PetscFE)Construct data structures for the PetscFE after the PetscFEType has been set
Collective
Input Parameter:
fem- thePetscFEobject to setup
Level: intermediate
See also: PetscFE, PetscFEView(), PetscFEDestroy()
External Links
- PETSc Manual:
FE/PetscFESetUp
PETSc.LibPETSc.PetscFEView — Method
PetscFEView(petsclib::PetscLibType, fem::PetscFE, viewer::PetscViewer)Views a PetscFE
Collective
Input Parameters:
fem- thePetscFEobject to viewviewer- the viewer
Level: beginner
See also: PetscFE, PetscViewer, PetscFEDestroy(), PetscFEViewFromOptions()
External Links
- PETSc Manual:
FE/PetscFEView
PETSc.LibPETSc.PetscFEViewFromOptions — Method
PetscFEViewFromOptions(petsclib::PetscLibType, A::PetscFE, obj, name::String)View a PetscFE based on values in the options database
Collective
Input Parameters:
A- thePetscFEobjectobj- Optional object that provides the options prefix, passNULLto use the options prefix ofAname- command line option name
Options Database Key:
-name [viewertype][:...]- option name and values. SeePetscObjectViewFromOptions()for the possible arguments
Level: intermediate
See also: PetscFE, PetscFEView(), PetscObjectViewFromOptions(), PetscFECreate()
External Links
- PETSc Manual:
FE/PetscFEViewFromOptions
PETSc.LibPETSc.PetscQuadratureComputePermutations — Method
Np::PetscInt,perm::Vector{IS} = PetscQuadratureComputePermutations(petsclib::PetscLibType, quad::PetscQuadrature)Compute permutations of quadrature points corresponding to domain orientations
Input Parameter:
quad- ThePetscQuadrature
Output Parameters:
Np- The number of domain orientationsperm- An array ofISpermutations, one for ech orientation,
Level: developer
See also: PetscQuadratureSetCellType(), PetscQuadrature
External Links
- PETSc Manual:
DT/PetscQuadratureComputePermutations
PETSc.LibPETSc.PetscQuadratureCreate — Method
q::PetscQuadrature = PetscQuadratureCreate(petsclib::PetscLibType, comm::MPI_Comm)Create a PetscQuadrature object
Collective
Input Parameter:
comm- The communicator for thePetscQuadratureobject
Output Parameter:
q- ThePetscQuadratureobject
Level: beginner
See also: PetscQuadrature, Petscquadraturedestroy(), PetscQuadratureGetData()
External Links
- PETSc Manual:
DT/PetscQuadratureCreate
PETSc.LibPETSc.PetscQuadratureDestroy — Method
PetscQuadratureDestroy(petsclib::PetscLibType, q::Union{PetscQuadrature, Ref{PetscQuadrature}})Destroys a PetscQuadrature object
Collective
Input Parameter:
q- ThePetscQuadratureobject
Level: beginner
See also: PetscQuadrature, PetscQuadratureCreate(), PetscQuadratureGetData()
External Links
- PETSc Manual:
DT/PetscQuadratureDestroy
PETSc.LibPETSc.PetscQuadratureDuplicate — Method
r::PetscQuadrature = PetscQuadratureDuplicate(petsclib::PetscLibType, q::PetscQuadrature)Create a deep copy of the PetscQuadrature object
Collective
Input Parameter:
q- ThePetscQuadratureobject
Output Parameter:
r- The newPetscQuadratureobject
Level: beginner
See also: PetscQuadrature, PetscQuadratureCreate(), PetscQuadratureDestroy(), PetscQuadratureGetData()
External Links
- PETSc Manual:
DT/PetscQuadratureDuplicate
PETSc.LibPETSc.PetscQuadratureEqual — Method
equal::PetscBool = PetscQuadratureEqual(petsclib::PetscLibType, A::PetscQuadrature, B::PetscQuadrature)determine whether two quadratures are equivalent
Input Parameters:
A- APetscQuadratureobjectB- AnotherPetscQuadratureobject
Output Parameter:
equal-PETSC_TRUEif the quadratures are the same
Level: intermediate
See also: PetscQuadrature, PetscQuadratureCreate()
External Links
- PETSc Manual:
DT/PetscQuadratureEqual
PETSc.LibPETSc.PetscQuadratureExpandComposite — Method
qref::PetscQuadrature = PetscQuadratureExpandComposite(petsclib::PetscLibType, q::PetscQuadrature, numSubelements::PetscInt, v0::Vector{PetscReal}, jac::Vector{PetscReal})Return a quadrature over the composite element, which has the original quadrature in each subelement
Not Collective; No Fortran Support
Input Parameters:
q- The originalPetscQuadraturenumSubelements- The number of subelements the original element is divided intov0- An array of the initial points for each subelementjac- An array of the Jacobian mappings from the reference to each subelement
Output Parameter:
qref- The dimension
Level: intermediate
See also: PetscQuadrature, PetscFECreate(), PetscSpaceGetDimension(), PetscDualSpaceGetDimension()
External Links
- PETSc Manual:
DT/PetscQuadratureExpandComposite
PETSc.LibPETSc.PetscQuadratureGetCellType — Method
ct::DMPolytopeType = PetscQuadratureGetCellType(petsclib::PetscLibType, q::PetscQuadrature)Return the cell type of the integration domain
Not Collective
Input Parameter:
q- ThePetscQuadratureobject
Output Parameter:
ct- The cell type of the integration domain
Level: intermediate
See also: PetscQuadrature, PetscQuadratureSetCellType(), PetscQuadratureGetData(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureGetCellType
PETSc.LibPETSc.PetscQuadratureGetData — Method
dim::PetscInt,Nc::PetscInt,npoints::PetscInt,points::Vector{PetscReal},weights::Vector{PetscReal} = PetscQuadratureGetData(petsclib::PetscLibType, q::PetscQuadrature)Returns the data defining the PetscQuadrature
Not Collective
Input Parameter:
q- ThePetscQuadratureobject
Output Parameters:
dim- The spatial dimensionNc- The number of componentsnpoints- The number of quadrature pointspoints- The coordinates of each quadrature pointweights- The weight of each quadrature point
Level: intermediate
See also: PetscQuadrature, PetscQuadratureCreate(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureGetData
PETSc.LibPETSc.PetscQuadratureGetNumComponents — Method
Nc::PetscInt = PetscQuadratureGetNumComponents(petsclib::PetscLibType, q::PetscQuadrature)Return the number of components for functions to be integrated
Not Collective
Input Parameter:
q- ThePetscQuadratureobject
Output Parameter:
Nc- The number of components
Level: intermediate
See also: PetscQuadrature, PetscQuadratureSetNumComponents(), PetscQuadratureGetData(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureGetNumComponents
PETSc.LibPETSc.PetscQuadratureGetOrder — Method
order::PetscInt = PetscQuadratureGetOrder(petsclib::PetscLibType, q::PetscQuadrature)Return the order of the method in the PetscQuadrature
Not Collective
Input Parameter:
q- ThePetscQuadratureobject
Output Parameter:
order- The order of the quadrature, i.e. the highest degree polynomial that is exactly integrated
Level: intermediate
See also: PetscQuadrature, PetscQuadratureSetOrder(), PetscQuadratureGetData(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureGetOrder
PETSc.LibPETSc.PetscQuadraturePushForward — Method
Jinvstarq::PetscQuadrature = PetscQuadraturePushForward(petsclib::PetscLibType, q::PetscQuadrature, imageDim::PetscInt, origin::Vector{PetscReal}, originImage::Vector{PetscReal}, J::Vector{PetscReal}, formDegree::PetscInt)Push forward a quadrature functional under an affine transformation.
Collective
Input Parameters:
q- the quadrature functionalimageDim- the dimension of the image of the transformationorigin- a point in the original spaceoriginImage- the image of the origin under the transformationJ- the Jacobian of the image: an [imageDim x dim] matrix in row major orderformDegree- transform the quadrature weights as k-forms of this form degree (if the number of components is a multiple of (dim chooseformDegree),
it is assumed that they represent multiple k-forms) [see PetscDTAltVPullback() for interpretation of formDegree]
Output Parameter:
Jinvstarq- a quadrature rule where each point is the image of a point in the original quadrature rule, and where the k-form weights have
been pulled-back by the pseudoinverse of J to the k-form weights in the image space.
Level: intermediate
See also: PetscQuadrature, PetscDTAltVPullback(), PetscDTAltVPullbackMatrix()
External Links
- PETSc Manual:
DT/PetscQuadraturePushForward
PETSc.LibPETSc.PetscQuadratureSetCellType — Method
PetscQuadratureSetCellType(petsclib::PetscLibType, q::PetscQuadrature, ct::DMPolytopeType)Set the cell type of the integration domain
Not Collective
Input Parameters:
q- ThePetscQuadratureobjectct- The cell type of the integration domain
Level: intermediate
See also: PetscQuadrature, PetscQuadratureGetCellType(), PetscQuadratureGetData(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureSetCellType
PETSc.LibPETSc.PetscQuadratureSetData — Method
PetscQuadratureSetData(petsclib::PetscLibType, q::PetscQuadrature, dim::PetscInt, Nc::PetscInt, npoints::PetscInt, points::Vector{PetscReal}, weights::Vector{PetscReal})Sets the data defining the quadrature
Not Collective
Input Parameters:
q- ThePetscQuadratureobjectdim- The spatial dimensionNc- The number of componentsnpoints- The number of quadrature pointspoints- The coordinates of each quadrature pointweights- The weight of each quadrature point
Level: intermediate
See also: PetscQuadrature, PetscQuadratureCreate(), PetscQuadratureGetData()
External Links
- PETSc Manual:
DT/PetscQuadratureSetData
PETSc.LibPETSc.PetscQuadratureSetNumComponents — Method
PetscQuadratureSetNumComponents(petsclib::PetscLibType, q::PetscQuadrature, Nc::PetscInt)Sets the number of components for functions to be integrated
Not Collective
Input Parameters:
q- ThePetscQuadratureobjectNc- The number of components
Level: intermediate
See also: PetscQuadrature, PetscQuadratureGetNumComponents(), PetscQuadratureGetData(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureSetNumComponents
PETSc.LibPETSc.PetscQuadratureSetOrder — Method
PetscQuadratureSetOrder(petsclib::PetscLibType, q::PetscQuadrature, order::PetscInt)Set the order of the method in the PetscQuadrature
Not Collective
Input Parameters:
q- ThePetscQuadratureobjectorder- The order of the quadrature, i.e. the highest degree polynomial that is exactly integrated
Level: intermediate
See also: PetscQuadrature, PetscQuadratureGetOrder(), PetscQuadratureGetData(), PetscQuadratureSetData()
External Links
- PETSc Manual:
DT/PetscQuadratureSetOrder
PETSc.LibPETSc.PetscQuadratureView — Method
PetscQuadratureView(petsclib::PetscLibType, quad::PetscQuadrature, viewer::PetscViewer)View a PetscQuadrature object
Collective
Input Parameters:
quad- ThePetscQuadratureobjectviewer- ThePetscViewerobject
Level: beginner
See also: PetscQuadrature, PetscViewer, PetscQuadratureCreate(), PetscQuadratureGetData()
External Links
- PETSc Manual:
DT/PetscQuadratureView
PETSc.LibPETSc.PetscTabulationDestroy — Method
PetscTabulationDestroy(petsclib::PetscLibType, T::Union{PetscTabulation, Ref{PetscTabulation}})Frees memory from the associated tabulation.
Not Collective
Input Parameter:
T- The tabulation
Level: intermediate
See also: PetscTabulation, PetscFECreateTabulation(), PetscFEGetCellTabulation()
External Links
- PETSc Manual:
FE/PetscTabulationDestroy
PETSc.LibPETSc.PetscWeakFormAddBdJacobian — Method
PetscWeakFormAddBdJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, g0::external, g1::external, g2::external, g3::external)Append boundary Jacobian pointwise functions g0, g1, g2, and g3 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedg0- Theg0boundary Jacobian pointwise function to append; aNULLis ignoredg1- Theg1boundary Jacobian pointwise function to append; aNULLis ignoredg2- Theg2boundary Jacobian pointwise function to append; aNULLis ignoredg3- Theg3boundary Jacobian pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobian(), PetscWeakFormGetBdJacobian(), PetscWeakFormAddJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormAddBdJacobian
PETSc.LibPETSc.PetscWeakFormAddBdJacobianPreconditioner — Method
PetscWeakFormAddBdJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, g0::external, g1::external, g2::external, g3::external)Append boundary Jacobian preconditioner pointwise functions g0, g1, g2, and g3 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedg0- Theg0boundary Jacobian preconditioner pointwise function to append; aNULLis ignoredg1- Theg1boundary Jacobian preconditioner pointwise function to append; aNULLis ignoredg2- Theg2boundary Jacobian preconditioner pointwise function to append; aNULLis ignoredg3- Theg3boundary Jacobian preconditioner pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobianPreconditioner(), PetscWeakFormGetBdJacobianPreconditioner(), PetscWeakFormAddBdJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormAddBdJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormAddBdResidual — Method
PetscWeakFormAddBdResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, f0::external, f1::external)Append boundary residual pointwise functions f0 and f1 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The field numberpart- The equation part, or 0 if unusedf0- Thef0boundary residual pointwise function to append; aNULLis ignoredf1- Thef1boundary residual pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdResidual(), PetscWeakFormGetBdResidual(), PetscWeakFormAddResidual()
External Links
- PETSc Manual:
DT/PetscWeakFormAddBdResidual
PETSc.LibPETSc.PetscWeakFormAddDynamicJacobian — Method
PetscWeakFormAddDynamicJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, g0::external, g1::external, g2::external, g3::external)Append dynamic Jacobian pointwise functions g0, g1, g2, and g3 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedg0- Theg0dynamic Jacobian pointwise function to append; aNULLis ignoredg1- Theg1dynamic Jacobian pointwise function to append; aNULLis ignoredg2- Theg2dynamic Jacobian pointwise function to append; aNULLis ignoredg3- Theg3dynamic Jacobian pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetDynamicJacobian(), PetscWeakFormGetDynamicJacobian(), PetscWeakFormAddJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormAddDynamicJacobian
PETSc.LibPETSc.PetscWeakFormAddJacobian — Method
PetscWeakFormAddJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, g0::external, g1::external, g2::external, g3::external)Append Jacobian pointwise functions g0, g1, g2, and g3 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedg0- Theg0Jacobian pointwise function to append; aNULLis ignoredg1- Theg1Jacobian pointwise function to append; aNULLis ignoredg2- Theg2Jacobian pointwise function to append; aNULLis ignoredg3- Theg3Jacobian pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobian(), PetscWeakFormGetJacobian(), PetscWeakFormSetIndexJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormAddJacobian
PETSc.LibPETSc.PetscWeakFormAddJacobianPreconditioner — Method
PetscWeakFormAddJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, g0::external, g1::external, g2::external, g3::external)Append Jacobian preconditioner pointwise functions g0, g1, g2, and g3 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedg0- Theg0Jacobian preconditioner pointwise function to append; aNULLis ignoredg1- Theg1Jacobian preconditioner pointwise function to append; aNULLis ignoredg2- Theg2Jacobian preconditioner pointwise function to append; aNULLis ignoredg3- Theg3Jacobian preconditioner pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobianPreconditioner(), PetscWeakFormGetJacobianPreconditioner(), PetscWeakFormAddJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormAddJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormAddObjective — Method
PetscWeakFormAddObjective(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, obj::external)Append an objective pointwise function to the list for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedobj- The objective pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetObjective(), PetscWeakFormGetObjective(), PetscWeakFormSetIndexObjective()
External Links
- PETSc Manual:
DT/PetscWeakFormAddObjective
PETSc.LibPETSc.PetscWeakFormAddResidual — Method
PetscWeakFormAddResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, f0::external, f1::external)Append residual pointwise functions f0 and f1 to the lists for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedf0- Thef0residual pointwise function to append; aNULLis ignoredf1- Thef1residual pointwise function to append; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetResidual(), PetscWeakFormGetResidual(), PetscWeakFormSetIndexResidual(), PetscWeakFormAddBdResidual()
External Links
- PETSc Manual:
DT/PetscWeakFormAddResidual
PETSc.LibPETSc.PetscWeakFormClear — Method
PetscWeakFormClear(petsclib::PetscLibType, wf::PetscWeakForm)Clear all functions from the PetscWeakForm
Not Collective
Input Parameter:
wf- The originalPetscWeakForm
Level: intermediate
See also: PetscWeakForm, PetscWeakFormCopy(), PetscWeakFormCreate(), PetscWeakFormDestroy()
External Links
- PETSc Manual:
DT/PetscWeakFormClear
PETSc.LibPETSc.PetscWeakFormClearIndex — Method
PetscWeakFormClearIndex(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, kind::PetscWeakFormKind, ind::PetscInt)Clear the pointwise function at a given index for the given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedkind- The kind of weak form, seePetscWeakFormKindind- The index of the function to clear in the function list for this key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormKind, PetscWeakFormCreate()
External Links
- PETSc Manual:
DT/PetscWeakFormClearIndex
PETSc.LibPETSc.PetscWeakFormCopy — Method
PetscWeakFormCopy(petsclib::PetscLibType, wf::PetscWeakForm, wfNew::PetscWeakForm)Copy the pointwise functions to another PetscWeakForm
Not Collective
Input Parameter:
wf- The originalPetscWeakForm
Output Parameter:
wfNew- The copy of thePetscWeakForm
Level: intermediate
See also: PetscWeakForm, PetscWeakFormCreate(), PetscWeakFormDestroy()
External Links
- PETSc Manual:
DT/PetscWeakFormCopy
PETSc.LibPETSc.PetscWeakFormCreate — Method
wf::PetscWeakForm = PetscWeakFormCreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscWeakForm object.
Collective
Input Parameter:
comm- The communicator for thePetscWeakFormobject
Output Parameter:
wf- ThePetscWeakFormobject
Level: beginner
See also: PetscWeakForm, PetscDS, PetscWeakFormDestroy()
External Links
- PETSc Manual:
DT/PetscWeakFormCreate
PETSc.LibPETSc.PetscWeakFormDestroy — Method
PetscWeakFormDestroy(petsclib::PetscLibType, wf::Union{PetscWeakForm, Ref{PetscWeakForm}})Destroys a PetscWeakForm object
Collective
Input Parameter:
wf- thePetscWeakFormobject to destroy
Level: developer
See also: PetscWeakForm, PetscWeakFormCreate(), PetscWeakFormView()
External Links
- PETSc Manual:
DT/PetscWeakFormDestroy
PETSc.LibPETSc.PetscWeakFormGetBdJacobian — Method
n0::PetscInt = PetscWeakFormGetBdJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of boundary Jacobian pointwise functions g0, g1, g2, and g3 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number ofg0boundary pointwise functions registered for this keyg0- The array ofg0boundary Jacobian pointwise functionsn1- The number ofg1boundary pointwise functions registered for this keyg1- The array ofg1boundary Jacobian pointwise functionsn2- The number ofg2boundary pointwise functions registered for this keyg2- The array ofg2boundary Jacobian pointwise functionsn3- The number ofg3boundary pointwise functions registered for this keyg3- The array ofg3boundary Jacobian pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobian(), PetscWeakFormAddBdJacobian(), PetscWeakFormHasBdJacobian(), PetscWeakFormGetJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormGetBdJacobian
PETSc.LibPETSc.PetscWeakFormGetBdJacobianPreconditioner — Method
n0::PetscInt = PetscWeakFormGetBdJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of boundary Jacobian preconditioner pointwise functions g0, g1, g2, and g3 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number ofg0boundary pointwise functions registered for this keyg0- The array ofg0boundary Jacobian preconditioner pointwise functionsn1- The number ofg1boundary pointwise functions registered for this keyg1- The array ofg1boundary Jacobian preconditioner pointwise functionsn2- The number ofg2boundary pointwise functions registered for this keyg2- The array ofg2boundary Jacobian preconditioner pointwise functionsn3- The number ofg3boundary pointwise functions registered for this keyg3- The array ofg3boundary Jacobian preconditioner pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobianPreconditioner(), PetscWeakFormAddBdJacobianPreconditioner(), PetscWeakFormHasBdJacobianPreconditioner(), PetscWeakFormGetBdJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormGetBdJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormGetBdResidual — Method
n0::PetscInt = PetscWeakFormGetBdResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of boundary residual pointwise functions f0 and f1 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number off0boundary pointwise functions registered for this keyf0- The array off0boundary residual pointwise functionsn1- The number off1boundary pointwise functions registered for this keyf1- The array off1boundary residual pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdResidual(), PetscWeakFormAddBdResidual(), PetscWeakFormGetResidual()
External Links
- PETSc Manual:
DT/PetscWeakFormGetBdResidual
PETSc.LibPETSc.PetscWeakFormGetDynamicJacobian — Method
n0::PetscInt = PetscWeakFormGetDynamicJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of dynamic Jacobian pointwise functions g0, g1, g2, and g3 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number ofg0pointwise functions registered for this keyg0- The array ofg0dynamic Jacobian pointwise functionsn1- The number ofg1pointwise functions registered for this keyg1- The array ofg1dynamic Jacobian pointwise functionsn2- The number ofg2pointwise functions registered for this keyg2- The array ofg2dynamic Jacobian pointwise functionsn3- The number ofg3pointwise functions registered for this keyg3- The array ofg3dynamic Jacobian pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetDynamicJacobian(), PetscWeakFormAddDynamicJacobian(), PetscWeakFormHasDynamicJacobian(), PetscWeakFormGetJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormGetDynamicJacobian
PETSc.LibPETSc.PetscWeakFormGetIndexObjective — Method
PetscWeakFormGetIndexObjective(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, ind::PetscInt, noname::Ptr{Cvoid})Retrieve a single objective pointwise function at the given index for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedind- The index into the list of objective pointwise functions for this key
Output Parameter:
obj- The objective pointwise function at positionind, orNULLif no function is registered for this key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetIndexObjective(), PetscWeakFormGetObjective(), PetscWeakFormSetObjective(), PetscWeakFormAddObjective()
External Links
- PETSc Manual:
DT/PetscWeakFormGetIndexObjective
PETSc.LibPETSc.PetscWeakFormGetJacobian — Method
n0::PetscInt = PetscWeakFormGetJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of Jacobian pointwise functions g0, g1, g2, and g3 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number ofg0pointwise functions registered for this keyg0- The array ofg0Jacobian pointwise functionsn1- The number ofg1pointwise functions registered for this keyg1- The array ofg1Jacobian pointwise functionsn2- The number ofg2pointwise functions registered for this keyg2- The array ofg2Jacobian pointwise functionsn3- The number ofg3pointwise functions registered for this keyg3- The array ofg3Jacobian pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobian(), PetscWeakFormAddJacobian(), PetscWeakFormHasJacobian(), PetscWeakFormGetJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscWeakFormGetJacobian
PETSc.LibPETSc.PetscWeakFormGetJacobianPreconditioner — Method
n0::PetscInt = PetscWeakFormGetJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of Jacobian preconditioner pointwise functions g0, g1, g2, and g3 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number ofg0pointwise functions registered for this keyg0- The array ofg0Jacobian preconditioner pointwise functionsn1- The number ofg1pointwise functions registered for this keyg1- The array ofg1Jacobian preconditioner pointwise functionsn2- The number ofg2pointwise functions registered for this keyg2- The array ofg2Jacobian preconditioner pointwise functionsn3- The number ofg3pointwise functions registered for this keyg3- The array ofg3Jacobian preconditioner pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobianPreconditioner(), PetscWeakFormAddJacobianPreconditioner(), PetscWeakFormHasJacobianPreconditioner(), PetscWeakFormGetJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormGetJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormGetNumFields — Method
Nf::PetscInt = PetscWeakFormGetNumFields(petsclib::PetscLibType, wf::PetscWeakForm)Returns the number of fields in a PetscWeakForm
Not Collective
Input Parameter:
wf- ThePetscWeakFormobject
Output Parameter:
Nf- The number of fields
Level: beginner
See also: PetscWeakForm, PetscWeakFormSetNumFields(), PetscWeakFormCreate()
External Links
- PETSc Manual:
DT/PetscWeakFormGetNumFields
PETSc.LibPETSc.PetscWeakFormGetObjective — Method
n::PetscInt = PetscWeakFormGetObjective(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the list of objective pointwise functions for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unused
Output Parameters:
n- The number of objective pointwise functions registered for this keyobj- The array of objective pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetObjective(), PetscWeakFormAddObjective(), PetscWeakFormSetIndexObjective(), PetscWeakFormGetIndexObjective()
External Links
- PETSc Manual:
DT/PetscWeakFormGetObjective
PETSc.LibPETSc.PetscWeakFormGetResidual — Method
n0::PetscInt = PetscWeakFormGetResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the lists of residual pointwise functions f0 and f1 for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unused
Output Parameters:
n0- The number off0pointwise functions registered for this keyf0- The array off0residual pointwise functionsn1- The number off1pointwise functions registered for this keyf1- The array off1residual pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetResidual(), PetscWeakFormAddResidual(), PetscWeakFormGetBdResidual()
External Links
- PETSc Manual:
DT/PetscWeakFormGetResidual
PETSc.LibPETSc.PetscWeakFormGetRiemannSolver — Method
n::PetscInt = PetscWeakFormGetRiemannSolver(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, noname::Ptr{Cvoid})Retrieve the list of Riemann solver pointwise functions for a given key from a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unused
Output Parameters:
n- The number of Riemann solver pointwise functions registered for this keyr- The array of Riemann solver pointwise functions
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetRiemannSolver(), PetscWeakFormSetIndexRiemannSolver()
External Links
- PETSc Manual:
DT/PetscWeakFormGetRiemannSolver
PETSc.LibPETSc.PetscWeakFormHasBdJacobian — Method
hasJac::PetscBool = PetscWeakFormHasBdJacobian(petsclib::PetscLibType, wf::PetscWeakForm)Returns whether the PetscWeakForm has any boundary Jacobian (g0, g1, g2, or g3) pointwise functions registered
Not Collective
Input Parameter:
wf- ThePetscWeakForm
Output Parameter:
hasJac-PETSC_TRUEif any boundary Jacobian pointwise functions are registered,PETSC_FALSEotherwise
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobian(), PetscWeakFormGetBdJacobian(), PetscWeakFormHasJacobian(), PetscWeakFormHasBdJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscWeakFormHasBdJacobian
PETSc.LibPETSc.PetscWeakFormHasBdJacobianPreconditioner — Method
hasJacPre::PetscBool = PetscWeakFormHasBdJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm)Returns whether the PetscWeakForm has any boundary Jacobian preconditioner (g0, g1, g2, or g3) pointwise functions registered
Not Collective
Input Parameter:
wf- ThePetscWeakForm
Output Parameter:
hasJacPre-PETSC_TRUEif any boundary Jacobian preconditioner pointwise functions are registered,PETSC_FALSEotherwise
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobianPreconditioner(), PetscWeakFormGetBdJacobianPreconditioner(), PetscWeakFormHasBdJacobian(), PetscWeakFormHasJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscWeakFormHasBdJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormHasDynamicJacobian — Method
hasDynJac::PetscBool = PetscWeakFormHasDynamicJacobian(petsclib::PetscLibType, wf::PetscWeakForm)Returns whether the PetscWeakForm has any dynamic Jacobian (g0, g1, g2, or g3) pointwise functions registered
Not Collective
Input Parameter:
wf- ThePetscWeakForm
Output Parameter:
hasDynJac-PETSC_TRUEif any dynamic Jacobian pointwise functions are registered,PETSC_FALSEotherwise
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetDynamicJacobian(), PetscWeakFormGetDynamicJacobian(), PetscWeakFormHasJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormHasDynamicJacobian
PETSc.LibPETSc.PetscWeakFormHasJacobian — Method
hasJac::PetscBool = PetscWeakFormHasJacobian(petsclib::PetscLibType, wf::PetscWeakForm)Returns whether the PetscWeakForm has any Jacobian (g0, g1, g2, or g3) pointwise functions registered
Not Collective
Input Parameter:
wf- ThePetscWeakForm
Output Parameter:
hasJac-PETSC_TRUEif any Jacobian pointwise functions are registered,PETSC_FALSEotherwise
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobian(), PetscWeakFormGetJacobian(), PetscWeakFormHasJacobianPreconditioner(), PetscWeakFormHasBdJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormHasJacobian
PETSc.LibPETSc.PetscWeakFormHasJacobianPreconditioner — Method
hasJacPre::PetscBool = PetscWeakFormHasJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm)Returns whether the PetscWeakForm has any Jacobian preconditioner (g0, g1, g2, or g3) pointwise functions registered
Not Collective
Input Parameter:
wf- ThePetscWeakForm
Output Parameter:
hasJacPre-PETSC_TRUEif any Jacobian preconditioner pointwise functions are registered,PETSC_FALSEotherwise
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobianPreconditioner(), PetscWeakFormGetJacobianPreconditioner(), PetscWeakFormHasJacobian(), PetscWeakFormHasBdJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscWeakFormHasJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormReplaceLabel — Method
PetscWeakFormReplaceLabel(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel)Change any key on a label of the same name to use the new label
Not Collective
Input Parameters:
wf- The originalPetscWeakFormlabel- The label to change keys for
Level: intermediate
See also: PetscWeakForm, DMLabel, PetscWeakFormRewriteKeys(), PetscWeakFormCreate(), PetscWeakFormDestroy()
External Links
- PETSc Manual:
DT/PetscWeakFormReplaceLabel
PETSc.LibPETSc.PetscWeakFormRewriteKeys — Method
PetscWeakFormRewriteKeys(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, Nv::PetscInt, values::Vector{PetscInt})Change any key on the given label to use the new set of label values
Not Collective
Input Parameters:
wf- The originalPetscWeakFormlabel- The label to change keys forNv- The number of new label valuesvalues- The set of new values to relabel keys with
Level: intermediate
See also: PetscWeakForm, DMLabel, PetscWeakFormReplaceLabel(), PetscWeakFormCreate(), PetscWeakFormDestroy()
External Links
- PETSc Manual:
DT/PetscWeakFormRewriteKeys
PETSc.LibPETSc.PetscWeakFormSetBdJacobian — Method
PetscWeakFormSetBdJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of boundary Jacobian pointwise functions g0, g1, g2, and g3 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedn0- The number ofg0boundary pointwise functions to setg0- The array ofg0boundary Jacobian pointwise functions, orNULLto clear the keyn1- The number ofg1boundary pointwise functions to setg1- The array ofg1boundary Jacobian pointwise functions, orNULLto clear the keyn2- The number ofg2boundary pointwise functions to setg2- The array ofg2boundary Jacobian pointwise functions, orNULLto clear the keyn3- The number ofg3boundary pointwise functions to setg3- The array ofg3boundary Jacobian pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetBdJacobian(), PetscWeakFormAddBdJacobian(), PetscWeakFormSetJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormSetBdJacobian
PETSc.LibPETSc.PetscWeakFormSetBdJacobianPreconditioner — Method
PetscWeakFormSetBdJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of boundary Jacobian preconditioner pointwise functions g0, g1, g2, and g3 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedn0- The number ofg0boundary pointwise functions to setg0- The array ofg0boundary Jacobian preconditioner pointwise functions, orNULLto clear the keyn1- The number ofg1boundary pointwise functions to setg1- The array ofg1boundary Jacobian preconditioner pointwise functions, orNULLto clear the keyn2- The number ofg2boundary pointwise functions to setg2- The array ofg2boundary Jacobian preconditioner pointwise functions, orNULLto clear the keyn3- The number ofg3boundary pointwise functions to setg3- The array ofg3boundary Jacobian preconditioner pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetBdJacobianPreconditioner(), PetscWeakFormAddBdJacobianPreconditioner(), PetscWeakFormSetBdJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormSetBdJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormSetBdResidual — Method
PetscWeakFormSetBdResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of boundary residual pointwise functions f0 and f1 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The field numberpart- The equation part, or 0 if unusedn0- The number off0boundary pointwise functions to setf0- The array off0boundary residual pointwise functions, orNULLto clear the keyn1- The number off1boundary pointwise functions to setf1- The array off1boundary residual pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetBdResidual(), PetscWeakFormAddBdResidual(), PetscWeakFormSetResidual()
External Links
- PETSc Manual:
DT/PetscWeakFormSetBdResidual
PETSc.LibPETSc.PetscWeakFormSetDynamicJacobian — Method
PetscWeakFormSetDynamicJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of dynamic Jacobian pointwise functions g0, g1, g2, and g3 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedn0- The number ofg0pointwise functions to setg0- The array ofg0dynamic Jacobian pointwise functions, orNULLto clear the keyn1- The number ofg1pointwise functions to setg1- The array ofg1dynamic Jacobian pointwise functions, orNULLto clear the keyn2- The number ofg2pointwise functions to setg2- The array ofg2dynamic Jacobian pointwise functions, orNULLto clear the keyn3- The number ofg3pointwise functions to setg3- The array ofg3dynamic Jacobian pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetDynamicJacobian(), PetscWeakFormAddDynamicJacobian(), PetscWeakFormSetJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormSetDynamicJacobian
PETSc.LibPETSc.PetscWeakFormSetIndexBdJacobian — Method
PetscWeakFormSetIndexBdJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, i0::PetscInt, g0::external, i1::PetscInt, g1::external, i2::PetscInt, g2::external, i3::PetscInt, g3::external)Set the boundary Jacobian pointwise functions g0, g1, g2, and g3 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedi0- The index at which to storeg0in theg0listg0- Theg0boundary Jacobian pointwise function; aNULLis ignoredi1- The index at which to storeg1in theg1listg1- Theg1boundary Jacobian pointwise function; aNULLis ignoredi2- The index at which to storeg2in theg2listg2- Theg2boundary Jacobian pointwise function; aNULLis ignoredi3- The index at which to storeg3in theg3listg3- Theg3boundary Jacobian pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobian(), PetscWeakFormAddBdJacobian(), PetscWeakFormGetBdJacobian(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexBdJacobian
PETSc.LibPETSc.PetscWeakFormSetIndexBdJacobianPreconditioner — Method
PetscWeakFormSetIndexBdJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, i0::PetscInt, g0::external, i1::PetscInt, g1::external, i2::PetscInt, g2::external, i3::PetscInt, g3::external)Set the boundary Jacobian preconditioner pointwise functions g0, g1, g2, and g3 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedi0- The index at which to storeg0in theg0listg0- Theg0boundary Jacobian preconditioner pointwise function; aNULLis ignoredi1- The index at which to storeg1in theg1listg1- Theg1boundary Jacobian preconditioner pointwise function; aNULLis ignoredi2- The index at which to storeg2in theg2listg2- Theg2boundary Jacobian preconditioner pointwise function; aNULLis ignoredi3- The index at which to storeg3in theg3listg3- Theg3boundary Jacobian preconditioner pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdJacobianPreconditioner(), PetscWeakFormAddBdJacobianPreconditioner(), PetscWeakFormGetBdJacobianPreconditioner(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexBdJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormSetIndexBdResidual — Method
PetscWeakFormSetIndexBdResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, i0::PetscInt, f0::external, i1::PetscInt, f1::external)Set the boundary residual pointwise functions f0 and f1 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the boundary region, orNULLfor the entire boundaryval- The label value selecting the boundary regionf- The field numberpart- The equation part, or 0 if unusedi0- The index at which to storef0in thef0listf0- Thef0boundary residual pointwise function; aNULLis ignoredi1- The index at which to storef1in thef1listf1- Thef1boundary residual pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetBdResidual(), PetscWeakFormAddBdResidual(), PetscWeakFormGetBdResidual(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexBdResidual
PETSc.LibPETSc.PetscWeakFormSetIndexDynamicJacobian — Method
PetscWeakFormSetIndexDynamicJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, i0::PetscInt, g0::external, i1::PetscInt, g1::external, i2::PetscInt, g2::external, i3::PetscInt, g3::external)Set the dynamic Jacobian pointwise functions g0, g1, g2, and g3 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedi0- The index at which to storeg0in theg0listg0- Theg0dynamic Jacobian pointwise function; aNULLis ignoredi1- The index at which to storeg1in theg1listg1- Theg1dynamic Jacobian pointwise function; aNULLis ignoredi2- The index at which to storeg2in theg2listg2- Theg2dynamic Jacobian pointwise function; aNULLis ignoredi3- The index at which to storeg3in theg3listg3- Theg3dynamic Jacobian pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetDynamicJacobian(), PetscWeakFormAddDynamicJacobian(), PetscWeakFormGetDynamicJacobian(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexDynamicJacobian
PETSc.LibPETSc.PetscWeakFormSetIndexJacobian — Method
PetscWeakFormSetIndexJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, i0::PetscInt, g0::external, i1::PetscInt, g1::external, i2::PetscInt, g2::external, i3::PetscInt, g3::external)Set the Jacobian pointwise functions g0, g1, g2, and g3 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedi0- The index at which to storeg0in theg0listg0- Theg0Jacobian pointwise function; aNULLis ignoredi1- The index at which to storeg1in theg1listg1- Theg1Jacobian pointwise function; aNULLis ignoredi2- The index at which to storeg2in theg2listg2- Theg2Jacobian pointwise function; aNULLis ignoredi3- The index at which to storeg3in theg3listg3- Theg3Jacobian pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobian(), PetscWeakFormAddJacobian(), PetscWeakFormGetJacobian(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexJacobian
PETSc.LibPETSc.PetscWeakFormSetIndexJacobianPreconditioner — Method
PetscWeakFormSetIndexJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, i0::PetscInt, g0::external, i1::PetscInt, g1::external, i2::PetscInt, g2::external, i3::PetscInt, g3::external)Set the Jacobian preconditioner pointwise functions g0, g1, g2, and g3 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedi0- The index at which to storeg0in theg0listg0- Theg0Jacobian preconditioner pointwise function; aNULLis ignoredi1- The index at which to storeg1in theg1listg1- Theg1Jacobian preconditioner pointwise function; aNULLis ignoredi2- The index at which to storeg2in theg2listg2- Theg2Jacobian preconditioner pointwise function; aNULLis ignoredi3- The index at which to storeg3in theg3listg3- Theg3Jacobian preconditioner pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetJacobianPreconditioner(), PetscWeakFormAddJacobianPreconditioner(), PetscWeakFormGetJacobianPreconditioner(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormSetIndexObjective — Method
PetscWeakFormSetIndexObjective(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, ind::PetscInt, obj::external)Set a single objective pointwise function at the given index for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedind- The index into the list of objective pointwise functions for this keyobj- The objective pointwise function to store at positionind; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetIndexObjective(), PetscWeakFormSetObjective(), PetscWeakFormAddObjective(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexObjective
PETSc.LibPETSc.PetscWeakFormSetIndexResidual — Method
PetscWeakFormSetIndexResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, i0::PetscInt, f0::external, i1::PetscInt, f1::external)Set the residual pointwise functions f0 and f1 at the given indices for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedi0- The index at which to storef0in thef0listf0- Thef0residual pointwise function; aNULLis ignoredi1- The index at which to storef1in thef1listf1- Thef1residual pointwise function; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetResidual(), PetscWeakFormAddResidual(), PetscWeakFormGetResidual(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexResidual
PETSc.LibPETSc.PetscWeakFormSetIndexRiemannSolver — Method
PetscWeakFormSetIndexRiemannSolver(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, i::PetscInt, r::external)Set a single Riemann solver pointwise function at the given index for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedi- The index into the list of Riemann solver pointwise functions for this keyr- The Riemann solver pointwise function to store at positioni; aNULLis ignored
Level: intermediate
See also: PetscWeakForm, PetscWeakFormSetRiemannSolver(), PetscWeakFormGetRiemannSolver(), PetscWeakFormClearIndex()
External Links
- PETSc Manual:
DT/PetscWeakFormSetIndexRiemannSolver
PETSc.LibPETSc.PetscWeakFormSetJacobian — Method
PetscWeakFormSetJacobian(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of Jacobian pointwise functions g0, g1, g2, and g3 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedn0- The number ofg0pointwise functions to setg0- The array ofg0Jacobian pointwise functions, orNULLto clear the keyn1- The number ofg1pointwise functions to setg1- The array ofg1Jacobian pointwise functions, orNULLto clear the keyn2- The number ofg2pointwise functions to setg2- The array ofg2Jacobian pointwise functions, orNULLto clear the keyn3- The number ofg3pointwise functions to setg3- The array ofg3Jacobian pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetJacobian(), PetscWeakFormAddJacobian(), PetscWeakFormSetIndexJacobian(), PetscWeakFormSetJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscWeakFormSetJacobian
PETSc.LibPETSc.PetscWeakFormSetJacobianPreconditioner — Method
PetscWeakFormSetJacobianPreconditioner(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, g::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of Jacobian preconditioner pointwise functions g0, g1, g2, and g3 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The test field numberg- The trial field numberpart- The equation part, or 0 if unusedn0- The number ofg0pointwise functions to setg0- The array ofg0Jacobian preconditioner pointwise functions, orNULLto clear the keyn1- The number ofg1pointwise functions to setg1- The array ofg1Jacobian preconditioner pointwise functions, orNULLto clear the keyn2- The number ofg2pointwise functions to setg2- The array ofg2Jacobian preconditioner pointwise functions, orNULLto clear the keyn3- The number ofg3pointwise functions to setg3- The array ofg3Jacobian preconditioner pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetJacobianPreconditioner(), PetscWeakFormAddJacobianPreconditioner(), PetscWeakFormSetJacobian()
External Links
- PETSc Manual:
DT/PetscWeakFormSetJacobianPreconditioner
PETSc.LibPETSc.PetscWeakFormSetNumFields — Method
PetscWeakFormSetNumFields(petsclib::PetscLibType, wf::PetscWeakForm, Nf::PetscInt)Sets the number of fields
Not Collective
Input Parameters:
wf- ThePetscWeakFormobjectNf- The number of fields
Level: beginner
See also: PetscWeakForm, PetscWeakFormGetNumFields(), PetscWeakFormCreate()
External Links
- PETSc Manual:
DT/PetscWeakFormSetNumFields
PETSc.LibPETSc.PetscWeakFormSetObjective — Method
PetscWeakFormSetObjective(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, n::PetscInt, noname::Ptr{Cvoid})Set the list of objective pointwise functions for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedn- The number of objective pointwise functions to setobj- The array of objective pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetObjective(), PetscWeakFormAddObjective(), PetscWeakFormSetIndexObjective()
External Links
- PETSc Manual:
DT/PetscWeakFormSetObjective
PETSc.LibPETSc.PetscWeakFormSetResidual — Method
PetscWeakFormSetResidual(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, n0::PetscInt, noname::Ptr{Cvoid})Set the lists of residual pointwise functions f0 and f1 for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedn0- The number off0pointwise functions to setf0- The array off0residual pointwise functions, orNULLto clear the keyn1- The number off1pointwise functions to setf1- The array off1residual pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetResidual(), PetscWeakFormAddResidual(), PetscWeakFormSetIndexResidual()
External Links
- PETSc Manual:
DT/PetscWeakFormSetResidual
PETSc.LibPETSc.PetscWeakFormSetRiemannSolver — Method
PetscWeakFormSetRiemannSolver(petsclib::PetscLibType, wf::PetscWeakForm, label::DMLabel, val::PetscInt, f::PetscInt, part::PetscInt, n::PetscInt, noname::Ptr{Cvoid})Set the list of Riemann solver pointwise functions for a given key in a PetscWeakForm
Not Collective
Input Parameters:
wf- ThePetscWeakFormlabel- The label selecting the mesh region, orNULLfor the entire domainval- The label value selecting the mesh regionf- The field numberpart- The equation part, or 0 if unusedn- The number of Riemann solver pointwise functions to setr- The array of Riemann solver pointwise functions, orNULLto clear the key
Level: intermediate
See also: PetscWeakForm, PetscWeakFormGetRiemannSolver(), PetscWeakFormSetIndexRiemannSolver()
External Links
- PETSc Manual:
DT/PetscWeakFormSetRiemannSolver
PETSc.LibPETSc.PetscWeakFormView — Method
PetscWeakFormView(petsclib::PetscLibType, wf::PetscWeakForm, v::PetscViewer)Views a PetscWeakForm
Collective
Input Parameters:
wf- thePetscWeakFormobject to viewv- the viewer
Level: developer
See also: PetscViewer, PetscWeakForm, PetscWeakFormDestroy(), PetscWeakFormCreate()
External Links
- PETSc Manual:
DT/PetscWeakFormView
PetscDS
PETSc.LibPETSc.PetscDSAddBoundary — Method
bd::PetscInt = PetscDSAddBoundary(petsclib::PetscLibType, ds::PetscDS, type::DMBoundaryConditionType, name::String, label::DMLabel, Nv::PetscInt, values::Vector{PetscInt}, field::PetscInt, Nc::PetscInt, comps::Vector{PetscInt}, bcFunc::Ptr{Cvoid}, bcFunc_t::Ptr{Cvoid}, ctx::Ptr{Cvoid})Add a boundary condition to the model.
Collective
Input Parameters:
ds- ThePetscDSobjecttype- The type of condition, e.g.DM_BC_ESSENTIAL/DM_BC_ESSENTIAL_FIELD(Dirichlet), orDM_BC_NATURAL(Neumann)name- The name for the boundary conditionlabel- The label defining constrained pointsNv- The number ofDMLabelvalues for constrained pointsvalues- An array of label values for constrained pointsfield- The field to constrainNc- The number of constrained field components (0 will constrain all fields)comps- An array of constrained component numbersbcFunc- A pointwise function giving boundary valuesbcFunc_t- A pointwise function giving the time derivative of the boundary values, orNULLctx- An optional application context forbcFunc
Output Parameter:
bd- The boundary number
Options Database Keys:
-bc_NAME values- comma separated list of values for the boundary condition NAME-bc_NAME_comp comps- comma separated list of components for the boundary condition NAME
Level: developer
See also: PetscDS, PetscWeakForm, DMLabel, DMBoundaryConditionType, PetscDSAddBoundaryByName(), PetscDSGetBoundary(), PetscDSSetResidual(), PetscDSSetBdResidual()
External Links
- PETSc Manual:
DT/PetscDSAddBoundary
PETSc.LibPETSc.PetscDSAddBoundaryByName — Method
bd::PetscInt = PetscDSAddBoundaryByName(petsclib::PetscLibType, ds::PetscDS, type::DMBoundaryConditionType, name::String, lname::String, Nv::PetscInt, values::Vector{PetscInt}, field::PetscInt, Nc::PetscInt, comps::Vector{PetscInt}, bcFunc::Ptr{Cvoid}, bcFunc_t::Ptr{Cvoid}, ctx::Ptr{Cvoid})Add a boundary condition to the model.
Collective
Input Parameters:
ds- ThePetscDSobjecttype- The type of condition, e.g.DM_BC_ESSENTIAL/DM_BC_ESSENTIAL_FIELD(Dirichlet), orDM_BC_NATURAL(Neumann)name- The boundary condition namelname- The name of the label defining constrained pointsNv- The number ofDMLabelvalues for constrained pointsvalues- An array of label values for constrained pointsfield- The field to constrainNc- The number of constrained field components (0 will constrain all fields)comps- An array of constrained component numbersbcFunc- A pointwise function giving boundary valuesbcFunc_t- A pointwise function giving the time derivative of the boundary values, orNULLctx- An optional application context forbcFunc
Output Parameter:
bd- The boundary number
Options Database Keys:
-bc_NAME values- comma separated list of values for the boundary condition NAME-bc_NAME_comp comps- comma separated list of components for the boundary condition NAME
Calling Sequence of bcFunc and bcFunc_t: If the type is DM_BC_ESSENTIAL $void bcFunc(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt Nc, PetscScalar bcval[])$ If the type is DM_BC_ESSENTIAL_FIELD or other FIELD value, `` void bcFunc(PetscInt dim, PetscInt Nf, PetscInt NfAux, const PetscInt uOff[], const PetscInt uOffx[], const PetscScalar u[], const PetscScalar ut[], const PetscScalar ux[], const PetscInt aOff[], const PetscInt aOffx[], const PetscScalar a[], const PetscScalar at[], const PetscScalar a_x[], PetscReal time, const PetscReal x[], PetscScalar bcval[]) ``
dim- the coordinate dimensionNf- the number of fieldsuOff- the offset intou[] andu_t[] for each fielduOff_x- the offset intou_x[] for each fieldu- each field evaluated at the current pointu_t- the time derivative of each field evaluated at the current pointu_x- the gradient of each field evaluated at the current pointaOff- the offset intoa[] anda_t[] for each auxiliary fieldaOff_x- the offset intoa_x[] for each auxiliary fielda- each auxiliary field evaluated at the current pointa_t- the time derivative of each auxiliary field evaluated at the current pointa_x- the gradient of auxiliary each field evaluated at the current pointt- current timex- coordinates of the current pointnumConstants- number of constant parametersconstants- constant parametersbcval- output values at the current point
Level: developer
See also: PetscDS, PetscWeakForm, DMLabel, DMBoundaryConditionType, PetscDSAddBoundary(), PetscDSGetBoundary(), PetscDSSetResidual(), PetscDSSetBdResidual()
External Links
- PETSc Manual:
DT/PetscDSAddBoundaryByName
PETSc.LibPETSc.PetscDSAddDiscretization — Method
PetscDSAddDiscretization(petsclib::PetscLibType, prob::PetscDS, disc)Adds a discretization object
Not Collective
Input Parameters:
prob- ThePetscDSobjectdisc- The discretization object, this can be aPetscFEorPetscFV
Level: beginner
See also: PetscWeakForm, PetscFE, PetscFV, PetscDSGetDiscretization(), PetscDSSetDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSAddDiscretization
PETSc.LibPETSc.PetscDSCopy — Method
PetscDSCopy(petsclib::PetscLibType, ds::PetscDS, minDegree::PetscInt, maxDegree::PetscInt, dmNew::AbstractPetscDM, dsNew::PetscDS)Copy the contents of a PetscDS into another PetscDS on a new DM.
Collective
Input Parameters:
ds- the sourcePetscDSminDegree- the minimum polynomial degree to consider when selecting discretizations, orPETSC_DETERMINEmaxDegree- the maximum polynomial degree to consider when selecting discretizations, orPETSC_DETERMINEdmNew- the targetDMused to resolve boundary condition labels for the copied boundaries
Output Parameter:
dsNew- the destinationPetscDS
Level: developer
See also: PetscDS, PetscDSCopyEquations(), PetscDSCopyConstants(), PetscDSCopyExactSolutions(), PetscDSCopyBounds(), PetscDSCopyBoundary()
External Links
- PETSc Manual:
DT/PetscDSCopy
PETSc.LibPETSc.PetscDSCopyBoundary — Method
PetscDSCopyBoundary(petsclib::PetscLibType, ds::PetscDS, numFields::PetscInt, fields::Vector{PetscInt}, newds::PetscDS)Copy all boundary condition objects to the new PetscDS
Not Collective
Input Parameters:
ds- The sourcePetscDSobjectnumFields- The number of selected fields, orPETSC_DEFAULTfor all fieldsfields- The selected fields, orNULLfor all fields
Output Parameter:
newds- The targetPetscDS, now with a copy of the boundary conditions
Level: intermediate
See also: PetscDS, DMBoundary, PetscDSCopyEquations(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSCopyBoundary
PETSc.LibPETSc.PetscDSCopyBounds — Method
PetscDSCopyBounds(petsclib::PetscLibType, ds::PetscDS, newds::PetscDS)Copy lower and upper solution bounds set with PetscDSSetLowerBound() and PetscDSSetLowerBound() to another PetscDS
Not Collective
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
newds- ThePetscDScopy
Level: intermediate
See also: PetscDS, PetscDSCopyBoundary(), PetscDSCopyEquations(), PetscDSCopyExactSolutions(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSCopyBounds
PETSc.LibPETSc.PetscDSCopyConstants — Method
PetscDSCopyConstants(petsclib::PetscLibType, prob::PetscDS, newprob::PetscDS)Copy all constants set with PetscDSSetConstants() to another PetscDS
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
newprob- ThePetscDScopy
Level: intermediate
See also: PetscDS, PetscDSCopyBoundary(), PetscDSCopyEquations(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSCopyConstants
PETSc.LibPETSc.PetscDSCopyEquations — Method
PetscDSCopyEquations(petsclib::PetscLibType, prob::PetscDS, newprob::PetscDS)Copy all pointwise function pointers to another PetscDS
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
newprob- ThePetscDScopy
Level: intermediate
See also: PetscDS, PetscDSCopyBoundary(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSCopyEquations
PETSc.LibPETSc.PetscDSCopyExactSolutions — Method
PetscDSCopyExactSolutions(petsclib::PetscLibType, ds::PetscDS, newds::PetscDS)Copy all exact solutions set with PetscDSSetExactSolution() and PetscDSSetExactSolutionTimeDerivative() to another PetscDS
Not Collective
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
newds- ThePetscDScopy
Level: intermediate
See also: PetscDS, PetscDSCopyBoundary(), PetscDSCopyEquations(), PetscDSCopyBounds(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSCopyExactSolutions
PETSc.LibPETSc.PetscDSCreate — Method
ds::PetscDS = PetscDSCreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscDS object. The type can then be set with PetscDSSetType().
Collective
Input Parameter:
comm- The communicator for thePetscDSobject
Output Parameter:
ds- ThePetscDSobject
Level: beginner
See also: PetscDS, PetscDSSetType(), PETSCDSBASIC, PetscDSType, PetscDSDestroy()
External Links
- PETSc Manual:
DT/PetscDSCreate
PETSc.LibPETSc.PetscDSDestroy — Method
PetscDSDestroy(petsclib::PetscLibType, ds::Union{PetscDS, Ref{PetscDS}})Destroys a PetscDS object
Collective
Input Parameter:
ds- thePetscDSobject to destroy
Level: developer
See also: PetscDSView()
External Links
- PETSc Manual:
DT/PetscDSDestroy
PETSc.LibPETSc.PetscDSDestroyBoundary — Method
PetscDSDestroyBoundary(petsclib::PetscLibType, ds::PetscDS)Remove all DMBoundary objects from the PetscDS
Not Collective
Input Parameter:
ds- ThePetscDSobject
Level: intermediate
See also: PetscDS, DMBoundary, PetscDSCopyBoundary(), PetscDSCopyEquations()
External Links
- PETSc Manual:
DT/PetscDSDestroyBoundary
PETSc.LibPETSc.PetscDSFinalizePackage — Method
PetscDSFinalizePackage(petsclib::PetscLibType)This function finalizes everything in the PetscDS package. It is called from PetscFinalize().
Level: developer
See also: PetscInitialize()
External Links
- PETSc Manual:
DM/PetscDSFinalizePackage
PETSc.LibPETSc.PetscDSGetBdJacobian — Method
g0::Ptr{Cvoid},g1::Ptr{Cvoid},g2::Ptr{Cvoid},g3::Ptr{Cvoid} = PetscDSGetBdJacobian(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt)Get the pointwise boundary Jacobian function for given test and basis field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field number
Output Parameters:
g0- integrand for the test and basis function term, seePetscBdPointJacFng1- integrand for the test function and basis function gradient term, seePetscBdPointJacFng2- integrand for the test function gradient and basis function term, seePetscBdPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscBdPointJacFn
Level: intermediate
See also: PetscDS, PetscBdPointJacFn, PetscDSSetBdJacobian()
External Links
- PETSc Manual:
DT/PetscDSGetBdJacobian
PETSc.LibPETSc.PetscDSGetBdJacobianPreconditioner — Method
g0::Ptr{Cvoid},g1::Ptr{Cvoid},g2::Ptr{Cvoid},g3::Ptr{Cvoid} = PetscDSGetBdJacobianPreconditioner(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt)Get the pointwise boundary Jacobian function for given test and basis field that constructs the matrix used to construct the preconditioner
Not Collective; No Fortran Support
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field number
Output Parameters:
g0- integrand for the test and basis function term, seePetscBdPointJacFng1- integrand for the test function and basis function gradient term, seePetscBdPointJacFng2- integrand for the test function gradient and basis function term, seePetscBdPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscBdPointJacFn
Level: intermediate
See also: PetscDS, PetscBdPointJacFn, PetscDSSetBdJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscDSGetBdJacobianPreconditioner
PETSc.LibPETSc.PetscDSGetBdResidual — Method
f0::Ptr{Cvoid},f1::Ptr{Cvoid} = PetscDSGetBdResidual(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise boundary residual function for a given test field
Not Collective
Input Parameters:
ds- The PetscDSf- The test field number
Output Parameters:
f0- boundary integrand for the test function term, seePetscBdPointFnf1- boundary integrand for the test function gradient term, seePetscBdPointFn
Level: intermediate
See also: PetscDS, PetscBdPointFn, PetscDSSetBdResidual()
External Links
- PETSc Manual:
DT/PetscDSGetBdResidual
PETSc.LibPETSc.PetscDSGetBoundary — Method
Nv::PetscInt,values::Vector{PetscInt},field::PetscInt,Nc::PetscInt,comps::Vector{PetscInt} = PetscDSGetBoundary(petsclib::PetscLibType, ds::PetscDS, bd::PetscInt, wf::PetscWeakForm, type::DMBoundaryConditionType, name::String, label::DMLabel, func::PetscVoidFn, func_t::PetscVoidFn, ctx::Cvoid)Gets a boundary condition from the model
Input Parameters:
ds- ThePetscDSobjectbd- The boundary condition number
Output Parameters:
wf- ThePetscWeakFormholding the pointwise functionstype- The type of condition, e.g.DM_BC_ESSENTIAL/DM_BC_ESSENTIAL_FIELD(Dirichlet), orDM_BC_NATURAL(Neumann)name- The boundary condition namelabel- The label defining constrained pointsNv- The number ofDMLabelids for constrained pointsvalues- An array of ids for constrained pointsfield- The field to constrainNc- The number of constrained field componentscomps- An array of constrained component numbersfunc- A pointwise function giving boundary valuesfunc_t- A pointwise function giving the time derivative of the boundary valuesctx- An optional user context forbcFunc
Options Database Keys:
-bc_<boundary name> <num>- Overrides the boundary ids-bc_<boundary name>_comp <num>- Overrides the boundary components
Level: developer
See also: PetscDS, PetscWeakForm, DMBoundaryConditionType, PetscDSAddBoundary(), DMLabel
External Links
- PETSc Manual:
Dm/PetscDSGetBoundary
PETSc.LibPETSc.PetscDSGetCohesive — Method
isCohesive::PetscBool = PetscDSGetCohesive(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Returns the flag indicating that a field is cohesive, meaning it is defined on the interior of a cohesive cell
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field index
Output Parameter:
isCohesive- The flag
Level: developer
See also: PetscDS, PetscDSSetCohesive(), PetscDSIsCohesive(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetCohesive
PETSc.LibPETSc.PetscDSGetComponentDerivativeOffsets — Method
offsets::Vector{PetscInt} = PetscDSGetComponentDerivativeOffsets(petsclib::PetscLibType, prob::PetscDS)Returns the offset of each field derivative on an evaluation point
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
offsets- The offsets
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetComponentDerivativeOffsets
PETSc.LibPETSc.PetscDSGetComponentDerivativeOffsetsCohesive — Method
offsets::Vector{PetscInt} = PetscDSGetComponentDerivativeOffsetsCohesive(petsclib::PetscLibType, ds::PetscDS, s::PetscInt)Returns the offset of each field derivative on an evaluation point
Not Collective
Input Parameters:
ds- ThePetscDSobjects- The cohesive side, 0 for negative, 1 for positive, 2 for cohesive
Output Parameter:
offsets- The offsets
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetComponentDerivativeOffsetsCohesive
PETSc.LibPETSc.PetscDSGetComponentOffset — Method
off::PetscInt = PetscDSGetComponentOffset(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Returns the offset of the given field on an evaluation point
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field number
Output Parameter:
off- The offset
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetComponentOffset
PETSc.LibPETSc.PetscDSGetComponentOffsets — Method
offsets::Vector{PetscInt} = PetscDSGetComponentOffsets(petsclib::PetscLibType, prob::PetscDS)Returns the offset of each field on an evaluation point
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
offsets- The offsets
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetComponentOffsets
PETSc.LibPETSc.PetscDSGetComponentOffsetsCohesive — Method
offsets::Vector{PetscInt} = PetscDSGetComponentOffsetsCohesive(petsclib::PetscLibType, ds::PetscDS, s::PetscInt)Returns the offset of each field on an evaluation point
Not Collective
Input Parameters:
ds- ThePetscDSobjects- The cohesive side, 0 for negative, 1 for positive, 2 for cohesive
Output Parameter:
offsets- The offsets
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetComponentOffsetsCohesive
PETSc.LibPETSc.PetscDSGetComponents — Method
components::Vector{PetscInt} = PetscDSGetComponents(petsclib::PetscLibType, prob::PetscDS)Returns the number of components for each field on an evaluation point
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
components- The number of components
Level: beginner
See also: PetscDS, PetscDSGetComponentOffsets(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetComponents
PETSc.LibPETSc.PetscDSGetConstants — Method
numConstants::PetscInt,constants::Vector{PetscScalar} = PetscDSGetConstants(petsclib::PetscLibType, ds::PetscDS)Returns the array of constants passed to point functions from a PetscDS object
Not Collective
Input Parameter:
ds- ThePetscDSobject
Output Parameters:
numConstants- The number of constants, or pass inNULLif not requiredconstants- The array of constants,NULLif there are none
Level: intermediate
See also: PetscDS, PetscDSSetConstants(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetConstants
PETSc.LibPETSc.PetscDSGetContext — Method
PetscDSGetContext(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, ctx::Ptr{Cvoid})Returns the context that was passed by PetscDSSetContext()
Not Collective
Input Parameters:
ds- ThePetscDSf- The field numberctx- the context
Level: intermediate
See also: PetscDS, PetscPointFn, PetscDSSetContext()
External Links
- PETSc Manual:
DT/PetscDSGetContext
PETSc.LibPETSc.PetscDSGetCoordinateDimension — Method
dimEmbed::PetscInt = PetscDSGetCoordinateDimension(petsclib::PetscLibType, prob::PetscDS)Returns the coordinate dimension of the PetscDS, meaning the dimension of the space into which the discretiaztions are embedded
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
dimEmbed- The coordinate dimension
Level: beginner
See also: PetscDS, PetscDSSetCoordinateDimension(), PetscDSGetSpatialDimension(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetCoordinateDimension
PETSc.LibPETSc.PetscDSGetDimensions — Method
dimensions::Vector{PetscInt} = PetscDSGetDimensions(petsclib::PetscLibType, prob::PetscDS)Returns the size of the approximation space for each field on an evaluation point
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
dimensions- The number of dimensions
Level: beginner
See also: PetscDS, PetscDSGetComponentOffsets(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetDimensions
PETSc.LibPETSc.PetscDSGetDiscretization — Method
disc::PetscObject = PetscDSGetDiscretization(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Returns the discretization object for the given field
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field number
Output Parameter:
disc- The discretization object, this can be aPetscFEor aPetscFV
Level: beginner
See also: PetscDS, PetscFE, PetscFV, PetscDSSetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetDiscretization
PETSc.LibPETSc.PetscDSGetDynamicJacobian — Method
g0::Ptr{Cvoid},g1::Ptr{Cvoid},g2::Ptr{Cvoid},g3::Ptr{Cvoid} = PetscDSGetDynamicJacobian(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt)Get the pointwise dynamic Jacobian, dF/du_t, function for given test and basis field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field number
Output Parameters:
g0- integrand for the test and basis function term, seePetscPointJacFng1- integrand for the test function and basis function gradient term, seePetscPointJacFng2- integrand for the test function gradient and basis function term, seePetscPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscPointJacFn
Level: intermediate
See also: PetscDS, PetscDSSetJacobian(), PetscDSSetDynamicJacobian(), PetscPointJacFn
External Links
- PETSc Manual:
DT/PetscDSGetDynamicJacobian
PETSc.LibPETSc.PetscDSGetEvaluationArrays — Method
u::Ptr{PetscScalar},u_t::Ptr{PetscScalar},u_x::Ptr{PetscScalar} = PetscDSGetEvaluationArrays(petsclib::PetscLibType, prob::PetscDS)Get scratch arrays used to evaluate fields, time derivatives, and field gradients at quadrature points.
Not Collective
Input Parameter:
prob- thePetscDS
Output Parameters:
u- array for the field values, orNULLif not neededu_t- array for the field time derivatives, orNULLif not neededu_x- array for the field gradients, orNULLif not needed
Level: developer
See also: PetscDS, PetscDSGetWeakFormArrays(), PetscDSGetWorkspace()
External Links
- PETSc Manual:
DT/PetscDSGetEvaluationArrays
PETSc.LibPETSc.PetscDSGetExactSolution — Method
sol::Ptr{Cvoid},ctx::Ptr{Cvoid} = PetscDSGetExactSolution(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Get the pointwise exact solution function for a given test field
Not Collective
Input Parameters:
prob- ThePetscDSf- The test field number
Output Parameters:
sol- exact solution function for the test field, seePetscPointExactSolutionFnctx- exact solution context
Level: intermediate
See also: PetscDS, PetscPointExactSolutionFn, PetscDSSetExactSolution(), PetscDSGetExactSolutionTimeDerivative()
External Links
- PETSc Manual:
DT/PetscDSGetExactSolution
PETSc.LibPETSc.PetscDSGetExactSolutionTimeDerivative — Method
sol::Ptr{Cvoid},ctx::Ptr{Cvoid} = PetscDSGetExactSolutionTimeDerivative(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Get the pointwise time derivative of the exact solution function for a given test field
Not Collective
Input Parameters:
prob- ThePetscDSf- The test field number
Output Parameters:
sol- time derivative of the exact solution for the test field, seePetscPointExactSolutionFnctx- the exact solution context
Level: intermediate
See also: PetscDS, PetscPointExactSolutionFn, PetscDSSetExactSolutionTimeDerivative(), PetscDSGetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSGetExactSolutionTimeDerivative
PETSc.LibPETSc.PetscDSGetFaceTabulation — Method
Tf::Ptr{PetscTabulation} = PetscDSGetFaceTabulation(petsclib::PetscLibType, prob::PetscDS)Return the basis tabulation at quadrature points on the faces
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
Tf- The basis function and derivative tabulation on each local face at quadrature points for each field
Level: intermediate
See also: PetscTabulation, PetscDS, PetscDSGetTabulation(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetFaceTabulation
PETSc.LibPETSc.PetscDSGetFieldIndex — Method
f::PetscInt = PetscDSGetFieldIndex(petsclib::PetscLibType, prob::PetscDS, disc)Returns the index of the given field
Not Collective
Input Parameters:
prob- ThePetscDSobjectdisc- The discretization object
Output Parameter:
f- The field number
Level: beginner
See also: PetscDS, PetscGetDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetFieldIndex
PETSc.LibPETSc.PetscDSGetFieldOffset — Method
off::PetscInt = PetscDSGetFieldOffset(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Returns the offset of the given field in the full space basis
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field number
Output Parameter:
off- The offset
Level: beginner
See also: PetscDS, PetscDSGetFieldSize(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetFieldOffset
PETSc.LibPETSc.PetscDSGetFieldOffsetCohesive — Method
off::PetscInt = PetscDSGetFieldOffsetCohesive(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Returns the offset of the given field in the full space basis on a cohesive cell
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field number
Output Parameter:
off- The offset
Level: beginner
See also: PetscDS, PetscDSGetFieldSize(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetFieldOffsetCohesive
PETSc.LibPETSc.PetscDSGetFieldSize — Method
size::PetscInt = PetscDSGetFieldSize(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Returns the size of the given field in the full space basis
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field number
Output Parameter:
size- The size
Level: beginner
See also: PetscDS, PetscDSGetFieldOffset(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetFieldSize
PETSc.LibPETSc.PetscDSGetForceQuad — Method
forceQuad::PetscBool = PetscDSGetForceQuad(petsclib::PetscLibType, ds::PetscDS)Returns the flag to force matching quadratures among the field discretizations
Not collective
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
forceQuad- The flag
Level: intermediate
See also: PetscDS, PetscDSSetForceQuad(), PetscDSGetDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetForceQuad
PETSc.LibPETSc.PetscDSGetHeightSubspace — Method
subprob::PetscDS = PetscDSGetHeightSubspace(petsclib::PetscLibType, prob::PetscDS, height::PetscInt)Get the PetscDS for the trace subspace at a given height in the mesh.
Not Collective
Input Parameters:
prob- thePetscDSheight- the height (0 for the ambient cell, 1 for faces, etc.)
Output Parameter:
subprob- thePetscDSfor the trace subspace;probitself is returned whenheightis 0
Level: developer
See also: PetscDS, PetscFE, PetscFEGetHeightSubspace(), PetscDSGetSpatialDimension()
External Links
- PETSc Manual:
DT/PetscDSGetHeightSubspace
PETSc.LibPETSc.PetscDSGetImplicit — Method
implicit::PetscBool = PetscDSGetImplicit(petsclib::PetscLibType, prob::PetscDS, f::PetscInt)Returns the flag for implicit solve for this field. This is just a guide for TSARKIMEX
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field number
Output Parameter:
implicit- The flag indicating what kind of solve to use for this field
Level: developer
See also: TSARKIMEX, PetscDS, PetscDSSetImplicit(), PetscDSSetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetImplicit
PETSc.LibPETSc.PetscDSGetJacobian — Method
g0::Ptr{Cvoid},g1::Ptr{Cvoid},g2::Ptr{Cvoid},g3::Ptr{Cvoid} = PetscDSGetJacobian(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt)Get the pointwise Jacobian function for given test and basis field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field number
Output Parameters:
g0- integrand for the test and basis function term, seePetscPointJacFng1- integrand for the test function and basis function gradient term, seePetscPointJacFng2- integrand for the test function gradient and basis function term, seePetscPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscPointJacFn
Level: intermediate
See also: PetscDS, PetscDSSetJacobian(), PetscPointJacFn
External Links
- PETSc Manual:
DT/PetscDSGetJacobian
PETSc.LibPETSc.PetscDSGetJacobianPreconditioner — Method
g0::Ptr{Cvoid},g1::Ptr{Cvoid},g2::Ptr{Cvoid},g3::Ptr{Cvoid} = PetscDSGetJacobianPreconditioner(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt)Get the pointwise Jacobian function for given test and basis field that constructs the matrix used to compute the preconditioner. If this is missing, the system matrix is used to build the preconditioner.
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field number
Output Parameters:
g0- integrand for the test and basis function term, seePetscPointJacFng1- integrand for the test function and basis function gradient term, seePetscPointJacFng2- integrand for the test function gradient and basis function term, seePetscPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscPointJacFn
Level: intermediate
See also: PetscDS, PetscDSSetJacobianPreconditioner(), PetscDSGetJacobian(), PetscPointJacFn
External Links
- PETSc Manual:
DT/PetscDSGetJacobianPreconditioner
PETSc.LibPETSc.PetscDSGetJetDegree — Method
k::PetscInt = PetscDSGetJetDegree(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Returns the highest derivative for this field equation, or the k-jet that the discretization needs to tabulate.
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field number
Output Parameter:
k- The highest derivative we need to tabulate
Level: developer
See also: PetscDS, PetscDSSetJetDegree(), PetscDSSetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetJetDegree
PETSc.LibPETSc.PetscDSGetLowerBound — Method
lb::Ptr{Cvoid},ctx::Ptr{Cvoid} = PetscDSGetLowerBound(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise lower bound function for a given field
Not Collective
Input Parameters:
ds- The PetscDSf- The field number
Output Parameters:
lb- lower bound function for the field, seePetscPointBoundFnctx- lower bound context that was set withPetscDSSetLowerBound()
Level: intermediate
See also: PetscDS, PetscPointBoundFn, PetscDSSetLowerBound(), PetscDSGetUpperBound(), PetscDSGetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSGetLowerBound
PETSc.LibPETSc.PetscDSGetNumBoundary — Method
numBd::PetscInt = PetscDSGetNumBoundary(petsclib::PetscLibType, ds::PetscDS)Get the number of registered boundary conditions
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
numBd- The number of boundary conditions
Level: intermediate
See also: PetscDS, PetscDSAddBoundary(), PetscDSGetBoundary()
External Links
- PETSc Manual:
DT/PetscDSGetNumBoundary
PETSc.LibPETSc.PetscDSGetNumCohesive — Method
numCohesive::PetscInt = PetscDSGetNumCohesive(petsclib::PetscLibType, ds::PetscDS)Returns the number of cohesive fields, meaning those defined on the interior of a cohesive cell
Not Collective
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
numCohesive- The number of cohesive fields
Level: developer
See also: PetscDS, PetscDSSetCohesive(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetNumCohesive
PETSc.LibPETSc.PetscDSGetNumFields — Method
Nf::PetscInt = PetscDSGetNumFields(petsclib::PetscLibType, prob::PetscDS)Returns the number of fields in the PetscDS
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
Nf- The number of fields
Level: beginner
See also: PetscDS, PetscDSGetSpatialDimension(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetNumFields
PETSc.LibPETSc.PetscDSGetObjective — Method
obj::Ptr{Cvoid} = PetscDSGetObjective(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise objective function for a given test field that was provided with PetscDSSetObjective()
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field number
Output Parameter:
obj- integrand for the test function term, seePetscPointFn
Level: intermediate
See also: PetscPointFn, PetscDS, PetscDSSetObjective(), PetscDSGetResidual()
External Links
- PETSc Manual:
DT/PetscDSGetObjective
PETSc.LibPETSc.PetscDSGetQuadrature — Method
q::PetscQuadrature = PetscDSGetQuadrature(petsclib::PetscLibType, prob::PetscDS)Returns the quadrature, which must agree for all fields in the PetscDS
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
q- The quadrature object
Level: intermediate
See also: PetscDS, PetscQuadrature, PetscDSSetImplicit(), PetscDSSetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetQuadrature
PETSc.LibPETSc.PetscDSGetRHSResidual — Method
f0::Ptr{Cvoid},f1::Ptr{Cvoid} = PetscDSGetRHSResidual(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise RHS residual function for explicit timestepping for a given test field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field number
Output Parameters:
f0- integrand for the test function term, seePetscPointFnf1- integrand for the test function gradient term, seePetscPointFn
Level: intermediate
See also: PetscPointFn, PetscDS, PetscDSSetRHSResidual()
External Links
- PETSc Manual:
DT/PetscDSGetRHSResidual
PETSc.LibPETSc.PetscDSGetResidual — Method
f0::Ptr{Cvoid},f1::Ptr{Cvoid} = PetscDSGetResidual(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise residual function for a given test field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field number
Output Parameters:
f0- integrand for the test function term, seePetscPointFnf1- integrand for the test function gradient term, seePetscPointFn
Level: intermediate
See also: PetscPointFn, PetscDS, PetscDSSetResidual()
External Links
- PETSc Manual:
DT/PetscDSGetResidual
PETSc.LibPETSc.PetscDSGetRiemannSolver — Method
r::Ptr{Cvoid} = PetscDSGetRiemannSolver(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Returns the Riemann solver for the given field
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field number
Output Parameter:
r- Riemann solver, seePetscRiemannFn
Level: intermediate
See also: PetscDS, PetscRiemannFn, PetscDSSetRiemannSolver()
External Links
- PETSc Manual:
DT/PetscDSGetRiemannSolver
PETSc.LibPETSc.PetscDSGetSpatialDimension — Method
dim::PetscInt = PetscDSGetSpatialDimension(petsclib::PetscLibType, prob::PetscDS)Returns the spatial dimension of the PetscDS, meaning the topological dimension of the discretizations
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
dim- The spatial dimension
Level: beginner
See also: PetscDS, PetscDSGetCoordinateDimension(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetSpatialDimension
PETSc.LibPETSc.PetscDSGetTabulation — Method
T::Ptr{PetscTabulation} = PetscDSGetTabulation(petsclib::PetscLibType, prob::PetscDS)Return the basis tabulation at quadrature points for the volume discretization
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
T- The basis function and derivatives tabulation at quadrature points for each field, seePetscTabulationfor its details
Level: intermediate
See also: PetscDS, PetscTabulation, PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetTabulation
PETSc.LibPETSc.PetscDSGetTotalComponents — Method
Nc::PetscInt = PetscDSGetTotalComponents(petsclib::PetscLibType, prob::PetscDS)Returns the total number of components in this system
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
Nc- The total number of components
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetTotalComponents
PETSc.LibPETSc.PetscDSGetTotalDimension — Method
dim::PetscInt = PetscDSGetTotalDimension(petsclib::PetscLibType, prob::PetscDS)Returns the total size of the approximation space for this system
Not Collective
Input Parameter:
prob- ThePetscDSobject
Output Parameter:
dim- The total problem dimension
Level: beginner
See also: PetscDS, PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetTotalDimension
PETSc.LibPETSc.PetscDSGetType — Method
name::String = PetscDSGetType(petsclib::PetscLibType, prob::PetscDS)Gets the PetscDSType name (as a string) from the PetscDS
Not Collective; No Fortran Support
Input Parameter:
prob- ThePetscDS
Output Parameter:
name- ThePetscDSTypename
Level: intermediate
See also: PetscDSType, PetscDS, PetscDSSetType(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetType
PETSc.LibPETSc.PetscDSGetUpdate — Method
update::Ptr{Cvoid} = PetscDSGetUpdate(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise update function for a given field
Not Collective
Input Parameters:
ds- ThePetscDSf- The field number
Output Parameter:
update- update function, seePetscPointFn
Level: intermediate
See also: PetscDS, PetscPointFn, PetscDSSetUpdate(), PetscDSSetResidual()
External Links
- PETSc Manual:
DT/PetscDSGetUpdate
PETSc.LibPETSc.PetscDSGetUpperBound — Method
ub::Ptr{Cvoid},ctx::Ptr{Cvoid} = PetscDSGetUpperBound(petsclib::PetscLibType, ds::PetscDS, f::PetscInt)Get the pointwise upper bound function for a given field
Not Collective
Input Parameters:
ds- ThePetscDSf- The field number
Output Parameters:
ub- upper bound function for the field, seePetscPointBoundFnctx- upper bound context that was set withPetscDSSetUpperBound()
Level: intermediate
See also: PetscDS, PetscPointBoundFn, PetscDSSetUpperBound(), PetscDSGetLowerBound(), PetscDSGetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSGetUpperBound
PETSc.LibPETSc.PetscDSGetWeakForm — Method
wf::PetscWeakForm = PetscDSGetWeakForm(petsclib::PetscLibType, ds::PetscDS)Returns the weak form object from within the PetscDS
Not Collective
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
wf- The weak form object
Level: beginner
See also: PetscWeakForm, PetscDSSetWeakForm(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSGetWeakForm
PETSc.LibPETSc.PetscDSGetWeakFormArrays — Method
f0::Ptr{PetscScalar},f1::Ptr{PetscScalar},g0::Ptr{PetscScalar},g1::Ptr{PetscScalar},g2::Ptr{PetscScalar},g3::Ptr{PetscScalar} = PetscDSGetWeakFormArrays(petsclib::PetscLibType, prob::PetscDS)External Links
- PETSc Manual:
DT/PetscDSGetWeakFormArrays
PETSc.LibPETSc.PetscDSGetWorkspace — Method
x::Ptr{PetscReal},basisReal::Ptr{PetscScalar},basisDerReal::Ptr{PetscScalar},testReal::Ptr{PetscScalar},testDerReal::Ptr{PetscScalar} = PetscDSGetWorkspace(petsclib::PetscLibType, prob::PetscDS)Get scratch storage used during discretization computations.
Not Collective
Input Parameter:
prob- thePetscDS
Output Parameters:
x- array for real-valued quadrature point coordinates, orNULLif not neededbasisReal- array for the real-valued basis function values, orNULLif not neededbasisDerReal- array for the real-valued basis function derivatives, orNULLif not neededtestReal- array for the real-valued test function values, orNULLif not neededtestDerReal- array for the real-valued test function derivatives, orNULLif not needed
Level: developer
See also: PetscDS, PetscDSGetEvaluationArrays(), PetscDSGetWeakFormArrays()
External Links
- PETSc Manual:
DT/PetscDSGetWorkspace
PETSc.LibPETSc.PetscDSHasBdJacobian — Method
hasBdJac::PetscBool = PetscDSHasBdJacobian(petsclib::PetscLibType, ds::PetscDS)Indicates that boundary Jacobian functions have been set
Not Collective
Input Parameter:
ds- ThePetscDS
Output Parameter:
hasBdJac- flag that pointwise function for the boundary Jacobian has been set
Level: intermediate
See also: PetscDS, PetscDSHasJacobian(), PetscDSSetBdJacobian(), PetscDSGetBdJacobian()
External Links
- PETSc Manual:
DT/PetscDSHasBdJacobian
PETSc.LibPETSc.PetscDSHasBdJacobianPreconditioner — Method
hasBdJacPre::PetscBool = PetscDSHasBdJacobianPreconditioner(petsclib::PetscLibType, ds::PetscDS)Signals that boundary Jacobian preconditioner functions have been set with PetscDSSetBdJacobianPreconditioner()
Not Collective
Input Parameter:
ds- ThePetscDS
Output Parameter:
hasBdJacPre- flag that pointwise function for the boundary Jacobian matrix to construct the preconditioner has been set
Level: intermediate
See also: PetscDS, PetscDSHasJacobian(), PetscDSSetBdJacobian(), PetscDSGetBdJacobian()
External Links
- PETSc Manual:
DT/PetscDSHasBdJacobianPreconditioner
PETSc.LibPETSc.PetscDSHasDynamicJacobian — Method
hasDynJac::PetscBool = PetscDSHasDynamicJacobian(petsclib::PetscLibType, ds::PetscDS)Signals that a dynamic Jacobian, dF/du_t, has been set
Not Collective
Input Parameter:
ds- ThePetscDS
Output Parameter:
hasDynJac- flag that pointwise function for dynamic Jacobian has been set
Level: intermediate
See also: PetscDS, PetscDSGetDynamicJacobian(), PetscDSSetDynamicJacobian(), PetscDSGetJacobian()
External Links
- PETSc Manual:
DT/PetscDSHasDynamicJacobian
PETSc.LibPETSc.PetscDSHasJacobian — Method
hasJac::PetscBool = PetscDSHasJacobian(petsclib::PetscLibType, ds::PetscDS)Checks that the Jacobian functions have been set
Not Collective
Input Parameter:
ds- ThePetscDS
Output Parameter:
hasJac- flag that indicates the pointwise function for the Jacobian has been set
Level: intermediate
See also: PetscDS, PetscDSGetJacobianPreconditioner(), PetscDSSetJacobianPreconditioner(), PetscDSGetJacobian()
External Links
- PETSc Manual:
DT/PetscDSHasJacobian
PETSc.LibPETSc.PetscDSHasJacobianPreconditioner — Method
hasJacPre::PetscBool = PetscDSHasJacobianPreconditioner(petsclib::PetscLibType, ds::PetscDS)Checks if a Jacobian matrix for constructing a preconditioner has been set
Not Collective
Input Parameter:
ds- ThePetscDS
Output Parameter:
hasJacPre- the flag
Level: intermediate
See also: PetscDS, PetscDSGetJacobianPreconditioner(), PetscDSSetJacobianPreconditioner(), PetscDSGetJacobian()
External Links
- PETSc Manual:
DT/PetscDSHasJacobianPreconditioner
PETSc.LibPETSc.PetscDSInitializePackage — Method
PetscDSInitializePackage(petsclib::PetscLibType)This function initializes everything in the PetscDS package. It is called from PetscDLLibraryRegister() when using dynamic libraries, and on the first call to PetscDSCreate() when using static libraries.
Level: developer
See also: PetscInitialize()
External Links
- PETSc Manual:
DM/PetscDSInitializePackage
PETSc.LibPETSc.PetscDSIsCohesive — Method
isCohesive::PetscBool = PetscDSIsCohesive(petsclib::PetscLibType, ds::PetscDS)Returns the flag indicating that this PetscDS is for a cohesive cell
Not Collective
Input Parameter:
ds- ThePetscDSobject
Output Parameter:
isCohesive- The flag
Level: developer
See also: PetscDS, PetscDSGetNumCohesive(), PetscDSGetCohesive(), PetscDSSetCohesive(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSIsCohesive
PETSc.LibPETSc.PetscDSPermuteQuadPoint — Method
qperm::PetscInt = PetscDSPermuteQuadPoint(petsclib::PetscLibType, ds::PetscDS, ornt::PetscInt, field::PetscInt, q::PetscInt)Permute a quadrature point index according to a cell orientation.
Not Collective
Input Parameters:
ds- thePetscDSornt- the cell orientation, in[-Na, Na)whereNais half the number of arrangements for the cell typefield- the field number whose quadrature is usedq- the input quadrature point index in[0, Nq)
Output Parameter:
qperm- the permuted quadrature point index
Level: developer
See also: PetscDS, PetscQuadrature, PetscQuadratureComputePermutations(), DMPolytopeTypeGetNumArrangements()
External Links
- PETSc Manual:
DT/PetscDSPermuteQuadPoint
PETSc.LibPETSc.PetscDSRegister — Method
PetscDSRegister(petsclib::PetscLibType, sname::String, fnc::external)Adds a new PetscDS implementation
Not Collective; No Fortran Support
Input Parameters:
sname- The name of a new user-defined creation routinefunction- The creation routine itself
See also: PetscDSType, PetscDS, PetscDSRegisterAll(), PetscDSRegisterDestroy()
External Links
- PETSc Manual:
DT/PetscDSRegister
PETSc.LibPETSc.PetscDSSelectDiscretizations — Method
PetscDSSelectDiscretizations(petsclib::PetscLibType, prob::PetscDS, numFields::PetscInt, fields::Vector{PetscInt}, minDegree::PetscInt, maxDegree::PetscInt, newprob::PetscDS)Copy discretizations to the new PetscDS with different field layout
Not Collective
Input Parameters:
prob- ThePetscDSobjectnumFields- Number of new fieldsfields- Old field number for each new fieldminDegree- Minimum degree for a discretization, orPETSC_DETERMINEfor no limitmaxDegree- Maximum degree for a discretization, orPETSC_DETERMINEfor no limit
Output Parameter:
newprob- ThePetscDScopy
Level: intermediate
See also: PetscDS, PetscDSSelectEquations(), PetscDSCopyBoundary(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSelectDiscretizations
PETSc.LibPETSc.PetscDSSelectEquations — Method
PetscDSSelectEquations(petsclib::PetscLibType, prob::PetscDS, numFields::PetscInt, fields::Vector{PetscInt}, newprob::PetscDS)Copy pointwise function pointers to the new PetscDS with different field layout
Not Collective
Input Parameters:
prob- ThePetscDSobjectnumFields- Number of new fieldsfields- Old field number for each new field
Output Parameter:
newprob- ThePetscDScopy
Level: intermediate
See also: PetscDS, PetscDSSelectDiscretizations(), PetscDSCopyBoundary(), PetscDSSetResidual(), PetscDSSetJacobian(), PetscDSSetRiemannSolver(), PetscDSSetBdResidual(), PetscDSSetBdJacobian(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSelectEquations
PETSc.LibPETSc.PetscDSSetBdJacobian — Method
PetscDSSetBdJacobian(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt, g0::Ptr{Cvoid}, g1::Ptr{Cvoid}, g2::Ptr{Cvoid}, g3::Ptr{Cvoid})Set the pointwise boundary Jacobian function for given test and basis field
Not Collective
Input Parameters:
ds- The PetscDSf- The test field numberg- The field numberg0- integrand for the test and basis function term, seePetscBdPointJacFng1- integrand for the test function and basis function gradient term, seePetscBdPointJacFng2- integrand for the test function gradient and basis function term, seePetscBdPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscBdPointJacFn
Level: intermediate
See also: PetscDS, PetscBdPointJacFn, PetscDSGetBdJacobian()
External Links
- PETSc Manual:
DT/PetscDSSetBdJacobian
PETSc.LibPETSc.PetscDSSetBdJacobianPreconditioner — Method
PetscDSSetBdJacobianPreconditioner(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt, g0::Ptr{Cvoid}, g1::Ptr{Cvoid}, g2::Ptr{Cvoid}, g3::Ptr{Cvoid})Set the pointwise boundary Jacobian preconditioner function for given test and basis field that constructs the matrix used to construct the preconditioner
Not Collective; No Fortran Support
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field numberg0- integrand for the test and basis function term, seePetscBdPointJacFng1- integrand for the test function and basis function gradient term, seePetscBdPointJacFng2- integrand for the test function gradient and basis function term, seePetscBdPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscBdPointJacFn
Level: intermediate
See also: PetscDS, PetscBdPointJacFn, PetscDSGetBdJacobianPreconditioner()
External Links
- PETSc Manual:
DT/PetscDSSetBdJacobianPreconditioner
PETSc.LibPETSc.PetscDSSetBdResidual — Method
PetscDSSetBdResidual(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, f0::Ptr{Cvoid}, f1::Ptr{Cvoid})Get the pointwise boundary residual function for a given test field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberf0- boundary integrand for the test function term, seePetscBdPointFnf1- boundary integrand for the test function gradient term, seePetscBdPointFn
Level: intermediate
See also: PetscDS, PetscBdPointFn, PetscDSGetBdResidual()
External Links
- PETSc Manual:
DT/PetscDSSetBdResidual
PETSc.LibPETSc.PetscDSSetCellParameters — Method
PetscDSSetCellParameters(petsclib::PetscLibType, ds::PetscDS, volume::PetscReal)Set the parameters for a particular cell
Not Collective
Input Parameters:
ds- ThePetscDSobjectvolume- The cell volume
Level: intermediate
See also: PetscDS, PetscDSSetConstants(), PetscDSGetConstants(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetCellParameters
PETSc.LibPETSc.PetscDSSetCohesive — Method
PetscDSSetCohesive(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, isCohesive::PetscBool)Set the flag indicating that a field is cohesive, meaning it is defined on the interior of a cohesive cell
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field indexisCohesive- The flag for a cohesive field
Level: developer
See also: PetscDS, PetscDSGetCohesive(), PetscDSIsCohesive(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetCohesive
PETSc.LibPETSc.PetscDSSetConstants — Method
PetscDSSetConstants(petsclib::PetscLibType, ds::PetscDS, numConstants::PetscInt, constants::Vector{PetscScalar})Set the array of constants passed to point functions from a PetscDS
Not Collective
Input Parameters:
ds- ThePetscDSobjectnumConstants- The number of constantsconstants- The array of constants,NULLif there are none
Level: intermediate
See also: PetscDS, PetscDSGetConstants(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetConstants
PETSc.LibPETSc.PetscDSSetContext — Method
PetscDSSetContext(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, ctx::Ptr{Cvoid})Sets the context that is passed back to some of the pointwise function callbacks used by this PetscDS
Not Collective
Input Parameters:
ds- ThePetscDSf- The field numberctx- the context
Level: intermediate
See also: PetscDS, PetscPointFn, PetscDSGetContext()
External Links
- PETSc Manual:
DT/PetscDSSetContext
PETSc.LibPETSc.PetscDSSetCoordinateDimension — Method
PetscDSSetCoordinateDimension(petsclib::PetscLibType, prob::PetscDS, dimEmbed::PetscInt)Set the coordinate dimension of the PetscDS, meaning the dimension of the space into which the discretiaztions are embedded
Logically Collective
Input Parameters:
prob- ThePetscDSobjectdimEmbed- The coordinate dimension
Level: beginner
See also: PetscDS, PetscDSGetCoordinateDimension(), PetscDSGetSpatialDimension(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetCoordinateDimension
PETSc.LibPETSc.PetscDSSetDiscretization — Method
PetscDSSetDiscretization(petsclib::PetscLibType, prob::PetscDS, f::PetscInt, disc)Sets the discretization object for the given field
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field numberdisc- The discretization object, this can be aPetscFEor aPetscFV
Level: beginner
See also: PetscDS, PetscFE, PetscFV, PetscDSGetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetDiscretization
PETSc.LibPETSc.PetscDSSetDynamicJacobian — Method
PetscDSSetDynamicJacobian(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt, g0::Ptr{Cvoid}, g1::Ptr{Cvoid}, g2::Ptr{Cvoid}, g3::Ptr{Cvoid})Set the pointwise dynamic Jacobian, dF/du_t, function for given test and basis fields
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field numberg0- integrand for the test and basis function term, seePetscPointJacFng1- integrand for the test function and basis function gradient term, seePetscPointJacFng2- integrand for the test function gradient and basis function term, seePetscPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscPointJacFn
Level: intermediate
See also: PetscDS, PetscDSGetDynamicJacobian(), PetscDSGetJacobian(), PetscPointJacFn
External Links
- PETSc Manual:
DT/PetscDSSetDynamicJacobian
PETSc.LibPETSc.PetscDSSetExactSolution — Method
PetscDSSetExactSolution(petsclib::PetscLibType, prob::PetscDS, f::PetscInt, sol::Ptr{Cvoid}, ctx::Ptr{Cvoid})Set the pointwise exact solution function for a given test field
Not Collective
Input Parameters:
prob- ThePetscDSf- The test field numbersol- solution function for the test fields, seePetscPointExactSolutionFnctx- solution context orNULL
Level: intermediate
See also: PetscDS, PetscPointExactSolutionFn, PetscDSGetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSSetExactSolution
PETSc.LibPETSc.PetscDSSetExactSolutionTimeDerivative — Method
PetscDSSetExactSolutionTimeDerivative(petsclib::PetscLibType, prob::PetscDS, f::PetscInt, sol::Ptr{Cvoid}, ctx::Ptr{Cvoid})Set the pointwise time derivative of the exact solution function for a given test field
Not Collective
Input Parameters:
prob- ThePetscDSf- The test field numbersol- time derivative of the solution function for the test fields, seePetscPointExactSolutionFnctx- the solution context orNULL
Level: intermediate
See also: PetscDS, PetscPointExactSolutionFn, PetscDSGetExactSolutionTimeDerivative(), PetscDSSetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSSetExactSolutionTimeDerivative
PETSc.LibPETSc.PetscDSSetForceQuad — Method
PetscDSSetForceQuad(petsclib::PetscLibType, ds::PetscDS, forceQuad::PetscBool)Set the flag to force matching quadratures among the field discretizations
Logically collective on ds
Input Parameters:
ds- ThePetscDSobjectforceQuad- The flag
Level: intermediate
See also: PetscDS, PetscDSGetForceQuad(), PetscDSGetDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetForceQuad
PETSc.LibPETSc.PetscDSSetFromOptions — Method
PetscDSSetFromOptions(petsclib::PetscLibType, prob::PetscDS)sets parameters in a PetscDS from the options database
Collective
Input Parameter:
prob- thePetscDSobject to set options for
Options Database Keys:
-petscds_type type- Set thePetscDStype-petscds_view- View thePetscDS-petscds_jac_pre (true|false)- Turn formation of a separate Jacobian preconditioner on or off-bc_NAME ids- comma separated list of label ids for the boundary condition NAME-bc_NAME_comp comps- comma separated list of field components to constrain for the boundary condition NAME
Level: intermediate
See also: PetscDS, PetscDSView()
External Links
- PETSc Manual:
DT/PetscDSSetFromOptions
PETSc.LibPETSc.PetscDSSetImplicit — Method
PetscDSSetImplicit(petsclib::PetscLibType, prob::PetscDS, f::PetscInt, implicit::PetscBool)Set the flag for implicit solve for this field. This is just a guide for TSARKIMEX
Not Collective
Input Parameters:
prob- ThePetscDSobjectf- The field numberimplicit- The flag indicating what kind of solve to use for this field
Level: developer
See also: TSARKIMEX, PetscDSGetImplicit(), PetscDSSetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetImplicit
PETSc.LibPETSc.PetscDSSetIntegrationParameters — Method
PetscDSSetIntegrationParameters(petsclib::PetscLibType, ds::PetscDS, fieldI::PetscInt, fieldJ::PetscInt)Set the parameters for a particular integration
Not Collective
Input Parameters:
ds- ThePetscDSobjectfieldI- The test field for a given point function, orPETSC_DETERMINEfieldJ- The basis field for a given point function, orPETSC_DETERMINE
Level: intermediate
See also: PetscDS, PetscDSSetConstants(), PetscDSGetConstants(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetIntegrationParameters
PETSc.LibPETSc.PetscDSSetJacobian — Method
PetscDSSetJacobian(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt, g0::Ptr{Cvoid}, g1::Ptr{Cvoid}, g2::Ptr{Cvoid}, g3::Ptr{Cvoid})Set the pointwise Jacobian function for given test and basis fields
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field numberg0- integrand for the test and basis function term, seePetscPointJacFng1- integrand for the test function and basis function gradient term, seePetscPointJacFng2- integrand for the test function gradient and basis function term, seePetscPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscPointJacFn
Level: intermediate
See also: PetscDS, PetscDSGetJacobian(), PetscPointJacFn
External Links
- PETSc Manual:
DT/PetscDSSetJacobian
PETSc.LibPETSc.PetscDSSetJacobianPreconditioner — Method
PetscDSSetJacobianPreconditioner(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, g::PetscInt, g0::Ptr{Cvoid}, g1::Ptr{Cvoid}, g2::Ptr{Cvoid}, g3::Ptr{Cvoid})Set the pointwise Jacobian function for given test and basis fields that constructs the matrix used to compute the preconditioner. If this is missing, the system matrix is used to build the preconditioner.
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberg- The field numberg0- integrand for the test and basis function term, seePetscPointJacFng1- integrand for the test function and basis function gradient term, seePetscPointJacFng2- integrand for the test function gradient and basis function term, seePetscPointJacFng3- integrand for the test function gradient and basis function gradient term, seePetscPointJacFn
Level: intermediate
See also: PetscDS, PetscDSGetJacobianPreconditioner(), PetscDSSetJacobian(), PetscPointJacFn
External Links
- PETSc Manual:
DT/PetscDSSetJacobianPreconditioner
PETSc.LibPETSc.PetscDSSetJetDegree — Method
PetscDSSetJetDegree(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, k::PetscInt)Set the highest derivative for this field equation, or the k-jet that the discretization needs to tabulate.
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field numberk- The highest derivative we need to tabulate
Level: developer
See also: PetscDS, PetscDSGetJetDegree(), PetscDSSetDiscretization(), PetscDSAddDiscretization(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetJetDegree
PETSc.LibPETSc.PetscDSSetLowerBound — Method
PetscDSSetLowerBound(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, lb::Ptr{Cvoid}, ctx::Ptr{Cvoid})Set the pointwise lower bound function for a given field
Not Collective
Input Parameters:
ds- ThePetscDSf- The field numberlb- lower bound function for the test fields, seePetscPointBoundFnctx- lower bound context orNULLwhich will be passed tolb
Level: intermediate
See also: PetscDS, PetscPointBoundFn, PetscDSGetLowerBound(), PetscDSGetUpperBound(), PetscDSGetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSSetLowerBound
PETSc.LibPETSc.PetscDSSetObjective — Method
PetscDSSetObjective(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, obj::Ptr{Cvoid})Set the pointwise objective function for a given test field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberobj- integrand for the test function term, seePetscPointFn
Level: intermediate
See also: PetscPointFn, PetscDS, PetscDSGetObjective(), PetscDSSetResidual()
External Links
- PETSc Manual:
DT/PetscDSSetObjective
PETSc.LibPETSc.PetscDSSetRHSResidual — Method
PetscDSSetRHSResidual(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, f0::Ptr{Cvoid}, f1::Ptr{Cvoid})Set the pointwise residual function for explicit timestepping for a given test field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberf0- integrand for the test function term, seePetscPointFnf1- integrand for the test function gradient term, seePetscPointFn
Level: intermediate
See also: PetscDS, PetscDSGetResidual()
External Links
- PETSc Manual:
DT/PetscDSSetRHSResidual
PETSc.LibPETSc.PetscDSSetResidual — Method
PetscDSSetResidual(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, f0::Ptr{Cvoid}, f1::Ptr{Cvoid})Set the pointwise residual function for a given test field
Not Collective
Input Parameters:
ds- ThePetscDSf- The test field numberf0- integrand for the test function term, seePetscPointFnf1- integrand for the test function gradient term, seePetscPointFn
Level: intermediate
See also: PetscPointFn, PetscDS, PetscDSGetResidual()
External Links
- PETSc Manual:
DT/PetscDSSetResidual
PETSc.LibPETSc.PetscDSSetRiemannSolver — Method
PetscDSSetRiemannSolver(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, r::Ptr{Cvoid})Sets the Riemann solver for the given field
Not Collective
Input Parameters:
ds- ThePetscDSobjectf- The field numberr- Riemann solver, seePetscRiemannFn
Level: intermediate
See also: PetscDS, PetscRiemannFn, PetscDSGetRiemannSolver()
External Links
- PETSc Manual:
DT/PetscDSSetRiemannSolver
PETSc.LibPETSc.PetscDSSetType — Method
PetscDSSetType(petsclib::PetscLibType, prob::PetscDS, name::String)Builds a particular PetscDS
Collective; No Fortran Support
Input Parameters:
prob- ThePetscDSobjectname- ThePetscDSType
Options Database Key:
-petscds_type type- Sets the PetscDS type; use -help for a list of available types
Level: intermediate
See also: PetscDSType, PetscDS, PetscDSGetType(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetType
PETSc.LibPETSc.PetscDSSetUp — Method
PetscDSSetUp(petsclib::PetscLibType, prob::PetscDS)Construct data structures for the PetscDS
Collective
Input Parameter:
prob- thePetscDSobject to setup
Level: developer
See also: PetscDS, PetscDSView(), PetscDSDestroy()
External Links
- PETSc Manual:
DT/PetscDSSetUp
PETSc.LibPETSc.PetscDSSetUpdate — Method
PetscDSSetUpdate(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, update::Ptr{Cvoid})Set the pointwise update function for a given field
Not Collective
Input Parameters:
ds- ThePetscDSf- The field numberupdate- update function, seePetscPointFn
Level: intermediate
See also: PetscDS, PetscPointFn, PetscDSGetResidual()
External Links
- PETSc Manual:
DT/PetscDSSetUpdate
PETSc.LibPETSc.PetscDSSetUpperBound — Method
PetscDSSetUpperBound(petsclib::PetscLibType, ds::PetscDS, f::PetscInt, ub::Ptr{Cvoid}, ctx::Ptr{Cvoid})Set the pointwise upper bound function for a given field
Not Collective
Input Parameters:
ds- ThePetscDSf- The field numberub- upper bound function for the test fields, seePetscPointBoundFnctx- context orNULLthat will be passed toub
Level: intermediate
See also: PetscDS, PetscPointBoundFn, PetscDSGetUpperBound(), PetscDSGetLowerBound(), PetscDSGetExactSolution()
External Links
- PETSc Manual:
DT/PetscDSSetUpperBound
PETSc.LibPETSc.PetscDSSetWeakForm — Method
PetscDSSetWeakForm(petsclib::PetscLibType, ds::PetscDS, wf::PetscWeakForm)Sets the weak form object to be used by the PetscDS
Not Collective
Input Parameters:
ds- ThePetscDSobjectwf- The weak form object
Level: beginner
See also: PetscWeakForm, PetscDSGetWeakForm(), PetscDSGetNumFields(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSSetWeakForm
PETSc.LibPETSc.PetscDSUpdateBoundary — Method
PetscDSUpdateBoundary(petsclib::PetscLibType, ds::PetscDS, bd::PetscInt, type::DMBoundaryConditionType, name::String, label::DMLabel, Nv::PetscInt, values::Vector{PetscInt}, field::PetscInt, Nc::PetscInt, comps::Vector{PetscInt}, bcFunc::Ptr{Cvoid}, bcFunc_t::Ptr{Cvoid}, ctx::Ptr{Cvoid})Change a boundary condition for the model.
Input Parameters:
ds- ThePetscDSobjectbd- The boundary condition numbertype- The type of condition, e.g.DM_BC_ESSENTIAL/DM_BC_ESSENTIAL_FIELD(Dirichlet), orDM_BC_NATURAL(Neumann)name- The boundary condition namelabel- The label defining constrained pointsNv- The number ofDMLabelids for constrained pointsvalues- An array of ids for constrained pointsfield- The field to constrainNc- The number of constrained field componentscomps- An array of constrained component numbersbcFunc- A pointwise function giving boundary valuesbcFunc_t- A pointwise function giving the time derivative of the boundary values, orNULLctx- An optional application context forbcFunc
Level: developer
See also: PetscDS, PetscWeakForm, DMBoundaryConditionType, PetscDSAddBoundary(), PetscDSGetBoundary(), PetscDSGetNumBoundary(), DMLabel
External Links
- PETSc Manual:
DT/PetscDSUpdateBoundary
PETSc.LibPETSc.PetscDSUpdateBoundaryLabels — Method
PetscDSUpdateBoundaryLabels(petsclib::PetscLibType, ds::PetscDS, dm::AbstractPetscDM)Update DMLabel in each boundary condition using the label name and the input DM
Not Collective
Input Parameters:
ds- The sourcePetscDSobjectdm- TheDMholding labels
Level: intermediate
See also: PetscDS, DMBoundary, DM, PetscDSCopyBoundary(), PetscDSCreate(), DMGetLabel()
External Links
- PETSc Manual:
DT/PetscDSUpdateBoundaryLabels
PETSc.LibPETSc.PetscDSUseJacobianPreconditioner — Method
PetscDSUseJacobianPreconditioner(petsclib::PetscLibType, prob::PetscDS, useJacPre::PetscBool)Set whether to construct a Jacobian preconditioner
Not Collective
Input Parameters:
prob- ThePetscDSuseJacPre- flag that enables construction of a Jacobian preconditioner
Level: intermediate
See also: PetscDS, PetscDSGetJacobianPreconditioner(), PetscDSSetJacobianPreconditioner(), PetscDSGetJacobian()
External Links
- PETSc Manual:
DT/PetscDSUseJacobianPreconditioner
PETSc.LibPETSc.PetscDSView — Method
PetscDSView(petsclib::PetscLibType, prob::PetscDS, v::PetscViewer)Views a PetscDS
Collective
Input Parameters:
prob- thePetscDSobject to viewv- the viewer
Level: developer
See also: PetscDSType, PetscDS, PetscViewer, PetscDSDestroy(), PetscDSViewFromOptions()
External Links
- PETSc Manual:
DT/PetscDSView
PETSc.LibPETSc.PetscDSViewFromOptions — Method
PetscDSViewFromOptions(petsclib::PetscLibType, A::PetscDS, obj, name::String)View a PetscDS based on values in the options database
Collective
Input Parameters:
A- thePetscDSobjectobj- Optional object that provides the options prefix used in the search of the options databasename- command line option
Options Database Key:
-name [viewertype][:...]- option name and values. SeePetscObjectViewFromOptions()for the possible arguments
Level: intermediate
See also: PetscDSType, PetscDS, PetscDSView(), PetscObjectViewFromOptions(), PetscDSCreate()
External Links
- PETSc Manual:
DT/PetscDSViewFromOptions
PetscSpace
PETSc.LibPETSc.PetscSpaceCreate — Method
sp::PetscSpace = PetscSpaceCreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscSpace object. The type can then be set with PetscSpaceSetType().
Collective
Input Parameter:
comm- The communicator for thePetscSpaceobject
Output Parameter:
sp- ThePetscSpaceobject
Level: beginner
See also: PetscSpace, PetscSpaceSetType(), PETSCSPACEPOLYNOMIAL
External Links
- PETSc Manual:
SPACE/PetscSpaceCreate
PETSc.LibPETSc.PetscSpaceCreateSubspace — Method
x::PetscReal,Jx::PetscReal,u::PetscReal,Ju::PetscReal,subspace::PetscSpace = PetscSpaceCreateSubspace(petsclib::PetscLibType, origSpace::PetscSpace, dualSubspace::PetscDualSpace, copymode::PetscCopyMode)creates a subspace from a an origSpace and its dual dualSubspace
Input Parameters:
origSpace- the originalPetscSpacedualSubspace- no ideax- no ideaJx- no ideau- no ideaJu- no ideacopymode- whether to copy, borrow, or own some of the input arrays I guess
Output Parameter:
subspace- the subspace
Level: advanced
See also: PetscSpace, PetscDualSpace, PetscCopyMode, PetscSpaceType
External Links
- PETSc Manual:
SPACE/PetscSpaceCreateSubspace
PETSc.LibPETSc.PetscSpaceDestroy — Method
PetscSpaceDestroy(petsclib::PetscLibType, sp::Union{PetscSpace, Ref{PetscSpace}})Destroys a PetscSpace object
Collective
Input Parameter:
sp- thePetscSpaceobject to destroy
Level: beginner
See also: PetscSpace, PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceDestroy
PETSc.LibPETSc.PetscSpaceEvaluate — Method
PetscSpaceEvaluate(petsclib::PetscLibType, sp::PetscSpace, npoints::PetscInt, points::Vector{PetscReal}, B::Vector{PetscReal}, D::Vector{PetscReal}, H::Vector{PetscReal})Evaluate the basis functions and their derivatives (jet) at each point
Input Parameters:
sp- ThePetscSpacenpoints- The number of evaluation points, in reference coordinatespoints- The point coordinates
Output Parameters:
B- The function evaluations in anpointsxnfuncsarrayD- The derivative evaluations in anpointsxnfuncsxdimarrayH- The second derivative evaluations in anpointsxnfuncsxdimxdimarray
Level: beginner
See also: PetscSpace, PetscFECreateTabulation(), PetscFEGetCellTabulation(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceEvaluate
PETSc.LibPETSc.PetscSpaceGetDegree — Method
minDegree::PetscInt,maxDegree::PetscInt = PetscSpaceGetDegree(petsclib::PetscLibType, sp::PetscSpace)Return the polynomial degrees that characterize this space
Input Parameter:
sp- ThePetscSpace
Output Parameters:
minDegree- The degree of the largest polynomial space contained in the space, passNULLif not neededmaxDegree- The degree of the smallest polynomial space containing the space, passNULLif not needed
Level: intermediate
See also: PetscSpace, PetscSpaceSetDegree(), PetscSpaceGetDimension(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceGetDegree
PETSc.LibPETSc.PetscSpaceGetDimension — Method
dim::PetscInt = PetscSpaceGetDimension(petsclib::PetscLibType, sp::PetscSpace)Return the dimension of this space, i.e. the number of basis vectors
Input Parameter:
sp- ThePetscSpace
Output Parameter:
dim- The dimension
Level: intermediate
See also: PetscSpace, PetscSpaceGetDegree(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceGetDimension
PETSc.LibPETSc.PetscSpaceGetHeightSubspace — Method
subsp::PetscSpace = PetscSpaceGetHeightSubspace(petsclib::PetscLibType, sp::PetscSpace, height::PetscInt)Get the subset of the primal space basis that is supported on a mesh point of a given height.
Not Collective
Input Parameters:
sp- thePetscSpaceobjectheight- the height of the mesh point for which the subspace is desired
Output Parameter:
subsp- the subspace
Level: advanced
See also: PetscDualSpaceGetHeightSubspace(), PetscSpace
External Links
- PETSc Manual:
SPACE/PetscSpaceGetHeightSubspace
PETSc.LibPETSc.PetscSpaceGetNumComponents — Method
Nc::PetscInt = PetscSpaceGetNumComponents(petsclib::PetscLibType, sp::PetscSpace)Return the number of components for this space
Input Parameter:
sp- ThePetscSpace
Output Parameter:
Nc- The number of components
Level: intermediate
See also: PetscSpace, PetscSpaceSetNumComponents(), PetscSpaceGetNumVariables(), PetscSpaceGetDimension(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceGetNumComponents
PETSc.LibPETSc.PetscSpaceGetNumVariables — Method
n::PetscInt = PetscSpaceGetNumVariables(petsclib::PetscLibType, sp::PetscSpace)Return the number of variables for this space
Input Parameter:
sp- ThePetscSpace
Output Parameter:
n- The number of variables, e.g. x, y, z...
Level: intermediate
See also: PetscSpace, PetscSpaceSetNumVariables(), PetscSpaceGetNumComponents(), PetscSpaceGetDimension(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceGetNumVariables
PETSc.LibPETSc.PetscSpaceGetType — Method
name::String = PetscSpaceGetType(petsclib::PetscLibType, sp::PetscSpace)Gets the PetscSpaceType (as a string) from the object.
Not Collective
Input Parameter:
sp- ThePetscSpace
Output Parameter:
name- ThePetscSpacetype name
Level: intermediate
See also: PetscSpaceType, PetscSpace, PetscSpaceSetType(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceGetType
PETSc.LibPETSc.PetscSpacePTrimmedGetFormDegree — Method
formDegree::PetscInt = PetscSpacePTrimmedGetFormDegree(petsclib::PetscLibType, sp::PetscSpace)Get the form degree of the trimmed polynomials.
Input Parameter:
sp- the function space object
Output Parameter:
formDegree- the form degree
Level: intermediate
See also: PetscSpace, PetscDTAltV, PetscDTPTrimmedEvalJet(), PetscSpacePTrimmedSetFormDegree()
External Links
- PETSc Manual:
SPACE/PetscSpacePTrimmedGetFormDegree
PETSc.LibPETSc.PetscSpacePTrimmedSetFormDegree — Method
PetscSpacePTrimmedSetFormDegree(petsclib::PetscLibType, sp::PetscSpace, formDegree::PetscInt)Set the form degree of the trimmed polynomials.
Input Parameters:
sp- the function space objectformDegree- the form degree
Options Database Key:
-petscspace_ptrimmed_form_degree degree- The trimmed polynomial form degree
Level: intermediate
See also: PetscSpace, PetscDTAltV, PetscDTPTrimmedEvalJet(), PetscSpacePTrimmedGetFormDegree()
External Links
- PETSc Manual:
SPACE/PetscSpacePTrimmedSetFormDegree
PETSc.LibPETSc.PetscSpacePointGetPoints — Method
q::PetscQuadrature = PetscSpacePointGetPoints(petsclib::PetscLibType, sp::PetscSpace)Gets the evaluation points for the space as the points of a quadrature rule
Logically Collective
Input Parameter:
sp- ThePetscSpace
Output Parameter:
q- ThePetscQuadraturedefining the points
Level: intermediate
See also: PetscSpace, PetscQuadrature, PetscSpaceCreate(), PetscSpaceSetType()
External Links
- PETSc Manual:
SPACE/PetscSpacePointGetPoints
PETSc.LibPETSc.PetscSpacePointSetPoints — Method
PetscSpacePointSetPoints(petsclib::PetscLibType, sp::PetscSpace, q::PetscQuadrature)Sets the evaluation points for the space to coincide with the points of a quadrature rule
Logically Collective
Input Parameters:
sp- ThePetscSpaceq- ThePetscQuadraturedefining the points
Level: intermediate
See also: PetscSpace, PetscQuadrature, PetscSpaceCreate(), PetscSpaceSetType()
External Links
- PETSc Manual:
SPACE/PetscSpacePointSetPoints
PETSc.LibPETSc.PetscSpacePolynomialGetTensor — Method
tensor::PetscBool = PetscSpacePolynomialGetTensor(petsclib::PetscLibType, sp::PetscSpace)Get whether a function space is a space of tensor polynomials.
Input Parameter:
sp- the function space object
Output Parameter:
tensor-PETSC_TRUEfor a tensor polynomial space,PETSC_FALSEfor a polynomial space
Level: intermediate
See also: PetscSpace, PetscSpacePolynomialSetTensor(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpacePolynomialGetTensor
PETSc.LibPETSc.PetscSpacePolynomialSetTensor — Method
PetscSpacePolynomialSetTensor(petsclib::PetscLibType, sp::PetscSpace, tensor::PetscBool)Set whether a function space is a space of tensor polynomials.
Input Parameters:
sp- the function space objecttensor-PETSC_TRUEfor a tensor polynomial space,PETSC_FALSEfor a polynomial space
Options Database Key:
-petscspace_poly_tensor (true|false)- Whether to use tensor product polynomials in higher dimension
Level: intermediate
See also: PetscSpace, PetscSpacePolynomialGetTensor(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpacePolynomialSetTensor
PETSc.LibPETSc.PetscSpaceRegister — Method
PetscSpaceRegister(petsclib::PetscLibType, sname::String, fnc::external)Adds a new PetscSpace implementation
Not Collective, No Fortran Support
Input Parameters:
sname- The name of a new user-defined creation routinefunction- The creation routine for the implementation type
See also: PetscSpace, PetscSpaceRegisterAll(), PetscSpaceRegisterDestroy()
External Links
- PETSc Manual:
SPACE/PetscSpaceRegister
PETSc.LibPETSc.PetscSpaceSetDegree — Method
PetscSpaceSetDegree(petsclib::PetscLibType, sp::PetscSpace, degree::PetscInt, maxDegree::PetscInt)Set the degree of approximation for this space.
Input Parameters:
sp- ThePetscSpacedegree- The degree of the largest polynomial space contained in the spacemaxDegree- The degree of the largest polynomial space containing the space. One of degree and maxDegree can bePETSC_DETERMINE.
Level: intermediate
See also: PetscSpace, PetscSpaceGetDegree(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceSetDegree
PETSc.LibPETSc.PetscSpaceSetFromOptions — Method
PetscSpaceSetFromOptions(petsclib::PetscLibType, sp::PetscSpace)sets parameters in a PetscSpace from the options database
Collective
Input Parameter:
sp- thePetscSpaceobject to set options for
Options Database Keys:
-petscspace_degree deg- the degree of the space-petscspace_variables n- the number of different variables, e.g. x and y-petscspace_components c- the number of components, say d for a vector field
Level: intermediate
See also: PetscSpace, PetscSpaceView()
External Links
- PETSc Manual:
SPACE/PetscSpaceSetFromOptions
PETSc.LibPETSc.PetscSpaceSetNumComponents — Method
PetscSpaceSetNumComponents(petsclib::PetscLibType, sp::PetscSpace, Nc::PetscInt)Set the number of components for this space
Input Parameters:
sp- ThePetscSpaceNc- The number of components
Level: intermediate
See also: PetscSpace, PetscSpaceGetNumComponents(), PetscSpaceSetNumVariables(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceSetNumComponents
PETSc.LibPETSc.PetscSpaceSetNumVariables — Method
PetscSpaceSetNumVariables(petsclib::PetscLibType, sp::PetscSpace, n::PetscInt)Set the number of variables for this space
Input Parameters:
sp- ThePetscSpacen- The number of variables, e.g. x, y, z...
Level: intermediate
See also: PetscSpace, PetscSpaceGetNumVariables(), PetscSpaceSetNumComponents(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceSetNumVariables
PETSc.LibPETSc.PetscSpaceSetType — Method
PetscSpaceSetType(petsclib::PetscLibType, sp::PetscSpace, name::String)Builds a particular PetscSpace
Collective
Input Parameters:
sp- ThePetscSpaceobjectname- The kind of space
Options Database Key:
-petscspace_type type- Sets thePetscSpacetype; use -help for a list of available types
Level: intermediate
See also: PetscSpace, PetscSpaceType, PetscSpaceGetType(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceSetType
PETSc.LibPETSc.PetscSpaceSetUp — Method
PetscSpaceSetUp(petsclib::PetscLibType, sp::PetscSpace)Construct data structures for the PetscSpace
Collective
Input Parameter:
sp- thePetscSpaceobject to setup
Level: intermediate
See also: PetscSpace, PetscSpaceView(), PetscSpaceDestroy()
External Links
- PETSc Manual:
SPACE/PetscSpaceSetUp
PETSc.LibPETSc.PetscSpaceSumGetConcatenate — Method
concatenate::PetscBool = PetscSpaceSumGetConcatenate(petsclib::PetscLibType, sp::PetscSpace)Get the concatenate flag for this space.
Input Parameter:
sp- the function space object
Output Parameter:
concatenate- flag indicating whether subspaces are concatenated.
Level: intermediate
See also: PETSCSPACESUM, PetscSpace, PetscSpaceSumSetConcatenate()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumGetConcatenate
PETSc.LibPETSc.PetscSpaceSumGetInterleave — Method
interleave_basis::PetscBool,interleave_components::PetscBool = PetscSpaceSumGetInterleave(petsclib::PetscLibType, sp::PetscSpace)Get whether the basis functions and components of a uniform sum are interleaved
Logically collective
Input Parameter:
sp- aPetscSpaceof typePETSCSPACESUM
Output Parameters:
interleave_basis- ifPETSC_TRUE, the basis vectors of the subspaces are interleavedinterleave_components- ifPETSC_TRUEand the space concatenates components (PetscSpaceSumGetConcatenate()),
interleave the concatenated components
Level: developer
See also: PetscSpace, PETSCSPACESUM, PETSCFEVECTOR, PetscSpaceSumSetInterleave()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumGetInterleave
PETSc.LibPETSc.PetscSpaceSumGetNumSubspaces — Method
numSumSpaces::PetscInt = PetscSpaceSumGetNumSubspaces(petsclib::PetscLibType, sp::PetscSpace)Get the number of spaces in the sum space
Input Parameter:
sp- the function space object
Output Parameter:
numSumSpaces- the number of spaces
Level: intermediate
See also: PETSCSPACESUM, PetscSpace, PetscSpaceSumSetNumSubspaces(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumGetNumSubspaces
PETSc.LibPETSc.PetscSpaceSumGetSubspace — Method
subsp::PetscSpace = PetscSpaceSumGetSubspace(petsclib::PetscLibType, sp::PetscSpace, s::PetscInt)Get a space in the sum space
Input Parameters:
sp- the function space objects- The space number
Output Parameter:
subsp- thePetscSpace
Level: intermediate
See also: PETSCSPACESUM, PetscSpace, PetscSpaceSumSetSubspace(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumGetSubspace
PETSc.LibPETSc.PetscSpaceSumSetConcatenate — Method
PetscSpaceSumSetConcatenate(petsclib::PetscLibType, sp::PetscSpace, concatenate::PetscBool)Sets the concatenate flag for this space.
Input Parameters:
sp- the function space objectconcatenate- are subspaces concatenated components (true) or direct summands (false)
Level: intermediate
See also: PETSCSPACESUM, PetscSpace, PetscSpaceSumGetConcatenate()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumSetConcatenate
PETSc.LibPETSc.PetscSpaceSumSetInterleave — Method
PetscSpaceSumSetInterleave(petsclib::PetscLibType, sp::PetscSpace, interleave_basis::PetscBool, interleave_components::PetscBool)Set whether the basis functions and components of a uniform sum are interleaved
Logically collective
Input Parameters:
sp- aPetscSpaceof typePETSCSPACESUMinterleave_basis- ifPETSC_TRUE, the basis vectors of the subspaces are interleavedinterleave_components- ifPETSC_TRUEand the space concatenates components (PetscSpaceSumGetConcatenate()),
interleave the concatenated components
Level: developer
See also: PetscSpace, PETSCSPACESUM, PETSCFEVECTOR, PetscSpaceSumGetInterleave()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumSetInterleave
PETSc.LibPETSc.PetscSpaceSumSetNumSubspaces — Method
PetscSpaceSumSetNumSubspaces(petsclib::PetscLibType, sp::PetscSpace, numSumSpaces::PetscInt)Set the number of spaces in the sum space
Input Parameters:
sp- the function space objectnumSumSpaces- the number of spaces
Level: intermediate
See also: PETSCSPACESUM, PetscSpace, PetscSpaceSumGetNumSubspaces(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumSetNumSubspaces
PETSc.LibPETSc.PetscSpaceSumSetSubspace — Method
PetscSpaceSumSetSubspace(petsclib::PetscLibType, sp::PetscSpace, s::PetscInt, subsp::PetscSpace)Set a space in the sum space
Input Parameters:
sp- the function space objects- The space numbersubsp- the number of spaces
Level: intermediate
See also: PETSCSPACESUM, PetscSpace, PetscSpaceSumGetSubspace(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceSumSetSubspace
PETSc.LibPETSc.PetscSpaceTensorGetNumSubspaces — Method
numTensSpaces::PetscInt = PetscSpaceTensorGetNumSubspaces(petsclib::PetscLibType, sp::PetscSpace)Get the number of spaces in the tensor product space
Input Parameter:
sp- the function space object
Output Parameter:
numTensSpaces- the number of spaces
Level: intermediate
See also: PETSCSPACETENSOR, PetscSpace, PetscSpaceTensorSetNumSubspaces(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceTensorGetNumSubspaces
PETSc.LibPETSc.PetscSpaceTensorGetSubspace — Method
subsp::PetscSpace = PetscSpaceTensorGetSubspace(petsclib::PetscLibType, sp::PetscSpace, s::PetscInt)Get a space in the tensor product space
Input Parameters:
sp- the function space objects- The space number
Output Parameter:
subsp- thePetscSpace
Level: intermediate
See also: PETSCSPACETENSOR, PetscSpace, PetscSpaceTensorSetSubspace(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceTensorGetSubspace
PETSc.LibPETSc.PetscSpaceTensorSetNumSubspaces — Method
PetscSpaceTensorSetNumSubspaces(petsclib::PetscLibType, sp::PetscSpace, numTensSpaces::PetscInt)Set the number of spaces in the tensor product space
Input Parameters:
sp- the function space objectnumTensSpaces- the number of spaces
Level: intermediate
See also: PETSCSPACETENSOR, PetscSpace, PetscSpaceTensorGetNumSubspaces(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceTensorSetNumSubspaces
PETSc.LibPETSc.PetscSpaceTensorSetSubspace — Method
PetscSpaceTensorSetSubspace(petsclib::PetscLibType, sp::PetscSpace, s::PetscInt, subsp::PetscSpace)Set a space in the tensor product space
Input Parameters:
sp- the function space objects- The space numbersubsp- the number of spaces
Level: intermediate
See also: PETSCSPACETENSOR, PetscSpace, PetscSpaceTensorGetSubspace(), PetscSpaceSetDegree(), PetscSpaceSetNumVariables()
External Links
- PETSc Manual:
SPACE/PetscSpaceTensorSetSubspace
PETSc.LibPETSc.PetscSpaceView — Method
PetscSpaceView(petsclib::PetscLibType, sp::PetscSpace, v::PetscViewer)Views a PetscSpace
Collective
Input Parameters:
sp- thePetscSpaceobject to viewv- the viewer
Level: beginner
See also: PetscSpace, PetscViewer, PetscSpaceViewFromOptions(), PetscSpaceDestroy()
External Links
- PETSc Manual:
SPACE/PetscSpaceView
PETSc.LibPETSc.PetscSpaceViewFromOptions — Method
PetscSpaceViewFromOptions(petsclib::PetscLibType, A::PetscSpace, obj, name::String)View a PetscSpace based on values in the options database
Collective
Input Parameters:
A- thePetscSpaceobjectobj- Optional object that provides the options name prefixname- command line option name
Options Database Key:
-name [viewertype][:...]- option name and values. SeePetscObjectViewFromOptions()for the possible arguments
Level: intermediate
See also: PetscSpace, PetscSpaceView(), PetscObjectViewFromOptions(), PetscSpaceCreate()
External Links
- PETSc Manual:
SPACE/PetscSpaceViewFromOptions
PetscDualSpace
PETSc.LibPETSc.PetscDualSpaceApply — Method
value::PetscScalar = PetscDualSpaceApply(petsclib::PetscLibType, sp::PetscDualSpace, f::PetscInt, time::PetscReal, cgeom::Vector{PetscFEGeom}, numComp::PetscInt, func::external, ctx::Ptr{Cvoid})Apply a functional from the dual space basis to an input function
Input Parameters:
sp- ThePetscDualSpaceobjectf- The basis functional indextime- The timecgeom- A context with geometric information for this cell, we use v0 (the initial vertex) and J (the Jacobian) (or evaluated at the coordinates of the functional)numComp- The number of components for the functionfunc- The input functionctx- A context for the function
Output Parameter:
value- numComp output values
Calling sequence: $PetscErrorCode func(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt numComponents, PetscScalar values[], PetscCtx ctx)$
Level: beginner
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApply
PETSc.LibPETSc.PetscDualSpaceApplyAll — Method
spValue::PetscScalar = PetscDualSpaceApplyAll(petsclib::PetscLibType, sp::PetscDualSpace, pointEval::Vector{PetscScalar})Apply all functionals from the dual space basis to the result of an evaluation at the points returned by PetscDualSpaceGetAllData()
Input Parameters:
sp- ThePetscDualSpaceobjectpointEval- Evaluation at the points returned byPetscDualSpaceGetAllData()
Output Parameter:
spValue- The values of all dual space functionals
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApplyAll
PETSc.LibPETSc.PetscDualSpaceApplyAllDefault — Method
spValue::PetscScalar = PetscDualSpaceApplyAllDefault(petsclib::PetscLibType, sp::PetscDualSpace, pointEval::Vector{PetscScalar})Apply all functionals from the dual space basis to the result of an evaluation at the points returned by PetscDualSpaceGetAllData()
Input Parameters:
sp- ThePetscDualSpaceobjectpointEval- Evaluation at the points returned byPetscDualSpaceGetAllData()
Output Parameter:
spValue- The values of all dual space functionals
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApplyAllDefault
PETSc.LibPETSc.PetscDualSpaceApplyDefault — Method
value::PetscScalar = PetscDualSpaceApplyDefault(petsclib::PetscLibType, sp::PetscDualSpace, f::PetscInt, time::PetscReal, cgeom::Vector{PetscFEGeom}, Nc::PetscInt, func::external, ctx::Ptr{Cvoid})Apply a functional from the dual space basis to an input function by assuming a point evaluation functional.
Input Parameters:
sp- ThePetscDualSpaceobjectf- The basis functional indextime- The timecgeom- A context with geometric information for this cell, we use v0 (the initial vertex) and J (the Jacobian)Nc- The number of components for the functionfunc- The input functionctx- A context for the function
Output Parameter:
value- The output value
Calling sequence: $PetscErrorCode func(PetscInt dim, PetscReal time, const PetscReal x[],PetscInt numComponents, PetscScalar values[], PetscCtx ctx)$
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApplyDefault
PETSc.LibPETSc.PetscDualSpaceApplyFVM — Method
value::PetscScalar = PetscDualSpaceApplyFVM(petsclib::PetscLibType, sp::PetscDualSpace, f::PetscInt, time::PetscReal, cgeom::Vector{PetscFVCellGeom}, Nc::PetscInt, func::external, ctx::Ptr{Cvoid})Apply a functional from the dual space basis to an input function by assuming a point evaluation functional at the cell centroid.
Input Parameters:
sp- ThePetscDualSpaceobjectf- The basis functional indextime- The timecgeom- A context with geometric information for this cell, we currently just use the centroidNc- The number of components for the functionfunc- The input functionctx- A context for the function
Output Parameter:
value- The output value (scalar)
Calling sequence: $PetscErrorCode func(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt numComponents, PetscScalar values[], PetscCtx ctx)$
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApplyFVM
PETSc.LibPETSc.PetscDualSpaceApplyInterior — Method
spValue::PetscScalar = PetscDualSpaceApplyInterior(petsclib::PetscLibType, sp::PetscDualSpace, pointEval::Vector{PetscScalar})Apply interior functionals from the dual space basis to the result of an evaluation at the points returned by PetscDualSpaceGetInteriorData()
Input Parameters:
sp- ThePetscDualSpaceobjectpointEval- Evaluation at the points returned byPetscDualSpaceGetInteriorData()
Output Parameter:
spValue- The values of interior dual space functionals
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApplyInterior
PETSc.LibPETSc.PetscDualSpaceApplyInteriorDefault — Method
spValue::PetscScalar = PetscDualSpaceApplyInteriorDefault(petsclib::PetscLibType, sp::PetscDualSpace, pointEval::Vector{PetscScalar})Apply interior functionals from the dual space basis to the result of an evaluation at the points returned by PetscDualSpaceGetInteriorData()
Input Parameters:
sp- ThePetscDualSpaceobjectpointEval- Evaluation at the points returned byPetscDualSpaceGetInteriorData()
Output Parameter:
spValue- The values of interior dual space functionals
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceApplyInteriorDefault
PETSc.LibPETSc.PetscDualSpaceCreate — Method
sp::PetscDualSpace = PetscDualSpaceCreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscDualSpace object. The type can then be set with PetscDualSpaceSetType().
Collective
Input Parameter:
comm- The communicator for thePetscDualSpaceobject
Output Parameter:
sp- ThePetscDualSpaceobject
Level: beginner
See also: PetscDualSpace, PetscDualSpaceSetType(), PETSCDUALSPACELAGRANGE
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceCreate
PETSc.LibPETSc.PetscDualSpaceCreateAllDataDefault — Method
allNodes::PetscQuadrature,allMat::PetscMat = PetscDualSpaceCreateAllDataDefault(petsclib::PetscLibType, sp::PetscDualSpace)Create all evaluation nodes and the node-to-dof matrix by examining functionals
Input Parameter:
sp- The dualspace
Output Parameters:
allNodes- APetscQuadratureobject containing all evaluation nodesallMat- AMatfor the node-to-dof transformation
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate(), Mat, PetscQuadrature
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceCreateAllDataDefault
PETSc.LibPETSc.PetscDualSpaceCreateInteriorDataDefault — Method
intNodes::PetscQuadrature,intMat::PetscMat = PetscDualSpaceCreateInteriorDataDefault(petsclib::PetscLibType, sp::PetscDualSpace)Create quadrature points by examining interior functionals and create the matrix mapping quadrature point values to interior dual space values
Input Parameter:
sp- The dualspace
Output Parameters:
intNodes- APetscQuadratureobject containing all evaluation points needed to evaluate interior degrees of freedomintMat- A matrix that computes dual space values from point values: size [spdim0 x (npoints * nc)], where spdim0 is
the size of the constrained layout (PetscSectionGetConstrainStorageSize()) of the dual space section, npoints is the number of points in allNodes and nc is PetscDualSpaceGetNumComponents().
Level: advanced
See also: PetscDualSpace, PetscQuadrature, Mat, PetscDualSpaceCreate(), PetscDualSpaceGetInteriorData()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceCreateInteriorDataDefault
PETSc.LibPETSc.PetscDualSpaceCreateSum — Method
sumSpace::PetscDualSpace = PetscDualSpaceCreateSum(petsclib::PetscLibType, numSubspaces::PetscInt, subspaces::Vector{PetscDualSpace}, concatenate::PetscBool)Create a finite element dual basis that is the sum of other dual bases
Collective
Input Parameters:
numSubspaces- the number of spaces that will be added togethersubspaces- an array of lengthnumSubspacesof spacesconcatenate- ifPETSC_FALSE, the sum-space has the same components as the individual dual spaces (PetscDualSpaceGetNumComponents()); ifPETSC_TRUE, the individual components are concatenated to create a dual space with more components
Output Parameter:
sumSpace- aPetscDualSpaceof typePETSCDUALSPACESUM
Level: advanced
See also: PetscDualSpace, PETSCDUALSPACESUM, PETSCSPACESUM
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceCreateSum
PETSc.LibPETSc.PetscDualSpaceDestroy — Method
PetscDualSpaceDestroy(petsclib::PetscLibType, sp::Union{PetscDualSpace, Ref{PetscDualSpace}})Destroys a PetscDualSpace object
Collective
Input Parameter:
sp- thePetscDualSpaceobject to destroy
Level: beginner
See also: PetscDualSpace, PetscDualSpaceView(), PetscDualSpace(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceDestroy
PETSc.LibPETSc.PetscDualSpaceDuplicate — Method
spNew::PetscDualSpace = PetscDualSpaceDuplicate(petsclib::PetscLibType, sp::PetscDualSpace)Creates a duplicate PetscDualSpace object that is not setup.
Collective
Input Parameter:
sp- The originalPetscDualSpace
Output Parameter:
spNew- The duplicatePetscDualSpace
Level: beginner
See also: PetscDualSpace, PetscDualSpaceCreate(), PetscDualSpaceSetType()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceDuplicate
PETSc.LibPETSc.PetscDualSpaceEqual — Method
equal::PetscBool = PetscDualSpaceEqual(petsclib::PetscLibType, A::PetscDualSpace, B::PetscDualSpace)Determine if two dual spaces are equivalent
Input Parameters:
A- APetscDualSpaceobjectB- AnotherPetscDualSpaceobject
Output Parameter:
equal-PETSC_TRUEif the dual spaces are equivalent
Level: advanced
See also: PetscDualSpace, PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceEqual
PETSc.LibPETSc.PetscDualSpaceGetAllData — Method
allNodes::PetscQuadrature,allMat::PetscMat = PetscDualSpaceGetAllData(petsclib::PetscLibType, sp::PetscDualSpace)Get all quadrature nodes from this space, and the matrix that sends quadrature node values to degree-of-freedom values
Input Parameter:
sp- The dualspace
Output Parameters:
allNodes- APetscQuadratureobject containing all evaluation nodes, passNULLif not neededallMat- AMatfor the node-to-dof transformation, passNULLif not needed
Level: advanced
See also: PetscQuadrature, PetscDualSpace, PetscDualSpaceCreate(), Mat
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetAllData
PETSc.LibPETSc.PetscDualSpaceGetDM — Method
dm::PetscDM = PetscDualSpaceGetDM(petsclib::PetscLibType, sp::PetscDualSpace)Get the DM representing the reference cell of a PetscDualSpace
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
dm- The reference cell, that is aDMthat consists of a single cell
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceSetDM(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetDM
PETSc.LibPETSc.PetscDualSpaceGetDeRahm — Method
k::PetscInt = PetscDualSpaceGetDeRahm(petsclib::PetscLibType, dsp::PetscDualSpace)Get the k-simplex associated with the functionals in this dual space
Input Parameter:
dsp- ThePetscDualSpace
Output Parameter:
k- The simplex dimension
Level: developer
See also: PetscDualSpace, PetscDualSpacePullback(), PetscDualSpacePushforward(), PetscDualSpaceTransform(), PetscDualSpaceTransformType
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetDeRahm
PETSc.LibPETSc.PetscDualSpaceGetDimension — Method
dim::PetscInt = PetscDualSpaceGetDimension(petsclib::PetscLibType, sp::PetscDualSpace)Get the dimension of the dual space, i.e. the number of basis functionals
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
dim- The dimension
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceGetFunctional(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetDimension
PETSc.LibPETSc.PetscDualSpaceGetFormDegree — Method
k::PetscInt = PetscDualSpaceGetFormDegree(petsclib::PetscLibType, dsp::PetscDualSpace)Get the form degree k for the k-form the describes the pushforwards/pullbacks of this dual space's functionals.
Input Parameter:
dsp- ThePetscDualSpace
Output Parameter:
k- The signed degree k of the k. If k >= 0, this means that the degrees of freedom are k-forms, and are stored
in lexicographic order according to the basis of k-forms constructed from the wedge product of 1-forms. So for example, the 1-form basis in 3-D is (dx, dy, dz), and the 2-form basis in 3-D is (dx wedge dy, dx wedge dz, dy wedge dz). If k < 0, this means that the degrees transform as k-forms, but are stored as (N-k) forms according to the Hodge star map. So for example if k = -2 and N = 3, this means that the degrees of freedom transform as 2-forms but are stored as 1-forms.
Level: developer
See also: PetscDualSpace, PetscDTAltV, PetscDualSpacePullback(), PetscDualSpacePushforward(), PetscDualSpaceTransform(), PetscDualSpaceTransformType
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetFormDegree
PETSc.LibPETSc.PetscDualSpaceGetFunctional — Method
functional::PetscQuadrature = PetscDualSpaceGetFunctional(petsclib::PetscLibType, sp::PetscDualSpace, i::PetscInt)Get the i-th basis functional in the dual space
Not Collective
Input Parameters:
sp- ThePetscDualSpacei- The basis number
Output Parameter:
functional- The basis functional
Level: intermediate
See also: PetscDualSpace, PetscQuadrature, PetscDualSpaceGetDimension(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetFunctional
PETSc.LibPETSc.PetscDualSpaceGetHeightSubspace — Method
subsp::PetscDualSpace = PetscDualSpaceGetHeightSubspace(petsclib::PetscLibType, sp::PetscDualSpace, height::PetscInt)Get the subset of the dual space basis that is supported on a mesh point of a given height. This assumes that the reference cell is symmetric over points of this height.
Not Collective
Input Parameters:
sp- thePetscDualSpaceobjectheight- the height of the mesh point for which the subspace is desired
Output Parameter:
subsp- the subspace. Note that the functionals in the subspace are with respect to the intrinsic geometry of the
point, which will be of lesser dimension if height > 0.
Level: advanced
See also: PetscDualSpace, PetscSpaceGetHeightSubspace(), PetscDualSpaceGetPointSubspace()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetHeightSubspace
PETSc.LibPETSc.PetscDualSpaceGetInteriorData — Method
intNodes::PetscQuadrature,intMat::PetscMat = PetscDualSpaceGetInteriorData(petsclib::PetscLibType, sp::PetscDualSpace)Get all quadrature points necessary to compute the interior degrees of freedom from this space, as well as the matrix that computes the degrees of freedom from the quadrature values.
Input Parameter:
sp- The dualspace
Output Parameters:
intNodes- APetscQuadratureobject containing all evaluation points needed to evaluate interior degrees of freedom,
pass NULL if not needed
intMat- A matrix that computes dual space values from point values: size [spdim0 x (npoints * nc)], where spdim0 is
the size of the constrained layout (PetscSectionGetConstrainStorageSize()) of the dual space section, npoints is the number of points in intNodes and nc is PetscDualSpaceGetNumComponents(). Pass NULL if not needed
Level: advanced
See also: PetscDualSpace, PetscQuadrature, Mat, PetscDualSpaceCreate(), PetscDualSpaceGetDimension(), PetscDualSpaceGetNumComponents(), PetscQuadratureGetData()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetInteriorData
PETSc.LibPETSc.PetscDualSpaceGetInteriorDimension — Method
intdim::PetscInt = PetscDualSpaceGetInteriorDimension(petsclib::PetscLibType, sp::PetscDualSpace)Get the interior dimension of the dual space, i.e. the number of basis functionals assigned to the interior of the reference domain
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
intdim- The dimension
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceGetFunctional(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetInteriorDimension
PETSc.LibPETSc.PetscDualSpaceGetInteriorSection — Method
section::PetscSection = PetscDualSpaceGetInteriorSection(petsclib::PetscLibType, sp::PetscDualSpace)Create a PetscSection over the reference cell with the layout from this space for interior degrees of freedom
Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
section- The interior section
Level: advanced
See also: PetscDualSpace, PetscSection, PetscDualSpaceCreate(), DMPLEX
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetInteriorSection
PETSc.LibPETSc.PetscDualSpaceGetNumComponents — Method
Nc::PetscInt = PetscDualSpaceGetNumComponents(petsclib::PetscLibType, sp::PetscDualSpace)Return the number of components for this space
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
Nc- The number of components
Level: intermediate
See also: PetscDualSpaceSetNumComponents(), PetscDualSpaceGetDimension(), PetscDualSpaceCreate(), PetscDualSpace
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetNumComponents
PETSc.LibPETSc.PetscDualSpaceGetNumDof — Method
numDof::Ptr{PetscInt} = PetscDualSpaceGetNumDof(petsclib::PetscLibType, sp::PetscDualSpace)Get the number of degrees of freedom for each spatial (topological) dimension
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
numDof- An array of length dim+1 which holds the number of dofs for each dimension
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceGetFunctional(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetNumDof
PETSc.LibPETSc.PetscDualSpaceGetOrder — Method
order::PetscInt = PetscDualSpaceGetOrder(petsclib::PetscLibType, sp::PetscDualSpace)Get the order of the dual space
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
order- The order
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceSetOrder(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetOrder
PETSc.LibPETSc.PetscDualSpaceGetPointSubspace — Method
bdsp::PetscDualSpace = PetscDualSpaceGetPointSubspace(petsclib::PetscLibType, sp::PetscDualSpace, point::PetscInt)Get the subset of the dual space basis that is supported on a particular mesh point.
Not Collective
Input Parameters:
sp- thePetscDualSpaceobjectpoint- the point (in the dual space's DM) for which the subspace is desired
Output Parameter:
bdsp- the subspace.
Level: advanced
See also: PetscDualSpace, PetscDualSpaceGetHeightSubspace()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetPointSubspace
PETSc.LibPETSc.PetscDualSpaceGetSection — Method
section::PetscSection = PetscDualSpaceGetSection(petsclib::PetscLibType, sp::PetscDualSpace)Create a PetscSection over the reference cell with the layout from this space
Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
section- The section
Level: advanced
See also: PetscDualSpace, PetscSection, PetscDualSpaceCreate(), DMPLEX
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetSection
PETSc.LibPETSc.PetscDualSpaceGetSymmetries — Method
perms::Ptr{PetscInt},flips::Ptr{PetscScalar} = PetscDualSpaceGetSymmetries(petsclib::PetscLibType, sp::PetscDualSpace)Returns a description of the symmetries of this basis
Not Collective
Input Parameter:
sp- thePetscDualSpaceobject
Output Parameters:
perms- Permutations of the interior degrees of freedom, parameterized by the point orientationflips- Sign reversal of the interior degrees of freedom, parameterized by the point orientation
Level: developer
See also: PetscDualSpace
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetSymmetries
PETSc.LibPETSc.PetscDualSpaceGetType — Method
name::String = PetscDualSpaceGetType(petsclib::PetscLibType, sp::PetscDualSpace)Gets the PetscDualSpaceType name (as a string) from the object.
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
name- ThePetscDualSpaceTypename
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceType, PetscDualSpaceSetType(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetType
PETSc.LibPETSc.PetscDualSpaceGetUniform — Method
uniform::PetscBool = PetscDualSpaceGetUniform(petsclib::PetscLibType, sp::PetscDualSpace)Whether this dual space is uniform
Not Collective
Input Parameter:
sp- A dual space
Output Parameter:
uniform-PETSC_TRUEif (a) the dual space is the same for each point in a stratum of the referenceDMPLEX, and
(b) every symmetry of each point in the reference DMPLEX is also a symmetry of the point's dual space.
Level: advanced
See also: PetscDualSpace, PetscDualSpaceGetPointSubspace(), PetscDualSpaceGetSymmetries()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceGetUniform
PETSc.LibPETSc.PetscDualSpaceLagrangeGetContinuity — Method
continuous::PetscBool = PetscDualSpaceLagrangeGetContinuity(petsclib::PetscLibType, sp::PetscDualSpace)Retrieves the flag for element continuity
Not Collective
Input Parameter:
sp- thePetscDualSpace
Output Parameter:
continuous- flag for element continuity
Level: intermediate
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeSetContinuity()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeGetContinuity
PETSc.LibPETSc.PetscDualSpaceLagrangeGetMomentOrder — Method
order::PetscInt = PetscDualSpaceLagrangeGetMomentOrder(petsclib::PetscLibType, sp::PetscDualSpace)Get the order for moment integration
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
order- Moment integration order
Level: advanced
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeSetMomentOrder()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeGetMomentOrder
PETSc.LibPETSc.PetscDualSpaceLagrangeGetNodeType — Method
nodeType::PetscDTNodeType,boundary::PetscBool,exponent::PetscReal = PetscDualSpaceLagrangeGetNodeType(petsclib::PetscLibType, sp::PetscDualSpace)Get a description of how nodes are laid out for Lagrange polynomials in this dual space
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameters:
nodeType- The type of nodesboundary- Whether the node type is one that includes endpoints (if nodeType isPETSCDTNODES_GAUSSJACOBI, nodes that
include the boundary are Gauss-Lobatto-Jacobi nodes)
exponent- If nodeType isPETSCDTNODES_GAUSSJACOBI, indicates the exponent used for both ends of the 1D Jacobi weight function
'0' is Gauss-Legendre, '-0.5' is Gauss-Chebyshev of the first type, '0.5' is Gauss-Chebyshev of the second type
Level: advanced
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDTNodeType, PetscDualSpaceLagrangeSetNodeType()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeGetNodeType
PETSc.LibPETSc.PetscDualSpaceLagrangeGetTensor — Method
tensor::PetscBool = PetscDualSpaceLagrangeGetTensor(petsclib::PetscLibType, sp::PetscDualSpace)Get the tensor nature of the dual space
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
tensor- Whether the dual space has tensor layout (vs. simplicial)
Level: intermediate
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeSetTensor(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeGetTensor
PETSc.LibPETSc.PetscDualSpaceLagrangeGetTrimmed — Method
trimmed::PetscBool = PetscDualSpaceLagrangeGetTrimmed(petsclib::PetscLibType, sp::PetscDualSpace)Get the trimmed nature of the dual space
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
trimmed- Whether the dual space represents to dual basis of a trimmed polynomial space (e.g. Raviart-Thomas and higher order / other form degree variants)
Level: intermediate
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeSetTrimmed(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeGetTrimmed
PETSc.LibPETSc.PetscDualSpaceLagrangeGetUseMoments — Method
useMoments::PetscBool = PetscDualSpaceLagrangeGetUseMoments(petsclib::PetscLibType, sp::PetscDualSpace)Get the flag for using moment functionals
Not Collective
Input Parameter:
sp- ThePetscDualSpace
Output Parameter:
useMoments- Moment flag
Level: advanced
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeSetUseMoments()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeGetUseMoments
PETSc.LibPETSc.PetscDualSpaceLagrangeSetContinuity — Method
PetscDualSpaceLagrangeSetContinuity(petsclib::PetscLibType, sp::PetscDualSpace, continuous::PetscBool)Indicate whether the element is continuous
Logically Collective
Input Parameters:
sp- thePetscDualSpacecontinuous- flag for element continuity
Options Database Key:
-petscdualspace_lagrange_continuity (true|false)- use a continuous element
Level: intermediate
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeGetContinuity()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeSetContinuity
PETSc.LibPETSc.PetscDualSpaceLagrangeSetMomentOrder — Method
PetscDualSpaceLagrangeSetMomentOrder(petsclib::PetscLibType, sp::PetscDualSpace, order::PetscInt)Set the order for moment integration
Logically Collective
Input Parameters:
sp- ThePetscDualSpaceorder- The order for moment integration
Level: advanced
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeGetMomentOrder()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeSetMomentOrder
PETSc.LibPETSc.PetscDualSpaceLagrangeSetNodeType — Method
PetscDualSpaceLagrangeSetNodeType(petsclib::PetscLibType, sp::PetscDualSpace, nodeType::PetscDTNodeType, boundary::PetscBool, exponent::PetscReal)Set a description of how nodes are laid out for Lagrange polynomials in this dual space
Logically Collective
Input Parameters:
sp- ThePetscDualSpacenodeType- The type of nodesboundary- Whether the node type is one that includes endpoints (if nodeType isPETSCDTNODES_GAUSSJACOBI, nodes that
include the boundary are Gauss-Lobatto-Jacobi nodes)
exponent- If nodeType isPETSCDTNODES_GAUSSJACOBI, indicates the exponent used for both ends of the 1D Jacobi weight function
'0' is Gauss-Legendre, '-0.5' is Gauss-Chebyshev of the first type, '0.5' is Gauss-Chebyshev of the second type
Level: advanced
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDTNodeType, PetscDualSpaceLagrangeGetNodeType()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeSetNodeType
PETSc.LibPETSc.PetscDualSpaceLagrangeSetTensor — Method
PetscDualSpaceLagrangeSetTensor(petsclib::PetscLibType, sp::PetscDualSpace, tensor::PetscBool)Set the tensor nature of the dual space
Not Collective
Input Parameters:
sp- ThePetscDualSpacetensor- Whether the dual space has tensor layout (vs. simplicial)
Level: intermediate
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeGetTensor(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeSetTensor
PETSc.LibPETSc.PetscDualSpaceLagrangeSetTrimmed — Method
PetscDualSpaceLagrangeSetTrimmed(petsclib::PetscLibType, sp::PetscDualSpace, trimmed::PetscBool)Set the trimmed nature of the dual space
Not Collective
Input Parameters:
sp- ThePetscDualSpacetrimmed- Whether the dual space represents to dual basis of a trimmed polynomial space (e.g. Raviart-Thomas and higher order / other form degree variants)
Level: intermediate
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeGetTrimmed(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeSetTrimmed
PETSc.LibPETSc.PetscDualSpaceLagrangeSetUseMoments — Method
PetscDualSpaceLagrangeSetUseMoments(petsclib::PetscLibType, sp::PetscDualSpace, useMoments::PetscBool)Set the flag for moment functionals
Logically Collective
Input Parameters:
sp- ThePetscDualSpaceuseMoments- The flag for moment functionals
Level: advanced
See also: PETSCDUALSPACELAGRANGE, PetscDualSpace, PetscDualSpaceLagrangeGetUseMoments()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceLagrangeSetUseMoments
PETSc.LibPETSc.PetscDualSpacePullback — Method
PetscDualSpacePullback(petsclib::PetscLibType, dsp::PetscDualSpace, fegeom::Vector{PetscFEGeom}, Nq::PetscInt, Nc::PetscInt, pointEval::Vector{PetscScalar})Transform the given functional so that it operates on real space, rather than the reference element. Operationally, this means that we map the function evaluations depending on continuity requirements of our finite element method.
Input Parameters:
dsp- ThePetscDualSpacefegeom- The geometry for this cellNq- The number of function samplesNc- The number of function componentspointEval- The function values
Output Parameter:
pointEval- The transformed function values
Level: advanced
See also: PetscDualSpace, PetscDualSpacePushforward(), PetscDualSpaceTransform(), PetscDualSpaceGetDeRahm()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpacePullback
PETSc.LibPETSc.PetscDualSpacePushforward — Method
PetscDualSpacePushforward(petsclib::PetscLibType, dsp::PetscDualSpace, fegeom::Vector{PetscFEGeom}, Nq::PetscInt, Nc::PetscInt, pointEval::Vector{PetscScalar})Transform the given function so that it operates on real space, rather than the reference element. Operationally, this means that we map the function evaluations depending on continuity requirements of our finite element method.
Input Parameters:
dsp- ThePetscDualSpacefegeom- The geometry for this cellNq- The number of function samplesNc- The number of function componentspointEval- The function values
Output Parameter:
pointEval- The transformed function values
Level: advanced
See also: PetscDualSpace, PetscDualSpacePullback(), PetscDualSpaceTransform(), PetscDualSpaceGetDeRahm()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpacePushforward
PETSc.LibPETSc.PetscDualSpacePushforwardGradient — Method
PetscDualSpacePushforwardGradient(petsclib::PetscLibType, dsp::PetscDualSpace, fegeom::Vector{PetscFEGeom}, Nq::PetscInt, Nc::PetscInt, pointEval::Vector{PetscScalar})Transform the given function gradient so that it operates on real space, rather than the reference element. Operationally, this means that we map the function evaluations depending on continuity requirements of our finite element method.
Input Parameters:
dsp- ThePetscDualSpacefegeom- The geometry for this cellNq- The number of function gradient samplesNc- The number of function componentspointEval- The function gradient values
Output Parameter:
pointEval- The transformed function gradient values
Level: advanced
See also: PetscDualSpace, PetscDualSpacePushforward(), PetscDualSpacePullback(), PetscDualSpaceTransform(), PetscDualSpaceGetDeRahm()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpacePushforwardGradient
PETSc.LibPETSc.PetscDualSpacePushforwardHessian — Method
PetscDualSpacePushforwardHessian(petsclib::PetscLibType, dsp::PetscDualSpace, fegeom::Vector{PetscFEGeom}, Nq::PetscInt, Nc::PetscInt, pointEval::Vector{PetscScalar})Transform the given function Hessian so that it operates on real space, rather than the reference element. Operationally, this means that we map the function evaluations depending on continuity requirements of our finite element method.
Input Parameters:
dsp- ThePetscDualSpacefegeom- The geometry for this cellNq- The number of function Hessian samplesNc- The number of function componentspointEval- The function gradient values
Output Parameter:
pointEval- The transformed function Hessian values
Level: advanced
See also: PetscDualSpace, PetscDualSpacePushforward(), PetscDualSpacePullback(), PetscDualSpaceTransform(), PetscDualSpaceGetDeRahm()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpacePushforwardHessian
PETSc.LibPETSc.PetscDualSpaceRefinedSetCellSpaces — Method
PetscDualSpaceRefinedSetCellSpaces(petsclib::PetscLibType, sp::PetscDualSpace, cellSpaces::Vector{PetscDualSpace})Set the dual spaces for the closures of each of the cells in the multicell DM of a PetscDualSpace
Collective
Input Parameters:
sp- aPetscDualSpacecellSpaces- onePetscDualSpacefor each of the cells. The reference count of each cell space will be incremented,
so the user is still responsible for these spaces afterwards
Level: intermediate
See also: PETSCDUALSPACEREFINED, PetscDualSpace, PetscFERefine()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceRefinedSetCellSpaces
PETSc.LibPETSc.PetscDualSpaceRegister — Method
PetscDualSpaceRegister(petsclib::PetscLibType, sname::String, fnc::external)Adds a new PetscDualSpaceType
Not Collective, No Fortran Support
Input Parameters:
sname- The name of a new user-defined creation routinefunction- The creation routine
See also: PetscDualSpace, PetscDualSpaceType, PetscDualSpaceRegisterAll(), PetscDualSpaceRegisterDestroy()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceRegister
PETSc.LibPETSc.PetscDualSpaceSetDM — Method
PetscDualSpaceSetDM(petsclib::PetscLibType, sp::PetscDualSpace, dm::AbstractPetscDM)Get the DM representing the reference cell
Not Collective
Input Parameters:
sp- ThePetscDualSpacedm- The reference cell
Level: intermediate
See also: PetscDualSpace, DM, PetscDualSpaceGetDM(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetDM
PETSc.LibPETSc.PetscDualSpaceSetFormDegree — Method
PetscDualSpaceSetFormDegree(petsclib::PetscLibType, dsp::PetscDualSpace, k::PetscInt)Set the form degree k for the k-form the describes the pushforwards/pullbacks of this dual space's functionals.
Input Parameters:
dsp- ThePetscDualSpacek- The signed degree k of the k. If k >= 0, this means that the degrees of freedom are k-forms, and are stored
in lexicographic order according to the basis of k-forms constructed from the wedge product of 1-forms. So for example, the 1-form basis in 3-D is (dx, dy, dz), and the 2-form basis in 3-D is (dx wedge dy, dx wedge dz, dy wedge dz). If k < 0, this means that the degrees transform as k-forms, but are stored as (N-k) forms according to the Hodge star map. So for example if k = -2 and N = 3, this means that the degrees of freedom transform as 2-forms but are stored as 1-forms.
Level: developer
See also: PetscDualSpace, PetscDTAltV, PetscDualSpacePullback(), PetscDualSpacePushforward(), PetscDualSpaceTransform(), PetscDualSpaceTransformType
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetFormDegree
PETSc.LibPETSc.PetscDualSpaceSetFromOptions — Method
PetscDualSpaceSetFromOptions(petsclib::PetscLibType, sp::PetscDualSpace)sets parameters in a PetscDualSpace from the options database
Collective
Input Parameter:
sp- thePetscDualSpaceobject to set options for
Options Database Keys:
-petscdualspace_order order- the approximation order of the space-petscdualspace_form_degree deg- the form degree, say 0 for point evaluations, or 2 for area integrals-petscdualspace_components c- the number of components, say d for a vector field-petscdualspace_refcell celltype- Reference cell type name-petscdualspace_lagrange_continuity (true|false)- Flag for continuous element-petscdualspace_lagrange_tensor (true|false)- Flag for tensor dual space-petscdualspace_lagrange_trimmed (true|false)- Flag for trimmed dual space-petscdualspace_lagrange_node_type nodetype- Lagrange node location type-petscdualspace_lagrange_node_endpoints (true|false)- Flag for nodes that include endpoints-petscdualspace_lagrange_node_exponent exponent- Gauss-Jacobi weight function exponent-petscdualspace_lagrange_use_moments (true|false)- Use moments (where appropriate) for functionals-petscdualspace_lagrange_moment_order order- Quadrature order for moment functionals
Level: intermediate
See also: PetscDualSpaceView(), PetscDualSpace, PetscObjectSetFromOptions()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetFromOptions
PETSc.LibPETSc.PetscDualSpaceSetNumComponents — Method
PetscDualSpaceSetNumComponents(petsclib::PetscLibType, sp::PetscDualSpace, Nc::PetscInt)Set the number of components for this space
Input Parameters:
sp- ThePetscDualSpaceNc- The number of components
Level: intermediate
See also: PetscDualSpaceGetNumComponents(), PetscDualSpaceCreate(), PetscDualSpace
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetNumComponents
PETSc.LibPETSc.PetscDualSpaceSetOrder — Method
PetscDualSpaceSetOrder(petsclib::PetscLibType, sp::PetscDualSpace, order::PetscInt)Set the order of the dual space
Not Collective
Input Parameters:
sp- ThePetscDualSpaceorder- The order
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceGetOrder(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetOrder
PETSc.LibPETSc.PetscDualSpaceSetType — Method
PetscDualSpaceSetType(petsclib::PetscLibType, sp::PetscDualSpace, name::String)Builds a particular PetscDualSpace based on its PetscDualSpaceType
Collective
Input Parameters:
sp- ThePetscDualSpaceobjectname- The kind of space
Options Database Key:
-petscdualspace_type type- Sets thePetscDualSpacetype; seePetscDualSpaceTypefor the choices
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceType, PetscDualSpaceGetType(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetType
PETSc.LibPETSc.PetscDualSpaceSetUp — Method
PetscDualSpaceSetUp(petsclib::PetscLibType, sp::PetscDualSpace)Construct a basis for a PetscDualSpace
Collective
Input Parameter:
sp- thePetscDualSpaceobject to setup
Level: intermediate
See also: PetscDualSpaceView(), PetscDualSpaceDestroy(), PetscDualSpace
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSetUp
PETSc.LibPETSc.PetscDualSpaceSimpleSetDimension — Method
PetscDualSpaceSimpleSetDimension(petsclib::PetscLibType, sp::PetscDualSpace, dim::PetscInt)Set the number of functionals in the dual space basis
Logically Collective
Input Parameters:
sp- thePetscDualSpacedim- the basis dimension
Level: intermediate
See also: PETSCDUALSPACESIMPLE, PetscDualSpace, PetscDualSpaceSimpleSetFunctional()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSimpleSetDimension
PETSc.LibPETSc.PetscDualSpaceSimpleSetFunctional — Method
PetscDualSpaceSimpleSetFunctional(petsclib::PetscLibType, sp::PetscDualSpace, func::PetscInt, q::PetscQuadrature)Set the given basis functional for this dual space
Not Collective
Input Parameters:
sp- thePetscDualSpacefunc- the basis indexq- the basis functional
Level: intermediate
See also: PETSCDUALSPACESIMPLE, PetscDualSpace, PetscDualSpaceSimpleSetDimension()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSimpleSetFunctional
PETSc.LibPETSc.PetscDualSpaceSumGetConcatenate — Method
concatenate::PetscBool = PetscDualSpaceSumGetConcatenate(petsclib::PetscLibType, sp::PetscDualSpace)Get the concatenate flag for this space.
Input Parameter:
sp- the dual space object
Output Parameter:
concatenate- flag indicating whether subspaces are concatenated.
Level: intermediate
See also: PETSCDUALSPACESUM, PetscDualSpace, PetscDualSpaceSumSetConcatenate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumGetConcatenate
PETSc.LibPETSc.PetscDualSpaceSumGetInterleave — Method
interleave_basis::PetscBool,interleave_components::PetscBool = PetscDualSpaceSumGetInterleave(petsclib::PetscLibType, sp::PetscDualSpace)Get whether the basis functions and components of a uniform sum are interleaved
Logically collective
Input Parameter:
sp- aPetscDualSpaceof typePETSCDUALSPACESUM
Output Parameters:
interleave_basis- ifPETSC_TRUE, the basis vectors of the subspaces are interleavedinterleave_components- ifPETSC_TRUEand the space concatenates components (PetscDualSpaceSumGetConcatenate()),
interleave the concatenated components
Level: developer
See also: PetscDualSpace, PETSCDUALSPACESUM, PETSCFEVECTOR, PetscDualSpaceSumSetInterleave()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumGetInterleave
PETSc.LibPETSc.PetscDualSpaceSumGetNumSubspaces — Method
numSumSpaces::PetscInt = PetscDualSpaceSumGetNumSubspaces(petsclib::PetscLibType, sp::PetscDualSpace)Get the number of spaces in the sum space
Input Parameter:
sp- the dual space object
Output Parameter:
numSumSpaces- the number of spaces
Level: intermediate
See also: PETSCDUALSPACESUM, PetscDualSpace, PetscDualSpaceSumSetNumSubspaces()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumGetNumSubspaces
PETSc.LibPETSc.PetscDualSpaceSumGetSubspace — Method
subsp::PetscDualSpace = PetscDualSpaceSumGetSubspace(petsclib::PetscLibType, sp::PetscDualSpace, s::PetscInt)Get a space in the sum space
Input Parameters:
sp- the dual space objects- The space number
Output Parameter:
subsp- thePetscDualSpace
Level: intermediate
See also: PETSCDUALSPACESUM, PetscDualSpace, PetscDualSpaceSumSetSubspace()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumGetSubspace
PETSc.LibPETSc.PetscDualSpaceSumSetConcatenate — Method
PetscDualSpaceSumSetConcatenate(petsclib::PetscLibType, sp::PetscDualSpace, concatenate::PetscBool)Sets the concatenate flag for this space.
Input Parameters:
sp- the dual space objectconcatenate- are subspaces concatenated components (true) or direct summands (false)
Level: intermediate
See also: PETSCDUALSPACESUM, PetscDualSpace, PetscDualSpaceSumGetConcatenate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumSetConcatenate
PETSc.LibPETSc.PetscDualSpaceSumSetInterleave — Method
PetscDualSpaceSumSetInterleave(petsclib::PetscLibType, sp::PetscDualSpace, interleave_basis::PetscBool, interleave_components::PetscBool)Set whether the basis functions and components of a uniform sum are interleaved
Logically collective
Input Parameters:
sp- aPetscDualSpaceof typePETSCDUALSPACESUMinterleave_basis- ifPETSC_TRUE, the basis vectors of the subspaces are interleavedinterleave_components- ifPETSC_TRUEand the space concatenates components (PetscDualSpaceSumGetConcatenate()),
interleave the concatenated components
Level: developer
See also: PetscDualSpace, PETSCDUALSPACESUM, PETSCFEVECTOR, PetscDualSpaceSumGetInterleave()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumSetInterleave
PETSc.LibPETSc.PetscDualSpaceSumSetNumSubspaces — Method
PetscDualSpaceSumSetNumSubspaces(petsclib::PetscLibType, sp::PetscDualSpace, numSumSpaces::PetscInt)Set the number of spaces in the sum space
Input Parameters:
sp- the dual space objectnumSumSpaces- the number of spaces
Level: intermediate
See also: PETSCDUALSPACESUM, PetscDualSpace, PetscDualSpaceSumGetNumSubspaces()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumSetNumSubspaces
PETSc.LibPETSc.PetscDualSpaceSumSetSubspace — Method
PetscDualSpaceSumSetSubspace(petsclib::PetscLibType, sp::PetscDualSpace, s::PetscInt, subsp::PetscDualSpace)Set a space in the sum space
Input Parameters:
sp- the dual space objects- The space numbersubsp- the number of spaces
Level: intermediate
See also: PETSCDUALSPACESUM, PetscDualSpace, PetscDualSpaceSumGetSubspace()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceSumSetSubspace
PETSc.LibPETSc.PetscDualSpaceTransform — Method
PetscDualSpaceTransform(petsclib::PetscLibType, dsp::PetscDualSpace, trans::PetscDualSpaceTransformType, isInverse::PetscBool, fegeom::Vector{PetscFEGeom}, Nv::PetscInt, Nc::PetscInt, vals::Vector{PetscScalar})Transform the function values
Input Parameters:
dsp- ThePetscDualSpacetrans- The type of transformisInverse- Flag to invert the transformfegeom- The cell geometryNv- The number of function samplesNc- The number of function componentsvals- The function values
Output Parameter:
vals- The transformed function values
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceTransformGradient(), PetscDualSpaceTransformHessian(), PetscDualSpacePullback(), PetscDualSpacePushforward(), PetscDualSpaceTransformType
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceTransform
PETSc.LibPETSc.PetscDualSpaceTransformGradient — Method
PetscDualSpaceTransformGradient(petsclib::PetscLibType, dsp::PetscDualSpace, trans::PetscDualSpaceTransformType, isInverse::PetscBool, fegeom::Vector{PetscFEGeom}, Nv::PetscInt, Nc::PetscInt, vals::Vector{PetscScalar})Transform the function gradient values
Input Parameters:
dsp- ThePetscDualSpacetrans- The type of transformisInverse- Flag to invert the transformfegeom- The cell geometryNv- The number of function gradient samplesNc- The number of function componentsvals- The function gradient values
Output Parameter:
vals- The transformed function gradient values
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceTransform(), PetscDualSpacePullback(), PetscDualSpacePushforward(), PetscDualSpaceTransformType
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceTransformGradient
PETSc.LibPETSc.PetscDualSpaceTransformHessian — Method
PetscDualSpaceTransformHessian(petsclib::PetscLibType, dsp::PetscDualSpace, trans::PetscDualSpaceTransformType, isInverse::PetscBool, fegeom::Vector{PetscFEGeom}, Nv::PetscInt, Nc::PetscInt, vals::Vector{PetscScalar})Transform the function Hessian values
Input Parameters:
dsp- ThePetscDualSpacetrans- The type of transformisInverse- Flag to invert the transformfegeom- The cell geometryNv- The number of function Hessian samplesNc- The number of function componentsvals- The function gradient values
Output Parameter:
vals- The transformed function Hessian values
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceTransform(), PetscDualSpacePullback(), PetscDualSpacePushforward(), PetscDualSpaceTransformType
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceTransformHessian
PETSc.LibPETSc.PetscDualSpaceView — Method
PetscDualSpaceView(petsclib::PetscLibType, sp::PetscDualSpace, v::PetscViewer)Views a PetscDualSpace
Collective
Input Parameters:
sp- thePetscDualSpaceobject to viewv- the viewer
Level: beginner
See also: PetscViewer, PetscDualSpaceDestroy(), PetscDualSpace
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceView
PETSc.LibPETSc.PetscDualSpaceViewFromOptions — Method
PetscDualSpaceViewFromOptions(petsclib::PetscLibType, A::PetscDualSpace, obj, name::String)View a PetscDualSpace based on values in the options database
Collective
Input Parameters:
A- thePetscDualSpaceobjectobj- Optional object, provides the options prefixname- command line option name
Options Database Key:
-name [viewertype][:...]- option name and values. SeePetscObjectViewFromOptions()for the possible arguments
Level: intermediate
See also: PetscDualSpace, PetscDualSpaceView(), PetscObjectViewFromOptions(), PetscDualSpaceCreate()
External Links
- PETSc Manual:
DUALSPACE/PetscDualSpaceViewFromOptions
PetscFV
PETSc.LibPETSc.PetscFVClone — Method
fvNew::PetscFV = PetscFVClone(petsclib::PetscLibType, fv::PetscFV)Create a shallow copy of a PetscFV object that just references the internal objects.
Input Parameter:
fv- The initialPetscFV
Output Parameter:
fvNew- A clone of thePetscFV
Level: advanced
See also: PetscFV, PetscFVType, PetscFVCreate(), PetscFVSetType()
External Links
- PETSc Manual:
FV/PetscFVClone
PETSc.LibPETSc.PetscFVComputeGradient — Method
PetscFVComputeGradient(petsclib::PetscLibType, fvm::PetscFV, numFaces::PetscInt, dx::Vector{PetscScalar}, grad::Vector{PetscScalar})Compute the gradient reconstruction matrix for a given cell
Input Parameters:
fvm- ThePetscFVobjectnumFaces- The number of cell faces which are not constraineddx- The vector from the cell centroid to the neighboring cell centroid for each face
Output Parameter:
grad- the gradient
Level: advanced
See also: PetscFV, PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVComputeGradient
PETSc.LibPETSc.PetscFVCreate — Method
fvm::PetscFV = PetscFVCreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscFV object. The type can then be set with PetscFVSetType().
Collective
Input Parameter:
comm- The communicator for thePetscFVobject
Output Parameter:
fvm- ThePetscFVobject
Level: beginner
See also: PetscFVSetUp(), PetscFVSetType(), PETSCFVUPWIND, PetscFVDestroy()
External Links
- PETSc Manual:
FV/PetscFVCreate
PETSc.LibPETSc.PetscFVCreateDualSpace — Method
PetscFVCreateDualSpace(petsclib::PetscLibType, fvm::PetscFV, ct::DMPolytopeType)Creates a PetscDualSpace appropriate for the PetscFV
Not Collective
Input Parameters:
fvm- ThePetscFVobjectct- TheDMPolytopeTypefor the cell
Level: intermediate
See also: PetscFVGetDualSpace(), PetscFVSetDualSpace(), PetscDualSpace, PetscFV, PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVCreateDualSpace
PETSc.LibPETSc.PetscFVCreateTabulation — Method
T::PetscTabulation = PetscFVCreateTabulation(petsclib::PetscLibType, fvm::PetscFV, nrepl::PetscInt, npoints::PetscInt, points::Vector{PetscReal}, K::PetscInt)Tabulates the basis functions, and perhaps derivatives, at the points provided.
Not Collective
Input Parameters:
fvm- ThePetscFVobjectnrepl- The number of replicasnpoints- The number of tabulation points in a replicapoints- The tabulation point coordinatesK- The order of derivative to tabulate
Output Parameter:
T- The basis function values and derivative at tabulation points
Level: intermediate
See also: PetscFV, PetscTabulation, PetscFECreateTabulation(), PetscTabulationDestroy(), PetscFEGetCellTabulation()
External Links
- PETSc Manual:
FV/PetscFVCreateTabulation
PETSc.LibPETSc.PetscFVDestroy — Method
PetscFVDestroy(petsclib::PetscLibType, fvm::Union{PetscFV, Ref{PetscFV}})Destroys a PetscFV object
Collective
Input Parameter:
fvm- thePetscFVobject to destroy
Level: beginner
See also: PetscFV, PetscFVCreate(), PetscFVView()
External Links
- PETSc Manual:
FV/PetscFVDestroy
PETSc.LibPETSc.PetscFVFinalizePackage — Method
PetscFVFinalizePackage(petsclib::PetscLibType)This function finalizes everything in the PetscFV package. It is called from PetscFinalize().
Level: developer
See also: PetscInitialize()
External Links
- PETSc Manual:
DM/PetscFVFinalizePackage
PETSc.LibPETSc.PetscFVGetCellTabulation — Method
T::PetscTabulation = PetscFVGetCellTabulation(petsclib::PetscLibType, fvm::PetscFV)Returns the tabulation of the basis functions at the quadrature points
Not Collective
Input Parameter:
fvm- ThePetscFVobject
Output Parameter:
T- The basis function values and derivatives at quadrature points
Level: intermediate
See also: PetscFV, PetscTabulation, PetscFEGetCellTabulation(), PetscFVCreateTabulation(), PetscFVGetQuadrature(), PetscQuadratureGetData()
External Links
- PETSc Manual:
FV/PetscFVGetCellTabulation
PETSc.LibPETSc.PetscFVGetComponentName — Method
name::String = PetscFVGetComponentName(petsclib::PetscLibType, fvm::PetscFV, comp::PetscInt)Get the name of a component (used in output and viewing) in a PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectcomp- the component number
Output Parameter:
name- the component name
Level: intermediate
See also: PetscFV, PetscFVSetComponentName()
External Links
- PETSc Manual:
FV/PetscFVGetComponentName
PETSc.LibPETSc.PetscFVGetComputeGradients — Method
computeGradients::PetscBool = PetscFVGetComputeGradients(petsclib::PetscLibType, fvm::PetscFV)Return flag for computation of cell gradients on a PetscFV
Not Collective
Input Parameter:
fvm- thePetscFVobject
Output Parameter:
computeGradients- Flag to compute cell gradients
Level: intermediate
See also: PetscFV, PetscFVSetComputeGradients()
External Links
- PETSc Manual:
FV/PetscFVGetComputeGradients
PETSc.LibPETSc.PetscFVGetDualSpace — Method
sp::PetscDualSpace = PetscFVGetDualSpace(petsclib::PetscLibType, fvm::PetscFV)Returns the PetscDualSpace used to define the inner product on a PetscFV
Not Collective
Input Parameter:
fvm- ThePetscFVobject
Output Parameter:
sp- ThePetscDualSpaceobject
Level: intermediate
See also: PetscFVSetDualSpace(), PetscFVCreateDualSpace(), PetscDualSpace, PetscFV, PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVGetDualSpace
PETSc.LibPETSc.PetscFVGetLimiter — Method
lim::PetscLimiter = PetscFVGetLimiter(petsclib::PetscLibType, fvm::PetscFV)Get the PetscLimiter object from the PetscFV
Not Collective
Input Parameter:
fvm- thePetscFVobject
Output Parameter:
lim- ThePetscLimiter
Level: intermediate
See also: PetscFV, PetscLimiter, PetscFVSetLimiter()
External Links
- PETSc Manual:
FV/PetscFVGetLimiter
PETSc.LibPETSc.PetscFVGetNumComponents — Method
comp::PetscInt = PetscFVGetNumComponents(petsclib::PetscLibType, fvm::PetscFV)Get the number of field components in a PetscFV
Not Collective
Input Parameter:
fvm- thePetscFVobject
Output Parameter:
comp- The number of components
Level: intermediate
See also: PetscFV, PetscFVSetNumComponents(), PetscFVSetComponentName()
External Links
- PETSc Manual:
FV/PetscFVGetNumComponents
PETSc.LibPETSc.PetscFVGetQuadrature — Method
q::PetscQuadrature = PetscFVGetQuadrature(petsclib::PetscLibType, fvm::PetscFV)Get the PetscQuadrature from a PetscFV
Not Collective
Input Parameter:
fvm- thePetscFVobject
Output Parameter:
q- ThePetscQuadrature
Level: intermediate
See also: PetscQuadrature, PetscFV, PetscFVSetQuadrature()
External Links
- PETSc Manual:
FV/PetscFVGetQuadrature
PETSc.LibPETSc.PetscFVGetSpatialDimension — Method
dim::PetscInt = PetscFVGetSpatialDimension(petsclib::PetscLibType, fvm::PetscFV)Get the spatial dimension of a PetscFV
Not Collective
Input Parameter:
fvm- thePetscFVobject
Output Parameter:
dim- The spatial dimension
Level: intermediate
See also: PetscFV, PetscFVSetSpatialDimension()
External Links
- PETSc Manual:
FV/PetscFVGetSpatialDimension
PETSc.LibPETSc.PetscFVGetType — Method
name::String = PetscFVGetType(petsclib::PetscLibType, fvm::PetscFV)Gets the PetscFVType (as a string) from a PetscFV.
Not Collective
Input Parameter:
fvm- ThePetscFV
Output Parameter:
name- ThePetscFVTypename
Level: intermediate
See also: PetscFV, PetscFVType, PetscFVSetType(), PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVGetType
PETSc.LibPETSc.PetscFVInitializePackage — Method
PetscFVInitializePackage(petsclib::PetscLibType)This function initializes everything in the PetscFV package. It is called from PetscDLLibraryRegister() when using dynamic libraries, and on the first call to PetscFVCreate() when using static libraries.
Level: developer
See also: PetscInitialize()
External Links
- PETSc Manual:
DM/PetscFVInitializePackage
PETSc.LibPETSc.PetscFVIntegrateRHSFunction — Method
neighborVol::PetscReal = PetscFVIntegrateRHSFunction(petsclib::PetscLibType, fvm::PetscFV, prob::PetscDS, field::PetscInt, Nf::PetscInt, fgeom::Vector{PetscFVFaceGeom}, uL::Vector{PetscScalar}, uR::Vector{PetscScalar}, fluxL::Vector{PetscScalar}, fluxR::Vector{PetscScalar})Produce the cell residual vector for a chunk of elements by quadrature integration
Not Collective
Input Parameters:
fvm- ThePetscFVobject for the field being integratedprob- ThePetscDSspecifying the discretizations and continuum functionsfield- The field being integratedNf- The number of faces in the chunkfgeom- The face geometry for each face in the chunkneighborVol- The volume for each pair of cells in the chunkuL- The state from the cell on the leftuR- The state from the cell on the right
Output Parameters:
fluxL- the left fluxes for each facefluxR- the right fluxes for each face
Level: developer
See also: PetscFV, PetscDS, PetscFVFaceGeom, PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVIntegrateRHSFunction
PETSc.LibPETSc.PetscFVLeastSquaresSetMaxFaces — Method
PetscFVLeastSquaresSetMaxFaces(petsclib::PetscLibType, fvm::PetscFV, maxFaces::PetscInt)Set the maximum number of cell faces for gradient reconstruction
Not Collective
Input Parameters:
fvm- ThePetscFVobjectmaxFaces- The maximum number of cell faces
Level: intermediate
See also: PetscFV, PetscFVCreate(), PETSCFVLEASTSQUARES, PetscFVComputeGradient()
External Links
- PETSc Manual:
FV/PetscFVLeastSquaresSetMaxFaces
PETSc.LibPETSc.PetscFVRefine — Method
fvRef::PetscFV = PetscFVRefine(petsclib::PetscLibType, fv::PetscFV)Create a "refined" PetscFV object that refines the reference cell into smaller copies.
Input Parameter:
fv- The initialPetscFV
Output Parameter:
fvRef- The refinedPetscFV
Level: advanced
See also: PetscFV, PetscFVType, PetscFVCreate(), PetscFVSetType()
External Links
- PETSc Manual:
FV/PetscFVRefine
PETSc.LibPETSc.PetscFVRegister — Method
PetscFVRegister(petsclib::PetscLibType, sname::String, fnc::external)Adds a new PetscFV implementation
Not Collective, No Fortran Support
Input Parameters:
sname- The name of a new user-defined creation routinefunction- The creation routine itself
See also: PetscFV, PetscFVType, PetscFVRegisterAll(), PetscFVRegisterDestroy()
External Links
- PETSc Manual:
FV/PetscFVRegister
PETSc.LibPETSc.PetscFVSetComponentName — Method
PetscFVSetComponentName(petsclib::PetscLibType, fvm::PetscFV, comp::PetscInt, name::String)Set the name of a component (used in output and viewing) in a PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectcomp- the component numbername- the component name
Level: intermediate
See also: PetscFV, PetscFVGetComponentName()
External Links
- PETSc Manual:
FV/PetscFVSetComponentName
PETSc.LibPETSc.PetscFVSetComputeGradients — Method
PetscFVSetComputeGradients(petsclib::PetscLibType, fvm::PetscFV, computeGradients::PetscBool)Toggle computation of cell gradients on a PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectcomputeGradients- Flag to compute cell gradients
Level: intermediate
See also: PetscFV, PetscFVGetComputeGradients()
External Links
- PETSc Manual:
FV/PetscFVSetComputeGradients
PETSc.LibPETSc.PetscFVSetDualSpace — Method
PetscFVSetDualSpace(petsclib::PetscLibType, fvm::PetscFV, sp::PetscDualSpace)Sets the PetscDualSpace used to define the inner product
Not Collective
Input Parameters:
fvm- ThePetscFVobjectsp- ThePetscDualSpaceobject
Level: intermediate
See also: PetscFVGetDualSpace(), PetscFVCreateDualSpace(), PetscDualSpace, PetscFV, PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVSetDualSpace
PETSc.LibPETSc.PetscFVSetFromOptions — Method
PetscFVSetFromOptions(petsclib::PetscLibType, fvm::PetscFV)sets parameters in a PetscFV from the options database
Collective
Input Parameter:
fvm- thePetscFVobject to set options for
Options Database Key:
-petscfv_compute_gradients (true|false)- Determines whether cell gradients are calculated
Level: intermediate
See also: PetscFV, PetscFVView()
External Links
- PETSc Manual:
FV/PetscFVSetFromOptions
PETSc.LibPETSc.PetscFVSetLimiter — Method
PetscFVSetLimiter(petsclib::PetscLibType, fvm::PetscFV, lim::PetscLimiter)Set the PetscLimiter to the PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectlim- ThePetscLimiter
Level: intermediate
See also: PetscFV, PetscLimiter, PetscFVGetLimiter()
External Links
- PETSc Manual:
FV/PetscFVSetLimiter
PETSc.LibPETSc.PetscFVSetNumComponents — Method
PetscFVSetNumComponents(petsclib::PetscLibType, fvm::PetscFV, comp::PetscInt)Set the number of field components in a PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectcomp- The number of components
Level: intermediate
See also: PetscFV, PetscFVGetNumComponents()
External Links
- PETSc Manual:
FV/PetscFVSetNumComponents
PETSc.LibPETSc.PetscFVSetQuadrature — Method
PetscFVSetQuadrature(petsclib::PetscLibType, fvm::PetscFV, q::PetscQuadrature)Set the PetscQuadrature object for a PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectq- ThePetscQuadrature
Level: intermediate
See also: PetscQuadrature, PetscFV, PetscFVGetQuadrature()
External Links
- PETSc Manual:
FV/PetscFVSetQuadrature
PETSc.LibPETSc.PetscFVSetSpatialDimension — Method
PetscFVSetSpatialDimension(petsclib::PetscLibType, fvm::PetscFV, dim::PetscInt)Set the spatial dimension of a PetscFV
Logically Collective
Input Parameters:
fvm- thePetscFVobjectdim- The spatial dimension
Level: intermediate
See also: PetscFV, PetscFVGetSpatialDimension()
External Links
- PETSc Manual:
FV/PetscFVSetSpatialDimension
PETSc.LibPETSc.PetscFVSetType — Method
PetscFVSetType(petsclib::PetscLibType, fvm::PetscFV, name::String)Builds a particular PetscFV
Collective
Input Parameters:
fvm- ThePetscFVobjectname- The type of FVM space
Options Database Key:
-petscfv_type type- Sets thePetscFVType; use -help for a list of available types
Level: intermediate
See also: PetscFV, PetscFVType, PetscFVGetType(), PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVSetType
PETSc.LibPETSc.PetscFVSetUp — Method
PetscFVSetUp(petsclib::PetscLibType, fvm::PetscFV)Setup the data structures for the PetscFV based on the PetscFVType provided by PetscFVSetType()
Collective
Input Parameter:
fvm- thePetscFVobject to setup
Level: intermediate
See also: PetscFV, PetscFVView(), PetscFVDestroy()
External Links
- PETSc Manual:
FV/PetscFVSetUp
PETSc.LibPETSc.PetscFVView — Method
PetscFVView(petsclib::PetscLibType, fvm::PetscFV, v::PetscViewer)Views a PetscFV
Collective
Input Parameters:
fvm- thePetscFVobject to viewv- the viewer
Level: beginner
See also: PetscFV, PetscViewer, PetscFVDestroy()
External Links
- PETSc Manual:
FV/PetscFVView
PETSc.LibPETSc.PetscFVViewFromOptions — Method
PetscFVViewFromOptions(petsclib::PetscLibType, A::PetscFV, obj, name::String)View a PetscFV based on values in the options database
Collective
Input Parameters:
A- thePetscFVobjectobj- Optional object that provides the options prefixname- command line option name
Options Database Key:
-name [viewertype][:...]- option name and values. SeePetscObjectViewFromOptions()for the possible arguments
Level: intermediate
See also: PetscFV, PetscFVView(), PetscObjectViewFromOptions(), PetscFVCreate()
External Links
- PETSc Manual:
FV/PetscFVViewFromOptions
PetscLimiter
PETSc.LibPETSc.PetscLimiterCreate — Method
lim::PetscLimiter = PetscLimiterCreate(petsclib::PetscLibType, comm::MPI_Comm)Creates an empty PetscLimiter object. The type can then be set with PetscLimiterSetType().
Collective
Input Parameter:
comm- The communicator for thePetscLimiterobject
Output Parameter:
lim- ThePetscLimiterobject
Level: beginner
See also: PetscLimiter, PetscLimiterType, PetscLimiterSetType(), PETSCLIMITERSIN
External Links
- PETSc Manual:
FV/PetscLimiterCreate
PETSc.LibPETSc.PetscLimiterDestroy — Method
PetscLimiterDestroy(petsclib::PetscLibType, lim::Union{PetscLimiter, Ref{PetscLimiter}})Destroys a PetscLimiter object
Collective
Input Parameter:
lim- thePetscLimiterobject to destroy
Level: beginner
See also: PetscLimiter, PetscLimiterView()
External Links
- PETSc Manual:
FV/PetscLimiterDestroy
PETSc.LibPETSc.PetscLimiterGetType — Method
name::String = PetscLimiterGetType(petsclib::PetscLibType, lim::PetscLimiter)Gets the PetscLimiterType name (as a string) from the PetscLimiter.
Not Collective
Input Parameter:
lim- ThePetscLimiter
Output Parameter:
name- ThePetscLimiterType
Level: intermediate
See also: PetscLimiter, PetscLimiterType, PetscLimiterSetType(), PetscLimiterCreate()
External Links
- PETSc Manual:
FV/PetscLimiterGetType
PETSc.LibPETSc.PetscLimiterLimit — Method
phi::PetscReal = PetscLimiterLimit(petsclib::PetscLibType, lim::PetscLimiter, flim::PetscReal)Limit the flux
Input Parameters:
lim- ThePetscLimiterflim- The input field
Output Parameter:
phi- The limited field
Level: beginner
See also: PetscLimiter, PetscLimiterType, PetscLimiterSetType(), PetscLimiterCreate()
External Links
- PETSc Manual:
FV/PetscLimiterLimit
PETSc.LibPETSc.PetscLimiterRegister — Method
PetscLimiterRegister(petsclib::PetscLibType, sname::String, fnc::external)Adds a new PetscLimiter implementation
Not Collective, No Fortran Support
Input Parameters:
sname- The name of a new user-defined creation routinefunction- The creation routine
See also: PetscLimiter, PetscLimiterType, PetscLimiterRegisterAll(), PetscLimiterRegisterDestroy()
External Links
- PETSc Manual:
FV/PetscLimiterRegister
PETSc.LibPETSc.PetscLimiterSetFromOptions — Method
PetscLimiterSetFromOptions(petsclib::PetscLibType, lim::PetscLimiter)sets parameters in a PetscLimiter from the options database
Collective
Input Parameter:
lim- thePetscLimiterobject to set options for
Level: intermediate
See also: PetscLimiter, PetscLimiterView()
External Links
- PETSc Manual:
FV/PetscLimiterSetFromOptions
PETSc.LibPETSc.PetscLimiterSetType — Method
PetscLimiterSetType(petsclib::PetscLibType, lim::PetscLimiter, name::String)Builds a PetscLimiter for a given PetscLimiterType
Collective
Input Parameters:
lim- ThePetscLimiterobjectname- The kind of limiter
Options Database Key:
-petsclimiter_type type- Sets the PetscLimiter type; use -help for a list of available types
Level: intermediate
See also: PetscLimiter, PetscLimiterType, PetscLimiterGetType(), PetscLimiterCreate()
External Links
- PETSc Manual:
FV/PetscLimiterSetType
PETSc.LibPETSc.PetscLimiterSetUp — Method
PetscLimiterSetUp(petsclib::PetscLibType, lim::PetscLimiter)Construct data structures for the PetscLimiter
Collective
Input Parameter:
lim- thePetscLimiterobject to setup
Level: intermediate
See also: PetscLimiter, PetscLimiterView(), PetscLimiterDestroy()
External Links
- PETSc Manual:
FV/PetscLimiterSetUp
PETSc.LibPETSc.PetscLimiterView — Method
PetscLimiterView(petsclib::PetscLibType, lim::PetscLimiter, v::PetscViewer)Views a PetscLimiter
Collective
Input Parameters:
lim- thePetscLimiterobject to viewv- the viewer
Level: beginner
See also: PetscLimiter, PetscViewer, PetscLimiterDestroy(), PetscLimiterViewFromOptions()
External Links
- PETSc Manual:
FV/PetscLimiterView
PETSc.LibPETSc.PetscLimiterViewFromOptions — Method
PetscLimiterViewFromOptions(petsclib::PetscLibType, A::PetscLimiter, obj, name::String)View a PetscLimiter based on values in the options database
Collective
Input Parameters:
A- thePetscLimiterobject to viewobj- Optional object that provides the options prefix to usename- command line option name
Options Database Key:
-name [viewertype][:...]- option name and values. SeePetscObjectViewFromOptions()for the possible arguments
Level: intermediate
See also: PetscLimiter, PetscLimiterView(), PetscObjectViewFromOptions(), PetscLimiterCreate()
External Links
- PETSc Manual:
FV/PetscLimiterViewFromOptions
PetscConvEst
PETSc.LibPETSc.PetscConvEstComputeError — Method
PetscConvEstComputeError(petsclib::PetscLibType, ce::PetscConvEst, r::PetscInt, dm::AbstractPetscDM, u::AbstractPetscVec, errors::Vector{PetscReal})Compute per-field discretization errors of u on refinement level r
Collective
Input Parameters:
ce- thePetscConvEstobjectr- the refinement leveldm- theDMon whichuis defined (may beNULL)u- the computed solution
Output Parameter:
errors- array of lengthNf(number of fields in the DS) filled with the error in each field
Level: developer
See also: PetscConvEst, PetscConvEstComputeInitialGuess(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstComputeError
PETSc.LibPETSc.PetscConvEstComputeInitialGuess — Method
PetscConvEstComputeInitialGuess(petsclib::PetscLibType, ce::PetscConvEst, r::PetscInt, dm::AbstractPetscDM, u::AbstractPetscVec)Fill u with the initial guess to use on refinement level r of a convergence-estimation run
Collective
Input Parameters:
ce- thePetscConvEstobjectr- the refinement leveldm- theDMon whichuis defined (may beNULL)
Output Parameter:
u- the initial-guess vector
Level: developer
See also: PetscConvEst, PetscConvEstComputeError(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstComputeInitialGuess
PETSc.LibPETSc.PetscConvEstCreate — Method
ce::PetscConvEst = PetscConvEstCreate(petsclib::PetscLibType, comm::MPI_Comm)Create a PetscConvEst object. This is used to study the convergence rate of approximations on grids to a continuum solution
Collective
Input Parameter:
comm- The communicator for thePetscConvEstobject
Output Parameter:
ce- ThePetscConvEstobject
Level: beginner
See also: PetscConvEst, PetscConvEstDestroy(), PetscConvEstGetConvRate(), DMAdaptorCreate(), DMAdaptor
External Links
- PETSc Manual:
SNES/PetscConvEstCreate
PETSc.LibPETSc.PetscConvEstDestroy — Method
PetscConvEstDestroy(petsclib::PetscLibType, ce::Union{PetscConvEst, Ref{PetscConvEst}})Destroys a PETSc convergence estimator PetscConvEst object
Collective
Input Parameter:
ce- ThePetscConvEstobject
Level: beginner
See also: PetscConvEst, PetscConvEstCreate(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstDestroy
PETSc.LibPETSc.PetscConvEstGetConvRate — Method
PetscConvEstGetConvRate(petsclib::PetscLibType, ce::PetscConvEst, alpha::Vector{PetscReal})Returns an estimate of the convergence rate for the discretization
Not Collective
Input Parameter:
ce- ThePetscConvEstobject
Output Parameter:
alpha- The convergence rate for each field
Options Database Keys:
-snes_convergence_estimate- Execute convergence estimation insideSNESSolve()and print out the rate-ts_convergence_estimate- Execute convergence estimation insideTSSolve()and print out the rate
Level: intermediate
See also: PetscConvEstSetSolver(), PetscConvEstCreate(), SNESSolve(), TSSolve()
External Links
- PETSc Manual:
SNES/PetscConvEstGetConvRate
PETSc.LibPETSc.PetscConvEstGetSolver — Method
solver::PetscObject = PetscConvEstGetSolver(petsclib::PetscLibType, ce::PetscConvEst)Gets the solver used to produce discrete solutions
Not Collective
Input Parameter:
ce- ThePetscConvEstobject
Output Parameter:
solver- The solver
Level: intermediate
See also: PetscConvEst, PetscConvEstSetSolver(), PetscConvEstCreate(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstGetSolver
PETSc.LibPETSc.PetscConvEstMonitorDefault — Method
PetscConvEstMonitorDefault(petsclib::PetscLibType, ce::PetscConvEst, r::PetscInt)Monitors the convergence estimation loop
Collective
Input Parameters:
ce- ThePetscConvEstobjectr- The refinement level
Options Database Key:
-convest_monitor- Activate the monitor
Level: intermediate
See also: PetscConvEst, PetscConvEstCreate(), PetscConvEstGetConvRate(), SNESSolve(), TSSolve()
External Links
- PETSc Manual:
SNES/PetscConvEstMonitorDefault
PETSc.LibPETSc.PetscConvEstRateView — Method
PetscConvEstRateView(petsclib::PetscLibType, ce::PetscConvEst, alpha::Vector{PetscReal}, viewer::PetscViewer)Displays the convergence rate obtained from PetscConvEstGetConvRate() using a PetscViewer
Collective
Input Parameters:
ce- iterative context obtained fromSNESCreate()alpha- the convergence rate for each fieldviewer- the viewer to display the reason
Options Database Key:
-snes_convergence_estimate- print the convergence rate
Level: developer
See also: PetscConvEst, PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstRateView
PETSc.LibPETSc.PetscConvEstSetFromOptions — Method
PetscConvEstSetFromOptions(petsclib::PetscLibType, ce::PetscConvEst)Sets a convergence estimator PetscConvEst object based on values in the options database
Collective
Input Parameter:
ce- ThePetscConvEstobject
Level: beginner
See also: PetscConvEst, PetscConvEstCreate(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstSetFromOptions
PETSc.LibPETSc.PetscConvEstSetSolver — Method
PetscConvEstSetSolver(petsclib::PetscLibType, ce::PetscConvEst, solver)Sets the solver used to produce discrete solutions
Not Collective
Input Parameters:
ce- ThePetscConvEstobjectsolver- The solver, must be aKSP,SNES, orTSobject with an attachedDM/DS, that can compute an exact solution
Level: intermediate
See also: PetscConvEst, PetscConvEstGetSNES(), PetscConvEstCreate(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstSetSolver
PETSc.LibPETSc.PetscConvEstSetUp — Method
PetscConvEstSetUp(petsclib::PetscLibType, ce::PetscConvEst)After the solver is specified, create data structures needed for estimating convergence
Collective
Input Parameter:
ce- ThePetscConvEstobject
Level: beginner
See also: PetscConvEst, PetscConvEstCreate(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstSetUp
PETSc.LibPETSc.PetscConvEstUseTS — Method
PetscConvEstUseTS(petsclib::PetscLibType, ce::PetscConvEst, checkTemporal::PetscBool)Configure a PetscConvEst object to use a TS solver for a convergence study
Not Collective
Input Parameters:
ce- the convergence estimatorcheckTemporal-PETSC_TRUEto run a temporal convergence study (refining the time step),PETSC_FALSEto run a spatial convergence study (refining the mesh)
Level: intermediate
See also: PetscConvEst, TS, PetscConvEstGetConvRate()
External Links
- PETSc Manual:
TS/PetscConvEstUseTS
PETSc.LibPETSc.PetscConvEstView — Method
PetscConvEstView(petsclib::PetscLibType, ce::PetscConvEst, viewer::PetscViewer)Views a PetscConvEst object
Collective
Input Parameters:
ce- ThePetscConvEstobjectviewer- ThePetscViewer
Level: beginner
See also: PetscConvEst, PetscViewer, PetscConvEstCreate(), PetscConvEstGetConvRate()
External Links
- PETSc Manual:
SNES/PetscConvEstView