Reference documentation for deal.II version 8.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | Private Attributes | List of all members
BlockDiagonalMatrix< MATRIX > Class Template Reference

#include <block_matrix.h>

Inheritance diagram for BlockDiagonalMatrix< MATRIX >:
[legend]

Public Member Functions

 BlockDiagonalMatrix (const MATRIX &M, const unsigned int n_blocks)
 
template<typename number1 , typename number2 >
void vmult (BlockVector< number1 > &dst, const BlockVector< number2 > &src) const
 
template<typename number1 , typename number2 >
void Tvmult (BlockVector< number1 > &dst, const BlockVector< number2 > &src) const
 
- Public Member Functions inherited from Subscriptor
 Subscriptor ()
 
 Subscriptor (const Subscriptor &)
 
virtual ~Subscriptor ()
 
Subscriptoroperator= (const Subscriptor &)
 
void subscribe (const char *identifier=0) const
 
void unsubscribe (const char *identifier=0) const
 
unsigned int n_subscriptions () const
 
void list_subscribers () const
 
 DeclException3 (ExcInUse, int, char *, std::string &,<< "Object of class "<< arg2<< " is still used by "<< arg1<< " other objects.\n"<< "(Additional information: "<< arg3<< ")\n"<< "Note the entry in the Frequently Asked Questions of "<< "deal.II (linked to from http://www.dealii.org/) for "<< "more information on what this error means.")
 
 DeclException2 (ExcNoSubscriber, char *, char *,<< "No subscriber with identifier \""<< arg2<< "\" did subscribe to this object of class "<< arg1)
 
template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Private Attributes

unsigned int num_blocks
 
SmartPointer< const MATRIX,
BlockDiagonalMatrix< MATRIX > > 
matrix
 

Detailed Description

template<class MATRIX>
class BlockDiagonalMatrix< MATRIX >

A matrix with several copies of the same block on the diagonal.

This matrix implements an m by m block matrix. Each diagonal block consists of the same (non-block) matrix, while off-diagonal blocks are void.

One special application is a one by one block matrix, allowing to apply the vmult of the original matrix (or preconditioner) to a block vector.

See Also
Block (linear algebra)
Author
Guido Kanschat, 2000

Definition at line 47 of file block_matrix.h.

Constructor & Destructor Documentation

template<class MATRIX >
BlockDiagonalMatrix< MATRIX >::BlockDiagonalMatrix ( const MATRIX M,
const unsigned int  n_blocks 
)

Constructor for an n_blocks by n_blocks matrix with diagonal blocks M.

Definition at line 87 of file block_matrix.h.

Member Function Documentation

template<class MATRIX >
template<typename number1 , typename number2 >
void BlockDiagonalMatrix< MATRIX >::vmult ( BlockVector< number1 > &  dst,
const BlockVector< number2 > &  src 
) const

Matrix-vector-multiplication.

Definition at line 98 of file block_matrix.h.

template<class MATRIX >
template<typename number1 , typename number2 >
void BlockDiagonalMatrix< MATRIX >::Tvmult ( BlockVector< number1 > &  dst,
const BlockVector< number2 > &  src 
) const

Transposed matrix-vector-multiplication.

Definition at line 114 of file block_matrix.h.

Member Data Documentation

template<class MATRIX >
unsigned int BlockDiagonalMatrix< MATRIX >::num_blocks
private

Number of blocks.

Definition at line 75 of file block_matrix.h.

template<class MATRIX >
SmartPointer<const MATRIX,BlockDiagonalMatrix<MATRIX> > BlockDiagonalMatrix< MATRIX >::matrix
private

Diagonal entry.

Definition at line 80 of file block_matrix.h.


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