COOLFluiD  Release kernel
COOLFluiD is a Collaborative Simulation Environment (CSE) focused on complex MultiPhysics simulations.
Partitioner.hpp
Go to the documentation of this file.
1 // Copyright (C) 2010-2011 von Karman Institute for Fluid Dynamics, Belgium
2 //
3 // This software is distributed under the terms of the
4 // GNU Lesser General Public License version 3 (LGPLv3).
5 // See doc/lgpl.txt and doc/gpl.txt for the license text.
6 
7 #ifndef cf3_mesh_ptscotch_Partitioner_hpp
8 #define cf3_mesh_ptscotch_Partitioner_hpp
9 
11 
12 #include "mesh/MeshPartitioner.hpp"
14 
15 namespace cf3 {
16 namespace mesh {
17 namespace ptscotch {
18 
20 
25 
26 public: // typedefs
27 
29 
31 
32 
33 public: // functions
34 
37  Partitioner ( const std::string& name );
38 
40  virtual ~Partitioner();
41 
43  static std::string type_name () { return "Partitioner"; }
44 
46 
47  virtual void build_graph();
48 
49  virtual void partition_graph();
50 
51 private: // functions
52 
53 
55  SCOTCH_Dgraph graph;
56 
57  SCOTCH_Num baseval; // first index of an array starts with 0 for c++
58  SCOTCH_Num vertglbnbr; // number of vertices in the total mesh
59  SCOTCH_Num edgeglbnbr; // number of connections in the total mesh
60  SCOTCH_Num procglbnbr; // number of processors
61 
62  SCOTCH_Num vertlocnbr; // number of vertices on this processor
63  SCOTCH_Num vertgstnbr; // number of vertices on this processor, including ghost vertices
64  SCOTCH_Num edgelocnbr; // number of connections to other vertices starting from each local vertex
65 
66  SCOTCH_Num vertlocmax;
67  SCOTCH_Num edgelocsiz;
68  std::vector<SCOTCH_Num> vertloctab;
69  std::vector<SCOTCH_Num> edgeloctab;
70  std::vector<SCOTCH_Num> edgegsttab;
71  std::vector<SCOTCH_Num> partloctab;
72  std::vector<SCOTCH_Num> proccnttab;// number of vertices per processor
73  std::vector<SCOTCH_Num> procvrttab;// start_idx of the vertex for each processor + one extra index greater than vertglbnbr
74 };
75 
77 
78 } // ptscotch
79 } // mesh
80 } // CF
81 
83 
84 #endif // cf3_mesh_ptscotch_Partitioner_hpp
std::vector< SCOTCH_Num > vertloctab
Definition: Partitioner.hpp:68
std::string name(ComponentWrapper &self)
static std::string type_name()
Get the class name.
Definition: Partitioner.hpp:43
SCOTCH_Dgraph graph
common values accessed by all tests goes here
Definition: Partitioner.hpp:55
std::vector< SCOTCH_Num > edgeloctab
Definition: Partitioner.hpp:69
std::vector< SCOTCH_Num > proccnttab
Definition: Partitioner.hpp:72
#define mesh_ptscotch_API
Definition: LibPTScotch.hpp:26
Top-level namespace for coolfluid.
Definition: Action.cpp:18
std::vector< SCOTCH_Num > procvrttab
Definition: Partitioner.hpp:73
std::vector< SCOTCH_Num > partloctab
Definition: Partitioner.hpp:71
std::vector< SCOTCH_Num > edgegsttab
Definition: Partitioner.hpp:70
Send comments to:
COOLFluiD Web Admin