Dune Core Modules (2.3.1)
densevector.hh
Go to the documentation of this file.
22 typedef typename FieldTraits< typename DenseMatVecTraits<V>::value_type >::field_type field_type;
124 friend class DenseIterator<const typename remove_const<C>::type, const typename remove_const<T>::type >;
147 DenseIterator(const DenseIterator<typename remove_const<C>::type, typename remove_const<T>::type >& other)
152 bool equals(const DenseIterator<typename remove_const<C>::type,typename remove_const<T>::type>& other) const
158 bool equals(const DenseIterator<const typename remove_const<C>::type,const typename remove_const<T>::type>& other) const
185 DifferenceType distanceTo(DenseIterator<const typename remove_const<C>::type,const typename remove_const<T>::type> other) const
191 DifferenceType distanceTo(DenseIterator<typename remove_const<C>::type, typename remove_const<T>::type> other) const
260 };
472 typename PromotionTraits<field_type,typename DenseVector<Other>::field_type>::PromotedType operator* (const DenseVector<Other>& y) const {
473 typedef typename PromotionTraits<field_type, typename DenseVector<Other>::field_type>::PromotedType PromotedType;
490 typename PromotionTraits<field_type,typename DenseVector<Other>::field_type>::PromotedType dot(const DenseVector<Other>& y) const {
491 typedef typename PromotionTraits<field_type, typename DenseVector<Other>::field_type>::PromotedType PromotedType;
Generic iterator class for dense vector and matrix implementations.
Definition: densevector.hh:122
std::ptrdiff_t DifferenceType
The type of the difference between two positions.
Definition: densevector.hh:131
C::size_type SizeType
The type to index the underlying container.
Definition: densevector.hh:136
Interface for a class of dense vectors over a given field.
Definition: densevector.hh:223
Traits::value_type value_type
export the type representing the field
Definition: densevector.hh:245
FieldTraits< value_type >::real_type two_norm2() const
square of two norm (sum over squared values of entries), need for block recursion
Definition: densevector.hh:530
ConstIterator const_iterator
typedef for stl compliant access
Definition: densevector.hh:330
Iterator iterator
typedef for stl compliant access
Definition: densevector.hh:293
ConstIterator find(size_type i) const
return iterator to given element or end()
Definition: densevector.hh:359
FieldTraits< value_type >::real_type two_norm() const
two norm sqrt(sum over squared values of entries)
Definition: densevector.hh:521
PromotionTraits< field_type, typenameDenseVector< Other >::field_type >::PromotedType dot(const DenseVector< Other > &y) const
vector dot product which corresponds to Petsc's VecDot
Definition: densevector.hh:490
derived_type & axpy(const value_type &a, const DenseVector< Other > &y)
vector space axpy operation ( *this += a y )
Definition: densevector.hh:456
DenseIterator< const DenseVector, const value_type > ConstIterator
ConstIterator class for sequential access.
Definition: densevector.hh:328
Traits::derived_type derived_type
type of derived vector class
Definition: densevector.hh:242
derived_type operator+(const DenseVector< Other > &b) const
Binary vector addition.
Definition: densevector.hh:388
derived_type & operator-=(const DenseVector< Other > &y)
vector space subtraction
Definition: densevector.hh:378
size_type dim() const
dimension of the vector space
Definition: densevector.hh:575
FieldTraits< value_type >::real_type infinity_norm_real() const
simplified infinity norm (uses Manhattan norm for complex values)
Definition: densevector.hh:553
derived_type & operator=(const value_type &k)
Assignment operator for scalar.
Definition: densevector.hh:264
PromotionTraits< field_type, typenameDenseVector< Other >::field_type >::PromotedType operator*(const DenseVector< Other > &y) const
indefinite vector dot product which corresponds to Petsc's VecTDot
Definition: densevector.hh:472
Traits::size_type size_type
The type used for the index access and size operation.
Definition: densevector.hh:254
derived_type operator-(const DenseVector< Other > &b) const
Binary vector subtraction.
Definition: densevector.hh:396
DenseIterator< DenseVector, value_type > Iterator
Iterator class for sequential access.
Definition: densevector.hh:291
@ blocklevel
The number of block levels we contain.
Definition: densevector.hh:259
derived_type & operator*=(const value_type &k)
vector space multiplication with scalar
Definition: densevector.hh:419
bool operator==(const DenseVector< Other > &y) const
Binary vector comparison.
Definition: densevector.hh:436
FieldTraits< value_type >::real_type infinity_norm() const
infinity norm (maximum of absolute values of entries)
Definition: densevector.hh:539
derived_type & operator+=(const DenseVector< Other > &y)
vector space addition
Definition: densevector.hh:368
ConstIterator begin() const
begin ConstIterator
Definition: densevector.hh:333
Traits::value_type block_type
export the type representing the components
Definition: densevector.hh:251
value_type & operator[](size_type i)
random access
Definition: densevector.hh:274
Traits::value_type field_type
export the type representing the field
Definition: densevector.hh:248
derived_type & operator/=(const value_type &k)
vector space division by scalar
Definition: densevector.hh:427
bool operator!=(const DenseVector< Other > &y) const
Binary vector incomparison.
Definition: densevector.hh:448
FieldTraits< value_type >::real_type one_norm_real() const
simplified one norm (uses Manhattan norm for complex values)
Definition: densevector.hh:512
Iterator find(size_type i)
return iterator to given element or end()
Definition: densevector.hh:322
FieldTraits< value_type >::real_type one_norm() const
one norm (sum over absolute values of entries)
Definition: densevector.hh:503
size_type N() const
number of blocks in the vector (are of size 1 here)
Definition: densevector.hh:569
Base class for stl conformant forward iterators.
Definition: iteratorfacades.hh:431
Provides the functions dot(a,b) := and dotT(a,b) := .
Type traits to determine the type of reals (when working with complex numbers)
Implements a generic iterator class for writing stl conformant iterators.
std::ostream & operator<<(std::ostream &s, const array< T, N > &e)
Output operator for array.
Definition: array.hh:159
enable_if<!IsVector< A >::value &&!is_same< typenameFieldTraits< A >::field_type, typenameFieldTraits< A >::real_type >::value, typenamePromotionTraits< A, B >::PromotedType >::type dot(const A &a, const B &b)
computes the dot product for fundamental data types according to Petsc's VectDot function: dot(a,...
Definition: dotproduct.hh:44
Documentation of the traits classes you need to write for each implementation of DenseVector or Dense...
Provides some promotion traits.
|
Legal Statements / Impressum |
Hosted by TU Dresden |
generated with Hugo v0.111.3
(Nov 12, 23:30, 2024)