3 #define OUTPUTPRECISION 12 8 std::string UniqueFullFileName;
21 std::ifstream iff(UniqueFullFileName);
28 }
while (file_n < 100000);
38 std::cout <<
"---------------------------------------------" << std::endl;
39 std::cout <<
"Iteration " <<
iteration_ << std::endl;
41 for (
int i = 0; i <
Vx_.size(); i++)
45 std::cout <<
"------------------------------" << std::endl;
53 std::cout <<
"------------------------------" << std::endl;
54 for (
int i = 0; i < r; i++)
56 for (
int j = 0; j < c; j++)
65 std::cout <<
"------------------------------" << std::endl;
70 std::cout <<
"------------------------------" << std::endl;
74 for (
int i = 0; i < r; i++)
76 for (
int j = 0; j < c; j++)
85 std::cout <<
"------------------------------" << std::endl;
94 std::string postfix =
".txt";
99 std::string postfix =
".txt";
108 file << std::setprecision(16);
109 for (
int i = 0; i <
Vx_.size(); i++)
111 file <<
Vx_[i] << std::endl;
122 std::string iter = std::to_string(
iteration_);
123 std::string postfix =
".txt";
128 std::string postfix =
".txt";
137 file << std::setprecision(16);
138 for (
int i = 0; i <
stdVec_.size(); i++)
140 file <<
stdVec_[i] << std::endl;
153 std::string postfix =
".txt";
166 file << std::setprecision(5);
167 for (
int i = 0; i < r; i++)
169 for (
int j = 0; j < c; j++)
188 std::string postfix =
".txt";
197 file << std::setprecision(5);
199 for (
int k = 0; k <
SpMat_.outerSize(); ++k)
201 for (SparseMatrix<double>::InnerIterator it(
SpMat_, k); it; ++it)
205 double v = it.value();
206 file <<
"(" << r <<
"," << c <<
") " << v <<
"\n";
void GenerateVectorFile()
Eigen::SparseMatrix< double > SpMat_
void StreamVectorOutPut()
void GenerateMatrixFile()
std::vector< double > stdVec_
void StreamSpMatrixOutput()
void GenerateStdVecFile()
void StreamDenMatrixOutput()