Rename RimWellLogDiffCurve to RimWellLogCalculatedCurve and additional improvements

* Rename from DiffCurve to CalculatedCurve and add operators selection
* Add option to select depth source for resampling in CalculatedCurve

- Select source for depth values for resampling
- Depths from first curve, second curve or union of these
- Added unit tests for function creating union depth values and calculate value with selected operator.

* Guard divide by zero

* Adjust algorithm for union of depths

- Prevent duplicated depth values (no need for enter/exist of k-layer when resampling)
- Add threshold for depth distance
- Update unit tests
This commit is contained in:
Jørgen Herje
2023-05-27 10:30:03 +02:00
committed by GitHub
parent a3efc16615
commit 5975fe6765
13 changed files with 635 additions and 333 deletions

View File

@@ -35,7 +35,7 @@
#include "RimIntersectionCollection.h"
#include "RimMainPlotCollection.h"
#include "RimModeledWellPath.h"
#include "RimWellLogDiffCurve.h"
#include "RimWellLogCalculatedCurve.h"
#include "RimWellLogExtractionCurve.h"
#include "RimWellLogPlotCollection.h"
#include "RimWellLogPlotNameConfig.h"
@@ -286,8 +286,8 @@ void RimGeoMechFaultReactivationResult::createWellLogCurves()
const bool doUpdateAfter = true;
RimWellLogTrack* wellLogExtractionDisplacementTrack =
RicNewWellLogPlotFeatureImpl::createWellLogPlotTrack( doUpdateAfter, QString( "Fault Reactivation Displacement Curves" ), newPlot );
RimWellLogTrack* wellLogDiffTrack =
RicNewWellLogPlotFeatureImpl::createWellLogPlotTrack( doUpdateAfter, QString( "Fault Reactivation Displacement Diff" ), newPlot );
RimWellLogTrack* wellLogCalculatedTrack =
RicNewWellLogPlotFeatureImpl::createWellLogPlotTrack( doUpdateAfter, QString( "Fault Reactivation Displacement Difference" ), newPlot );
RimWellLogTrack* wellLogExtractionFaultmobTrack =
RicNewWellLogPlotFeatureImpl::createWellLogPlotTrack( doUpdateAfter, QString( "Fault Reactivation Faultmob Curves" ), newPlot );
@@ -308,11 +308,12 @@ void RimGeoMechFaultReactivationResult::createWellLogCurves()
return;
}
// Create well log diff curve for m_faceAWellPath and m_faceBWellPath
RimWellLogDiffCurve* faceWellLogDiffCurve = RicWellLogTools::addWellLogDiffCurve( wellLogDiffTrack );
faceWellLogDiffCurve->setWellLogCurves( faceADisplacementCurve, faceBDisplacementCurve );
faceWellLogDiffCurve->loadDataAndUpdate( true );
faceWellLogDiffCurve->updateConnectedEditors();
// Create well log calculated curve for m_faceAWellPath and m_faceBWellPath
RimWellLogCalculatedCurve* wellLogCalculatedCurve = RicWellLogTools::addWellLogCalculatedCurve( wellLogCalculatedTrack );
wellLogCalculatedCurve->setOperator( RimWellLogCalculatedCurve::Operators::SUBTRACT );
wellLogCalculatedCurve->setWellLogCurves( faceADisplacementCurve, faceBDisplacementCurve );
wellLogCalculatedCurve->loadDataAndUpdate( true );
wellLogCalculatedCurve->updateConnectedEditors();
// Well log extraction faultmob curves
RigFemResultAddress wellLogExtractionFaultmobResult( RigFemResultPosEnum::RIG_ELEMENT_NODAL_FACE, "SE", "FAULTMOB" );