36 if (argc < 2)
assert(
false &&
"please, give the matrix market file ");
41 cout <<
"End charging matrix " << endl;
42 bool iscomplex =
false, isvector =
false;
46 cout <<
" Not for complex matrices \n";
50 cout <<
"The provided file is not a matrix file\n";
76 cout <<
"Time to load the matrix " <<
timer.value() << endl;
94 cout <<
"Starting the factorization " << endl;
97 cout <<
"Size of Input Matrix " <<
b.size() <<
"\n\n";
98 cout <<
"Rows and columns " <<
A.
rows() <<
" " <<
A.
cols() <<
"\n";
103 std::cout <<
"The solver failed \n";
107 float time_comp =
timer.value();
108 cout <<
" Compute Time " << time_comp << endl;
115 float time_solve =
timer.value();
116 cout <<
" Time to solve " << time_solve << endl;
119 VectorXd tmp2 =
b -
A *
x;
120 double tempNorm = tmp2.norm() /
b.norm();
121 cout <<
"Relative norm of the computed solution : " << tempNorm <<
"\n";
125 cout <<
"Total time " << totaltime.
value() <<
"\n";
Matrix< Scalar, Dynamic, Dynamic > DenseMatrix
Definition: BenchSparseUtil.h:23
BiCGSTAB< SparseMatrix< double > > solver
Definition: BiCGSTAB_simple.cpp:5
int i
Definition: BiCGSTAB_step_by_step.cpp:9
const unsigned n
Definition: CG3DPackingUnitTest.cpp:11
#define assert(e,...)
Definition: Logger.h:744
Scalar * b
Definition: benchVecAdd.cpp:17
Matrix< SCALARA, Dynamic, Dynamic, opt_A > A
Definition: bench_gemm.cpp:47
Definition: BenchTimer.h:55
double value(int TIMER=CPU_TIMER) const
Definition: BenchTimer.h:94
void stop()
Definition: BenchTimer.h:77
void start()
Definition: BenchTimer.h:73
A conjugate gradient solver for sparse (or dense) self-adjoint problems.
Definition: ConjugateGradient.h:152
Modified Incomplete Cholesky with dual threshold.
Definition: IncompleteCholesky.h:51
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE EIGEN_CONSTEXPR Index cols() const EIGEN_NOEXCEPT
Definition: PlainObjectBase.h:192
EIGEN_DEVICE_FUNC constexpr EIGEN_STRONG_INLINE void resize(Index rows, Index cols)
Definition: PlainObjectBase.h:294
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE EIGEN_CONSTEXPR Index rows() const EIGEN_NOEXCEPT
Definition: PlainObjectBase.h:191
ConstSelfAdjointViewReturnType< UpLo >::Type selfadjointView() const
A versatible sparse matrix representation.
Definition: SparseMatrix.h:121
@ Lower
Definition: Constants.h:211
@ Success
Definition: Constants.h:440
Eigen::Matrix< Scalar, Dynamic, Dynamic, ColMajor > tmp
Definition: level3_impl.h:365
bool loadMarketVector(VectorType &vec, const std::string &filename)
Same functionality as loadMarketDense, deprecated.
Definition: MarketIO.h:284
bool loadMarket(SparseMatrixType &mat, const std::string &filename)
Loads a sparse matrix from a matrixmarket format file.
Definition: MarketIO.h:156
bool getMarketHeader(const std::string &filename, int &sym, bool &iscomplex, bool &isdense)
Reads the header of a matrixmarket file and determines the properties of a matrix.
Definition: MarketIO.h:122
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
Definition: Meta.h:83
line
Definition: calibrate.py:103
args
Definition: compute_granudrum_aor.py:143
list x
Definition: plotDoE.py:28
double timer
Definition: oomph_metis_from_parmetis_3.1.1/struct.h:210