mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#6074 MSW: Add helper function to compute TVD
This commit is contained in:
parent
501f6e8611
commit
a8d25c13e0
@ -849,17 +849,17 @@ RicMswExportInfo RicWellPathExportMswCompletionsImpl::generateFishbonesMswExport
|
||||
for ( auto& sub : subs->installedLateralIndices() )
|
||||
{
|
||||
double subEndMD = subs->measuredDepth( sub.subIndex );
|
||||
double subEndTVD = -wellPath->wellPathGeometry()->interpolatedPointAlongWellPath( subEndMD ).z();
|
||||
double subEndTVD = RicWellPathExportMswCompletionsImpl::tvdFromMeasuredDepth( wellPath, subEndMD );
|
||||
int subSegCount =
|
||||
SubSegmentIntersectionInfo::numberOfSplittedSegments( subStartMD, subEndMD, maxSegmentLength );
|
||||
double subSegLen = ( subEndMD - subStartMD ) / subSegCount;
|
||||
|
||||
double startMd = subStartMD;
|
||||
double startTvd = -wellPath->wellPathGeometry()->interpolatedPointAlongWellPath( startMd ).z();
|
||||
double startTvd = RicWellPathExportMswCompletionsImpl::tvdFromMeasuredDepth( wellPath, startMd );
|
||||
for ( int ssi = 0; ssi < subSegCount; ssi++ )
|
||||
{
|
||||
double endMd = startMd + subSegLen;
|
||||
double endTvd = -wellPath->wellPathGeometry()->interpolatedPointAlongWellPath( endMd ).z();
|
||||
double endTvd = RicWellPathExportMswCompletionsImpl::tvdFromMeasuredDepth( wellPath, endMd );
|
||||
|
||||
std::shared_ptr<RicMswSegment> location(
|
||||
new RicMswSegment( subs->generatedName(), startMd, endMd, startTvd, endTvd, sub.subIndex ) );
|
||||
@ -1910,6 +1910,18 @@ void RicWellPathExportMswCompletionsImpl::assignBranchAndSegmentNumbers( const R
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
double RicWellPathExportMswCompletionsImpl::tvdFromMeasuredDepth( const RimWellPath* wellPath, double measuredDepth )
|
||||
{
|
||||
CVF_ASSERT( wellPath && wellPath->wellPathGeometry() );
|
||||
|
||||
double tvdValue = -wellPath->wellPathGeometry()->interpolatedPointAlongWellPath( measuredDepth ).z();
|
||||
|
||||
return tvdValue;
|
||||
}
|
||||
|
||||
SubSegmentIntersectionInfo::SubSegmentIntersectionInfo( size_t globCellIndex,
|
||||
double startTVD,
|
||||
double endTVD,
|
||||
|
@ -163,4 +163,6 @@ private:
|
||||
int* branchNum,
|
||||
int* segmentNum );
|
||||
static void assignBranchAndSegmentNumbers( const RimEclipseCase* caseToApply, RicMswExportInfo* exportInfo );
|
||||
|
||||
static double tvdFromMeasuredDepth( const RimWellPath* wellPath, double measuredDepth );
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user