46 #if defined(Ifpack_SHOW_DEPRECATED_WARNINGS)
48 #warning "The Ifpack package is deprecated"
52 #include "Ifpack_ConfigDefs.h"
54 #ifdef HAVE_IFPACK_SUPERLU
55 #include "Ifpack_Preconditioner.h"
56 #include "Ifpack_Condest.h"
58 #include "Ifpack_IlukGraph.h"
59 #include "Epetra_CompObject.h"
60 #include "Epetra_MultiVector.h"
61 #include "Epetra_Vector.h"
62 #include "Epetra_CrsGraph.h"
63 #include "Epetra_CrsMatrix.h"
64 #include "Epetra_BlockMap.h"
65 #include "Epetra_Map.h"
66 #include "Epetra_Object.h"
67 #include "Epetra_Comm.h"
68 #include "Epetra_RowMatrix.h"
69 #include "Epetra_Time.h"
70 #include "Teuchos_RefCountPtr.hpp"
77 #include "slu_ddefs.h"
113 return(IsInitialized_);
145 int SetUseTranspose(
bool UseTranspose_in) {UseTranspose_ = UseTranspose_in;
return(0);};
154 return(Multiply(
false,X,Y));
177 double Condest(
const Ifpack_CondestType CT = Ifpack_Cheap,
178 const int MaxIters = 1550,
179 const double Tol = 1e-9,
194 const char*
Label()
const {
return(Label_);}
199 strcpy(Label_,Label_in);
228 virtual std::ostream&
Print(std::ostream& os)
const;
233 return(NumInitialize_);
245 return(NumApplyInverse_);
251 return(InitializeTime_);
257 return(ComputeTime_);
263 return(ApplyInverseTime_);
318 double DropTol()
const {
return DropTol_;}
321 double FillTol()
const{
return FillTol_;}
324 double FillFactor()
const{
return FillFactor_;}
327 int DropRule()
const{
return DropRule_;}
329 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
330 int NumGlobalRows()
const {
return(Graph().NumGlobalRows());};
334 int NumGlobalCols()
const {
return(Graph().NumGlobalCols());};
337 int NumGlobalNonzeros()
const {
return(Graph().NumGlobalNonzeros());};
340 virtual int NumGlobalBlockDiagonals()
const {
return(Graph().NumGlobalBlockDiagonals());};
344 long long NumGlobalRows64()
const {
return(Graph().NumGlobalRows64());};
347 long long NumGlobalCols64()
const {
return(Graph().NumGlobalCols64());};
350 long long NumGlobalNonzeros64()
const {
return(Graph().NumGlobalNonzeros64());};
353 virtual long long NumGlobalBlockDiagonals64()
const {
return(Graph().NumGlobalBlockDiagonals64());};
356 int NumMyRows()
const {
return(Graph().NumMyRows());};
359 int NumMyCols()
const {
return(Graph().NumMyCols());};
362 int NumMyNonzeros()
const {
return(Graph().NumMyNonzeros());};
365 virtual int NumMyBlockDiagonals()
const {
return(Graph().NumMyBlockDiagonals());};
368 virtual int NumMyDiagonals()
const {
return(NumMyDiagonals_);};
370 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
371 int IndexBase()
const {
return(Graph().IndexBase());};
374 long long IndexBase64()
const {
return(Graph().IndexBase64());};
391 Teuchos::RefCountPtr<Epetra_RowMatrix> A_;
392 Teuchos::RefCountPtr<Epetra_CrsGraph> Graph_;
393 Teuchos::RefCountPtr<Epetra_Map> IlukRowMap_;
394 Teuchos::RefCountPtr<Epetra_Map> IlukDomainMap_;
395 Teuchos::RefCountPtr<Epetra_Map> IlukRangeMap_;
398 Teuchos::RefCountPtr<Epetra_CrsMatrix> Aover_;
403 bool ValuesInitialized_;
428 mutable int NumApplyInverse_;
430 double InitializeTime_;
434 mutable double ApplyInverseTime_;
438 #ifdef HAVE_IFPACK_SUPERLU5_API
439 mutable GlobalLU_t lu_;
441 mutable SuperLUStat_t stat_;
444 mutable superlu_options_t options_;
446 mutable SuperMatrix SA_,SAc_,SL_,SU_,SY_;
448 int *etree_,*perm_r_,*perm_c_;
452 template<
typename int_type>
int SetLabel(const char *Label_in)
Sets label for this object.
virtual double ApplyInverseTime() const
Returns the time spent in ApplyInverse().
virtual double InitializeFlops() const
Returns the number of flops in the initialization phase.
const char * Label() const
Returns a character string describing the operator.
Ifpack_SILU(Epetra_RowMatrix *A)
Constructor.
virtual int NumInitialize() const
Returns the number of calls to Initialize().
bool UseTranspose() const
Returns the current UseTranspose setting.
const Epetra_RowMatrix & Matrix() const
Returns a reference to the matrix to be preconditioned.
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...
A wrapper to SuperLU 4.0's supernodal ILUT w/ partial pivoting.
virtual double InitializeTime() const
Returns the time spent in Initialize().
~Ifpack_SILU()
Destructor.
bool IsInitialized() const
Returns true if the preconditioner has been successfully initialized.
bool HasNormInf() const
Returns false because this class cannot compute an Inf-norm.
virtual std::ostream & Print(std::ostream &os) const
Prints on stream basic information about this object.
Ifpack_ScalingType enumerable type.
Ifpack_Preconditioner: basic class for preconditioning in Ifpack.
int Compute()
Compute ILU factors L and U using the specified graph, diagonal perturbation thresholds and relaxatio...
int Initialize()
Initialize the preconditioner, does not touch matrix values.
int SetParameters(Teuchos::ParameterList ¶meterlist)
Set parameters using a Teuchos::ParameterList object.
const Epetra_Map & OperatorDomainMap() const
Returns the Epetra_Map object associated with the domain of this operator.
int SetUseTranspose(bool UseTranspose_in)
If set true, transpose of this operator will be applied.
bool IsComputed() const
If factor is completed, this query returns true, otherwise it returns false.
virtual double ComputeTime() const
Returns the time spent in Compute().
virtual double ApplyInverseFlops() const
Returns the number of flops in the application of the preconditioner.
virtual int NumCompute() const
Returns the number of calls to Compute().
const Epetra_Map & OperatorRangeMap() const
Returns the Epetra_Map object associated with the range of this operator.
const Epetra_Comm & Comm() const
Returns the Epetra_BlockMap object associated with the range of this matrix operator.
virtual int NumApplyInverse() const
Returns the number of calls to ApplyInverse().
double NormInf() const
Returns 0.0 because this class cannot compute Inf-norm.
virtual double ComputeFlops() const
Returns the number of flops in the computation phase.
double Condest() const
Returns the computed estimated condition number, or -1.0 if not computed.