mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
More Rename of globalCell to reservoirCell
This commit is contained in:
committed by
Magne Sjaastad
parent
3022a40204
commit
09313c6caa
@@ -170,7 +170,7 @@ public:
|
||||
hostCellK.reserve(numMatrixModelActiveCells);
|
||||
globalCoarseningBoxIdx.reserve(numMatrixModelActiveCells);
|
||||
|
||||
const std::vector<RigCell>& globalCells = reservoirCase->reservoirData()->mainGrid()->cells();
|
||||
const std::vector<RigCell>& reservoirCells = reservoirCase->reservoirData()->mainGrid()->cells();
|
||||
|
||||
|
||||
std::vector<size_t> globalCoarseningBoxIndexStart;
|
||||
@@ -190,13 +190,13 @@ public:
|
||||
}
|
||||
|
||||
|
||||
for (size_t cIdx = 0; cIdx < globalCells.size(); ++cIdx)
|
||||
for (size_t cIdx = 0; cIdx < reservoirCells.size(); ++cIdx)
|
||||
{
|
||||
if (actCellInfo->isActive(cIdx))
|
||||
{
|
||||
RigGridBase* grid = globalCells[cIdx].hostGrid();
|
||||
RigGridBase* grid = reservoirCells[cIdx].hostGrid();
|
||||
CVF_ASSERT(grid != NULL);
|
||||
size_t cellIndex = globalCells[cIdx].cellIndex();
|
||||
size_t cellIndex = reservoirCells[cIdx].cellIndex();
|
||||
|
||||
size_t i, j, k;
|
||||
grid->ijkFromCellIndex(cellIndex, &i, &j, &k);
|
||||
@@ -213,7 +213,7 @@ public:
|
||||
}
|
||||
else
|
||||
{
|
||||
size_t parentCellIdx = globalCells[cIdx].parentCellIndex();
|
||||
size_t parentCellIdx = reservoirCells[cIdx].parentCellIndex();
|
||||
parentGrid = (static_cast<RigLocalGrid*>(grid))->parentGrid();
|
||||
CVF_ASSERT(parentGrid != NULL);
|
||||
parentGrid->ijkFromCellIndex(parentCellIdx, &pi, &pj, &pk);
|
||||
@@ -229,7 +229,7 @@ public:
|
||||
hostCellJ.push_back(static_cast<qint32>(pj + 1)); // NB: 1-based index in Octave
|
||||
hostCellK.push_back(static_cast<qint32>(pk + 1)); // NB: 1-based index in Octave
|
||||
|
||||
size_t coarseningIdx = globalCells[cIdx].coarseningBoxIndex();
|
||||
size_t coarseningIdx = reservoirCells[cIdx].coarseningBoxIndex();
|
||||
if (coarseningIdx != cvf::UNDEFINED_SIZE_T)
|
||||
{
|
||||
size_t globalCoarseningIdx = globalCoarseningBoxIndexStart[grid->gridIndex()] + coarseningIdx;
|
||||
|
||||
@@ -148,11 +148,11 @@ public:
|
||||
std::vector<double> values(valueCount);
|
||||
size_t valueIndex = 0;
|
||||
|
||||
size_t globalCellCount = activeInfo->reservoirCellCount();
|
||||
size_t reservoirCellCount = activeInfo->reservoirCellCount();
|
||||
for (size_t tIdx = 0; tIdx < requestedTimesteps.size(); ++tIdx)
|
||||
{
|
||||
std::vector<double>& doubleValues = scalarResultFrames->at(requestedTimesteps[tIdx]);
|
||||
for (size_t gcIdx = 0; gcIdx < globalCellCount; ++gcIdx)
|
||||
for (size_t gcIdx = 0; gcIdx < reservoirCellCount; ++gcIdx)
|
||||
{
|
||||
size_t resultIdx = activeInfo->cellResultIndex(gcIdx);
|
||||
if (resultIdx == cvf::UNDEFINED_SIZE_T) continue;
|
||||
@@ -528,18 +528,18 @@ public:
|
||||
|
||||
RigActiveCellInfo* activeCellInfo = m_currentReservoir->reservoirData()->activeCellInfo(m_porosityModelEnum);
|
||||
|
||||
size_t globalActiveCellCount = activeCellInfo->reservoirActiveCellCount();
|
||||
size_t activeCellCountReservoir = activeCellInfo->reservoirActiveCellCount();
|
||||
size_t totalCellCount = activeCellInfo->reservoirCellCount();
|
||||
size_t globalCellResultCount = activeCellInfo->reservoirCellResultCount();
|
||||
size_t reservoirCellResultCount = activeCellInfo->reservoirCellResultCount();
|
||||
|
||||
bool isCoarseningActive = globalCellResultCount != globalActiveCellCount;
|
||||
bool isCoarseningActive = reservoirCellResultCount != activeCellCountReservoir;
|
||||
|
||||
if (cellCountFromOctave != globalActiveCellCount )
|
||||
if (cellCountFromOctave != activeCellCountReservoir )
|
||||
{
|
||||
server->errorMessageDialog()->showMessage(RiaSocketServer::tr("ResInsight SocketServer: \n") +
|
||||
RiaSocketServer::tr("The number of cells in the data coming from octave does not match the case") + ":\"" + m_currentReservoir->caseUserDescription() + "\"\n"
|
||||
" Octave: " + QString::number(cellCountFromOctave) + "\n"
|
||||
" " + m_currentReservoir->caseUserDescription() + ": Active cell count: " + QString::number(globalActiveCellCount) + " Total cell count: " + QString::number(totalCellCount)) ;
|
||||
" " + m_currentReservoir->caseUserDescription() + ": Active cell count: " + QString::number(activeCellCountReservoir) + " Total cell count: " + QString::number(totalCellCount)) ;
|
||||
|
||||
cellCountFromOctave = 0;
|
||||
m_invalidActiveCellCountDetected = true;
|
||||
@@ -554,7 +554,7 @@ public:
|
||||
for (size_t tIdx = 0; tIdx < m_timeStepCountToRead; ++tIdx)
|
||||
{
|
||||
size_t tsId = m_requestedTimesteps[tIdx];
|
||||
m_scalarResultsToAdd->at(tsId).resize(globalCellResultCount, HUGE_VAL);
|
||||
m_scalarResultsToAdd->at(tsId).resize(reservoirCellResultCount, HUGE_VAL);
|
||||
}
|
||||
|
||||
std::vector<double> readBuffer;
|
||||
|
||||
Reference in New Issue
Block a user