Diffpack Documentation


Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Search  

Proj Class Reference

base class for Projection operators between grids. More...

#include <Proj.h>

Inheritance diagram for Proj::

HandleId ProjIm ProjInterp ProjMatrix ProjMat ProjMatSparse ProjInterpMat ProjInterpSparse ProjInterpSparseHier MxProj List of all members.

Public Methods

 Proj (const char *description_="Projection operator")
 Proj (const Proj_prm &prm, const char *description_="Projection operator")
virtual ~Proj ()
virtual bool rebindDOF (DegFreeFE &coarse, DegFreeFE &fine)
virtual bool rebindMatrix (LinEqMatrix &mat)
virtual bool rebindMatSparse (MatSparse(NUMT) &m)
virtual bool rebindMat (Mat(NUMT) &m)
virtual bool rebindBoxRef (DegFreeFE &coarse, const Ptv(int) &refinement_factor)
virtual void init (bool optimize=false)
virtual bool ok () const
virtual void apply (const LinEqVector &c, LinEqVector &d, TransposeMode tpmode, bool add_to_d=false)=0
virtual void scale (const LinEqVector &s, TransposeMode tpmode)=0
virtual void scale (real s)=0
virtual int getWork () const=0
virtual real getStorage () const=0
virtual LinEqMatrixA ()=0
virtual String description () const
virtual String prm2name () const
virtual void print (Os os, int output=1) const

Public Attributes

String desc

Detailed Description

base class for Projection operators between grids.

NAME: Proj - base class for Projection operators between grids

DESCRIPTION:

This is the base class for projection operators between grids, typically for use in multilevel methods. That is, the projection is typically used for transportation of data between grids with different resolution.


Constructor & Destructor Documentation

Proj::Proj ( const char * description_ = "Projection operator" )
 

The constructors accepts a "String" argument naming the projection operator. One constructor also accepts a "Proj_prm" object, possibly containing further parameters. The function "init" should be called prior to use of the operator.

Proj::Proj ( const Proj_prm & prm,
const char * description_ = "Projection operator" )
 

See documentation of one of the overloaded constructor.

Proj::~Proj ( ) [virtual]
 


Member Function Documentation

LinEqMatrix & Proj::A ( ) [pure virtual]
 

returns access to the matrix representation of the projection operator.

Reimplemented in ProjMatrix, ProjIm, and ProjInterp.

void Proj::apply ( const LinEqVector & c,
LinEqVector & d,
TransposeMode tpmode,
bool add_to_d = false ) [pure virtual]
 

applies the projection operator to the vector "c", producting the vector "d". Depending on the "tpmode" argument, either operator or its transposed is used. If the flag "add_to_d" is true, the computed results is added to "d", otherwise it overwrites any prior contents in "d".

Reimplemented in ProjMatrix, ProjIm, and ProjInterp.

String Proj::description ( ) const [virtual]
 

returns the "String" description of the projection operator.

Reimplemented in ProjInterpSparse, ProjMatrix, ProjMatSparse, MxProj, ProjIm, ProjInterp, ProjInterpMat, ProjInterpSparseHier, and ProjMat.

real Proj::getStorage ( ) const [pure virtual]
 

Reimplemented in ProjMatrix, ProjIm, and ProjInterp.

int Proj::getWork ( ) const [pure virtual]
 

Reimplemented in ProjMatrix, ProjIm, and ProjInterp.

void Proj::init ( bool optimize = false ) [virtual]
 

initializes the projection operator, if possible the peformance of the operator is optimized whenever the boolean argument is true.

Reimplemented in ProjInterpSparse, and MxProj.

bool Proj::ok ( ) const [virtual]
 

returns true if the projection operator is in a consistent state.

Reimplemented in ProjMatrix, ProjIm, and ProjInterp.

void Proj::print ( Os os,
int output = 1 ) const [virtual]
 

Reimplemented in ProjInterpSparse, ProjMatrix, ProjMatSparse, and MxProj.

String Proj::prm2name ( ) const [virtual]
 

returns the name of the class.

bool Proj::rebindBoxRef ( DegFreeFE & coarse,
const Ptv(int) & refinement_factor ) [virtual]
 

for future use.

bool Proj::rebindDOF ( DegFreeFE & coarse,
DegFreeFE & fine ) [virtual]
 

connects the projection operator to two "DegFreeFE" objects, one for the coarse and one for the fine grid.

Reimplemented in ProjInterpSparse, MxProj, ProjIm, ProjInterp, ProjInterpMat, and ProjInterpSparseHier.

bool Proj::rebindMat ( Mat(NUMT) & m ) [virtual]
 

connects the projection operator to a "Mat" object, i.e., a dense matrix, which will be used to store the projection.

Reimplemented in ProjMat.

bool Proj::rebindMatSparse ( MatSparse(NUMT) & m ) [virtual]
 

connects the projection operator to a "MatSparse" object, i.e., a sparse matrix, which will be used to store the projection.

Reimplemented in ProjMatSparse.

bool Proj::rebindMatrix ( LinEqMatrix & mat ) [virtual]
 

connects the projection operator to a "LinEqMatrix" object which will be used to store the projection. That is, through the "LinEqMatrix" interface, any matrix storage format can be applied.

Reimplemented in ProjMatrix.

void Proj::scale ( real s ) [pure virtual]
 

See documentation of one of the overloaded functions.

Reimplemented in ProjMatrix, ProjMatSparse, ProjIm, ProjInterp, and ProjMat.

void Proj::scale ( const LinEqVector & s,
TransposeMode tpmode ) [pure virtual]
 

scales the projection operator according to input values. If the a scalar constant "s" is applied, all entries in the operator is scaled by the constant value, "P(i,j)=s*P(i,j)".

If the input sepcifies a "LinEqVector", the operator is scaled row- or columnwise. That is, for "tpmode=TRANSPOSED" the rows are scaled, "P(i,j) = s(i)*P(i,j)". Similarly, for "tpmode=NOT_TRANSPOSED" the wolumns are scaled as "P(i,j)=s(j)*P(i,j)".

Reimplemented in ProjMatrix, ProjMatSparse, ProjIm, ProjInterp, and ProjMat.


Member Data Documentation

String Proj::desc
 


The documentation for this class was generated from the following file:
Copyright © 2003 inuTech GmbH. All rights reserved.