Go to the documentation of this file.00001
00002
00003 #ifndef PARDISO_HH
00004 #define PARDISO_HH
00005
00006 #include <cstdlib>
00007 #include "basics/typedefs.hh"
00008 #include "basics/fortranException.hh"
00009 #include "compositions.hh"
00010
00011 namespace concepts {
00012
00013
00014 template<typename F>
00015 class SparseMatrix;
00016
00017
00018
00040 class Pardiso : public Operator<Real> {
00041 public:
00043 enum MATRIX_TYPE {STRUCT_SYMM = 1, SPD = 2, SYMM_INDEF = -2, UNSYMM = 11};
00057 Pardiso(const SparseMatrix<Real>& matrix, enum MATRIX_TYPE type);
00058 virtual ~Pardiso();
00059 virtual void operator()(const Function<Real>& fncY, Function<Real>& fncX);
00060 void operator()(const Vector<Real>& fncY, Vector<Real>& fncX);
00061 virtual const Space<Real>& spaceX() const { return spcX_; }
00062 virtual const Space<Real>& spaceY() const { return spcY_; }
00063 protected:
00064 virtual std::ostream& info(std::ostream& os) const;
00065 private:
00067 const uint n_;
00069 const Space<Real>& spcX_;
00071 const Space<Real>& spcY_;
00073 bool symmetric_;
00075 bool factored_;
00076
00078 uint nnz_;
00080 void* A_;
00082 Array<Real> a_;
00084 Array<uint> ia_, ja_;
00086 Array<size_t> handle;
00088 Array<int> iparam;
00090 int max_factorizations, matrix_number, matrix_type, msglvl, error,
00091 nb, max_threads;
00092
00094 int solver_pardiso_factor_();
00096 int solver_pardiso_solve_(double*, double*);
00098 void errorcheck_(int error) const throw(FortranException);
00099 };
00100
00101 }
00102
00103 #endif // PARDISO_HH