From b70d8a564d827aa20c751c3a8a49d613729cef7a Mon Sep 17 00:00:00 2001 From: Kilian Weishaupt <kilian.weishaupt@iws.uni-stuttgart.de> Date: Fri, 15 Dec 2017 17:48:59 +0100 Subject: [PATCH] [staggered][faceVars] Use new index method --- dumux/discretization/staggered/freeflow/facevariables.hh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dumux/discretization/staggered/freeflow/facevariables.hh b/dumux/discretization/staggered/freeflow/facevariables.hh index dc09d3d43f..26b07b34df 100644 --- a/dumux/discretization/staggered/freeflow/facevariables.hh +++ b/dumux/discretization/staggered/freeflow/facevariables.hh @@ -43,6 +43,7 @@ class StaggeredFaceVariables using FacePrimaryVariables = typename GET_PROP_TYPE(TypeTag, FacePrimaryVariables); using SubControlVolumeFace = typename GET_PROP_TYPE(TypeTag, SubControlVolumeFace); using FVElementGeometry = typename GET_PROP_TYPE(TypeTag, FVElementGeometry); + using Indices = typename GET_PROP_TYPE(TypeTag, Indices); static constexpr int dimWorld = GridView::dimensionworld; static constexpr int numPairs = (dimWorld == 2) ? 2 : 4; @@ -120,13 +121,13 @@ public: { const auto& normalFace = fvGeometry.scvf(scvf.insideScvIdx(), subFaceData.localNormalFaceIdx); const auto normalDirIdx = normalFace.directionIndex(); - velocityNormalOutside_[i] = problem.dirichlet(element, makeGhostFace(subFaceData.virtualOuterNormalFaceDofPos))[faceIdx][normalDirIdx]; + velocityNormalOutside_[i] = problem.dirichlet(element, makeGhostFace(subFaceData.virtualOuterNormalFaceDofPos))[Indices::velocity(normalDirIdx)]; } // treat the velocity parallel to the face velocityParallel_[i] = hasParallelNeighbor(subFaceData) ? velocityParallel_[i] = faceSol[subFaceData.outerParallelFaceDofIdx] : - problem.dirichlet(element, makeGhostFace(subFaceData.virtualOuterParallelFaceDofPos))[faceIdx][scvf.directionIndex()]; + problem.dirichlet(element, makeGhostFace(subFaceData.virtualOuterParallelFaceDofPos))[Indices::velocity(scvf.directionIndex())]; } } -- GitLab