mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
Reduce err properly
This commit is contained in:
parent
596eab4bb6
commit
6e77ddc532
1 changed files with 1 additions and 2 deletions
|
|
@ -133,7 +133,6 @@ int cmfd_linsolver_1g(const double* A_data, const double* b, double* x,
|
|||
|
||||
// Check convergence
|
||||
err = std::sqrt(err / cmfd::dim);
|
||||
std::cout << err << "\n";
|
||||
if (err < tol)
|
||||
return igs;
|
||||
|
||||
|
|
@ -220,7 +219,7 @@ int cmfd_linsolver_2g(const double* A_data, const double* b, double* x,
|
|||
|
||||
// Compute residual and update error
|
||||
double res = (tmpx[irow] - x[irow]) / tmpx[irow];
|
||||
err = res * res;
|
||||
err += res * res;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue