IFPACK Development
Loading...
Searching...
No Matches
List of all members
Ifpack_SILU Class Reference

A wrapper to SuperLU 4.0's supernodal ILUT w/ partial pivoting. More...

#include <Ifpack_SILU.h>

Inheritance diagram for Ifpack_SILU:
Inheritance graph
[legend]
Collaboration diagram for Ifpack_SILU:
Collaboration graph
[legend]

Public Member Functions

Constructors and destructors.
 Ifpack_SILU (Epetra_RowMatrix *A)
 Constructor.
 
 ~Ifpack_SILU ()
 Destructor.
 
Construction methods
int Initialize ()
 Initialize the preconditioner, does not touch matrix values.
 
bool IsInitialized () const
 Returns true if the preconditioner has been successfully initialized.
 
int Compute ()
 Compute ILU factors L and U using the specified graph, diagonal perturbation thresholds and relaxation parameters.
 
bool IsComputed () const
 If factor is completed, this query returns true, otherwise it returns false.
 
int SetParameters (Teuchos::ParameterList &parameterlist)
 Set parameters using a Teuchos::ParameterList object.
 
int SetUseTranspose (bool UseTranspose_in)
 If set true, transpose of this operator will be applied.
 
Mathematical functions.
int Apply (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const
 
int Multiply (bool Trans, const Epetra_MultiVector &X, Epetra_MultiVector &Y) const
 
int ApplyInverse (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const
 Returns the result of a Epetra_Operator inverse applied to an Epetra_MultiVector X in Y.
 
double Condest (const Ifpack_CondestType CT=Ifpack_Cheap, const int MaxIters=1550, const double Tol=1e-9, Epetra_RowMatrix *Matrix_in=0)
 Computes the estimated condition number and returns the value.
 
double Condest () const
 Returns the computed estimated condition number, or -1.0 if not computed.
 
Query methods
const char * Label () const
 Returns a character string describing the operator.
 
int SetLabel (const char *Label_in)
 Sets label for this object.
 
double NormInf () const
 Returns 0.0 because this class cannot compute Inf-norm.
 
bool HasNormInf () const
 Returns false because this class cannot compute an Inf-norm.
 
bool UseTranspose () const
 Returns the current UseTranspose setting.
 
const Epetra_MapOperatorDomainMap () const
 Returns the Epetra_Map object associated with the domain of this operator.
 
const Epetra_MapOperatorRangeMap () const
 Returns the Epetra_Map object associated with the range of this operator.
 
const Epetra_CommComm () const
 Returns the Epetra_BlockMap object associated with the range of this matrix operator.
 
const Epetra_RowMatrixMatrix () const
 Returns a reference to the matrix to be preconditioned.
 
virtual std::ostream & Print (std::ostream &os) const
 Prints on stream basic information about this object.
 
virtual int NumInitialize () const
 Returns the number of calls to Initialize().
 
virtual int NumCompute () const
 Returns the number of calls to Compute().
 
virtual int NumApplyInverse () const
 Returns the number of calls to ApplyInverse().
 
virtual double InitializeTime () const
 Returns the time spent in Initialize().
 
virtual double ComputeTime () const
 Returns the time spent in Compute().
 
virtual double ApplyInverseTime () const
 Returns the time spent in ApplyInverse().
 
virtual double InitializeFlops () const
 Returns the number of flops in the initialization phase.
 
virtual double ComputeFlops () const
 Returns the number of flops in the computation phase.
 
virtual double ApplyInverseFlops () const
 Returns the number of flops in the application of the preconditioner.
 
virtual int SetParameters (Teuchos::ParameterList &List)=0
 Sets all parameters for the preconditioner.
 
virtual int Initialize ()=0
 Computes all it is necessary to initialize the preconditioner.
 
virtual bool IsInitialized () const =0
 Returns true if the preconditioner has been successfully initialized, false otherwise.
 
virtual int Compute ()=0
 Computes all it is necessary to apply the preconditioner.
 
virtual bool IsComputed () const =0
 Returns true if the preconditioner has been successfully computed, false otherwise.
 
virtual double Condest (const Ifpack_CondestType CT=Ifpack_Cheap, const int MaxIters=1550, const double Tol=1e-9, Epetra_RowMatrix *Matrix=0)=0
 Computes the condition number estimate, returns its value.
 
virtual double Condest () const =0
 Returns the computed condition number estimate, or -1.0 if not computed.
 
virtual int ApplyInverse (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const =0
 Applies the preconditioner to vector X, returns the result in Y.
 
virtual const Epetra_RowMatrixMatrix () const =0
 Returns a pointer to the matrix to be preconditioned.
 
virtual int NumInitialize () const =0
 Returns the number of calls to Initialize().
 
virtual int NumCompute () const =0
 Returns the number of calls to Compute().
 
virtual int NumApplyInverse () const =0
 Returns the number of calls to ApplyInverse().
 
virtual double InitializeTime () const =0
 Returns the time spent in Initialize().
 
virtual double ComputeTime () const =0
 Returns the time spent in Compute().
 
virtual double ApplyInverseTime () const =0
 Returns the time spent in ApplyInverse().
 
virtual double InitializeFlops () const =0
 Returns the number of flops in the initialization phase.
 
virtual double ComputeFlops () const =0
 Returns the number of flops in the computation phase.
 
virtual double ApplyInverseFlops () const =0
 Returns the number of flops in the application of the preconditioner.
 
virtual std::ostream & Print (std::ostream &os) const =0
 Prints basic information on iostream. This function is used by operator<<.
 
virtual int SetUseTranspose (bool UseTranspose)=0
 
virtual int Apply (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const=0
 
virtual int ApplyInverse (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const=0
 
virtual double NormInf () const=0
 
virtual const char * Label () const=0
 
virtual bool UseTranspose () const=0
 
virtual bool HasNormInf () const=0
 
virtual const Epetra_CommComm () const=0
 
virtual const Epetra_MapOperatorDomainMap () const=0
 
virtual const Epetra_MapOperatorRangeMap () const=0
 
virtual int SetUseTranspose (bool UseTranspose)=0
 
virtual int Apply (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const=0
 
virtual int ApplyInverse (const Epetra_MultiVector &X, Epetra_MultiVector &Y) const=0
 
virtual double NormInf () const=0
 
virtual const char * Label () const=0
 
virtual bool UseTranspose () const=0
 
virtual bool HasNormInf () const=0
 
virtual const Epetra_CommComm () const=0
 
virtual const Epetra_MapOperatorDomainMap () const=0
 
virtual const Epetra_MapOperatorRangeMap () const=0
 

Detailed Description

A wrapper to SuperLU 4.0's supernodal ILUT w/ partial pivoting.

The Ifpack_SILU class is a wrapper to SuperLU 4.0's supernodal ILUT w/ partial pivoting.

Author
Chris Siefert, SNL 1431
Date
Last modified on 07-Apr-10

Definition at line 83 of file Ifpack_SILU.h.

Constructor & Destructor Documentation

◆ Ifpack_SILU()

Ifpack_SILU::Ifpack_SILU ( Epetra_RowMatrix A)

Constructor.

Definition at line 70 of file Ifpack_SILU.cpp.

References SetParameters().

◆ ~Ifpack_SILU()

Ifpack_SILU::~Ifpack_SILU ( )
inline

Destructor.

Definition at line 92 of file Ifpack_SILU.h.

Member Function Documentation

◆ Apply()

int Ifpack_SILU::Apply ( const Epetra_MultiVector X,
Epetra_MultiVector Y 
) const
inlinevirtual

Implements Epetra_Operator.

Definition at line 145 of file Ifpack_SILU.h.

◆ ApplyInverse()

int Ifpack_SILU::ApplyInverse ( const Epetra_MultiVector X,
Epetra_MultiVector Y 
) const
virtual

Returns the result of a Epetra_Operator inverse applied to an Epetra_MultiVector X in Y.

In this implementation, we use several existing attributes to determine how virtual method ApplyInverse() should call the concrete method Solve(). We pass in the UpperTriangular(), the Epetra_CrsMatrix::UseTranspose(), and NoDiagonal() methods. The most notable warning is that if a matrix has no diagonal values we assume that there is an implicit unit diagonal that should be accounted for when doing a triangular solve.

Parameters
X- (In) A Epetra_MultiVector of dimension NumVectors to solve for.
OutY - (Out) A Epetra_MultiVector of dimension NumVectors containing result.
Returns
Integer error code, set to 0 if successful.

Implements Ifpack_Preconditioner.

Definition at line 358 of file Ifpack_SILU.cpp.

References Epetra_Time::ElapsedTime(), IsComputed(), Epetra_MultiVector::NumVectors(), Epetra_MultiVector::Pointers(), Epetra_Time::ResetStartTime(), and UseTranspose().

◆ ApplyInverseFlops()

virtual double Ifpack_SILU::ApplyInverseFlops ( ) const
inlinevirtual

Returns the number of flops in the application of the preconditioner.

Implements Ifpack_Preconditioner.

Definition at line 270 of file Ifpack_SILU.h.

Referenced by Print().

◆ ApplyInverseTime()

virtual double Ifpack_SILU::ApplyInverseTime ( ) const
inlinevirtual

Returns the time spent in ApplyInverse().

Implements Ifpack_Preconditioner.

Definition at line 255 of file Ifpack_SILU.h.

Referenced by Print().

◆ Comm()

const Epetra_Comm & Ifpack_SILU::Comm ( ) const
inlinevirtual

Returns the Epetra_BlockMap object associated with the range of this matrix operator.

Implements Epetra_Operator.

Definition at line 213 of file Ifpack_SILU.h.

Referenced by Print().

◆ Compute()

int Ifpack_SILU::Compute ( )
virtual

Compute ILU factors L and U using the specified graph, diagonal perturbation thresholds and relaxation parameters.

Implements Ifpack_Preconditioner.

Definition at line 248 of file Ifpack_SILU.cpp.

References Epetra_Time::ElapsedTime(), Initialize(), IsInitialized(), and Epetra_Time::ResetStartTime().

◆ ComputeFlops()

virtual double Ifpack_SILU::ComputeFlops ( ) const
inlinevirtual

Returns the number of flops in the computation phase.

Implements Ifpack_Preconditioner.

Definition at line 265 of file Ifpack_SILU.h.

Referenced by Print().

◆ ComputeTime()

virtual double Ifpack_SILU::ComputeTime ( ) const
inlinevirtual

Returns the time spent in Compute().

Implements Ifpack_Preconditioner.

Definition at line 249 of file Ifpack_SILU.h.

Referenced by Print().

◆ Condest() [1/2]

double Ifpack_SILU::Condest ( ) const
inlinevirtual

Returns the computed estimated condition number, or -1.0 if not computed.

Implements Ifpack_Preconditioner.

Definition at line 177 of file Ifpack_SILU.h.

Referenced by Print().

◆ Condest() [2/2]

double Ifpack_SILU::Condest ( const Ifpack_CondestType  CT = Ifpack_Cheap,
const int  MaxIters = 1550,
const double  Tol = 1e-9,
Epetra_RowMatrix Matrix_in = 0 
)
virtual

Computes the estimated condition number and returns the value.

Implements Ifpack_Preconditioner.

Definition at line 392 of file Ifpack_SILU.cpp.

References IsComputed().

◆ HasNormInf()

bool Ifpack_SILU::HasNormInf ( ) const
inlinevirtual

Returns false because this class cannot compute an Inf-norm.

Implements Epetra_Operator.

Definition at line 201 of file Ifpack_SILU.h.

◆ Initialize()

int Ifpack_SILU::Initialize ( )
virtual

Initialize the preconditioner, does not touch matrix values.

Implements Ifpack_Preconditioner.

Definition at line 230 of file Ifpack_SILU.cpp.

Referenced by Compute().

◆ InitializeFlops()

virtual double Ifpack_SILU::InitializeFlops ( ) const
inlinevirtual

Returns the number of flops in the initialization phase.

Implements Ifpack_Preconditioner.

Definition at line 260 of file Ifpack_SILU.h.

◆ InitializeTime()

virtual double Ifpack_SILU::InitializeTime ( ) const
inlinevirtual

Returns the time spent in Initialize().

Implements Ifpack_Preconditioner.

Definition at line 243 of file Ifpack_SILU.h.

Referenced by Print().

◆ IsComputed()

bool Ifpack_SILU::IsComputed ( ) const
inlinevirtual

If factor is completed, this query returns true, otherwise it returns false.

Implements Ifpack_Preconditioner.

Definition at line 114 of file Ifpack_SILU.h.

Referenced by ApplyInverse(), and Condest().

◆ IsInitialized()

bool Ifpack_SILU::IsInitialized ( ) const
inlinevirtual

Returns true if the preconditioner has been successfully initialized.

Implements Ifpack_Preconditioner.

Definition at line 105 of file Ifpack_SILU.h.

Referenced by Compute().

◆ Label()

const char * Ifpack_SILU::Label ( ) const
inlinevirtual

Returns a character string describing the operator.

Implements Epetra_Operator.

Definition at line 188 of file Ifpack_SILU.h.

Referenced by Print().

◆ Matrix()

const Epetra_RowMatrix & Ifpack_SILU::Matrix ( ) const
inlinevirtual

Returns a reference to the matrix to be preconditioned.

Implements Ifpack_Preconditioner.

Definition at line 216 of file Ifpack_SILU.h.

◆ Multiply()

int Ifpack_SILU::Multiply ( bool  Trans,
const Epetra_MultiVector X,
Epetra_MultiVector Y 
) const

Definition at line 346 of file Ifpack_SILU.cpp.

◆ NormInf()

double Ifpack_SILU::NormInf ( ) const
inlinevirtual

Returns 0.0 because this class cannot compute Inf-norm.

Implements Epetra_Operator.

Definition at line 198 of file Ifpack_SILU.h.

◆ NumApplyInverse()

virtual int Ifpack_SILU::NumApplyInverse ( ) const
inlinevirtual

Returns the number of calls to ApplyInverse().

Implements Ifpack_Preconditioner.

Definition at line 237 of file Ifpack_SILU.h.

Referenced by Print().

◆ NumCompute()

virtual int Ifpack_SILU::NumCompute ( ) const
inlinevirtual

Returns the number of calls to Compute().

Implements Ifpack_Preconditioner.

Definition at line 231 of file Ifpack_SILU.h.

Referenced by Print().

◆ NumInitialize()

virtual int Ifpack_SILU::NumInitialize ( ) const
inlinevirtual

Returns the number of calls to Initialize().

Implements Ifpack_Preconditioner.

Definition at line 225 of file Ifpack_SILU.h.

Referenced by Print().

◆ OperatorDomainMap()

const Epetra_Map & Ifpack_SILU::OperatorDomainMap ( ) const
inlinevirtual

Returns the Epetra_Map object associated with the domain of this operator.

Implements Epetra_Operator.

Definition at line 207 of file Ifpack_SILU.h.

◆ OperatorRangeMap()

const Epetra_Map & Ifpack_SILU::OperatorRangeMap ( ) const
inlinevirtual

Returns the Epetra_Map object associated with the range of this operator.

Implements Epetra_Operator.

Definition at line 210 of file Ifpack_SILU.h.

◆ Print()

std::ostream & Ifpack_SILU::Print ( std::ostream &  os) const
virtual

Prints on stream basic information about this object.

Implements Ifpack_Preconditioner.

Definition at line 411 of file Ifpack_SILU.cpp.

References ApplyInverseFlops(), ApplyInverseTime(), Comm(), ComputeFlops(), ComputeTime(), Condest(), InitializeTime(), Label(), NumApplyInverse(), NumCompute(), and NumInitialize().

◆ SetLabel()

int Ifpack_SILU::SetLabel ( const char *  Label_in)
inline

Sets label for this object.

Definition at line 191 of file Ifpack_SILU.h.

◆ SetParameters()

int Ifpack_SILU::SetParameters ( Teuchos::ParameterList &  parameterlist)
virtual

Set parameters using a Teuchos::ParameterList object.

Implements Ifpack_Preconditioner.

Definition at line 124 of file Ifpack_SILU.cpp.

Referenced by Ifpack_SILU().

◆ SetUseTranspose()

int Ifpack_SILU::SetUseTranspose ( bool  UseTranspose_in)
inlinevirtual

If set true, transpose of this operator will be applied.

This flag allows the transpose of the given operator to be used implicitly. Setting this flag affects only the Apply() and ApplyInverse() methods. If the implementation of this interface does not support transpose use, this method should return a value of -1.

Parameters
UseTranspose_in- (In) If true, multiply by the transpose of operator, otherwise just use operator.
Returns
Always returns 0.

Implements Epetra_Operator.

Definition at line 139 of file Ifpack_SILU.h.

◆ UseTranspose()

bool Ifpack_SILU::UseTranspose ( ) const
inlinevirtual

Returns the current UseTranspose setting.

Implements Epetra_Operator.

Definition at line 204 of file Ifpack_SILU.h.

Referenced by ApplyInverse().


The documentation for this class was generated from the following files: