#14878: Add FMU well-picks data model (RigWellPathFormations, RimWellFormationsFile/Collection)

Parse depth-based FMU well-pick formations.csv files in RifWellPathFormationReader
and expose them as a project-level RimWellFormationsCollection of RimWellFormationsFile
objects. RigWellPathFormations becomes a value type with top/base MD and TVD depths
per formation, independent from the existing K-layer-index .lyr formation names.
This commit is contained in:
Magne Sjaastad committed 2026-10-08 12:44:14 +02:00
1 parent fe887270e5
commit 37cacc9a41
13 files changed
+740 -23

No files matched your search

@@ -2,6 +2,8 @@
#include "Well/RigWellPathFormations.h"
#include "RiaWellLogTrackDefines.h"
#include <QString>
#include <vector>
@@ -131,3 +133,44 @@ TEST( RigWellPathFormations, UnsupportedDepthTypeGivesNoPicks )
EXPECT_TRUE( depths.empty() );
}
}
TEST( RigWellPathFormations, DepthRangesUpToLevelReturnsZoneIntervals )
{
auto formations = createHierarchy();
{
auto ranges = formations.depthRangesUpToLevel( FormationLevel::GROUP, DepthType::MEASURED_DEPTH );
ASSERT_EQ( 1u, ranges.size() );
EXPECT_EQ( QString( "GARN" ), std::get<0>( ranges[0] ) );
EXPECT_DOUBLE_EQ( 100.0, std::get<1>( ranges[0] ) );
EXPECT_DOUBLE_EQ( 200.0, std::get<2>( ranges[0] ) );
}
{
auto ranges = formations.depthRangesUpToLevel( FormationLevel::LEVEL1, DepthType::MEASURED_DEPTH );
ASSERT_EQ( 3u, ranges.size() );
EXPECT_EQ( QString( "GARN" ), std::get<0>( ranges[0] ) );
EXPECT_EQ( QString( "Garn 1" ), std::get<0>( ranges[1] ) );
EXPECT_EQ( QString( "Garn 2" ), std::get<0>( ranges[2] ) );
}
{
auto ranges = formations.depthRangesUpToLevel( FormationLevel::NONE, DepthType::MEASURED_DEPTH );
EXPECT_TRUE( ranges.empty() );
}
}
TEST( RigWellPathFormations, DepthRangesUpToLevelExcludesFluids )
{
RigWellPathFormations formations( { formation( "Garn", 100.0, 200.0 ), formation( "OIL", 120.0, 140.0 ) }, "file", "well" );
auto ranges = formations.depthRangesUpToLevel( FormationLevel::ALL, DepthType::MEASURED_DEPTH );
ASSERT_EQ( 1u, ranges.size() );
EXPECT_EQ( QString( "Garn" ), std::get<0>( ranges[0] ) );
}
TEST( RigWellPathFormations, DepthRangesUpToLevelUnsupportedDepthTypeGivesNoRanges )
{
RigWellPathFormations formations( { formation( "Garn", 100.0, 200.0 ) }, "file", "well" );
auto ranges = formations.depthRangesUpToLevel( FormationLevel::ALL, DepthType::TRUE_VERTICAL_DEPTH_RKB );
EXPECT_TRUE( ranges.empty() );
}