mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#3958 Starting refactoring of eclipse results addressing
Preparations for time diff results
This commit is contained in:
@@ -31,10 +31,10 @@
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RigEclipseNativeVisibleCellsStatCalc::RigEclipseNativeVisibleCellsStatCalc(RigCaseCellResultsData* cellResultsData,
|
||||
size_t scalarResultIndex,
|
||||
const RigEclipseResultAddress& scalarResultIndex,
|
||||
const cvf::UByteArray* cellVisibilities)
|
||||
: m_caseData(cellResultsData),
|
||||
m_scalarResultIndex(scalarResultIndex),
|
||||
m_resultAddress(scalarResultIndex),
|
||||
m_cellVisibilities(cellVisibilities)
|
||||
{
|
||||
|
||||
@@ -97,7 +97,7 @@ void RigEclipseNativeVisibleCellsStatCalc::uniqueValues(size_t timeStepIndex, st
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
size_t RigEclipseNativeVisibleCellsStatCalc::timeStepCount()
|
||||
{
|
||||
return m_caseData->timeStepCount(m_scalarResultIndex);
|
||||
return m_caseData->timeStepCount(m_resultAddress);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -107,11 +107,11 @@ void RigEclipseNativeVisibleCellsStatCalc::mobileVolumeWeightedMean(size_t timeS
|
||||
{
|
||||
size_t mobPVResultIndex = m_caseData->findOrLoadScalarResult(RiaDefines::ResultCatType::STATIC_NATIVE, RiaDefines::mobilePoreVolumeName());
|
||||
|
||||
const std::vector<double>& weights = m_caseData->cellScalarResults(mobPVResultIndex)[0];
|
||||
const std::vector<double>& values = m_caseData->cellScalarResults(m_scalarResultIndex, timeStepIndex);
|
||||
const std::vector<double>& weights = m_caseData->cellScalarResults(RigEclipseResultAddress(mobPVResultIndex), 0);
|
||||
const std::vector<double>& values = m_caseData->cellScalarResults(m_resultAddress, timeStepIndex);
|
||||
|
||||
const RigActiveCellInfo* actCellInfo = m_caseData->activeCellInfo();
|
||||
|
||||
RigWeightedMeanCalc::weightedMeanOverCells(&weights, &values, m_cellVisibilities.p(), true, actCellInfo, m_caseData->isUsingGlobalActiveIndex(m_scalarResultIndex), &result);
|
||||
RigWeightedMeanCalc::weightedMeanOverCells(&weights, &values, m_cellVisibilities.p(), true, actCellInfo, m_caseData->isUsingGlobalActiveIndex(m_resultAddress), &result);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user