dune-fem
2.4.1-rc
|
#include </local/tomalk/somewhere/tmp/dune-fem/dune/fem/space/common/arrays.hh>
Public Types | |
typedef T | FieldType |
typedef T | value_type |
definition conforming to STL More... | |
typedef T | block_type |
definition conforming to ISTL More... | |
typedef GenericIterator< ThisType, T > | DofIteratorType |
DofIterator. More... | |
typedef DofIteratorType | iterator |
make compatible with std::vector More... | |
typedef GenericIterator< const ThisType, const T > | ConstDofIteratorType |
Const DofIterator. More... | |
typedef ConstDofIteratorType | const_iterator |
make compatible with std::vector More... | |
typedef size_t | size_type |
type of unsigned integral type of indexing More... | |
Public Member Functions | |
MutableArray () | |
create array of length 0 More... | |
MutableArray (const MutableArray &other) | |
copy constructor More... | |
MutableArray (const size_t size) | |
create array of length size More... | |
void | setMemoryFactor (const double memFactor) |
set memory factor More... | |
~MutableArray () | |
Destructor. More... | |
size_t | capacity () const |
return number of total enties of array More... | |
ThisType & | operator= (const ThisType &org) |
assign arrays More... | |
void | resize (size_t nsize) |
void | reserve (size_t mSize) |
size_t | usedMemorySize () const |
return size of vector in bytes More... | |
DofIteratorType | begin () |
iterator pointing to begin of array More... | |
ConstDofIteratorType | begin () const |
const iterator pointing to begin of array More... | |
DofIteratorType | end () |
iterator pointing to end of array More... | |
ConstDofIteratorType | end () const |
const iterator pointing to end of array More... | |
size_t | size () const |
return number of enties of array More... | |
T & | operator[] (const size_t i) |
return reference to entry i More... | |
const T & | operator[] (const size_t i) const |
return reference to const entry i More... | |
ThisType & | operator+= (const ThisType &org) |
operator += More... | |
ThisType & | operator-= (const ThisType &org) |
operator -= More... | |
ThisType & | operator*= (const T scalar) |
operator *= multiplies array with a scalar More... | |
ThisType & | operator/= (const T scalar) |
operator /= divides array with a scalar More... | |
void | axpy (const ThisType &org, const T scalar) |
axpy operation More... | |
template<> | |
void | axpy (const ThisType &org, const double scalar) |
void | clear () |
set all entries to zero More... | |
template<> | |
void | clear () |
template<> | |
void | clear () |
void | memmove (const int length, const int oldStartIdx, const int newStartIdx) |
move memory from old to new destination More... | |
bool | operator== (const ThisType &other) const |
T * | leakPointer () |
return leak pointer for usage in BLAS routines More... | |
const T * | leakPointer () const |
return leak pointer for usage in BLAS routines More... | |
T * | data () |
return leak pointer for usage in BLAS routines More... | |
const T * | data () const |
return leak pointer for usage in BLAS routines More... | |
template<class StreamTraits > | |
bool | write (OutStreamInterface< StreamTraits > &out) const |
write to stream More... | |
template<class StreamTraits > | |
bool | read (InStreamInterface< StreamTraits > &in) |
write to stream More... | |
void | print (std::ostream &s) const |
print array More... | |
Protected Types | |
typedef MutableArray< T, AllocatorType > | ThisType |
typedef StaticArray< T > | BaseType |
Protected Member Functions | |
void | adjustMemory (size_t mSize) |
adjust the memory More... | |
void | freeMemory () |
Protected Attributes | |
double | memoryFactor_ |
size_t | memSize_ |
T * | vec_ |
size_t | size_ |
MutableArray is the array that a discrete functions sees. If a discrete function is created, then it is signed in by the function space and the return value is a MemObject. This MemObject contains a MutableArrayMemory which is then as reference given to the MutableArray of the DiscreteFunction. The MutableArray is only a wrapper class for MutableArrayMemory where we dont know the type of the dofs only the size of one dof. Therefore we have this wrapper class for cast to the right type.
|
protected |
|
inherited |
definition conforming to ISTL
|
inherited |
make compatible with std::vector
|
inherited |
Const DofIterator.
|
inherited |
DofIterator.
|
inherited |
|
inherited |
make compatible with std::vector
|
inherited |
type of unsigned integral type of indexing
|
protected |
|
inherited |
definition conforming to STL
|
inline |
create array of length 0
|
inline |
copy constructor
|
inline |
create array of length size
|
inline |
Destructor.
|
inlineprotected |
adjust the memory
|
inlineinherited |
axpy operation
|
inlineinherited |
References Dune::Fem::StaticArray< T >::vec_.
|
inlineinherited |
iterator pointing to begin of array
Referenced by Dune::Fem::CodimIndexSet< GridImp >::read(), and Dune::Fem::CodimIndexSet< GridImp >::resetUsed().
|
inlineinherited |
const iterator pointing to begin of array
|
inline |
return number of total enties of array
|
inlineinherited |
set all entries to zero
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
return leak pointer for usage in BLAS routines
|
inlineinherited |
return leak pointer for usage in BLAS routines
|
inlineinherited |
iterator pointing to end of array
Referenced by Dune::Fem::CodimIndexSet< GridImp >::read(), and Dune::Fem::CodimIndexSet< GridImp >::resetUsed().
|
inlineinherited |
const iterator pointing to end of array
|
inlineprotected |
|
inlineinherited |
return leak pointer for usage in BLAS routines
|
inlineinherited |
return leak pointer for usage in BLAS routines
|
inlineinherited |
move memory from old to new destination
|
inlineinherited |
operator *= multiplies array with a scalar
|
inlineinherited |
operator +=
|
inlineinherited |
operator -=
|
inlineinherited |
operator /= divides array with a scalar
|
inline |
assign arrays
|
inlineinherited |
Comparison operator The comparison operator checks for object identity, i.e. if this and other are the same objects in memory rather than containing the same data
|
inlineinherited |
return reference to entry i
|
inlineinherited |
return reference to const entry i
|
inlineinherited |
print array
|
inlineinherited |
write to stream
|
inline |
reserve vector size with new mSize if mSize is smaller then actual memSize, then nothing is done
Referenced by Dune::Fem::CommunicationIndexMap::reserve(), and Dune::Fem::MutableBlockVector< MutableArray< F >, BlockSize >::reserve().
|
inline |
resize vector with new size nsize if nsize is smaller then actual memSize, size is just set to new value
Referenced by Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::applyLocal(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::applyLocalNeighbor(), Dune::Fem::CodimIndexSet< GridImp >::clear(), Dune::Fem::CodimIndexSet< GridImp >::compress(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::evalVolumetricPartBoth(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::evalVolumetricPartFlux(), Dune::Fem::CodimIndexSet< GridImp >::insertIdx(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::prepare(), Dune::Fem::CodimIndexSet< GridImp >::read(), Dune::Fem::CommunicationIndexMap::readFromBuffer(), Dune::Fem::CommunicationIndexMap::resize(), Dune::Fem::MutableBlockVector< MutableArray< F >, BlockSize >::resize(), and Dune::Fem::ThreadIterator< GridPart, ptype >::update().
|
inline |
set memory factor
Referenced by Dune::Fem::CommunicationIndexMap::CommunicationIndexMap(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::LocalDGPass(), Dune::Fem::CodimIndexSet< GridImp >::setMemoryFactor(), Dune::Fem::SpecialArrayFeatures< MutableArray< ValueType > >::setMemoryFactor(), and Dune::Fem::ThreadIterator< GridPart, ptype >::ThreadIterator().
|
inlineinherited |
return number of enties of array
Referenced by Dune::Fem::CodimIndexSet< GridImp >::additionalSizeEstimate(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::applyLocal(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::applyLocalNeighbor(), Dune::Fem::CodimIndexSet< GridImp >::clearHoles(), Dune::Fem::CodimIndexSet< GridImp >::compress(), Dune::Fem::CodimIndexSet< GridImp >::consecutive(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::evalVolumetricPartBoth(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::evalVolumetricPartFlux(), Dune::Fem::CodimIndexSet< GridImp >::exists(), Dune::Fem::CommunicationIndexMap::insert(), Dune::Fem::CodimIndexSet< GridImp >::insertIdx(), Dune::Fem::SpecialArrayFeatures< MutableArray< ValueType > >::memMoveBackward(), Dune::Fem::CodimIndexSet< GridImp >::newIndex(), Dune::Fem::CodimIndexSet< GridImp >::oldIndex(), Dune::Fem::StaticArray< JacobianRangeType >::operator-=(), Dune::Fem::LocalDGPass< DiscreteModelImp, PreviousPassImp >::prepare(), Dune::Fem::CommunicationIndexMap::size(), Dune::Fem::CodimIndexSet< GridImp >::size(), Dune::Fem::ThreadIterator< GridPart, ptype >::thread(), Dune::Fem::ThreadIterator< GridPart, ptype >::update(), Dune::Fem::CodimIndexSet< GridImp >::write(), and Dune::Fem::CommunicationIndexMap::writeToBuffer().
|
inline |
return size of vector in bytes
Referenced by Dune::Fem::SpecialArrayFeatures< MutableArray< ValueType > >::used().
|
inlineinherited |
write to stream
|
protected |
Referenced by Dune::Fem::MutableArray< JacobianRangeType >::operator=().
|
protected |
|
protectedinherited |
|
protectedinherited |
Referenced by Dune::Fem::StaticArray< JacobianRangeType >::axpy(), Dune::Fem::StaticArray< T >::axpy(), Dune::Fem::StaticArray< JacobianRangeType >::operator+=(), Dune::Fem::StaticArray< JacobianRangeType >::operator-=(), Dune::Fem::StaticArray< JacobianRangeType >::operator=(), Dune::Fem::MutableArray< JacobianRangeType >::operator=(), and Dune::Fem::StaticArray< JacobianRangeType >::operator==().