[refactor] Remove unnecessary copy in axisCentroid and simply code.

We stored 3 copies of each cell centroid in axisCentroid. This seemed
to be a waste of memory and also made the function distanceVector_ hard
to understand.

With this change we omit this copy of information and simplify distanceVector_
This commit is contained in:
Markus Blatt
2024-06-27 15:15:33 +02:00
parent 54d303ae5d
commit d7c869d01a
2 changed files with 17 additions and 62 deletions

View File

@@ -257,10 +257,8 @@ protected:
const DimVector& distance,
const Scalar& poro) const;
DimVector distanceVector_(const DimVector& center,
int faceIdx, // in the reference element that contains the intersection
unsigned elemIdx,
const std::array<std::vector<DimVector>, dimWorld>& axisCentroids) const;
DimVector distanceVector_(const DimVector& faceCenter,
const std::array<double,dimWorld>& cellCenter) const;
void applyMultipliers_(Scalar& trans,
unsigned faceIdx,