Komplex_LinearProblem Class Reference

Komplex_LinearProblem: A class for explicitly eliminating matrix rows and columns. More...

#include <Komplex_LinearProblem.h>

Collaboration diagram for Komplex_LinearProblem:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 Komplex_LinearProblem ()
 Komplex_LinearProblem default constructor.
virtual ~Komplex_LinearProblem ()
 Komplex_LinearProblem Destructor.
int SetKomplexOperator (double c0r, double c0i, const Epetra_RowMatrix &A0, double c1r, double c1i, const Epetra_RowMatrix &Ai)
 Construct the komplex linear operator from VbrMatrix objects.
int SetKomplexLHS (const Epetra_MultiVector &Xr, const Epetra_MultiVector &Xi)
 Set the left hand side of a Komplex linear problem.
int SetKomplexRHS (const Epetra_MultiVector &Br, const Epetra_MultiVector &Bi)
 Set the right hand side of a Komplex linear problem.
int ExtractSolution (Epetra_MultiVector *Xr, Epetra_MultiVector *Xi)
 Extrac a solution for the original complex-valued problem using the solution of the Komplex problem.
Epetra_LinearProblemKomplexProblem () const
 Returns pointer to the Epetra_LinearProblem object that defines the Komplex formulation.
Epetra_VbrMatrixKomplexVbrMatrix () const
 Returns pointer to Epetra_VbrMatrix from Komplex problem.

Protected Member Functions

void InitializeDefaults ()
 SetKomplexOperatorVbr (double c0r, double c0i, const Epetra_VbrMatrix &A0, double c1r, double c1i, const Epetra_VbrMatrix &Ai)
 SetKomplexOperatorRow (double c0r, double c0i, const Epetra_RowMatrix &A0, double c1r, double c1i, const Epetra_RowMatrix &Ai)
int ConstructKomplexMaps (const Epetra_BlockMap &A0DomainMap, const Epetra_BlockMap &A0RangeMap, const Epetra_BlockMap &A0RowMap, const Epetra_BlockMap &A0ColMap, const Epetra_BlockMap &A1DomainMap, const Epetra_BlockMap &A1RangeMap, const Epetra_BlockMap &A1RowMap, const Epetra_BlockMap &A1ColMap)
int MakeKomplexMap (const Epetra_BlockMap &Map, Epetra_BlockMap *&KMap)
int InitFullMatrixAccess ()
int GetRow (int Row, int &NumIndices, int *&Indices)
int GetRowGCIDs (int Row, int &NumIndices, double *&Values, int *&GlobalIndices)
int GetRow (int Row, int &NumIndices, double *&Values, int *&Indices)

Protected Attributes

Epetra_LinearProblemKomplexProblem_
Epetra_VbrMatrixKomplexMatrix_
Epetra_CrsGraphKomplexGraph_
Epetra_MultiVectorKomplexRHS_
Epetra_MultiVectorKomplexLHS_
Epetra_BlockMapKomplexMatrixRowMap_
Epetra_BlockMapKomplexMatrixColMap_
Epetra_BlockMapKomplexMatrixDomainMap_
Epetra_BlockMapKomplexMatrixRangeMap_
bool HaveKomplexProblem_
bool AnalysisDone_
int * Indices_
double * Values_
bool UserMatrixIsCrsMatrix_
bool UserMatrixIsVbrMatrix_
int MaxNumMyEntries_

Detailed Description

Komplex_LinearProblem: A class for explicitly eliminating matrix rows and columns.

The Komplex_LinearProblem class takes an existing Epetra_LinearProblem object, analyzes it structure and explicitly eliminates rows and columns from the matrix based on density of nonzero entries.


Member Function Documentation

int Komplex_LinearProblem::ExtractSolution ( Epetra_MultiVector Xr,
Epetra_MultiVector Xi 
)

Extrac a solution for the original complex-valued problem using the solution of the Komplex problem.

After solving the komplex linear system, this method can be called to extract the solution of the original problem, assuming the solution for the komplex system is valid.

Parameters:
Xr (In) The real part of the complex valued solution.
Xi (In) The imag part of the complex valued solution.

int Komplex_LinearProblem::SetKomplexLHS ( const Epetra_MultiVector Xr,
const Epetra_MultiVector Xi 
)

Set the left hand side of a Komplex linear problem.

Parameters:
Xr (In) The real part of the complex valued LHS.
Xi (In) The imag part of the complex valued LHS.
Returns:
Error code, set to 0 if no error.

int Komplex_LinearProblem::SetKomplexOperator ( double  c0r,
double  c0i,
const Epetra_RowMatrix A0,
double  c1r,
double  c1i,
const Epetra_RowMatrix Ai 
)

Construct the komplex linear operator from VbrMatrix objects.

Constructs the Komplex operator from the user definition of the complex-valued matrix C = (c0r+i*c0i)*A0 +(c1r+i*c1i)*A1. Using this general expression for the complex matrix allows easy formulation of a variety of common complex problems.

The operator will be explicitly constructed as an Epetra_VbrMatrix object when the first call to SetKomplexOperator() is made. Subsequent calls to this method will attempt to reuse the the existing KomplexVbrMatrix object if possible, rather than reconstructing from scratch. If this is not possible (typically because the structure has changed) then a the previous KomplexVbrMatrix object will be deleted and a new one will be constructed.

Parameters:
c0r (In) The real part of the complex coefficient multiplying A0.
c0i (In) The imag part of the complex coefficient multiplying A0.
A0 (In) An Epetra_RowMatrix that is one of the matrices used to define the true complex operator.
c1r (In) The real part of the complex coefficient multiplying A1.
c1i (In) The imag part of the complex coefficient multiplying A1.
A1 (In) An Epetra_RowMatrix that is the second of the matrices used to define the true complex operator.
Returns:
Error code, set to 0 if no error.

int Komplex_LinearProblem::SetKomplexRHS ( const Epetra_MultiVector Br,
const Epetra_MultiVector Bi 
)

Set the right hand side of a Komplex linear problem.

Parameters:
Br (In) The real part of the complex valued RHS.
Bi (In) The imag part of the complex valued RHS.
Returns:
Error code, set to 0 if no error.


The documentation for this class was generated from the following files:
Generated on Tue Oct 20 12:46:00 2009 for Komplex by doxygen 1.4.7