LifeV
VectorBlockMonolithicEpetraView Class Reference

VectorBlockMonolithicEpetraView - class representing a block in a VectorBlockMonolithicEpetra. More...

#include <VectorBlockMonolithicEpetraView.hpp>

+ Collaboration diagram for VectorBlockMonolithicEpetraView:

Private Attributes

UInt M_blockSize
 
UInt M_firstIndex
 
UInt M_lastValidIndex
 
vector_TypeM_vector
 

Public Types

typedef VectorEpetra vector_Type
 Typedef for the underlying vector type. More...
 

Constructor & Destructor

 VectorBlockMonolithicEpetraView ()
 Default constructor. More...
 
 VectorBlockMonolithicEpetraView (const VectorBlockMonolithicEpetraView &otherView)
 Copy constructor. More...
 
 ~VectorBlockMonolithicEpetraView ()
 Default destructor. More...
 

Methods

void showMe (std::ostream &output=std::cout) const
 Print the informations about the VectorBlockMonolithicEpetraView. More...
 
Int sumIntoGlobalValues (const Int GID, const Real value) const
 Assembly procedure. More...
 

Set Methods

void setup (const UInt &firstIndex, const UInt &blockSize, vector_Type *vector)
 

Get Methods

UInt blockSize () const
 Returns the size of the block. More...
 
UInt firstIndex () const
 Returns the index in the block. More...
 
UInt lastValidIndex () const
 Returns the last index in the block. More...
 
vector_TypevectorPtr () const
 Return the shared_pointer of the Epetra_FEVector. More...
 

Private Methods

VectorBlockMonolithicEpetraView operator= (const VectorBlockMonolithicEpetraView &otherView)
 No assignement operator. More...
 

Detailed Description

VectorBlockMonolithicEpetraView - class representing a block in a VectorBlockMonolithicEpetra.

Author
Samuel Quinodoz

The VectorBlockMonolithicEpetraView class contains data related to block of a vector. It is useful to setup a clean and easy-to-use blocks management.

For more information about the block structures in LifeV, see this page.

Definition at line 58 of file VectorBlockMonolithicEpetraView.hpp.

Member Typedef Documentation

◆ vector_Type

Typedef for the underlying vector type.

Definition at line 66 of file VectorBlockMonolithicEpetraView.hpp.

Constructor & Destructor Documentation

◆ VectorBlockMonolithicEpetraView() [1/2]

Default constructor.

Definition at line 47 of file VectorBlockMonolithicEpetraView.cpp.

◆ VectorBlockMonolithicEpetraView() [2/2]

Copy constructor.

Beware that using the copy constructor, the view is copied but not the underlying vector (both views still look at the same vector, not at different copies).

Definition at line 55 of file VectorBlockMonolithicEpetraView.cpp.

◆ ~VectorBlockMonolithicEpetraView()

Default destructor.

Definition at line 63 of file VectorBlockMonolithicEpetraView.cpp.

Member Function Documentation

◆ showMe()

void showMe ( std::ostream &  output = std::cout) const

Print the informations about the VectorBlockMonolithicEpetraView.

Parameters
outputStream where to print the informations

Definition at line 72 of file VectorBlockMonolithicEpetraView.cpp.

◆ sumIntoGlobalValues()

Int sumIntoGlobalValues ( const Int  GID,
const Real  value 
) const

Assembly procedure.

This procedure should always have the same behaviour and the same syntax than the corresponding method in MatrixEpetra.

Parameters
GIDthe global index of the element within the block viewed.
valuethe value to be added

Definition at line 82 of file VectorBlockMonolithicEpetraView.cpp.

◆ setup()

void setup ( const UInt firstIndex,
const UInt blockSize,
vector_Type vector 
)

Set all the informations relative to the block

Parameters
firstIndexFirst index in the block
blockSizeNumber of indices in the block
vectorVector from which the view has to be extracted

Definition at line 98 of file VectorBlockMonolithicEpetraView.cpp.

◆ blockSize()

UInt blockSize ( ) const
inline

Returns the size of the block.

Definition at line 132 of file VectorBlockMonolithicEpetraView.hpp.

◆ firstIndex()

UInt firstIndex ( ) const
inline

Returns the index in the block.

Definition at line 138 of file VectorBlockMonolithicEpetraView.hpp.

◆ lastValidIndex()

UInt lastValidIndex ( ) const
inline

Returns the last index in the block.

Definition at line 144 of file VectorBlockMonolithicEpetraView.hpp.

◆ vectorPtr()

vector_Type* vectorPtr ( ) const
inline

Return the shared_pointer of the Epetra_FEVector.

Definition at line 150 of file VectorBlockMonolithicEpetraView.hpp.

◆ operator=()

VectorBlockMonolithicEpetraView operator= ( const VectorBlockMonolithicEpetraView otherView)
private

No assignement operator.

The assignement operator is disabled in order to avoid confusing notation like vector.block(0) = vector.block(1), that would only copy the views and not the blocks.

Field Documentation

◆ M_blockSize

UInt M_blockSize
private

Definition at line 173 of file VectorBlockMonolithicEpetraView.hpp.

◆ M_firstIndex

UInt M_firstIndex
private

Definition at line 174 of file VectorBlockMonolithicEpetraView.hpp.

◆ M_lastValidIndex

UInt M_lastValidIndex
private

Definition at line 175 of file VectorBlockMonolithicEpetraView.hpp.

◆ M_vector

vector_Type* M_vector
private

Definition at line 176 of file VectorBlockMonolithicEpetraView.hpp.


The documentation for this class was generated from the following files: