#1996 Rename RigSingleWellResultsData -> RigSimWellData

This commit is contained in:
Rebecca Cox
2017-10-13 13:44:53 +02:00
parent e3ac94a940
commit 44be1bfd6b
39 changed files with 203 additions and 217 deletions

View File

@@ -26,7 +26,7 @@
#include "RigEclipseCaseData.h"
#include "RigFlowDiagResults.h"
#include "RigMainGrid.h"
#include "RigSingleWellResultsData.h"
#include "RigSimWellData.h"
#include "RimEclipseResultCase.h"
#include "RimEclipseView.h"
@@ -128,12 +128,12 @@ std::vector<QString> RimFlowDiagSolution::tracerNames() const
if (eclCase)
{
const cvf::Collection<RigSingleWellResultsData>& wellResults = eclCase->eclipseCaseData()->wellResults();
const cvf::Collection<RigSimWellData>& simWellData = eclCase->eclipseCaseData()->wellResults();
for (size_t wIdx = 0; wIdx < wellResults.size(); ++wIdx)
for (size_t wIdx = 0; wIdx < simWellData.size(); ++wIdx)
{
tracerNameSet.push_back(wellResults[wIdx]->m_wellName);
tracerNameSet.push_back(addCrossFlowEnding(wellResults[wIdx]->m_wellName));
tracerNameSet.push_back(simWellData[wIdx]->m_wellName);
tracerNameSet.push_back(addCrossFlowEnding(simWellData[wIdx]->m_wellName));
}
}
@@ -168,20 +168,20 @@ std::map<std::string, std::vector<int> > RimFlowDiagSolution::allTracerActiveCel
if ( eclCase )
{
const cvf::Collection<RigSingleWellResultsData>& wellResults = eclCase->eclipseCaseData()->wellResults();
const cvf::Collection<RigSimWellData>& simWellData = eclCase->eclipseCaseData()->wellResults();
RigMainGrid* mainGrid = eclCase->eclipseCaseData()->mainGrid();
RigActiveCellInfo* activeCellInfo = eclCase->eclipseCaseData()->activeCellInfo(RiaDefines::MATRIX_MODEL); //Todo: Must come from the results definition
for ( size_t wIdx = 0; wIdx < wellResults.size(); ++wIdx )
for ( size_t wIdx = 0; wIdx < simWellData.size(); ++wIdx )
{
if (!wellResults[wIdx]->hasWellResult(timeStepIndex) ) continue;
const RigWellResultFrame& wellResFrame = wellResults[wIdx]->wellResultFrame(timeStepIndex);
if (!simWellData[wIdx]->hasWellResult(timeStepIndex) ) continue;
const RigWellResultFrame& wellResFrame = simWellData[wIdx]->wellResultFrame(timeStepIndex);
bool isInjectorWell = ( wellResFrame.m_productionType != RigWellResultFrame::PRODUCER
&& wellResFrame.m_productionType != RigWellResultFrame::UNDEFINED_PRODUCTION_TYPE);
std::string wellName = wellResults[wIdx]->m_wellName.toStdString();
std::string wellNameXf = addCrossFlowEnding(wellResults[wIdx]->m_wellName).toStdString();
std::string wellName = simWellData[wIdx]->m_wellName.toStdString();
std::string wellNameXf = addCrossFlowEnding(simWellData[wIdx]->m_wellName).toStdString();
std::vector<int>& tracerCells = tracersWithCells[wellName];
std::vector<int>& tracerCellsCrossFlow = tracersWithCells[wellNameXf];
@@ -228,16 +228,16 @@ RimFlowDiagSolution::TracerStatusType RimFlowDiagSolution::tracerStatusOverall(c
TracerStatusType tracerStatus = UNDEFINED;
const cvf::Collection<RigSingleWellResultsData>& wellResults = eclCase->eclipseCaseData()->wellResults();
const cvf::Collection<RigSimWellData>& simWellData = eclCase->eclipseCaseData()->wellResults();
for ( size_t wIdx = 0; wIdx < wellResults.size(); ++wIdx )
for ( size_t wIdx = 0; wIdx < simWellData.size(); ++wIdx )
{
QString wellName = removeCrossFlowEnding(tracerName);
if ( wellResults[wIdx]->m_wellName != wellName ) continue;
if ( simWellData[wIdx]->m_wellName != wellName ) continue;
tracerStatus = CLOSED;
for ( const RigWellResultFrame& wellResFrame : wellResults[wIdx]->m_wellCellsTimeSteps )
for ( const RigWellResultFrame& wellResFrame : simWellData[wIdx]->m_wellCellsTimeSteps )
{
if ( wellResFrame.m_productionType == RigWellResultFrame::GAS_INJECTOR
|| wellResFrame.m_productionType == RigWellResultFrame::OIL_INJECTOR
@@ -274,16 +274,16 @@ RimFlowDiagSolution::TracerStatusType RimFlowDiagSolution::tracerStatusInTimeSte
RimEclipseResultCase* eclCase;
this->firstAncestorOrThisOfTypeAsserted(eclCase);
const cvf::Collection<RigSingleWellResultsData>& wellResults = eclCase->eclipseCaseData()->wellResults();
const cvf::Collection<RigSimWellData>& simWellData = eclCase->eclipseCaseData()->wellResults();
for ( size_t wIdx = 0; wIdx < wellResults.size(); ++wIdx )
for ( size_t wIdx = 0; wIdx < simWellData.size(); ++wIdx )
{
QString wellName = removeCrossFlowEnding(tracerName);
if ( wellResults[wIdx]->m_wellName != wellName ) continue;
if (!wellResults[wIdx]->hasWellResult(timeStepIndex)) return CLOSED;
if ( simWellData[wIdx]->m_wellName != wellName ) continue;
if (!simWellData[wIdx]->hasWellResult(timeStepIndex)) return CLOSED;
const RigWellResultFrame& wellResFrame = wellResults[wIdx]->wellResultFrame(timeStepIndex);
const RigWellResultFrame& wellResFrame = simWellData[wIdx]->wellResultFrame(timeStepIndex);
if ( wellResFrame.m_productionType == RigWellResultFrame::GAS_INJECTOR
|| wellResFrame.m_productionType == RigWellResultFrame::OIL_INJECTOR

View File

@@ -24,7 +24,7 @@
#include "RimEclipseWellCollection.h"
#include "RimWellAllocationPlot.h"
#include "RigSingleWellResultsData.h"
#include "RigSimWellData.h"
#include "RigTofAccumulatedPhaseFractionsCalculator.h"
#include "RimWellLogPlot.h"

View File

@@ -23,7 +23,7 @@
#include "RimEclipseView.h"
#include "RimEclipseWellCollection.h"
#include "RigSingleWellResultsData.h"
#include "RigSimWellData.h"
#include "RimWellLogPlot.h"
#include "RimWellLogTrack.h"

View File

@@ -26,7 +26,7 @@
#include "RigFlowDiagResults.h"
#include "RigSimulationWellCenterLineCalculator.h"
#include "RigSimulationWellCoordsAndMD.h"
#include "RigSingleWellResultsData.h"
#include "RigSimWellData.h"
#include "RimEclipseCase.h"
#include "RimEclipseCellColors.h"
@@ -135,7 +135,7 @@ void RimWellAllocationPlot::setFromSimulationWell(RimSimWellInView* simWell)
simWell->firstAncestorOrThisOfType(eclCase);
m_case = eclCase;
m_wellName = simWell->wellResults()->m_wellName;
m_wellName = simWell->simWellData()->m_wellName;
m_timeStep = eclView->currentTimeStep();
// Use the active flow diag solutions, or the first one as default
@@ -187,9 +187,9 @@ void RimWellAllocationPlot::updateFromWell()
if (!m_case) return;
const RigSingleWellResultsData* wellResults = m_case->eclipseCaseData()->findWellResult(m_wellName);
const RigSimWellData* simWellData = m_case->eclipseCaseData()->findSimWellData(m_wellName);
if (!wellResults) return;
if (!simWellData) return;
// Set up the Accumulated Well Flow Calculator
@@ -197,14 +197,14 @@ void RimWellAllocationPlot::updateFromWell()
std::vector< std::vector <RigWellResultPoint> > pipeBranchesCellIds;
RigSimulationWellCenterLineCalculator::calculateWellPipeCenterlineFromWellFrame(m_case->eclipseCaseData(),
wellResults,
simWellData,
m_timeStep,
true,
true,
pipeBranchesCLCoords,
pipeBranchesCellIds);
std::map<QString, const std::vector<double>* > tracerFractionCellValues = findRelevantTracerCellFractions(wellResults);
std::map<QString, const std::vector<double>* > tracerFractionCellValues = findRelevantTracerCellFractions(simWellData);
std::unique_ptr< RigAccWellFlowCalculator > wfCalculator;
@@ -213,8 +213,8 @@ void RimWellAllocationPlot::updateFromWell()
if ( tracerFractionCellValues.size() )
{
bool isProducer = ( wellResults->wellProductionType(m_timeStep) == RigWellResultFrame::PRODUCER
|| wellResults->wellProductionType(m_timeStep) == RigWellResultFrame::UNDEFINED_PRODUCTION_TYPE );
bool isProducer = ( simWellData->wellProductionType(m_timeStep) == RigWellResultFrame::PRODUCER
|| simWellData->wellProductionType(m_timeStep) == RigWellResultFrame::UNDEFINED_PRODUCTION_TYPE );
RigEclCellIndexCalculator cellIdxCalc(m_case->eclipseCaseData()->mainGrid(), m_case->eclipseCaseData()->activeCellInfo(RiaDefines::MATRIX_MODEL));
wfCalculator.reset(new RigAccWellFlowCalculator(pipeBranchesCLCoords,
pipeBranchesCellIds,
@@ -327,15 +327,15 @@ void RimWellAllocationPlot::updateFromWell()
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::map<QString, const std::vector<double> *> RimWellAllocationPlot::findRelevantTracerCellFractions(const RigSingleWellResultsData* wellResults)
std::map<QString, const std::vector<double> *> RimWellAllocationPlot::findRelevantTracerCellFractions(const RigSimWellData* simWellData)
{
std::map<QString, const std::vector<double> *> tracerCellFractionValues;
if ( m_flowDiagSolution && wellResults->hasWellResult(m_timeStep) )
if ( m_flowDiagSolution && simWellData->hasWellResult(m_timeStep) )
{
RimFlowDiagSolution::TracerStatusType requestedTracerType = RimFlowDiagSolution::UNDEFINED;
const RigWellResultFrame::WellProductionType prodType = wellResults->wellProductionType(m_timeStep);
const RigWellResultFrame::WellProductionType prodType = simWellData->wellProductionType(m_timeStep);
if ( prodType == RigWellResultFrame::PRODUCER
|| prodType == RigWellResultFrame::UNDEFINED_PRODUCTION_TYPE )
{
@@ -465,13 +465,13 @@ QString RimWellAllocationPlot::wellStatusTextForTimeStep(const QString& wellName
if (eclipseResultCase)
{
const RigSingleWellResultsData* wellResults = eclipseResultCase->eclipseCaseData()->findWellResult(wellName);
const RigSimWellData* simWellData = eclipseResultCase->eclipseCaseData()->findSimWellData(wellName);
if (wellResults)
if (simWellData)
{
if (wellResults->hasWellResult(timeStep))
if (simWellData->hasWellResult(timeStep))
{
const RigWellResultFrame& wellResultFrame = wellResults->wellResultFrame(timeStep);
const RigWellResultFrame& wellResultFrame = simWellData->wellResultFrame(timeStep);
RigWellResultFrame::WellProductionType prodType = wellResultFrame.m_productionType;
@@ -718,11 +718,11 @@ std::set<QString> RimWellAllocationPlot::findSortedWellNames()
std::set<QString> sortedWellNames;
if ( m_case && m_case->eclipseCaseData() )
{
const cvf::Collection<RigSingleWellResultsData>& wellRes = m_case->eclipseCaseData()->wellResults();
const cvf::Collection<RigSimWellData>& simWellData = m_case->eclipseCaseData()->wellResults();
for ( size_t wIdx = 0; wIdx < wellRes.size(); ++wIdx )
for ( size_t wIdx = 0; wIdx < simWellData.size(); ++wIdx )
{
sortedWellNames.insert(wellRes[wIdx]->m_wellName);
sortedWellNames.insert(simWellData[wIdx]->m_wellName);
}
}

View File

@@ -27,7 +27,7 @@
#include <QPointer>
class RigSingleWellResultsData;
class RigSimWellData;
class RimEclipseResultCase;
class RimFlowDiagSolution;
class RimSimWellInView;
@@ -100,7 +100,7 @@ protected:
private:
void updateFromWell();
std::map<QString, const std::vector<double> *> findRelevantTracerCellFractions(const RigSingleWellResultsData* wellResults);
std::map<QString, const std::vector<double> *> findRelevantTracerCellFractions(const RigSimWellData* simWellData);
void updateWellFlowPlotXAxisTitle(RimWellLogTrack* plotTrack);

View File

@@ -29,18 +29,7 @@
#include <QDate>
#include <QMetaType>
class RigSingleWellResultsData;
class RimEclipseResultCase;
class RimFlowDiagSolution;
class RimTofAccumulatedPhaseFractionsPlot;
class RimTotalWellAllocationPlot;
class RimWellLogFile;
class RimWellLogFileChannel;
class RimWellLogPlot;
class RimWellLogTrack;
class RiuWellRftPlot;
//==================================================================================================
///

View File

@@ -24,7 +24,7 @@
#include "RifReaderEclipseRft.h"
#include "RigCaseCellResultsData.h"
#include "RigEclipseCaseData.h"
#include "RigSingleWellResultsData.h"
#include "RigSimWellData.h"
#include "RigWellPath.h"
#include "RimEclipseCase.h"
#include "RimEclipseCaseCollection.h"

View File

@@ -33,17 +33,12 @@
#include <set>
#include <map>
class RigSingleWellResultsData;
class RigWellPath;
class RimEclipseCase;
class RimEclipseResultCase;
class RimFlowDiagSolution;
class RimTofAccumulatedPhaseFractionsPlot;
class RimTotalWellAllocationPlot;
class RimWellLogCurve;
class RimWellLogFileChannel;
class RimWellLogPlot;
class RimWellLogTrack;
class RimWellPath;
class RiuWellRftPlot;