Flow123d
JS_before_hm-1804-gf2ad740aa
|
Go to the documentation of this file.
18 #ifndef SPARSE_GRAPH_HH_
19 #define SPARSE_GRAPH_HH_
27 #include "petscistypes.h"
79 void set_edge(
const int a,
const int b,
int weight=1);
90 void set_vtx_position(
const int vtx,
const float xyz[3],
int weight=1);
108 virtual void partition(
int *loc_part) = 0;
114 bool check_subgraph_connectivity(
int *part);
159 virtual void allocate_sparse_graph(
int lsize_vtxs,
int lsize_adj)=0;
187 :
SparseGraph(distr), petsc_adj_mat(0), petsc_part(0), part_IS(0) {}
191 virtual void partition(
int *loc_part);
198 virtual void allocate_sparse_graph(
int lsize_vtxs,
int lsize_adj);
226 virtual void partition(
int *loc_part);
229 virtual void allocate_sparse_graph(
int lsize_vtxs,
int lsize_adj);
SparseGraphPETSC(int n_vtxs, MPI_Comm comm)
SparseGraphMETIS(const Distribution &distr)
MatPartitioning petsc_part
Support classes for parallel programing.
SparseGraphPETSC(const Distribution &distr)
Distribution vtx_distr
distribution of vertexes
int * part_to_check
created partitioning used through check of connectivity
vector< stack< Edge > > adj_of_proc
storage for graph edges for individual processors
SparseGraphMETIS(int n_vtxs, MPI_Comm comm)
int proc_to_check
subgraph to check
std::vector< int > checked_vtx
coloring of DFS algorithm
float * vtx_XYZ
optional vertex coordinates (global array)
ostream & operator<<(ostream &out, const SparseGraph &sg)
Output a sparse graph.
int weight
Edge weights for communication (optional).
bool operator<(IntersectionResult a, IntersectionResult b)
int * vtx_weights
Vertex weights for computations (optional).
Virtual class for construction and partitioning of a distributed sparse graph.