Chaste Release::3.1
|
#include <StokesFlowPreconditionerAssembler.hpp>
Public Member Functions | |
StokesFlowPreconditionerAssembler (QuadraticMesh< DIM > *pMesh, StokesFlowProblemDefinition< DIM > *pProblemDefinition) | |
Private Member Functions | |
c_matrix< double, PRESSURE_BLOCK_SIZE_ELEMENTAL, PRESSURE_BLOCK_SIZE_ELEMENTAL > | ComputePressurePressureMatrixTerm (c_vector< double, NUM_VERTICES_PER_ELEMENT > &rLinearPhi, c_matrix< double, DIM, NUM_VERTICES_PER_ELEMENT > &rGradLinearPhi, c_vector< double, DIM > &rX, Element< DIM, DIM > *pElement) |
Static Private Attributes | |
static const unsigned | NUM_VERTICES_PER_ELEMENT = DIM+1 |
static const unsigned | PRESSURE_BLOCK_SIZE_ELEMENTAL = NUM_VERTICES_PER_ELEMENT |
Assembler for setting up (volume-integral parts of) the preconditioner matrix used in the FEM solver Stokes' Flow.
The system matrix has the block form (except see comment below) [A B] [B^T 0] In contrast, the preconditioner is: [A B] [B^T M]
The class therefore just needs to inherit from StokesFlowAssembler, which will assemble the A,B,B^T terms, and it just has to overload the pressure-pressure block method.
NOTE: The elemental matrix and vector is as above. The full matrix and vector uses a completely different ordering: for parallelisation reasons the pressure variables are interleaved with the spatial variables and dummy pressure variables are used for internal nodes. For example, in 2d, the ordering is [U1 V1 P1 , .. , Un Vn, Pn] where n is the total number of nodes.
Definition at line 65 of file StokesFlowPreconditionerAssembler.hpp.
StokesFlowPreconditionerAssembler< DIM >::StokesFlowPreconditionerAssembler | ( | QuadraticMesh< DIM > * | pMesh, |
StokesFlowProblemDefinition< DIM > * | pProblemDefinition | ||
) | [inline] |
Constructor
pMesh | mesh |
pProblemDefinition | problem definition |
Definition at line 106 of file StokesFlowPreconditionerAssembler.hpp.
c_matrix<double,PRESSURE_BLOCK_SIZE_ELEMENTAL,PRESSURE_BLOCK_SIZE_ELEMENTAL> StokesFlowPreconditionerAssembler< DIM >::ComputePressurePressureMatrixTerm | ( | c_vector< double, NUM_VERTICES_PER_ELEMENT > & | rLinearPhi, |
c_matrix< double, DIM, NUM_VERTICES_PER_ELEMENT > & | rGradLinearPhi, | ||
c_vector< double, DIM > & | rX, | ||
Element< DIM, DIM > * | pElement | ||
) | [inline, private, virtual] |
For a continuum mechanics problem in mixed form (displacement-pressure or velocity-pressure), the matrix has the form (except see comments about ordering above) [A B1] [B2^T C ] The function is related to the pressure-pressure block, i.e. C
The method just returns C=M, the mass matrix.
rLinearPhi | All the linear basis functions on this element, evaluated at the current quad point |
rGradLinearPhi | Gradients of all the linear basis functions on this element, evaluated at the current quad point |
rX | Current location (physical position) |
pElement | Current element |
Reimplemented from AbstractContinuumMechanicsAssembler< DIM, true, true >.
Definition at line 91 of file StokesFlowPreconditionerAssembler.hpp.
const unsigned StokesFlowPreconditionerAssembler< DIM >::NUM_VERTICES_PER_ELEMENT = DIM+1 [static, private] |
Number of vertices per element
Reimplemented from StokesFlowAssembler< DIM >.
Definition at line 69 of file StokesFlowPreconditionerAssembler.hpp.
const unsigned StokesFlowPreconditionerAssembler< DIM >::PRESSURE_BLOCK_SIZE_ELEMENTAL = NUM_VERTICES_PER_ELEMENT [static, private] |
Size of the pressure block, per element, equal num_vertices times 1 (as p solved for at each vertex.
Reimplemented from StokesFlowAssembler< DIM >.
Definition at line 75 of file StokesFlowPreconditionerAssembler.hpp.