From 79bcb0eddacb79d2f4146df9bc036844b739e44a Mon Sep 17 00:00:00 2001 From: Thomas Witkowski <thomas.witkowski@gmx.de> Date: Thu, 9 Feb 2012 12:57:30 +0000 Subject: [PATCH] Fixed a sequential problem in ARH reader. --- AMDiS/src/io/ArhReader.h | 8 ++++++++ AMDiS/src/parallel/ElementObjectData.cc | 6 ++++-- AMDiS/src/parallel/ElementObjectData.h | 9 ++++++--- 3 files changed, 18 insertions(+), 5 deletions(-) diff --git a/AMDiS/src/io/ArhReader.h b/AMDiS/src/io/ArhReader.h index 22862e81..800564ef 100644 --- a/AMDiS/src/io/ArhReader.h +++ b/AMDiS/src/io/ArhReader.h @@ -36,12 +36,20 @@ namespace AMDiS { DOFVector<double>* vec0 = NULL, DOFVector<double>* vec1 = NULL, DOFVector<double>* vec2 = NULL, +#ifdef HAVE_PARALLEL_DOMAIN_AMDIS bool writeParallel = true, +#else + bool writeParallel = false, +#endif int nProcs = -1); static void read(string filename, Mesh *mesh, vector<DOFVector<double>*> vecs, +#ifdef HAVE_PARALLEL_DOMAIN_AMDIS bool writeParallel = true, +#else + bool writeParallel = false, +#endif int nProcs = -1); static int getNumValueVectors(string filename) diff --git a/AMDiS/src/parallel/ElementObjectData.cc b/AMDiS/src/parallel/ElementObjectData.cc index 177d5a5b..b0f5a2fb 100644 --- a/AMDiS/src/parallel/ElementObjectData.cc +++ b/AMDiS/src/parallel/ElementObjectData.cc @@ -290,8 +290,10 @@ namespace AMDiS { pair<DegreeOfFreedom, DegreeOfFreedom> testVertex = make_pair(it->first.second, it->first.first); - TEST_EXIT_DBG(periodicVertices.count(testVertex) == 1)("Should not happen!\n"); - TEST_EXIT_DBG(periodicVertices[testVertex] == it->second)("Should not happen!\n"); + TEST_EXIT_DBG(periodicVertices.count(testVertex) == 1) + ("Should not happen!\n"); + TEST_EXIT_DBG(periodicVertices[testVertex] == it->second) + ("Should not happen!\n"); } for (PerBoundMap<DofEdge>::iterator it = periodicEdges.begin(); diff --git a/AMDiS/src/parallel/ElementObjectData.h b/AMDiS/src/parallel/ElementObjectData.h index cb0d444b..dd0737f2 100644 --- a/AMDiS/src/parallel/ElementObjectData.h +++ b/AMDiS/src/parallel/ElementObjectData.h @@ -315,7 +315,8 @@ namespace AMDiS { } - /// Returns a vector with all macro elements that have a given vertex DOF in common. + /// Returns a vector with all macro elements that have a given vertex DOF + /// in common. vector<ElementObjectData>& getElements(DegreeOfFreedom vertex) { return vertexElements[vertex]; @@ -334,7 +335,8 @@ namespace AMDiS { } - /// Returns a vector with all macro elements that have a given vertex DOF in common. + /// Returns a vector with all macro elements that have a given vertex DOF + /// in common. vector<ElementObjectData>& getElementsVertex(int elIndex, int ithVertex) { ElementObjectData elObj(elIndex, ithVertex); @@ -506,7 +508,8 @@ namespace AMDiS { void deserialize(istream &in, map<int, ElementObjectData>& data); private: - /// The mesh that is used to store all its element information in the database. + /// The mesh that is used to store all its element information in + /// the database. Mesh *mesh; /// Maps to each vertex DOF all element objects that represent this vertex. -- GitLab