• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

MLAPI_Operator_Utils.h

Go to the documentation of this file.
00001 #ifndef ML_OPERATOR_UTILS_H
00002 #define ML_OPERATOR_UTILS_H
00003 
00012 /* ******************************************************************** */
00013 /* See the file COPYRIGHT for a complete copyright notice, contact      */
00014 /* person and disclaimer.                                               */        
00015 /* ******************************************************************** */
00016 #include "ml_common.h"
00017 
00018 #include "ml_include.h"
00019 #include <iostream>
00020 #include "ml_operator.h"
00021 #include "ml_epetra.h"
00022 #include "ml_amesos.h"
00023 #include "ml_epetra_utils.h"
00024 #include "ml_amesos_wrap.h"
00025 #ifdef HAVE_ML_ANASAZI
00026 #include "ml_anasazi.h"
00027 #endif
00028 #include "Teuchos_ParameterList.hpp"
00029 #include "Teuchos_RefCountPtr.hpp"
00030 #include "MLAPI_Error.h"
00031 #include "MLAPI_Space.h"
00032 #include "MLAPI_MultiVector.h"
00033 #include "MLAPI_Operator.h"
00034 
00035 namespace Teuchos {
00036   class ParameterList;
00037 }
00038 
00039 namespace MLAPI {
00040 
00042 Operator GetRAP(const Operator& R, const Operator& A, 
00043                 const Operator& P);
00044 
00046 Operator GetTranspose(const Operator& A, const bool byrow = true);
00047 
00049 Operator GetIdentity(const Space& DomainSpace, const Space& RangeSpace);
00050 
00052 MultiVector GetDiagonal(const Operator& A);
00053 
00055 MultiVector GetDiagonal(const Operator& A, const int offset);
00056 
00058 Operator GetDiagonal(const MultiVector& D);
00059 
00061 Operator GetJacobiIterationOperator(const Operator& Amat, double Damping);
00062 
00064 Operator GetPtent1D(const MultiVector& D, const int offset = 0);
00065 
00066 // Creates C = scalarA * A + scalarB * B.
00067 int ML_Operator_Add2(ML_Operator *A, ML_Operator *B, ML_Operator *C,
00068         int matrix_type, double scalarA, double scalarB);
00069 
00071 void AnalyzeCheap(const Operator& A);
00072 
00074 void PrintSparsity(const Operator& A, int NumPDEEquations = 1);
00075 
00077 Operator GetScaledOperator(const Operator& A, const double alpha);
00078 
00080 Operator Duplicate(const Operator& A);
00081 
00082 } // namespace MLAPI
00083 
00084 #endif // ML_OPERATOR_UTILS_H