mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#6305 GeoMech derived result: fix normalization when combined with time lapse.
The results for the different time steps are now normalized before the difference is computed.
This commit is contained in:
committed by
Magne Sjaastad
parent
59679f54ad
commit
26c863e310
@@ -73,9 +73,22 @@ RigFemScalarResultFrames* RigFemPartResultCalculatorTimeLapse::calculate( int
|
|||||||
resVarAddr.componentName,
|
resVarAddr.componentName,
|
||||||
RigFemResultAddress::noTimeLapseValue(),
|
RigFemResultAddress::noTimeLapseValue(),
|
||||||
resVarAddr.refKLayerIndex );
|
resVarAddr.refKLayerIndex );
|
||||||
RigFemScalarResultFrames* srcDataFrames = m_resultCollection->findOrLoadScalarResult( partIndex, resVarNative );
|
resVarNative.normalizedByHydrostaticPressure = resVarAddr.normalizedByHydrostaticPressure;
|
||||||
|
|
||||||
|
RigFemScalarResultFrames* srcDataFrames = nullptr;
|
||||||
RigFemScalarResultFrames* dstDataFrames = m_resultCollection->createScalarResult( partIndex, resVarAddr );
|
RigFemScalarResultFrames* dstDataFrames = m_resultCollection->createScalarResult( partIndex, resVarAddr );
|
||||||
|
|
||||||
|
// Normalizable result: needs to be normalized before the diff is calculated
|
||||||
|
if ( resVarAddr.normalizeByHydrostaticPressure() && RigFemPartResultsCollection::isNormalizableResult( resVarAddr ) )
|
||||||
|
{
|
||||||
|
RigFemPartResultCalculatorNormalized normalizedCalculator( *m_resultCollection );
|
||||||
|
srcDataFrames = normalizedCalculator.calculate( partIndex, resVarNative );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
srcDataFrames = m_resultCollection->findOrLoadScalarResult( partIndex, resVarNative );
|
||||||
|
}
|
||||||
|
|
||||||
frameCountProgress.incrementProgress();
|
frameCountProgress.incrementProgress();
|
||||||
|
|
||||||
int frameCount = srcDataFrames->frameCount();
|
int frameCount = srcDataFrames->frameCount();
|
||||||
|
|||||||
Reference in New Issue
Block a user