From 7bc840467dd4c4fcbdb95b821cffbc929d74418a Mon Sep 17 00:00:00 2001 From: Thomas Witkowski <thomas.witkowski@gmx.de> Date: Mon, 13 Feb 2012 12:41:50 +0000 Subject: [PATCH] Rename some object in parallel sources. --- AMDiS/CMakeLists.txt | 2 +- ...ObjectData.cc => ElementObjectDatabase.cc} | 55 ++++++------ ...ntObjectData.h => ElementObjectDatabase.h} | 10 +-- AMDiS/src/parallel/MeshDistributor.cc | 90 ++++++++++--------- AMDiS/src/parallel/MeshDistributor.h | 86 +++++++----------- AMDiS/src/parallel/MeshManipulation.cc | 15 ++-- AMDiS/src/parallel/MeshManipulation.h | 4 +- 7 files changed, 125 insertions(+), 137 deletions(-) rename AMDiS/src/parallel/{ElementObjectData.cc => ElementObjectDatabase.cc} (94%) rename AMDiS/src/parallel/{ElementObjectData.h => ElementObjectDatabase.h} (99%) diff --git a/AMDiS/CMakeLists.txt b/AMDiS/CMakeLists.txt index f131a603..8524b8e5 100644 --- a/AMDiS/CMakeLists.txt +++ b/AMDiS/CMakeLists.txt @@ -224,7 +224,7 @@ if(ENABLE_PARALLEL_DOMAIN) SET(PARALLEL_DOMAIN_AMDIS_SRC ${SOURCE_DIR}/parallel/DofComm.cc ${SOURCE_DIR}/parallel/CheckerPartitioner.cc - ${SOURCE_DIR}/parallel/ElementObjectData.cc + ${SOURCE_DIR}/parallel/ElementObjectDatabase.cc ${SOURCE_DIR}/parallel/MeshDistributor.cc ${SOURCE_DIR}/parallel/MeshManipulation.cc ${SOURCE_DIR}/parallel/MeshPartitioner.cc diff --git a/AMDiS/src/parallel/ElementObjectData.cc b/AMDiS/src/parallel/ElementObjectDatabase.cc similarity index 94% rename from AMDiS/src/parallel/ElementObjectData.cc rename to AMDiS/src/parallel/ElementObjectDatabase.cc index b0f5a2fb..5e42c5f4 100644 --- a/AMDiS/src/parallel/ElementObjectData.cc +++ b/AMDiS/src/parallel/ElementObjectDatabase.cc @@ -10,14 +10,14 @@ // See also license.opensource.txt in the distribution. -#include "ElementObjectData.h" #include "VertexVector.h" +#include "parallel/ElementObjectDatabase.h" namespace AMDiS { - void ElementObjects::addElement(ElInfo *elInfo) + void ElementObjectDatabase::addElement(ElInfo *elInfo) { - FUNCNAME("ElementObjects::addElement()"); + FUNCNAME("ElementObjectDatabase::addElement()"); TEST_EXIT_DBG(mesh)("Mesh not set!\n"); @@ -128,9 +128,9 @@ namespace AMDiS { } - void ElementObjects::createPeriodicData(const FiniteElemSpace *feSpace) + void ElementObjectDatabase::createPeriodicData(const FiniteElemSpace *feSpace) { - FUNCNAME("ElementObjects::createPeriodicData()"); + FUNCNAME("ElementObjectDatabase::createPeriodicData()"); TEST_EXIT_DBG(mesh)("Mesh not set!\n"); @@ -317,9 +317,9 @@ namespace AMDiS { } - BoundaryType ElementObjects::getNewBoundaryType(DOFAdmin *admin) + BoundaryType ElementObjectDatabase::getNewBoundaryType(DOFAdmin *admin) { - FUNCNAME("ElementObjects::getNewBoundaryType()"); + FUNCNAME("ElementObjectDatabase::getNewBoundaryType()"); BoundaryType newPeriodicBoundaryType = 0; for (map<BoundaryType, VertexVector*>::iterator it = mesh->getPeriodicAssociations().begin(); @@ -336,11 +336,12 @@ namespace AMDiS { } - BoundaryType ElementObjects::provideConnectedPeriodicBoundary(DOFAdmin *admin, - BoundaryType b0, - BoundaryType b1) + BoundaryType + ElementObjectDatabase::provideConnectedPeriodicBoundary(DOFAdmin *admin, + BoundaryType b0, + BoundaryType b1) { - FUNCNAME("ElementObjects::provideConnectedPeriodicBoundary()"); + FUNCNAME("ElementObjectDatabase::provideConnectedPeriodicBoundary()"); std::pair<BoundaryType, BoundaryType> bConn = (b0 <= b1 ? make_pair(b0, b1) : make_pair(b1, b0)); @@ -371,9 +372,9 @@ namespace AMDiS { } - void ElementObjects::createRankData(map<int, int>& macroElementRankMap) + void ElementObjectDatabase::createRankData(map<int, int>& macroElementRankMap) { - FUNCNAME("ElementObjects::createRankData()"); + FUNCNAME("ElementObjectDatabase::createRankData()"); vertexOwner.clear(); vertexInRank.clear(); @@ -424,11 +425,11 @@ namespace AMDiS { } - void ElementObjects::createReverseModeData(const FiniteElemSpace* feSpace, - map<int, Element*> &elIndexMap, - map<int, int> &elIndexTypeMap) + void ElementObjectDatabase::createReverseModeData(const FiniteElemSpace* feSpace, + map<int, Element*> &elIndexMap, + map<int, int> &elIndexTypeMap) { - FUNCNAME("ElementObjects::createReverseModeData()"); + FUNCNAME("ElementObjectDatabase::createReverseModeData()"); // === In 2D, all reverse modes are always true! === @@ -537,9 +538,9 @@ namespace AMDiS { } - void ElementObjects::serialize(ostream &out) + void ElementObjectDatabase::serialize(ostream &out) { - FUNCNAME("ElementObjects::serialize()"); + FUNCNAME("ElementObjectDatabase::serialize()"); int nSize = vertexElements.size(); SerUtil::serialize(out, nSize); @@ -664,9 +665,9 @@ namespace AMDiS { } - void ElementObjects::deserialize(istream &in) + void ElementObjectDatabase::deserialize(istream &in) { - FUNCNAME("ElementObjects::deserialize()"); + FUNCNAME("ElementObjectDatabase::deserialize()"); int nSize; SerUtil::deserialize(in, nSize); @@ -821,7 +822,8 @@ namespace AMDiS { } - void ElementObjects::serialize(ostream &out, vector<ElementObjectData>& elVec) + void ElementObjectDatabase::serialize(ostream &out, + vector<ElementObjectData>& elVec) { int nSize = elVec.size(); SerUtil::serialize(out, nSize); @@ -830,7 +832,8 @@ namespace AMDiS { } - void ElementObjects::deserialize(istream &in, vector<ElementObjectData>& elVec) + void ElementObjectDatabase::deserialize(istream &in, + vector<ElementObjectData>& elVec) { int nSize; SerUtil::deserialize(in, nSize); @@ -840,7 +843,8 @@ namespace AMDiS { } - void ElementObjects::serialize(ostream &out, map<int, ElementObjectData>& data) + void ElementObjectDatabase::serialize(ostream &out, + map<int, ElementObjectData>& data) { int nSize = data.size(); SerUtil::serialize(out, nSize); @@ -852,7 +856,8 @@ namespace AMDiS { } - void ElementObjects::deserialize(istream &in, map<int, ElementObjectData>& data) + void ElementObjectDatabase::deserialize(istream &in, + map<int, ElementObjectData>& data) { int nSize; SerUtil::deserialize(in, nSize); diff --git a/AMDiS/src/parallel/ElementObjectData.h b/AMDiS/src/parallel/ElementObjectDatabase.h similarity index 99% rename from AMDiS/src/parallel/ElementObjectData.h rename to AMDiS/src/parallel/ElementObjectDatabase.h index 25d85e28..bb8d857a 100644 --- a/AMDiS/src/parallel/ElementObjectData.h +++ b/AMDiS/src/parallel/ElementObjectDatabase.h @@ -18,10 +18,10 @@ -/** \file ElementObjectData.h */ +/** \file ElementObjectDatabase.h */ -#ifndef AMDIS_ELEMENTOBJECTDATA_H -#define AMDIS_ELEMENTOBJECTDATA_H +#ifndef AMDIS_ELEMENT_OBJECT_DATABASE_H +#define AMDIS_ELEMENT_OBJECT_DATABASE_H #include <map> #include <vector> @@ -99,9 +99,9 @@ namespace AMDiS { * boundaries on object level. This is required, because two elements may share * a common vertex without beging neighbours in the definition of AMDiS. */ - class ElementObjects { + class ElementObjectDatabase { public: - ElementObjects() + ElementObjectDatabase() : mesh(NULL), iterGeoPos(CENTER) {} diff --git a/AMDiS/src/parallel/MeshDistributor.cc b/AMDiS/src/parallel/MeshDistributor.cc index dfe708d1..8168809d 100644 --- a/AMDiS/src/parallel/MeshDistributor.cc +++ b/AMDiS/src/parallel/MeshDistributor.cc @@ -156,7 +156,7 @@ namespace AMDiS { } } while (doNext); - elObjects.setMesh(feSpaces[0]->getMesh()); + elObjDb.setMesh(feSpaces[0]->getMesh()); // If the problem has been already read from a file, we need only to set // isRankDofs to all matrices and rhs vector and to remove periodic @@ -559,7 +559,7 @@ namespace AMDiS { while (elInfo) { for (int i = 0; i < 4; i++) { ElementObjectData elData(elInfo->getElement()->getIndex(), i); - allEdges.insert(elObjects.getEdgeLocalMap(elData)); + allEdges.insert(elObjDb.getEdgeLocalMap(elData)); } rankMacroEls.insert(elInfo->getElement()->getIndex()); @@ -572,7 +572,7 @@ namespace AMDiS { bool valid3dMesh = true; for (std::set<DofEdge>::iterator it = allEdges.begin(); it != allEdges.end(); ++it) { - vector<ElementObjectData>& edgeEls = elObjects.getElements(*it); + vector<ElementObjectData>& edgeEls = elObjDb.getElements(*it); TEST_EXIT_DBG(edgeEls.size() > 0) ("No edge %d/%d in elObjDB!\n", it->first, it->second); @@ -1326,7 +1326,7 @@ namespace AMDiS { // === Remove double DOFs. === MeshManipulation meshManipulation(mesh); - meshManipulation.deleteDoubleDofs(feSpaces, newMacroEl, elObjects); + meshManipulation.deleteDoubleDofs(feSpaces, newMacroEl, elObjDb); mesh->dofCompress(); partitioner->createPartitionMap(partitionMap); @@ -1415,7 +1415,7 @@ namespace AMDiS { { FUNCNAME("MeshDistributor::updateInteriorBoundaryInfo()"); - elObjects.createRankData(partitionMap); + elObjDb.createRankData(partitionMap); createBoundaryData(); #if (DEBUG != 0) @@ -1443,22 +1443,22 @@ namespace AMDiS { macroElIndexMap.insert(make_pair(el->getIndex(), el)); macroElIndexTypeMap.insert(make_pair(el->getIndex(), elInfo->getType())); - // Add all sub object of the element to the variable elObjects. - elObjects.addElement(elInfo); + // Add all sub object of the element to the variable elObjDb. + elObjDb.addElement(elInfo); elInfo = stack.traverseNext(elInfo); } // Create periodic data, if there are periodic boundary conditions. - elObjects.createPeriodicData(feSpaces[0]); + elObjDb.createPeriodicData(feSpaces[0]); // Create data about the reverse modes of neighbouring elements. - elObjects.createReverseModeData(feSpaces[0], macroElIndexMap, - macroElIndexTypeMap); + elObjDb.createReverseModeData(feSpaces[0], macroElIndexMap, + macroElIndexTypeMap); // Create mesh element data for this rank. - elObjects.createRankData(partitionMap); + elObjDb.createRankData(partitionMap); } @@ -1478,12 +1478,12 @@ namespace AMDiS { for (int geoPos = 0; geoPos < mesh->getDim(); geoPos++) { GeoIndex geoIndex = INDEX_OF_DIM(geoPos, mesh->getDim()); - while (elObjects.iterate(geoIndex)) { - map<int, ElementObjectData>& objData = elObjects.getIterateData(); + while (elObjDb.iterate(geoIndex)) { + map<int, ElementObjectData>& objData = elObjDb.getIterateData(); if (!(objData.count(mpiRank) && objData.size() > 1)) continue; - int owner = elObjects.getIterateOwner(); + int owner = elObjDb.getIterateOwner(); ElementObjectData& rankBoundEl = objData[mpiRank]; AtomicBoundary bound; @@ -1521,10 +1521,10 @@ namespace AMDiS { b = bound; if (geoIndex == EDGE) b.neighObj.reverseMode = - elObjects.getEdgeReverseMode(rankBoundEl, it2->second); + elObjDb.getEdgeReverseMode(rankBoundEl, it2->second); if (geoIndex == FACE) b.neighObj.reverseMode = - elObjects.getFaceReverseMode(rankBoundEl, it2->second); + elObjDb.getFaceReverseMode(rankBoundEl, it2->second); } } else { @@ -1545,10 +1545,10 @@ namespace AMDiS { b = bound; if (geoIndex == EDGE) b.rankObj.reverseMode = - elObjects.getEdgeReverseMode(rankBoundEl, ownerBoundEl); + elObjDb.getEdgeReverseMode(rankBoundEl, ownerBoundEl); if (geoIndex == FACE) b.rankObj.reverseMode = - elObjects.getFaceReverseMode(rankBoundEl, ownerBoundEl); + elObjDb.getFaceReverseMode(rankBoundEl, ownerBoundEl); } } } @@ -1556,16 +1556,16 @@ namespace AMDiS { // === Create periodic boundary data structure. === - for (PerBoundMap<DegreeOfFreedom>::iterator it = elObjects.getPeriodicVertices().begin(); - it != elObjects.getPeriodicVertices().end(); ++it) { - if (elObjects.isInRank(it->first.first, mpiRank) == false) + for (PerBoundMap<DegreeOfFreedom>::iterator it = elObjDb.getPeriodicVertices().begin(); + it != elObjDb.getPeriodicVertices().end(); ++it) { + if (elObjDb.isInRank(it->first.first, mpiRank) == false) continue; ElementObjectData& perDofEl0 = - elObjects.getElementsInRank(it->first.first)[mpiRank]; + elObjDb.getElementsInRank(it->first.first)[mpiRank]; - for (map<int, ElementObjectData>::iterator elIt = elObjects.getElementsInRank(it->first.second).begin(); - elIt != elObjects.getElementsInRank(it->first.second).end(); ++elIt) { + for (map<int, ElementObjectData>::iterator elIt = elObjDb.getElementsInRank(it->first.second).begin(); + elIt != elObjDb.getElementsInRank(it->first.second).end(); ++elIt) { int otherElementRank = elIt->first; ElementObjectData& perDofEl1 = elIt->second; @@ -1601,15 +1601,15 @@ namespace AMDiS { } - for (PerBoundMap<DofEdge>::iterator it = elObjects.getPeriodicEdges().begin(); - it != elObjects.getPeriodicEdges().end(); ++it) { - if (elObjects.isInRank(it->first.first, mpiRank) == false) + for (PerBoundMap<DofEdge>::iterator it = elObjDb.getPeriodicEdges().begin(); + it != elObjDb.getPeriodicEdges().end(); ++it) { + if (elObjDb.isInRank(it->first.first, mpiRank) == false) continue; - ElementObjectData& perEdgeEl0 = elObjects.getElementsInRank(it->first.first)[mpiRank]; + ElementObjectData& perEdgeEl0 = elObjDb.getElementsInRank(it->first.first)[mpiRank]; - for (map<int, ElementObjectData>::iterator elIt = elObjects.getElementsInRank(it->first.second).begin(); - elIt != elObjects.getElementsInRank(it->first.second).end(); ++elIt) { + for (map<int, ElementObjectData>::iterator elIt = elObjDb.getElementsInRank(it->first.second).begin(); + elIt != elObjDb.getElementsInRank(it->first.second).end(); ++elIt) { int otherElementRank = elIt->first; ElementObjectData& perEdgeEl1 = elIt->second; @@ -1633,27 +1633,29 @@ namespace AMDiS { b = bound; if (mpiRank > otherElementRank) - b.neighObj.reverseMode = elObjects.getEdgeReverseMode(perEdgeEl0, perEdgeEl1); + b.neighObj.reverseMode = + elObjDb.getEdgeReverseMode(perEdgeEl0, perEdgeEl1); else - b.rankObj.reverseMode = elObjects.getEdgeReverseMode(perEdgeEl0, perEdgeEl1); + b.rankObj.reverseMode = + elObjDb.getEdgeReverseMode(perEdgeEl0, perEdgeEl1); } } - for (PerBoundMap<DofFace>::iterator it = elObjects.getPeriodicFaces().begin(); - it != elObjects.getPeriodicFaces().end(); ++it) { - if (elObjects.isInRank(it->first.first, mpiRank) == false) + for (PerBoundMap<DofFace>::iterator it = elObjDb.getPeriodicFaces().begin(); + it != elObjDb.getPeriodicFaces().end(); ++it) { + if (elObjDb.isInRank(it->first.first, mpiRank) == false) continue; - TEST_EXIT_DBG(elObjects.getElements(it->first.first).size() == 1) + TEST_EXIT_DBG(elObjDb.getElements(it->first.first).size() == 1) ("Should not happen!\n"); - TEST_EXIT_DBG(elObjects.getElements(it->first.second).size() == 1) + TEST_EXIT_DBG(elObjDb.getElements(it->first.second).size() == 1) ("Should not happen!\n"); - ElementObjectData& perFaceEl0 = elObjects.getElementsInRank(it->first.first)[mpiRank]; + ElementObjectData& perFaceEl0 = elObjDb.getElementsInRank(it->first.first)[mpiRank]; - for (map<int, ElementObjectData>::iterator elIt = elObjects.getElementsInRank(it->first.second).begin(); - elIt != elObjects.getElementsInRank(it->first.second).end(); ++elIt) { + for (map<int, ElementObjectData>::iterator elIt = elObjDb.getElementsInRank(it->first.second).begin(); + elIt != elObjDb.getElementsInRank(it->first.second).end(); ++elIt) { int otherElementRank = elIt->first; ElementObjectData& perFaceEl1 = elIt->second; @@ -1678,10 +1680,10 @@ namespace AMDiS { if (mpiRank > otherElementRank) b.neighObj.reverseMode = - elObjects.getFaceReverseMode(perFaceEl0, perFaceEl1); + elObjDb.getFaceReverseMode(perFaceEl0, perFaceEl1); else b.rankObj.reverseMode = - elObjects.getFaceReverseMode(perFaceEl0, perFaceEl1); + elObjDb.getFaceReverseMode(perFaceEl0, perFaceEl1); } } @@ -2259,7 +2261,7 @@ namespace AMDiS { SerUtil::serialize(out, elemWeights); SerUtil::serialize(out, partitionMap); - elObjects.serialize(out); + elObjDb.serialize(out); rankIntBoundary.serialize(out); otherIntBoundary.serialize(out); @@ -2329,7 +2331,7 @@ namespace AMDiS { } } - elObjects.deserialize(in); + elObjDb.deserialize(in); rankIntBoundary.deserialize(in, elIndexMap); otherIntBoundary.deserialize(in, elIndexMap); diff --git a/AMDiS/src/parallel/MeshDistributor.h b/AMDiS/src/parallel/MeshDistributor.h index a7c91421..fe6ed677 100644 --- a/AMDiS/src/parallel/MeshDistributor.h +++ b/AMDiS/src/parallel/MeshDistributor.h @@ -26,7 +26,7 @@ #include <mpi.h> #include "parallel/DofComm.h" -#include "parallel/ElementObjectData.h" +#include "parallel/ElementObjectDatabase.h" #include "parallel/ParallelTypes.h" #include "parallel/MeshPartitioner.h" #include "parallel/InteriorBoundary.h" @@ -607,11 +607,9 @@ namespace AMDiS { /// Mesh of the problem. Mesh *mesh; - /** \brief - * A refinement manager that should be used on the mesh. It is used to - * refine elements at interior boundaries in order to fit together with - * elements on the other side of the interior boundary. - */ + /// A refinement manager that should be used on the mesh. It is used to + /// refine elements at interior boundaries in order to fit together with + /// elements on the other side of the interior boundary. RefinementManager *refineManager; /// Info level. @@ -625,17 +623,15 @@ namespace AMDiS { /// this element. map<int, double> elemWeights; - /** \brief - * Stores to every macro element index the number of the rank that owns this - * macro element. - */ + /// Stores to every macro element index the number of the rank that owns this + /// macro element. map<int, int> partitionMap; map<const FiniteElemSpace*, DofData> dofFeData; - /// Data structure to store all sub-objects of all elements of the + /// Database to store and query all sub-objects of all elements of the /// macro mesh. - ElementObjects elObjects; + ElementObjectDatabase elObjDb; /// Maps to each macro element index a pointer to the corresponding element. map<int, Element*> macroElIndexMap; @@ -643,47 +639,35 @@ namespace AMDiS { /// Maps to each macro element index the type of this element. map<int, int> macroElIndexTypeMap; - /** \brief - * Defines the interior boundaries of the domain that result from - * partitioning the whole mesh. Contains only the boundaries, which are - * owned by the rank, i.e., the object gives for every neighbour rank i - * the boundaries this rank owns and shares with rank i. - */ + /// Defines the interior boundaries of the domain that result from + /// partitioning the whole mesh. Contains only the boundaries, which are + /// owned by the rank, i.e., the object gives for every neighbour rank i + /// the boundaries this rank owns and shares with rank i. InteriorBoundary rankIntBoundary; - /** \brief - * Defines the interior boundaries of the domain that result from - * partitioning the whole mesh. Contains only the boundaries, which are - * not owned by the rank, i.e., the object gives for every neighbour rank - * i the boundaries that are owned by rank i and are shared with this rank. - */ + /// Defines the interior boundaries of the domain that result from + /// partitioning the whole mesh. Contains only the boundaries, which are + /// not owned by the rank, i.e., the object gives for every neighbour rank + /// i the boundaries that are owned by rank i and are shared with this rank. InteriorBoundary otherIntBoundary; - /** \brief - * Defines the periodic boundaries with other ranks. Periodic boundaries - * have no owner, as it is the case of interior boundaries. - */ + /// Defines the periodic boundaries with other ranks. Periodic boundaries + /// have no owner, as it is the case of interior boundaries. InteriorBoundary periodicBoundary; - /** \brief - * This map contains for each rank the list of DOFs the current rank must - * send to exchange solution DOFs at the interior boundaries. - */ + /// This map contains for each rank the list of DOFs the current rank must + /// end to exchange solution DOFs at the interior boundaries. DofComm sendDofs; - /** \brief - * This map contains on each rank the list of DOFs from which the current - * rank will receive DOF values (i.e., this are all DOFs at an interior - * boundary). The DOF indices are given in rank's local numbering. - */ + /// This map contains on each rank the list of DOFs from which the current + /// rank will receive DOF values (i.e., this are all DOFs at an interior + /// boundary). The DOF indices are given in rank's local numbering. DofComm recvDofs; - /** \brief - * This map contains on each rank a list of DOFs along the interior bound- - * aries to communicate with other ranks. The DOF indices are given in rank's - * local numbering. Periodic boundaries within one subdomain are not - * considered here. - */ + /// This map contains on each rank a list of DOFs along the interior bound- + /// aries to communicate with other ranks. The DOF indices are given in rank's + /// local numbering. Periodic boundaries within one subdomain are not + /// considered here. DofComm periodicDofs; PeriodicMap periodicMap; @@ -692,12 +676,10 @@ namespace AMDiS { /// repartitioned. vector<DOFVector<double>*> interchangeVectors; - /** \brief - * If the problem definition has been read from a serialization file, this - * variable is true, otherwise it is false. This variable is used to stop the - * initialization function, if the problem definition has already been read - * from a serialization file. - */ + /// If the problem definition has been read from a serialization file, this + /// variable is true, otherwise it is false. This variable is used to stop the + /// initialization function, if the problem definition has already been read + /// from a serialization file. bool deserialized; /// Denotes whether there exists a filewriter for this object. @@ -721,10 +703,8 @@ namespace AMDiS { /// Directory name where all debug output files should be written to. string debugOutputDir; - /** \brief - * Stores the mesh change index. This is used to recognize changes in the - * mesh structure (e.g. through refinement or coarsening managers). - */ + /// Stores the mesh change index. This is used to recognize changes in the + /// mesh structure (e.g. through refinement or coarsening managers). long lastMeshChangeIndex; /// Stores for all macro elements of the original macro mesh the diff --git a/AMDiS/src/parallel/MeshManipulation.cc b/AMDiS/src/parallel/MeshManipulation.cc index 5583cd6b..a5d29129 100644 --- a/AMDiS/src/parallel/MeshManipulation.cc +++ b/AMDiS/src/parallel/MeshManipulation.cc @@ -43,7 +43,7 @@ namespace AMDiS { void MeshManipulation::deleteDoubleDofs(vector<const FiniteElemSpace*>& feSpaces, std::set<MacroElement*>& newMacroEl, - ElementObjects &objects) + ElementObjectDatabase &elObjDb) { FUNCNAME("MeshManipulation::deleteDoubleDofs()"); @@ -92,7 +92,7 @@ namespace AMDiS { for (int i = 0; i < mesh->getGeo(VERTEX); i++) { vector<ElementObjectData> &vertexEl = - objects.getElementsVertex((*it)->getIndex(), i); + elObjDb.getElementsVertex((*it)->getIndex(), i); for (vector<ElementObjectData>::iterator elIt = vertexEl.begin(); elIt != vertexEl.end(); ++elIt) { @@ -121,7 +121,7 @@ namespace AMDiS { ElementObjectData elObj((*it)->getIndex(), i); vector<ElementObjectData> &edgeEl = - objects.getElementsEdge((*it)->getIndex(), i); + elObjDb.getElementsEdge((*it)->getIndex(), i); for (vector<ElementObjectData>::iterator elIt = edgeEl.begin(); elIt != edgeEl.end(); ++elIt) { @@ -135,7 +135,7 @@ namespace AMDiS { Element *el0 = (*it)->getElement(); Element *el1 = macroIndexMap[elIt->elIndex]->getElement(); - bool reverseMode = objects.getEdgeReverseMode(elObj, *elIt); + bool reverseMode = elObjDb.getEdgeReverseMode(elObj, *elIt); BoundaryObject b0(el0, 0, EDGE, i, reverseMode); BoundaryObject b1(el1, 0, EDGE, elIt->ithObject, false); @@ -171,7 +171,7 @@ namespace AMDiS { ElementObjectData elObj((*it)->getIndex(), i); vector<ElementObjectData> &faceEl = - objects.getElementsFace((*it)->getIndex(), i); + elObjDb.getElementsFace((*it)->getIndex(), i); for (vector<ElementObjectData>::iterator elIt = faceEl.begin(); elIt != faceEl.end(); ++elIt) { @@ -179,12 +179,13 @@ namespace AMDiS { continue; if (macrosProcessed.count(elIt->elIndex) == 1) { - TEST_EXIT_DBG(macroIndexMap.count(elIt->elIndex))("Should not happen!\n"); + TEST_EXIT_DBG(macroIndexMap.count(elIt->elIndex)) + ("Should not happen!\n"); Element *el0 = (*it)->getElement(); Element *el1 = macroIndexMap[elIt->elIndex]->getElement(); - bool reverseMode = objects.getFaceReverseMode(elObj, *elIt); + bool reverseMode = elObjDb.getFaceReverseMode(elObj, *elIt); BoundaryObject b0(el0, 0, FACE, i, reverseMode); BoundaryObject b1(el1, 0, FACE, elIt->ithObject, false); diff --git a/AMDiS/src/parallel/MeshManipulation.h b/AMDiS/src/parallel/MeshManipulation.h index c64bd8ae..d9726945 100644 --- a/AMDiS/src/parallel/MeshManipulation.h +++ b/AMDiS/src/parallel/MeshManipulation.h @@ -27,7 +27,7 @@ #include <map> #include "AMDiS_fwd.h" -#include "parallel/ElementObjectData.h" +#include "parallel/ElementObjectDatabase.h" namespace AMDiS { @@ -39,7 +39,7 @@ namespace AMDiS { void deleteDoubleDofs(vector<const FiniteElemSpace*>& feSpaces, std::set<MacroElement*>& newMacroEl, - ElementObjects &elObj); + ElementObjectDatabase &elObj); /** \brief * Starts the procedure to fit a given edge/face of an element with a mesh -- GitLab