From 70dc296a13089e86841e9836fc9e76e12718d2e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jacob=20St=C3=B8ren?= Date: Fri, 8 Aug 2014 10:51:39 +0200 Subject: [PATCH] Rename of GlobalCell to ReservoirCell --- .../RivFaultGeometryGenerator.cpp | 4 ++-- .../ReservoirDataModel/RigFault.cpp | 6 +++--- ApplicationCode/ReservoirDataModel/RigFault.h | 10 +++++----- .../ReservoirDataModel/RigMainGrid.cpp | 20 +++++++++---------- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/ApplicationCode/ModelVisualization/RivFaultGeometryGenerator.cpp b/ApplicationCode/ModelVisualization/RivFaultGeometryGenerator.cpp index a45a4dad3e..a0ef33d344 100644 --- a/ApplicationCode/ModelVisualization/RivFaultGeometryGenerator.cpp +++ b/ApplicationCode/ModelVisualization/RivFaultGeometryGenerator.cpp @@ -163,12 +163,12 @@ void RivFaultGeometryGenerator::computeArrays() #pragma omp parallel for for (int fIdx = 0; fIdx < static_cast(faultFaces.size()); fIdx++) { - size_t cellIndex = faultFaces[fIdx].m_nativeGlobalCellIndex; + size_t cellIndex = faultFaces[fIdx].m_nativeReservoirCellIndex; cvf::StructGridInterface::FaceType face = faultFaces[fIdx].m_nativeFace; if (!m_computeNativeFaultFaces) { - cellIndex = faultFaces[fIdx].m_oppositeGlobalCellIndex; + cellIndex = faultFaces[fIdx].m_oppositeReservoirCellIndex; face = cvf::StructGridInterface::oppositeFace(faultFaces[fIdx].m_nativeFace); } diff --git a/ApplicationCode/ReservoirDataModel/RigFault.cpp b/ApplicationCode/ReservoirDataModel/RigFault.cpp index 0db6f08c90..82e5c35eb3 100644 --- a/ApplicationCode/ReservoirDataModel/RigFault.cpp +++ b/ApplicationCode/ReservoirDataModel/RigFault.cpp @@ -145,10 +145,10 @@ void RigFault::accumulateFaultsPrCell(RigFaultsPrCellAccumulator* faultsPrCellA { const FaultFace& ff = m_faultFaces[ffIdx]; - // Could detect overlapping faults here .... if (faultsPrCellAcc->faultIdx(ff.m_nativeGlobalCellIndex, ff.m_nativeFace) >= 0) + // Could detect overlapping faults here .... if (faultsPrCellAcc->faultIdx(ff.m_nativeReservoirCellIndex, ff.m_nativeFace) >= 0) - faultsPrCellAcc->setFaultIdx(ff.m_nativeGlobalCellIndex, ff.m_nativeFace, faultIdx); - faultsPrCellAcc->setFaultIdx(ff.m_oppositeGlobalCellIndex, cvf::StructGridInterface::oppositeFace(ff.m_nativeFace), faultIdx); + faultsPrCellAcc->setFaultIdx(ff.m_nativeReservoirCellIndex, ff.m_nativeFace, faultIdx); + faultsPrCellAcc->setFaultIdx(ff.m_oppositeReservoirCellIndex, cvf::StructGridInterface::oppositeFace(ff.m_nativeFace), faultIdx); } } diff --git a/ApplicationCode/ReservoirDataModel/RigFault.h b/ApplicationCode/ReservoirDataModel/RigFault.h index 0d310bce35..44d232bd7d 100644 --- a/ApplicationCode/ReservoirDataModel/RigFault.h +++ b/ApplicationCode/ReservoirDataModel/RigFault.h @@ -66,15 +66,15 @@ public: struct FaultFace { - FaultFace(size_t nativeGlobalCellIndex, cvf::StructGridInterface::FaceType nativeFace, size_t oppositeGlobalCellIndex) : - m_nativeGlobalCellIndex(nativeGlobalCellIndex), + FaultFace(size_t nativeReservoirCellIndex, cvf::StructGridInterface::FaceType nativeFace, size_t oppositeReservoirCellIndex) : + m_nativeReservoirCellIndex(nativeReservoirCellIndex), m_nativeFace(nativeFace), - m_oppositeGlobalCellIndex(oppositeGlobalCellIndex) + m_oppositeReservoirCellIndex(oppositeReservoirCellIndex) { } - size_t m_nativeGlobalCellIndex; + size_t m_nativeReservoirCellIndex; cvf::StructGridInterface::FaceType m_nativeFace; - size_t m_oppositeGlobalCellIndex; + size_t m_oppositeReservoirCellIndex; }; public: diff --git a/ApplicationCode/ReservoirDataModel/RigMainGrid.cpp b/ApplicationCode/ReservoirDataModel/RigMainGrid.cpp index dc58bf21c3..21a8645632 100644 --- a/ApplicationCode/ReservoirDataModel/RigMainGrid.cpp +++ b/ApplicationCode/ReservoirDataModel/RigMainGrid.cpp @@ -234,7 +234,7 @@ void RigMainGrid::calculateFaults() continue; } - size_t neighborGlobalCellIdx; + size_t neighborReservoirCellIdx; size_t neighborGridCellIdx; size_t i, j, k; RigGridBase* hostGrid = NULL; @@ -259,8 +259,8 @@ void RigMainGrid::calculateFaults() continue; } - neighborGlobalCellIdx = hostGrid->reservoirCellIndex(neighborGridCellIdx); - if (m_cells[neighborGlobalCellIdx].isInvalid()) + neighborReservoirCellIdx = hostGrid->reservoirCellIndex(neighborGridCellIdx); + if (m_cells[neighborReservoirCellIdx].isInvalid()) { continue; } @@ -271,7 +271,7 @@ void RigMainGrid::calculateFaults() caf::SizeTArray4 faceIdxs; m_cells[gcIdx].faceIndices(face, &faceIdxs); caf::SizeTArray4 nbFaceIdxs; - m_cells[neighborGlobalCellIdx].faceIndices(StructGridInterface::oppositeFace(face), &nbFaceIdxs); + m_cells[neighborReservoirCellIdx].faceIndices(StructGridInterface::oppositeFace(face), &nbFaceIdxs); const std::vector& vxs = m_mainGrid->nodes(); @@ -289,17 +289,17 @@ void RigMainGrid::calculateFaults() // To avoid doing this calculation for the opposite face faultsPrCellAcc->setFaultIdx(gcIdx, face, unNamedFaultIdx); - faultsPrCellAcc->setFaultIdx(neighborGlobalCellIdx, StructGridInterface::oppositeFace(face), unNamedFaultIdx); + faultsPrCellAcc->setFaultIdx(neighborReservoirCellIdx, StructGridInterface::oppositeFace(face), unNamedFaultIdx); //m_cells[gcIdx].setCellFaceFault(face); - //m_cells[neighborGlobalCellIdx].setCellFaceFault(StructGridInterface::oppositeFace(face)); + //m_cells[neighborReservoirCellIdx].setCellFaceFault(StructGridInterface::oppositeFace(face)); // Add as fault face only if the grid index is less than the neighbors - if (static_cast(gcIdx) < neighborGlobalCellIdx) + if (static_cast(gcIdx) < neighborReservoirCellIdx) { { - RigFault::FaultFace ff(gcIdx, cvf::StructGridInterface::FaceType(faceIdx), neighborGlobalCellIdx); + RigFault::FaultFace ff(gcIdx, cvf::StructGridInterface::FaceType(faceIdx), neighborReservoirCellIdx); unNamedFault->faultFaces().push_back(ff); } @@ -382,7 +382,7 @@ const RigFault* RigMainGrid::findFaultFromCellIndexAndCellFace(size_t cellIndex, for (size_t fIdx = 0; fIdx < faultFaces.size(); fIdx++) { - if (faultFaces[fIdx].m_nativeGlobalCellIndex == cellIndex) + if (faultFaces[fIdx].m_nativeReservoirCellIndex == cellIndex) { if (face == faultFaces[fIdx].m_nativeFace ) { @@ -390,7 +390,7 @@ const RigFault* RigMainGrid::findFaultFromCellIndexAndCellFace(size_t cellIndex, } } - if (faultFaces[fIdx].m_oppositeGlobalCellIndex == cellIndex) + if (faultFaces[fIdx].m_oppositeReservoirCellIndex == cellIndex) { if (face == cvf::StructGridInterface::oppositeFace(faultFaces[fIdx].m_nativeFace)) {