22 for (
int i = 0; i<ess_tdof_list.
Size(); i++)
24 int tdof = ess_tdof_list[i];
96 R->
SetBlock(i,i,const_cast<SparseMatrix*>(R_));
104 Vector &B,
int copy_interior)
126 for (
int j = 0; j<
nblocks; j++)
129 for (
int i = 0; i <
ess_tdofs[j]->Size(); i++)
158 const int remove_zeros = 0;
195 for (
int i = 0; i<
nblocks; i++)
212 for (
int i = 0; i<
nblocks; i++)
void EliminateRowsCols(const Array< int > &rows_cols, const HypreParVector &X, HypreParVector &B)
int owns_blocks
If owns_blocks the SparseMatrix objects Aij will be deallocated.
void SetSize(int s)
Resize the vector to size s.
Pointer to an Operator of a specified type.
int Width() const
Get the width (size of input) of the Operator. Synonym with NumCols().
int Size() const
Returns the size of the vector.
void FormSystemMatrix(Operator::DiagonalPolicy diag_policy)
HypreParMatrix * ParMult(const HypreParMatrix *A, const HypreParMatrix *B, bool own_matrix)
Operator & GetBlock(int i, int j)
Return a reference to block i,j.
void SetBlock(int i, int j, SparseMatrix *mat)
Set A(i,j) = mat.
void ReduceSystem(Vector &x, Vector &X, Vector &B, int copy_interior=0) const
Set the reduced solution X and r.h.s B vectors from the full linear system solution x and r...
bool HasEliminatedBC() const
void RAP(const DenseMatrix &A, const DenseMatrix &P, DenseMatrix &RAP)
void SetSubVectorComplement(const Array< int > &dofs, const double val)
Set all vector entries NOT in the dofs Array to the given val.
virtual void MultTranspose(const Vector &x, Vector &y) const
Action of the transpose operator.
HypreParMatrix * EliminateCols(const Array< int > &cols)
virtual void Mult(const Vector &x, Vector &y) const
Operator application.
virtual void Mult(const Vector &x, Vector &y) const
Matrix-Vector Multiplication y = A*x.
int Height() const
Get the height (size of output) of the Operator. Synonym with NumRows().
HypreParMatrix * Transpose() const
Returns the transpose of *this.
void SetEssentialTrueDofs(const Array< int > &ess_tdof_list)
Determine and save internally essential reduced true dofs.
void EliminateRows(const Array< int > &rows)
Eliminate rows from the diagonal and off-diagonal blocks of the matrix.
SparseMatrix & GetBlock(int i, int j)
Return a reference to block (i,j). Reference may be invalid if Aij(i,j) == NULL.
int Size() const
Return the logical size of the array.
void ComputeSolution(const Vector &sc_sol, Vector &sol) const
Wrapper for hypre's ParCSR matrix class.
A class to handle Block systems in a matrix-free implementation.
BlockOperator & GetParallelSchurMatrix()
Return the parallel Schur complement matrix.
void SetBlock(int iRow, int iCol, Operator *op, double c=1.0)
Add a block op in the block-entry (iblock, jblock).
int IsZeroBlock(int i, int j) const
Check if block (i,j) is a zero block.
void Reset(OpType *A, bool own_A=true)
Reset the OperatorHandle to the given OpType pointer, A.