Zoltan2
Zoltan2_Typedefs.hpp
Go to the documentation of this file.
1 // @HEADER
2 //
3 // ***********************************************************************
4 //
5 // Zoltan2: A package of combinatorial algorithms for scientific computing
6 // Copyright 2012 Sandia Corporation
7 //
8 // Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
9 // the U.S. Government retains certain rights in this software.
10 //
11 // Redistribution and use in source and binary forms, with or without
12 // modification, are permitted provided that the following conditions are
13 // met:
14 //
15 // 1. Redistributions of source code must retain the above copyright
16 // notice, this list of conditions and the following disclaimer.
17 //
18 // 2. Redistributions in binary form must reproduce the above copyright
19 // notice, this list of conditions and the following disclaimer in the
20 // documentation and/or other materials provided with the distribution.
21 //
22 // 3. Neither the name of the Corporation nor the names of the
23 // contributors may be used to endorse or promote products derived from
24 // this software without specific prior written permission.
25 //
26 // THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
27 // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
28 // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
29 // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
30 // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
31 // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
32 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
33 // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
34 // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
35 // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
36 // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
37 //
38 // Questions? Contact Karen Devine (kddevin@sandia.gov)
39 // Erik Boman (egboman@sandia.gov)
40 // Siva Rajamanickam (srajama@sandia.gov)
41 //
42 // ***********************************************************************
43 //
44 // @HEADER
45 
50 #ifndef ZOLTAN2_TYPEDEFS
51 #define ZOLTAN2_TYPEDEFS
52 
53 #include "Zoltan2_TestHelpers.hpp"
54 #include <Tpetra_MultiVector.hpp>
55 #include <Tpetra_Vector.hpp>
56 #include <Tpetra_CrsMatrix.hpp>
57 #include <Zoltan2_Metric.hpp>
58 //#include <Tpetra_Map.hpp>
59 //#include <Xpetra_Vector_decl.hpp>
60 //#include <Xpetra_CrsMatrix_decl.hpp>
61 //#include <Xpetra_CrsGraph_decl.hpp>
62 //
67 //
69 //#include "GeometricGenerator.hpp"
70 
71 // Forward declaration for classes in the Tpetra namespace
72 // namespace Tpetra {
73 //
74 // template<typename T1, typename T2, typename T3, typename T4, const bool T5>
75 // class CrsMatrix;
76 //
77 // template<typename T1, typename T2, typename T3, const bool T4>
78 // class CrsGraph;
79 //
80 // template<typename T1, typename T2, typename T3, typename T4, const bool T5>
81 // class Vector;
82 //
83 // template<typename T1, typename T2, typename T3, typename T4, const bool T5>
84 // class MultiVector;
85 // }
86 //
87 // // Forward declaration for classes in the Xpetra namespace
88 // namespace Xpetra {
89 //
90 // template<typename T1, typename T2, typename T3, typename T4>
91 // class CrsMatrix;
92 //
93 // template<typename T1, typename T2, typename T3>
94 // class CrsGraph;
95 //
96 // template<typename T1, typename T2, typename T3, typename T4>
97 // class Vector;
98 //
99 // template<typename T1, typename T2, typename T3, typename T4>
100 // class MultiVector;
101 // }
102 
103  // Forward declaration for classes in the GeometricGen namespace
104  namespace GeometricGen {
105  template<typename T1, typename T2, typename T3, typename T4>
106  class GeometricGenerator;
107  }
108 
109 // Forward declaration of classes in the Zoltan2 namespace
110  namespace Zoltan2 {
111  template<typename T1, typename T2, typename T3>
112  class BasicUserTypes;
113 
114  template<typename T1>
115  class BaseAdapter;
116 
117  template<typename T1>
118  class BasicIdentifierAdapter;
119 
120  template<typename T1>
121  class XpetraMultiVectorAdapter;
122 
123  template<typename T1, typename T2>
124  class XpetraCrsGraphAdapter;
125 
126  template<typename T1, typename T2>
127  class XpetraCrsMatrixAdapter;
128 
129  template<typename T1>
130  class BasicVectorAdapter;
131 
132  #ifdef HAVE_ZOLTAN2_PAMGEN
133  template<typename T1>
134  class PamgenMeshAdapter;
135  #endif
136 
137  template<typename T1>
138  class Problem;
139 
140  template<typename T1>
141  class PartitioningProblem;
142 
143  template<typename T1>
144  class OrderingProblem;
145 
146  template<typename T1>
147  class ColoringProblem;
148  }
149 
150 namespace Zoltan2_TestingFramework {
151 
152  // Data types
153  typedef Tpetra::CrsMatrix<zscalar_t, zlno_t, zgno_t, znode_t> tcrsMatrix_t;
154  typedef Tpetra::CrsGraph<zlno_t, zgno_t, znode_t> tcrsGraph_t;
155  typedef Tpetra::Vector<zscalar_t, zlno_t, zgno_t, znode_t> tVector_t;
156  typedef Tpetra::MultiVector<zscalar_t, zlno_t, zgno_t, znode_t> tMVector_t;
157 
158  typedef Xpetra::CrsMatrix<zscalar_t, zlno_t, zgno_t, znode_t> xcrsMatrix_t;
159  typedef Xpetra::CrsGraph<zlno_t, zgno_t, znode_t> xcrsGraph_t;
160  typedef Xpetra::Vector<zscalar_t, zlno_t, zgno_t, znode_t> xVector_t;
161  typedef Xpetra::MultiVector<zscalar_t, zlno_t, zgno_t, znode_t> xMVector_t;
162 
165 
166  // Adapter types
174 
175 #ifdef HAVE_ZOLTAN2_PAMGEN
177 #else
178  // This typedef exists only to satisfy the compiler.
179  // PamgenMeshAdapter cannot be used when Trilinos is not built with Pamgen
181 #endif
182 
183  // Problem types
188 
190 }
191 
192 #endif
Zoltan2::BaseAdapter< userTypes_t > base_adapter_t
Tpetra::MultiVector< zscalar_t, zlno_t, zgno_t, znode_t > tMVector_t
ColoringProblem sets up coloring problems for the user.
Zoltan2::BasicUserTypes< zscalar_t, zlno_t, zgno_t > userTypes_t
Xpetra::Vector< zscalar_t, zlno_t, zgno_t, znode_t > xVector_t
Provides access for Zoltan2 to Xpetra::CrsMatrix data.
Zoltan2::PartitioningProblem< basic_id_t > partitioning_problem_t
Zoltan2::OrderingProblem< basic_id_t > ordering_problem_t
A simple class that can be the User template argument for an InputAdapter.
Provides access for Zoltan2 to Xpetra::CrsGraph data.
common code used by tests
Zoltan2::ColoringProblem< basic_id_t > coloring_problem_t
Zoltan2::BasicVectorAdapter< tMVector_t > basic_vector_adapter
OrderingProblem sets up ordering problems for the user.
This class represents a collection of global Identifiers and their associated weights, if any.
Zoltan2::XpetraMultiVectorAdapter< tMVector_t > xpetra_mv_adapter
Xpetra::MultiVector< zscalar_t, zlno_t, zgno_t, znode_t > xMVector_t
GeometricGen::GeometricGenerator< zscalar_t, zlno_t, zgno_t, znode_t > geometricgen_t
Xpetra::CrsGraph< zlno_t, zgno_t, znode_t > xcrsGraph_t
Problem base class from which other classes (PartitioningProblem, ColoringProblem, OrderingProblem, MatchingProblem, etc.) derive.
Xpetra::CrsMatrix< zscalar_t, zlno_t, zgno_t, znode_t > xcrsMatrix_t
BasicVectorAdapter represents a vector (plus optional weights) supplied by the user as pointers to st...
An adapter for Xpetra::MultiVector.
Tpetra::Vector< zscalar_t, zlno_t, zgno_t, znode_t > tVector_t
Tpetra::CrsMatrix< zscalar_t, zlno_t, zgno_t, znode_t > tcrsMatrix_t
Tpetra::CrsGraph< zlno_t, zgno_t, znode_t > tcrsGraph_t
PartitioningProblem sets up partitioning problems for the user.
BaseAdapter defines methods required by all Adapters.
Zoltan2::XpetraCrsGraphAdapter< tcrsGraph_t, tMVector_t > xcrsGraph_adapter
Zoltan2::XpetraCrsMatrixAdapter< tcrsMatrix_t, tMVector_t > xcrsMatrix_adapter
This class represents a mesh.
Zoltan2::BasicIdentifierAdapter< userTypes_t > basic_id_t
Zoltan2::BasicVectorAdapter< tMVector_t > pamgen_adapter_t
Zoltan2::BaseClassMetrics< zscalar_t > base_metric_t
Zoltan2::Problem< basic_id_t > base_problem_t