PointerMatrixAux< MATRIX, VECTOR > Class Template Reference
[Derived matrices]

Inheritance diagram for PointerMatrixAux< MATRIX, VECTOR >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 PointerMatrixAux (VectorMemory< VECTOR > *mem=0, const MATRIX *M=0)
 PointerMatrixAux (VectorMemory< VECTOR > *mem, const char *name)
 PointerMatrixAux (VectorMemory< VECTOR > *mem, const MATRIX *M, const char *name)
virtual void clear ()
bool empty () const
void set_memory (VectorMemory< VECTOR > *mem)
const PointerMatrixAuxoperator= (const MATRIX *M)
virtual void vmult (VECTOR &dst, const VECTOR &src) const
virtual void Tvmult (VECTOR &dst, const VECTOR &src) const
virtual void vmult_add (VECTOR &dst, const VECTOR &src) const
virtual void Tvmult_add (VECTOR &dst, const VECTOR &src) const

Private Member Functions

virtual const void * get () const

Private Attributes

GrowingVectorMemory< VECTOR > my_memory
SmartPointer< VectorMemory
< VECTOR > > 
mem
SmartPointer< const MATRIX > m

Related Functions

(Note that these are not member functions.)



template<class VECTOR , class MATRIX >
PointerMatrixBase< VECTOR > * new_pointer_matrix_base (MATRIX &matrix, const VECTOR &, const char *name="PointerMatrixAux")

Detailed Description

template<class MATRIX, class VECTOR>
class PointerMatrixAux< MATRIX, VECTOR >

A pointer to be used as a matrix. This class stores a pointer to a matrix and can be used as a matrix itself in iterative methods.

The main purpose for the existence of this class is its base class, which only has a vector as template argument. Therefore, this interface provides an abstract base class for matrices.

This class differs form PointerMatrix by its additional VectorMemory object and by the fact that it implements the functions vmult_add() and Tvmult_add() only using vmult() and Tvmult() of the MATRIX.

Author:
Guido Kanschat 2006

Constructor & Destructor Documentation

template<class MATRIX , class VECTOR >
PointerMatrixAux< MATRIX, VECTOR >::PointerMatrixAux ( VectorMemory< VECTOR > *  mem = 0,
const MATRIX *  M = 0 
) [inline]

Constructor. The pointer in the argument is stored in this class. As usual, the lifetime of *M must be longer than the one of the PointerMatrixAux.

If M is zero, no matrix is stored.

If mem is zero, then GrowingVectorMemory is used.

References PointerMatrixAux< MATRIX, VECTOR >::my_memory.

template<class MATRIX , class VECTOR >
PointerMatrixAux< MATRIX, VECTOR >::PointerMatrixAux ( VectorMemory< VECTOR > *  mem,
const char *  name 
) [inline]

Constructor not using a matrix. The name argument is used to identify the SmartPointer for this object.

References PointerMatrixAux< MATRIX, VECTOR >::my_memory.

template<class MATRIX , class VECTOR >
PointerMatrixAux< MATRIX, VECTOR >::PointerMatrixAux ( VectorMemory< VECTOR > *  mem,
const MATRIX *  M,
const char *  name 
) [inline]

Constructor. M points to a matrix which must live longer than the PointerMatrixAux. The name argument is used to identify the SmartPointer for this object.

References PointerMatrixAux< MATRIX, VECTOR >::my_memory.


Member Function Documentation

template<class MATRIX , class VECTOR >
void PointerMatrixAux< MATRIX, VECTOR >::clear (  )  [inline, virtual]

Reset pointer and release the matrix pointed to.

Implements PointerMatrixBase< VECTOR >.

References PointerMatrixAux< MATRIX, VECTOR >::m.

template<class MATRIX , class VECTOR >
bool PointerMatrixAux< MATRIX, VECTOR >::empty (  )  const [inline]

Return whether the object is empty.

References PointerMatrixAux< MATRIX, VECTOR >::m.

template<class MATRIX , class VECTOR >
void PointerMatrixAux< MATRIX, VECTOR >::set_memory ( VectorMemory< VECTOR > *  mem  )  [inline]

Assign a new VectorMemory object for getting auxiliary vectors.

References PointerMatrixAux< MATRIX, VECTOR >::mem, and PointerMatrixAux< MATRIX, VECTOR >::my_memory.

template<class MATRIX , class VECTOR >
const PointerMatrixAux< MATRIX, VECTOR > & PointerMatrixAux< MATRIX, VECTOR >::operator= ( const MATRIX *  M  )  [inline]

Assign a new matrix pointer. Deletes the old pointer and releases its matrix.

See also:
SmartPointer

References PointerMatrixAux< MATRIX, VECTOR >::m.

template<class MATRIX , class VECTOR >
void PointerMatrixAux< MATRIX, VECTOR >::vmult ( VECTOR &  dst,
const VECTOR &  src 
) const [inline, virtual]
template<class MATRIX , class VECTOR >
void PointerMatrixAux< MATRIX, VECTOR >::Tvmult ( VECTOR &  dst,
const VECTOR &  src 
) const [inline, virtual]
template<class MATRIX , class VECTOR >
void PointerMatrixAux< MATRIX, VECTOR >::vmult_add ( VECTOR &  dst,
const VECTOR &  src 
) const [inline, virtual]
template<class MATRIX , class VECTOR >
void PointerMatrixAux< MATRIX, VECTOR >::Tvmult_add ( VECTOR &  dst,
const VECTOR &  src 
) const [inline, virtual]
template<class MATRIX , class VECTOR >
const void * PointerMatrixAux< MATRIX, VECTOR >::get (  )  const [inline, private, virtual]

Return the address of the matrix for comparison.

Implements PointerMatrixBase< VECTOR >.

References PointerMatrixAux< MATRIX, VECTOR >::m.


Member Data Documentation

template<class MATRIX, class VECTOR>
GrowingVectorMemory<VECTOR> PointerMatrixAux< MATRIX, VECTOR >::my_memory [mutable, private]
template<class MATRIX, class VECTOR>
SmartPointer<VectorMemory<VECTOR> > PointerMatrixAux< MATRIX, VECTOR >::mem [mutable, private]
template<class MATRIX, class VECTOR>
SmartPointer<const MATRIX> PointerMatrixAux< MATRIX, VECTOR >::m [private]

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

deal.II documentation generated on Mon Nov 23 22:57:59 2009 by doxygen 1.6.1