33 #ifndef ANASAZI_SPECIALIZED_EPETRA_ADAPTER_HPP 34 #define ANASAZI_SPECIALIZED_EPETRA_ADAPTER_HPP 37 #include "Anasaziepetra_DLLExportMacro.h" 43 #include "Teuchos_Assert.hpp" 44 #include "Teuchos_SerialDenseMatrix.hpp" 45 #include "Teuchos_RCP.hpp" 46 #include "Epetra_MultiVector.h" 47 #include "Epetra_Vector.h" 48 #include "Epetra_Operator.h" 49 #include "Epetra_Map.h" 50 #include "Epetra_LocalMap.h" 52 #if defined(HAVE_ANASAZI_TPETRA) && defined(HAVE_ANASAZI_TSQR) 53 # include <Tpetra_ConfigDefs.hpp> 54 # if defined(HAVE_TPETRA_EPETRA) 55 # include <Epetra_TsqrAdaptor.hpp> 56 # endif // defined(HAVE_TPETRA_EPETRA) 57 #endif // defined(HAVE_ANASAZI_TPETRA) && defined(HAVE_ANASAZI_TSQR) 97 EpetraOpMultiVec(
const Teuchos::RCP<Epetra_Operator> &Op,
const Epetra_BlockMap& Map_in,
const int numvecs);
109 EpetraOpMultiVec(
const Teuchos::RCP<Epetra_Operator> &Op,
const Epetra_BlockMap& Map_in,
double * array,
const int numvecs,
const int stride=0);
118 EpetraOpMultiVec(
const Teuchos::RCP<Epetra_Operator> &Op, Epetra_DataAccess CV,
const Epetra_MultiVector& P_vec,
const std::vector<int>& index);
174 Teuchos::RCP<Epetra_MultiVector> GetEpetraMultiVector() {
return Epetra_MV; }
182 if ( Epetra_MV->Map().GlobalIndicesLongLong() )
183 return static_cast<ptrdiff_t>( Epetra_MV->GlobalLength64() );
185 return static_cast<ptrdiff_t
>( Epetra_MV->GlobalLength() );
198 const Teuchos::SerialDenseMatrix<int,double>& B,
208 void MvTransMv (
double alpha,
const MultiVec<double>& A, Teuchos::SerialDenseMatrix<int,double>& B
209 #ifdef HAVE_ANASAZI_EXPERIMENTAL
217 #ifdef HAVE_ANASAZI_EXPERIMENTAL
226 "Anasazi::EpetraOpMultiVec::MvScale call to Epetra_MultiVector::Scale() returned a nonzero value.");
231 void MvScale (
const std::vector<double>& alpha );
240 void MvNorm ( std::vector<double> & normvec )
const;
257 "Anasazi::EpetraOpMultiVec::MvRandom call to Epetra_MultiVector::Random() returned a nonzero value.");
264 "Anasazi::EpetraOpMultiVec::MvInit call to Epetra_MultiVector::PutScalar() returned a nonzero value.");
283 void MvPrint( std::ostream& os )
const { Epetra_MV->Print( os ); }
291 #pragma warning(push) 292 #pragma warning(disable:4251) 294 Teuchos::RCP<Epetra_Operator> Epetra_OP;
295 Teuchos::RCP<Epetra_MultiVector> Epetra_MV;
296 Teuchos::RCP<Epetra_MultiVector> Epetra_MV_Temp;
305 #endif // end of file ANASAZI_SPECIALIZED_EPETRA_ADAPTER_HPP EpetraMultiVecAccessor is an interfaceto allow any Anasazi::MultiVec implementation that is based on ...
const Epetra_MultiVector * GetEpetraMultiVec() const
Return the pointer to the Epetra_MultiVector object.
EpetraSpecializedMultiVecFailure is thrown when a return value from an Epetra call on an Epetra_Multi...
void MvInit(double alpha)
Replace each element of the vectors in *this with alpha.
virtual ~EpetraOpMultiVec()
Destructor.
An exception class parent to all Anasazi exceptions.
Interface for multivectors used by Anasazi' linear solvers.
Namespace Anasazi contains the classes, structs, enums and utilities used by the Anasazi package...
ConjType
Enumerated types used to specify conjugation arguments.
void MvScale(double alpha)
Scale each element of the vectors in *this with alpha.
ptrdiff_t GetGlobalLength() const
The number of rows in the multivector.
Specialized adapter class for Anasazi::MultiVec that uses Epetra_MultiVector and Epetra_Operator to d...
Anasazi header file which uses auto-configuration information to include necessary C++ headers...
void MvPrint(std::ostream &os) const
Print *this EpetraOpMultiVec.
Epetra_MultiVector * GetEpetraMultiVec()
Return the pointer to the Epetra_MultiVector object.
Templated virtual class for creating operators that can interface with the Anasazi::OperatorTraits cl...
Types and exceptions used within Anasazi solvers and interfaces.
void MvRandom()
Fill the vectors in *this with random numbers.
Interface for multivectors used by Anasazi's linear solvers.
Declarations of Anasazi multi-vector and operator classes using Epetra_MultiVector and Epetra_Operato...
int GetNumberVecs() const
Obtain the vector length of *this.