35 #include <lifev/core/array/VectorEpetraStructured.hpp> 59 ASSERT ( mapVector.nbMap() > 0 ,
"Map vector empty, impossible to construct a VectorBlockMonolithicEpetra!" );
61 map_Type myMap ( mapVector.totalMap() );
64 this->setMap ( myMap );
93 M_blockStructure.setBlockStructure ( blockSizes );
95 ASSERT ( M_blockStructure.totalSize() ==
static_cast<UInt> (
this->size() ),
" Incompatible block structure (global size does not match) " );
102 M_blockStructure.setBlockStructure ( mapVector );
104 ASSERT ( M_blockStructure.totalSize() ==
static_cast<UInt> (
this->size() ),
" Incompatible block structure (global size does not match) " );
111 M_blockStructure.setBlockStructure ( blockStructure );
122 return M_blockStructure.blockSize ( index );
129 blockView.setup ( M_blockStructure.blockFirstIndex ( index ), M_blockStructure.blockSize ( index ),
this );
138 vectorBlockView->setup ( M_blockStructure.blockFirstIndex ( index ), M_blockStructure.blockSize ( index ),
this );
140 return vectorBlockView;
147 return M_blockStructure;
VectorEpetra - The Epetra Vector format Wrapper.
VectorEpetraStructuredView block_type
Type of the view.
Epetra_CombineMode combineMode_Type
void blockView(const UInt &index, block_type &blockView)
Getter for the block index.
VectorBlockStructure - class representing the structure of a vector.
VectorBlockStructure blockStructure() const
VectorEpetraStructured(const mapVector_type &mapVector, const mapType_type &mapType=Unique, const combineMode_Type combineMode=Add)
Construction with a vector of map.
VectorEpetraStructured(const VectorEpetraStructured &vector)
Copy constructor.
VectorEpetraStructured(const VectorEpetraStructured &vector, const mapType_type &mapType)
Copy constructor with a specified map type (Repeated/Unique)
VectorEpetra(const MapEpetra &map, const MapEpetraType &mapType=Unique, const combineMode_Type combineMode=Add)
Constructor - Using Maps.
void updateInverseJacobian(const UInt &iQuadPt)
VectorEpetraStructured(const map_Type &map, const mapType_type &mapType=Unique, const combineMode_Type combineMode=Add)
Constructor with the monolithic map.
void setBlockStructure(const std::vector< UInt > &blockSizes)
VectorEpetraStructured - class of block vector.
VectorEpetra(const MapEpetraType &mapType=Unique, const combineMode_Type combineMode=Add)
Empty Constructor.
MapEpetraType mapType_type
Type of the map (Unique/Repeated)
std::shared_ptr< block_type > block_ptrType
Pointer on the view.
Epetra_CombineMode combine_type
Combine mode.
MapVector< map_Type > mapVector_type
Type of the MapVector to be used with this class.
UInt blockSize(const UInt &index) const
Getter for the size of the block index.
void setBlockStructure(const VectorBlockStructure &blockStructure)
MapEpetra map_Type
Type of the map to be used.
block_ptrType block(const UInt &index)
Getter for the block index.
uint32_type UInt
generic unsigned integer (used mainly for addressing)
VectorEpetraStructured(const VectorEpetraStructured &vector, const mapType_type &mapType, const combine_type &combineMode)
Copy constructor with specified map type and combine mode.
void setBlockStructure(const mapVector_type &mapVector)
Reset the block structure using the blocks of a vector of map.