#4874 Dual Porosity : Missing active cells in some cases

This commit is contained in:
Magne Sjaastad 2019-10-16 11:11:01 +02:00
parent a53f1e1e91
commit 61db98ef04

View File

@ -89,19 +89,22 @@ std::vector<std::vector<int>> RifActiveCellsReader::activeCellsFromPorvKeyword(
if ( porvValues[poreValueIndex] > 0.0 ) if ( porvValues[poreValueIndex] > 0.0 )
{ {
if ( !dualPorosity || poreValueIndex < porvValues.size() / 2 ) if ( dualPorosity )
{ {
activeCellsOneGrid[indexToCell] = CELL_ACTIVE_MATRIX; if ( poreValueIndex < activeCellCount )
{
activeCellsOneGrid[indexToCell] += CELL_ACTIVE_MATRIX;
}
else
{
activeCellsOneGrid[indexToCell] += CELL_ACTIVE_FRACTURE;
}
} }
else else
{ {
activeCellsOneGrid[indexToCell] += CELL_ACTIVE_FRACTURE; activeCellsOneGrid[indexToCell] = CELL_ACTIVE_MATRIX;
} }
} }
else
{
activeCellsOneGrid[indexToCell] = 0;
}
} }
activeCellsAllGrids.push_back( activeCellsOneGrid ); activeCellsAllGrids.push_back( activeCellsOneGrid );