25 #include <queso/asserts.h>
26 #include <queso/DistArray.h>
27 #include <queso/GslVector.h>
28 #include <queso/GslMatrix.h>
29 #include <queso/ScalarSequence.h>
30 #include <queso/SampledScalarCdf.h>
31 #include <queso/OneDGrid.h>
39 #ifdef QUESO_HAS_TRILINOS
40 m_epetraDistArray(new EpetraExt::
DistArray<T>(inputMap.epetraMap(),inputRowSize))
42 m_rowSize(inputRowSize)
45 #ifdef QUESO_HAS_TRILINOS
58 #ifdef QUESO_HAS_TRILINOS
60 m_epetraDistArray(NULL)
63 #ifdef QUESO_HAS_TRILINOS
74 #ifdef QUESO_HAS_TRILINOS
75 delete m_epetraDistArray;
76 m_epetraDistArray = NULL;
78 for (
int i = 0; i < m_Map.NumGlobalElements(); ++i) {
79 m_elements[i].clear();
90 #ifdef QUESO_HAS_TRILINOS
92 for (
int i = 0; i < m_Map.NumGlobalElements(); ++i) {
93 m_elements[i].clear();
106 #ifdef QUESO_HAS_TRILINOS
107 return (*m_epetraDistArray)(localElementId,colId);
109 return m_elements[localElementId][colId];
117 #ifdef QUESO_HAS_TRILINOS
118 return (*m_epetraDistArray)(localElementId,colId);
120 return m_elements[localElementId][colId];
128 #ifdef QUESO_HAS_TRILINOS
129 return m_epetraDistArray->GlobalLength();
131 return m_Map.NumGlobalElements();
139 #ifdef QUESO_HAS_TRILINOS
140 return m_epetraDistArray->MyLength();
142 return m_Map.NumMyElements();
150 #ifdef QUESO_HAS_TRILINOS
151 return m_epetraDistArray->RowSize();
170 #ifdef QUESO_HAS_TRILINOS
171 os << *m_epetraDistArray;
173 os <<
"m_rowSize = " << m_rowSize
174 <<
", m_elements.size() = " << m_elements.size()
int GlobalLength() const
Returns the global length of the array.
DistArray< T > & operator=(const DistArray< T > &rhs)
Assignment operator.
DistArray()
Default constructor. Do not call this directly.
std::vector< std::vector< T > > m_elements
void copy(const DistArray< T > &src)
Copies the array.
int MyLength() const
Returns the length of the locally owned array.
int RowSize() const
Returns the row size, that is, the amount of data associated with each element.
#define queso_not_implemented()
A class for partitioning vectors and matrices.
T & operator()(int localElementId, int colId)
Returns a reference to the colId column component of the localElementId local element.
A class for partitioning vectors and matrices.
void print(std::ostream &os) const
int NumGlobalElements() const
Returns the total number of elements across all processors.
and that you are informed that you can do these things To protect your we need to make restrictions that forbid distributors to deny you these rights or to ask you to surrender these rights These restrictions translate to certain responsibilities for you if you distribute copies of the library or if you modify it For if you distribute copies of the whether gratis or for a you must give the recipients all the rights that we gave you You must make sure that receive or can get the source code If you link other code with the you must provide complete object files to the so that they can relink them with the library after making changes to the library and recompiling it And you must show them these terms so they know their rights We protect your rights with a two step which gives you legal permission to copy