51 #include "shylu_amesos_schur_operator.h" 56 IsInitialized_(false),
64 void AmesosSchurOperator::Destroy()
76 if(
Comm().NumProc() != 1)
81 LP_ = Teuchos::RCP<Epetra_LinearProblem> (
new Epetra_LinearProblem());
83 const char* SolverType =
"Amesos_Klu";
92 (void) Factory.Query(SolverType);
94 bool IsAvailable = Factory.Query(SolverType);
95 assert(IsAvailable ==
true);
97 Solver_ = Teuchos::RCP<Amesos_BaseSolver> (Factory.Create(SolverType,
100 Teuchos::ParameterList aList;
101 aList.set(
"Reindex",
true);
103 LP_->SetOperator(A_);
104 Solver_->SetParameters(aList);
105 LP_->SetLHS(0); LP_->SetRHS(0);
107 Solver_->SymbolicFactorization();
109 IsInitialized_ =
true;
115 List_ = parameterlist;
122 Solver_->NumericFactorization();
127 Epetra_MultiVector& Y)
const 130 LP_->SetRHS(const_cast<Epetra_MultiVector *>(&X));
139 os <<
" !!!!!!!!! " << endl;
const Epetra_Comm & Comm() const
Returns the Epetra_BlockMap object associated with the range of this matrix operator.
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...
virtual ostream & Print(ostream &os) const
Prints on stream basic information about this object.
int Compute()
Compute ILU factors L and U using the specified parameters.
AmesosSchurOperator(Epetra_CrsMatrix *A)
Constructor.
int Initialize()
Initialize the preconditioner, does not touch matrix values.
int SetParameters(Teuchos::ParameterList ¶meterlist)
Set parameters using a Teuchos::ParameterList object.