Commit bf1916a2 authored by Alexander Danilov's avatar Alexander Danilov
Browse files

Updates for FVDiscr example

Perform partitioning only for serial meshes in parallel mode.
Reorder rows in GeomParam table (Issue #3).
parent d2399f89
......@@ -88,6 +88,7 @@ int main(int argc,char ** argv)
//~ if( m->GetProcessorRank() == 0 ) std::cout << "Load(MPI_Scatter): " << Timer()-ttt2 << std::endl;
#if defined(USE_PARTITIONER)
if (!repartition) { // currently only non-distributed meshes are supported by Inner_RCM partitioner
ttt = Timer();
Partitioner * p = new Partitioner(m);
p->SetMethod(Partitioner::Inner_RCM,Partitioner::Partition); // Specify the partitioner
......@@ -103,6 +104,7 @@ int main(int argc,char ** argv)
BARRIER
if( m->GetProcessorRank() == 0 ) std::cout << "Redistribute: " << Timer()-ttt << std::endl;
}
#endif
ttt = Timer();
......@@ -128,13 +130,13 @@ int main(int argc,char ** argv)
Solver::Matrix A; // Declare the matrix of the linear system to be solved
Solver::Vector x,b; // Declare the solution and the right-hand side vectors
tiny_map<GeometricData,ElementType,5> table;
Mesh::GeomParam table;
table[MEASURE] = CELL | FACE;
table[CENTROID] = CELL | FACE;
table[BARYCENTER] = CELL | FACE;
table[NORMAL] = FACE;
table[ORIENTATION] = FACE;
table[MEASURE] = CELL | FACE;
table[BARYCENTER] = CELL | FACE;
m->PrepareGeometricData(table);
//~ BARRIER
//~ if( m->GetProcessorRank() == 0 ) std::cout << "Prepare geometric data: " << Timer()-ttt << std::endl;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment