Dual porosity: Shift K-layer to fracture section for completion export

For dual porosity models, the first N K-layers represent MATRIX and
K-layers N+1 to 2N represent FRACTURE. Shift K to the fracture section
at production points so exported completion data (COMPDAT, WPIMULT,
COMPLUMP, COMPSEGS) references the correct K-layer. Subtract the offset
in LGR bounding box computation where original grid K is needed.
This commit is contained in:
Magne Sjaastad committed 2026-02-20 09:27:20 +01:00
1 parent 05623a3fc6
commit 33bf89d196
6 files changed
+165 -7

No files matched your search

@@ -455,6 +455,13 @@ void RicWellPathExportMswTableData::appendFishbonesMswExportInfo( const RimEclip
size_t i, j, k;
localGrid->ijkFromCellIndex( localGridCellIndex, &i, &j, &k );
// Shift K to fracture section for dual porosity models
if ( mainGrid->isDualPorosity() )
{
k += mainGrid->cellCountK();
}
caf::VecIjk0 localIJK( i, j, k );
auto mswIntersect = std::make_shared<RicMswSegmentCellIntersection>( gridName,
@@ -1346,6 +1353,13 @@ void RicWellPathExportMswTableData::assignFishbonesLateralIntersections( const R
size_t i = 0u, j = 0u, k = 0u;
localGrid->ijkFromCellIndex( localGridCellIndex, &i, &j, &k );
// For dual porosity models, shift K to the fracture section so exported completion data references the correct K-layer.
if ( grid->isDualPorosity() )
{
k += grid->cellCountK();
}
auto subSegment = std::make_unique<RicMswSegment>( "Sub segment",
previousExitMD,
cellIntInfo.endMD,