Skip to content

Commit

Permalink
Amesos2::SuperLU_dist: shift the local row and col scaling by offset
Browse files Browse the repository at this point in the history
  • Loading branch information
iyamazaki committed Oct 26, 2021
1 parent 03f4904 commit 98bc0c8
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions packages/amesos2/src/Amesos2_Superludist_def.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -572,7 +572,9 @@ namespace Amesos2 {
if (data_.options.Equil == SLUD::YES && data_.rowequ) {
SLUD::int_t ld = as<SLUD::int_t>(local_len_rhs);
for(global_size_type j = 0; j < nrhs; ++j) {
for(size_t i = 0; i < local_len_rhs; ++i) bvals_[i + j*ld] *= data_.R[i];
for(size_t i = 0; i < local_len_rhs; ++i) {
bvals_[i + j*ld] *= data_.R[first_global_row_b + i];
}
}
}

Expand Down Expand Up @@ -624,7 +626,9 @@ namespace Amesos2 {
if (data_.options.Equil == SLUD::YES && data_.colequ) {
SLUD::int_t ld = as<SLUD::int_t>(local_len_rhs);
for(global_size_type j = 0; j < nrhs; ++j) {
for(size_t i = 0; i < local_len_rhs; ++i) xvals_[i + j*ld] *= data_.C[i];
for(size_t i = 0; i < local_len_rhs; ++i) {
xvals_[i + j*ld] *= data_.C[first_global_row_b + i];
}
}
}
}
Expand Down

0 comments on commit 98bc0c8

Please sign in to comment.