Skip to content

Commit

Permalink
fix argument interpretation
Browse files Browse the repository at this point in the history
  • Loading branch information
superwhiskers committed Jul 25, 2024
1 parent 10e0454 commit bfba9f4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/r_LUSOL_LUSOL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ int main(int argc, char* argv[])

for (int system = 0; system < n_systems; system++) {

std::string matrix_file_path = matrix_file_prefix + argv[system + 4] + ".mtx";
std::string matrix_file_path = matrix_file_prefix + argv[(2 * system) + 4] + ".mtx";
std::ifstream matrix_file(matrix_file_path);
if (!matrix_file.is_open()) {
std::cout << "Failed to open file " << matrix_file_path << "\n";
Expand All @@ -109,7 +109,7 @@ int main(int argc, char* argv[])

std::cout << "Matrix file: " << matrix_file_path << std::endl;

std::string rhs_file_path = rhs_file_prefix + argv[system + 5] + ".mtx";
std::string rhs_file_path = rhs_file_prefix + argv[(2 * system) + 5] + ".mtx";
std::ifstream rhs_file(rhs_file_path);
if (!rhs_file.is_open()) {
std::cout << "Failed to open file " << rhs_file_path << "\n";
Expand Down

0 comments on commit bfba9f4

Please sign in to comment.