00001 #ifndef APP_INVERSE_OPT_H 00002 #define APP_INVERSE_OPT_H 00003 00004 #include <petscksp.h> 00005 #include "MatrixUtil.hpp" 00006 #include <time.h> 00007 #include <math.h> 00008 #include "../../../include/uth_system.h" 00009 #include <map> 00010 #include "lin_alg_intf.h" 00011 00012 extern double* row_dot_products; 00013 extern Mat dot_product_matrix; 00014 00015 Mat getApproximateInverseOpt(Mat Avv, int band, bool symmetric); 00016 int getSpaiBandSize(int size, int band); 00017 void getRowsPattern(Mat Avv, int column, int* columns, int* band, int size, bool symmetric); 00018 void solve_lapack(double* matrix, int size, double *rhs); 00019 void getSystem3(int *columns, int band, double* system); 00020 void getApproximateInversePreallocation(int** diagonal_nonzero, int** off_diagonal_nonzero, Mat Avv, int band, bool symmetric, 00021 bool parallel); 00022 00023 #endif