Feel++
0.91.0
|
Public Member Functions | |
VectorPetscMPI (Vec v, DataMap const &dm) | |
VectorPetscMPI (DataMap const &dm) | |
void | init (const size_type N, const size_type n_local, const bool fast=false) |
value_type | operator() (const size_type i) const |
void | set (size_type i, const value_type &value) |
void | add (const size_type i, const value_type &value) |
void | addVector (int *i, int n, value_type *v) |
void | clear () |
void | localize () |
void | close () |
size_type | firstLocalIndex () const |
size_type | lastLocalIndex () const |
Feel::VectorPetscMPI< T >::VectorPetscMPI | ( | Vec | v, |
DataMap const & | dm | ||
) |
HERE!!!
References Feel::VectorPetscMPI< T >::close(), Feel::Vector< T >::comm(), and Feel::DataMap::nLocalDofWithGhost().
void Feel::VectorPetscMPI< T >::add | ( | const size_type | i, |
const value_type & | value | ||
) | [virtual] |
v(i) += value
Reimplemented from Feel::VectorPetsc< T >.
void Feel::VectorPetscMPI< T >::addVector | ( | int * | i, |
int | n, | ||
value_type * | v | ||
) | [virtual] |
v([i1,i2,...,in]) += [value1,...,valuen]
Reimplemented from Feel::VectorPetsc< T >.
void Feel::VectorPetscMPI< T >::clear | ( | ) | [virtual] |
VectorPetsc<T>
to a pristine state. Reimplemented from Feel::VectorPetsc< T >.
void Feel::VectorPetscMPI< T >::close | ( | ) | [virtual] |
Call the assemble functions
Reimplemented from Feel::VectorPetsc< T >.
Referenced by Feel::VectorPetscMPI< T >::VectorPetscMPI(), and Feel::MatrixPetscMPI< T >::zeroRows().
size_type Feel::VectorPetscMPI< T >::firstLocalIndex | ( | ) | const [virtual] |
Reimplemented from Feel::VectorPetsc< T >.
void Feel::VectorPetscMPI< T >::init | ( | const size_type | N, |
const size_type | n_local, | ||
const bool | fast = false |
||
) | [virtual] |
Change the dimension of the vector to N
. The reserved memory for this vector remains unchanged if possible, to make things faster, but this may waste some memory, so take this in the back of your head. However, if N==0
all memory is freed, i.e. if you want to resize the vector and release the memory not needed, you have to first call init(0)
and then init(N)
. This cited behaviour is analogous to that of the STL containers.
On fast==false
, the vector is filled by zeros.
Reimplemented from Feel::VectorPetsc< T >.
size_type Feel::VectorPetscMPI< T >::lastLocalIndex | ( | ) | const [virtual] |
Reimplemented from Feel::VectorPetsc< T >.
VectorPetscMPI< T >::value_type Feel::VectorPetscMPI< T >::operator() | ( | const size_type | i | ) | const [virtual] |
Access components, returns U(i)
.
Reimplemented from Feel::VectorPetsc< T >.
void Feel::VectorPetscMPI< T >::set | ( | size_type | i, |
const value_type & | value | ||
) | [virtual] |
v(i) = value
Reimplemented from Feel::VectorPetsc< T >.