![]() |
v0.16.3 |
Public Member Functions | |
| ConstrainMatrixCtxImpl (MPI_Comm comm, DM x_dm, DM y_dm) | |
| ConstrainMatrixCtxImpl (MPI_Comm comm, VecScatter scatter) | |
| ~ConstrainMatrixCtxImpl () override=default | |
| MoFEMErrorCode | setConstrainMatrix (Mat constrain_matrix, Mat inverse_cct) override |
| Mat | getConstrainMatrix () const override |
| Mat | getInverseCCT () const override |
| MoFEMErrorCode | setSystemMatrix (Mat system_matrix) override |
| Mat | getSystemMatrix () const override |
| MoFEMErrorCode | initializeQorP (Vec x) override |
| MoFEMErrorCode | initializeQTKQ () override |
| MoFEMErrorCode | recalculateCT () override |
| MoFEMErrorCode | recalculateCTC () override |
| MoFEMErrorCode | applyQ (Vec x, Vec f) override |
| MoFEMErrorCode | applyP (Vec x, Vec f) override |
| MoFEMErrorCode | applyR (Vec x, Vec f) override |
| MoFEMErrorCode | applyRT (Vec x, Vec f) override |
| MoFEMErrorCode | applyCTC_QTKQ (Vec x, Vec f) override |
Public Member Functions inherited from MoFEM::ConstrainMatrixCtx | |
| virtual | ~ConstrainMatrixCtx ()=default |
Private Member Functions | |
| MoFEMErrorCode | invalidateProjectionData () |
| MoFEMErrorCode | invalidateSystemData () |
| MoFEMErrorCode | validatePetscObject (PetscObject object, const char *object_name) const |
| MoFEMErrorCode | validateVectorLayout (Vec vec, PetscInt local_size, PetscInt global_size, const char *vector_name) const |
| MoFEMErrorCode | validateInverseCCTLayout (Mat constrain_matrix, Mat inverse_cct) const |
| MoFEMErrorCode | validateSystemMatrixLayout () const |
| MoFEMErrorCode | applyInverseCCT (Vec x, Vec f, bool transpose) |
| MoFEMErrorCode | applyQImpl (Vec x, Vec f, bool transpose_inverse) |
Private Attributes | |
| MPI_Comm | comm |
| SmartPetscObj< DM > | xDm |
| SmartPetscObj< DM > | yDm |
| SmartPetscObj< Mat > | C |
| SmartPetscObj< Mat > | CT |
| SmartPetscObj< Mat > | inverseCCT |
| SmartPetscObj< Mat > | CTC |
| SmartPetscObj< Mat > | K |
| SmartPetscObj< Vec > | Cx |
| SmartPetscObj< Vec > | CCTm1Cx |
| SmartPetscObj< Vec > | CTCCTm1Cx |
| SmartPetscObj< Vec > | CTCx |
| SmartPetscObj< Vec > | X |
| SmartPetscObj< Vec > | Qx |
| SmartPetscObj< Vec > | KQx |
| SmartPetscObj< VecScatter > | scatter |
| bool | projectionInitialized = false |
| bool | qtkqInitialized = false |
| bool | buildScatterFromDms = true |
| PetscInt | fullLocalSize = 0 |
| PetscInt | fullGlobalSize = 0 |
Definition at line 115 of file ConstrainMatrixCtx.cpp.
| MoFEM::ConstrainMatrixCtxImpl::ConstrainMatrixCtxImpl | ( | MPI_Comm | comm, |
| DM | x_dm, | ||
| DM | y_dm | ||
| ) |
Definition at line 180 of file ConstrainMatrixCtx.cpp.
| MoFEM::ConstrainMatrixCtxImpl::ConstrainMatrixCtxImpl | ( | MPI_Comm | comm, |
| VecScatter | scatter | ||
| ) |
Definition at line 185 of file ConstrainMatrixCtx.cpp.
|
overridedefault |
|
overridevirtual |
Apply C^T C + Q^T K Q.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 658 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 525 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Apply P = C^T S C for the supplied inverse action S.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 575 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Apply Q = I - C^T S C for the supplied inverse action S.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 563 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 545 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Apply R = C^T S for the supplied inverse action S.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 599 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Apply R^T = S^T C for the supplied inverse action S.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 630 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Get the constraint matrix C.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 355 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Get the supplied inverse action for C C^T.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 357 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Get the matrix K used by C^T C + Q^T K Q.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 367 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Initialize matrices, vectors, and the scatter used by Q, P, R, and R^T. The operation is idempotent until the C/inverse-action pair is replaced.
| x | Vector defining the full problem layout. |
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 369 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Initialize matrices and work vectors used by C^T C + Q^T K Q. The operation is idempotent until C or K is replaced.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 472 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 329 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 319 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Recalculate C^T after an in-place value change in C. The layout and nonzero structure of C must be unchanged. The caller must update the supplied inverse action in the same transaction. Projection MATSHELL objects already created from this context do not receive a PETSc state increment; recreate them before passing the changed operator to a consumer which caches by matrix state.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 460 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Recalculate C^T C after an in-place value change in C. The layout and nonzero structure of C must be unchanged.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 515 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Set the constraint matrix C and its row-space inverse action atomically.
inverse_cct represents (C C^T)^-1 on the selected constraint space, or the corresponding embedded generalized inverse for a masked full space. It must have the row layout of C in both dimensions and support MatMult(). MatMultTranspose() is additionally required by applyRT() and applyCTC_QTKQ(). Both PETSc objects are retained.
All data derived from the previous pair are invalidated. For in-place value changes which preserve layouts and sparsity, update inverse_cct in the same transaction and call recalculateCT() and recalculateCTC().
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 345 of file ConstrainMatrixCtx.cpp.
|
overridevirtual |
Set the matrix K used by C^T C + Q^T K Q and retain a PETSc reference. Work vectors derived from the previous K are invalidated.
Implements MoFEM::ConstrainMatrixCtx.
Definition at line 359 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 236 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 192 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 290 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 215 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 174 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 158 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 164 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 154 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 159 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 161 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 165 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 166 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 163 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 177 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 176 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 160 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 162 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 169 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 172 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 173 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 168 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 170 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 167 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 155 of file ConstrainMatrixCtx.cpp.
|
private |
Definition at line 156 of file ConstrainMatrixCtx.cpp.