mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Save space in computeFluidAndSpace.
Both hcpv and res will be used to save only dims elements. As dims will most likely be much smaller than the number of cells, we only allocate containers of size dims with this commit.
This commit is contained in:
parent
bbd2575e00
commit
e15f9bfb9c
@ -2369,8 +2369,8 @@ namespace detail {
|
||||
|
||||
// compute PAV and PORV for every regions.
|
||||
const V hydrocarbon = saturation[Oil].value() + saturation[Gas].value();
|
||||
V hcpv = V::Zero(nc);
|
||||
V pres = V::Zero(nc);
|
||||
V hcpv = V::Zero(dims);
|
||||
V pres = V::Zero(dims);
|
||||
for (int c = 0; c < nc; ++c) {
|
||||
if (fipnum[c] != 0) {
|
||||
hcpv[fipnum[c]-1] += pv[c] * hydrocarbon[c];
|
||||
|
Loading…
Reference in New Issue
Block a user