petsc4py.PETSc.DualSpace
- class petsc4py.PETSc.DualSpace
Bases:
Object
Dual space to a linear space.
Enumerations
The dual space types.
Methods Summary
create
([comm])Create an empty
DualSpace
object.destroy
()Destroy the
DualSpace
object.Create a duplicate
DualSpace
object that is not set up.getDM
()Return the
DM
representing the reference cell of aDualSpace
.Return the dimension of the dual space.
Return the i-th basis functional in the dual space.
Return the interior dimension of the dual space.
Return whether the element is continuous.
Return the tensor nature of the dual space.
Return the trimmed nature of the dual space.
Return the number of components for this space.
Return the number of degrees of freedom for each spatial dimension.
getOrder
()Return the order of the dual space.
getType
()Return the type of the dual space object.
setDM
(dm)Set the
DM
representing the reference cell.setLagrangeContinuity
(continuous)Indicate whether the element is continuous.
setLagrangeTensor
(tensor)Set the tensor nature of the dual space.
setLagrangeTrimmed
(trimmed)Set the trimmed nature of the dual space.
setNumComponents
(nc)Set the number of components for this space.
setOrder
(order)Set the order of the dual space.
setSimpleDimension
(dim)Set the number of functionals in the dual space basis.
setSimpleFunctional
(func, functional)Set the given basis element for this dual space.
setType
(dualspace_type)Build a particular type of dual space.
setUp
()Construct a basis for a
DualSpace
.view
([viewer])View a
DualSpace
.Methods Documentation
- create(comm=None)
Create an empty
DualSpace
object.Collective.
The type can then be set with
setType
.- Parameters:
comm (Comm | None) – MPI communicator, defaults to
Sys.getDefaultComm
.- Return type:
See also
petsc.PetscDualSpaceCreate
- destroy()
Destroy the
DualSpace
object.Collective.
See also
petsc.PetscDualSpaceDestroy
Source code at petsc4py/PETSc/Space.pyx:635
- Return type:
- duplicate()
Create a duplicate
DualSpace
object that is not set up.Collective.
See also
petsc.PetscDualSpaceDuplicate
Source code at petsc4py/PETSc/Space.pyx:648
- Return type:
- getDM()
Return the
DM
representing the reference cell of aDualSpace
.Not collective.
See also
setDM
,petsc.PetscDualSpaceGetDM
Source code at petsc4py/PETSc/Space.pyx:661
- Return type:
- getDimension()
Return the dimension of the dual space.
Not collective.
The dimension of the dual space, i.e. the number of basis functionals.
See also
petsc.PetscDualSpaceGetDimension
Source code at petsc4py/PETSc/Space.pyx:692
- Return type:
- getFunctional(i)
Return the i-th basis functional in the dual space.
Not collective.
See also
petsc.PetscDualSpaceGetFunctional
- getInteriorDimension()
Return the interior dimension of the dual space.
Not collective.
The interior dimension of the dual space, i.e. the number of basis functionals assigned to the interior of the reference domain.
See also
petsc.PetscDualSpaceGetInteriorDimension
Source code at petsc4py/PETSc/Space.pyx:842
- Return type:
- getLagrangeContinuity()
Return whether the element is continuous.
Not collective.
See also
setLagrangeContinuity
,petsc.PetscDualSpaceLagrangeGetContinuity
Source code at petsc4py/PETSc/Space.pyx:859
- Return type:
- getLagrangeTensor()
Return the tensor nature of the dual space.
Not collective.
See also
setLagrangeTensor
,petsc.PetscDualSpaceLagrangeGetTensor
Source code at petsc4py/PETSc/Space.pyx:891
- Return type:
- getLagrangeTrimmed()
Return the trimmed nature of the dual space.
Not collective.
See also
setLagrangeTrimmed
,petsc.PetscDualSpaceLagrangeGetTrimmed
Source code at petsc4py/PETSc/Space.pyx:923
- Return type:
- getNumComponents()
Return the number of components for this space.
Not collective.
See also
setNumComponents
,petsc.PetscDualSpaceGetNumComponents
Source code at petsc4py/PETSc/Space.pyx:708
- Return type:
- getNumDof()
Return the number of degrees of freedom for each spatial dimension.
Not collective.
See also
petsc.PetscDualSpaceGetNumDof
Source code at petsc4py/PETSc/Space.pyx:806
- Return type:
- getOrder()
Return the order of the dual space.
Not collective.
See also
setOrder
,petsc.PetscDualSpaceGetOrder
Source code at petsc4py/PETSc/Space.pyx:774
- Return type:
- getType()
Return the type of the dual space object.
Not collective.
See also
setType
,petsc.PetscDualSpaceGetType
Source code at petsc4py/PETSc/Space.pyx:740
- Return type:
- setDM(dm)
Set the
DM
representing the reference cell.Not collective.
See also
getDM
,petsc.PetscDualSpaceSetDM
- setLagrangeContinuity(continuous)
Indicate whether the element is continuous.
Not collective.
See also
getLagrangeContinuity
,petsc.PetscDualSpaceLagrangeSetContinuity
- setLagrangeTensor(tensor)
Set the tensor nature of the dual space.
Not collective.
- Parameters:
tensor (bool) – Whether the dual space has tensor layout (vs. simplicial).
- Return type:
See also
getLagrangeTensor
,petsc.PetscDualSpaceLagrangeSetTensor
- setLagrangeTrimmed(trimmed)
Set the trimmed nature of the dual space.
Not collective.
- Parameters:
trimmed (bool) – Whether the dual space represents to dual basis of a trimmed polynomial space (e.g. Raviart-Thomas and higher order / other form degree variants).
- Return type:
See also
getLagrangeTrimmed
,petsc.PetscDualSpaceLagrangeSetTrimmed
- setNumComponents(nc)
Set the number of components for this space.
Logically collective.
See also
getNumComponents
,petsc.PetscDualSpaceSetNumComponents
- setOrder(order)
Set the order of the dual space.
Not collective.
See also
getOrder
,petsc.PetscDualSpaceSetOrder
- setSimpleDimension(dim)
Set the number of functionals in the dual space basis.
Logically collective.
See also
petsc.PetscDualSpaceSimpleSetDimension
- setSimpleFunctional(func, functional)
Set the given basis element for this dual space.
Not collective.
- Parameters:
- Return type:
See also
petsc.PetscDualSpaceSimpleSetFunctional
- setType(dualspace_type)
Build a particular type of dual space.
Collective.
See also
getType
,petsc.PetscDualSpaceSetType
- setUp()
Construct a basis for a
DualSpace
.Collective.
See also
petsc.PetscDualSpaceSetUp
Source code at petsc4py/PETSc/Space.pyx:581
- Return type: