43 #ifndef IFPACK_KRYLOV_H
44 #define IFPACK_KRYLOV_H
46 #include "Ifpack_ConfigDefs.h"
47 #include "Ifpack_Preconditioner.h"
48 #include "Teuchos_RefCountPtr.hpp"
49 #include "Ifpack_PointRelaxation.h"
50 #include "Ifpack_BlockRelaxation.h"
51 #include "Ifpack_SparseContainer.h"
52 #include "Ifpack_DenseContainer.h"
53 #include "Ifpack_Amesos.h"
54 #ifdef HAVE_IFPACK_AZTECOO
70 #ifdef HAVE_IFPACK_AZTECOO
75 #ifdef HAVE_IFPACK_EPETRAEXT
76 class EpetraExt_PointToBlockDiagPermute;
109 UseTranspose_ = UseTranspose_in;
150 virtual const char * Label()
const
152 return(Label_.c_str());
158 return(UseTranspose_);
180 return(IsInitialized_);
198 virtual double Condest(
const Ifpack_CondestType CT = Ifpack_Cheap,
199 const int MaxIters = 1550,
200 const double Tol = 1e-9,
213 virtual std::ostream&
Print(std::ostream & os)
const;
222 return(NumInitialize_);
234 return(NumApplyInverse_);
240 return(InitializeTime_);
246 return(ComputeTime_);
252 return(ApplyInverseTime_);
264 return(ComputeFlops_);
270 return(ApplyInverseFlops_);
279 virtual void SetLabel();
301 mutable int NumApplyInverse_;
303 double InitializeTime_;
307 mutable double ApplyInverseTime_;
309 double ComputeFlops_;
311 mutable double ApplyInverseFlops_;
322 int PreconditionerType_;
328 double DampingParameter_;
337 bool ComputeCondest_;
348 long long NumGlobalRows_;
350 long long NumGlobalNonzeros_;
352 Teuchos::RefCountPtr<Epetra_Operator> Operator_;
354 Teuchos::RefCountPtr<Epetra_RowMatrix> Matrix_;
359 Teuchos::RefCountPtr<Epetra_Time> Time_;
361 bool ZeroStartingSolution_;
364 #ifdef HAVE_IFPACK_AZTECOO
365 Teuchos::RCP<AztecOO> AztecSolver_;
369 Teuchos::RCP<Ifpack_Preconditioner> IfpackPrec_;
374 #endif // IFPACK_KRYLOV_H
virtual int NumInitialize() const
Returns the number of calls to Initialize().
virtual double ComputeFlops() const
Returns the number of flops in the computation phase.
virtual int Initialize()
Computes all it is necessary to initialize the preconditioner.
virtual int Apply(const Epetra_MultiVector &X, Epetra_MultiVector &Y) const
Applies the matrix to an Epetra_MultiVector.
virtual int NumCompute() const
Returns the number of calls to Compute().
virtual double Condest() const
Returns the condition number estimate, or -1.0 if not computed.
virtual double InitializeTime() const
Returns the time spent in Initialize().
virtual double ComputeTime() const
Returns the time spent in Compute().
virtual bool HasNormInf() const
Returns true if the this object can provide an approximate Inf-norm, false otherwise.
virtual int NumApplyInverse() const
Returns the number of calls to ApplyInverse().
virtual double InitializeFlops() const
Returns the number of flops in the initialization phase.
virtual double NormInf() const
Returns the infinity norm of the global matrix (not implemented)
virtual int Compute()
Computes the preconditioners.
virtual int SetUseTranspose(bool UseTranspose_in)
Ifpack_Preconditioner: basic class for preconditioning in Ifpack.
virtual int SetParameters(Teuchos::ParameterList &List)
Sets all the parameters for the preconditioner.
virtual std::ostream & Print(std::ostream &os) const
Prints object to an output stream.
virtual const Epetra_Map & OperatorDomainMap() const
Returns the Epetra_Map object associated with the domain of this operator.
virtual bool IsInitialized() const
Returns true if the preconditioner has been successfully initialized, false otherwise.
virtual bool IsComputed() const
Returns true if the preconditioner has been successfully computed.
virtual const Epetra_Map & OperatorRangeMap() const
Returns the Epetra_Map object associated with the range of this operator.
Ifpack_Krylov: class for smoothing with Krylov solvers in Ifpack.
virtual const Epetra_RowMatrix & Matrix() const
Returns a pointer to the matrix to be preconditioned.
virtual bool UseTranspose() const
Returns the current UseTranspose setting.
virtual const Epetra_Comm & Comm() const
Returns a pointer to the Epetra_Comm communicator associated with this operator.
virtual double ApplyInverseFlops() const
Returns the number of flops for the application of the preconditioner.
virtual double ApplyInverseTime() const
Returns the time spent in ApplyInverse().
virtual ~Ifpack_Krylov()
Destructor.
virtual int ApplyInverse(const Epetra_MultiVector &X, Epetra_MultiVector &Y) const
Applies the preconditioner to X, returns the result in Y.