mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-01-16 01:01:55 -06:00
Prevent copying the porevolume when checking for convergence.
As it is just used to compute the tempV value there is no need to copy it to a new vector. With commit we use a reference to geo.poreVolume() instead to prevent the copy.
This commit is contained in:
parent
ef41a0db02
commit
1916c8d35a
@ -2445,7 +2445,7 @@ namespace detail {
|
||||
const int nm = asImpl().numMaterials();
|
||||
assert(int(rq_.size()) == nm);
|
||||
|
||||
const V pv = geo_.poreVolume();
|
||||
const V& pv = geo_.poreVolume();
|
||||
|
||||
std::vector<double> R_sum(nm);
|
||||
std::vector<double> B_avg(nm);
|
||||
@ -2564,7 +2564,7 @@ namespace detail {
|
||||
const int np = asImpl().numPhases();
|
||||
const int nm = asImpl().numMaterials();
|
||||
|
||||
const V pv = geo_.poreVolume();
|
||||
const V& pv = geo_.poreVolume();
|
||||
std::vector<double> R_sum(nm);
|
||||
std::vector<double> B_avg(nm);
|
||||
std::vector<double> maxCoeff(nm);
|
||||
|
Loading…
Reference in New Issue
Block a user