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

NodeLevelMG Class Reference

Multigrid solver on a level. More...

#include <NodeLevelMG.H>

Collaboration diagram for NodeLevelMG:

Collaboration graph
[legend]
List of all members.

Public Methods

 NodeLevelMG ()
 {\bf constructors, destructor and defines}

 NodeLevelMG (const DisjointBoxLayout &a_grids, const DisjointBoxLayout *a_gridsCoarsePtr, const ProblemDomain &a_domain, Real a_dx, int a_refToCoarse, const NodeMaskLevelOp *const a_opin, int a_nCoarserLevels)
 NodeLevelMG (const DisjointBoxLayout &a_grids, const DisjointBoxLayout *a_gridsCoarsePtr, const Box &a_domain, Real a_dx, int a_refToCoarse, const NodeMaskLevelOp *const a_opin, int a_nCoarserLevels)
 ~NodeLevelMG ()
 NodeLevelMG (NodeLevelMG &a_L, int a_refToCoarse, const NodeMaskLevelOp *a_opin)
void define (const DisjointBoxLayout &a_grids, const DisjointBoxLayout *a_gridsCoarsePtr, const ProblemDomain &a_domain, Real a_dx, int a_refToCoarse, const NodeMaskLevelOp *const a_opin, int a_nCoarserLevels)
void define (const DisjointBoxLayout &a_grids, const DisjointBoxLayout *a_gridsCoarsePtr, const Box &a_domain, Real a_dx, int a_refToCoarse, const NodeMaskLevelOp *const a_opin, int a_nCoarserLevels)
void define (const NodeLevelMG &a_L, int a_refToCoarse, const NodeMaskLevelOp *a_opin)
void clear ()
bool isDefined () const
 {\bf access functions}

void setnumBottomGSRB (int a_numBottomGSRB)
 {\bf parameter-setting functions}

void setnumSmoothUp (int a_numSmoothUp)
void setnumSmoothDown (int a_numSmoothDown)
void setVerbose (bool a_verbose)
void mgRelax (LevelData< NodeFArrayBox > &a_phi, const LevelData< NodeFArrayBox > &a_rhs, bool a_bottomsolveflag)
 {\bf data modification functions}

NodeMaskLevelOplevelOpPtr ()
NodeLevelMG * lCoarsePtr ()

Protected Methods

void setDefaultValues ()
void clearMemory ()

Protected Attributes

bool m_isDefined
bool m_verbose
LevelData< NodeFArrayBoxm_resid
LevelData< NodeFArrayBoxm_crseResid
LevelData< NodeFArrayBoxm_crseCorr
DisjointBoxLayout m_grids
DisjointBoxLayout m_coarsenedGrids
const DisjointBoxLayout * m_gridsCoarsePtr
Real m_dx
ProblemDomain m_domain
int m_nCoarserLevels
NodeLevelMG * m_lCoarsePtr
NodeMaskLevelOpm_levelopPtr
int m_numBottomGSRB
int m_numSmoothUp
int m_numSmoothDown
int m_refToCoarsened
NodeMaskAverage m_averageOp
NodeMGInterp m_mginterp

Detailed Description

Multigrid solver on a level.

Multigrid solver on a level. This class is to be considered internal to LevelNodeSolver and not a part of the Chombo API.


Constructor & Destructor Documentation

NodeLevelMG::NodeLevelMG  
 

{\bf constructors, destructor and defines}

Default constructor. User must subsequently call define().

NodeLevelMG::NodeLevelMG const DisjointBoxLayout &    a_grids,
const DisjointBoxLayout *    a_gridsCoarsePtr,
const ProblemDomain &    a_domain,
Real    a_dx,
int    a_refToCoarse,
const NodeMaskLevelOp *const    a_opin,
int    a_nCoarserLevels
 

Constructor to define NodeLevelMG from the inputs. Calls full {\bf define} function with identical arguments.

NodeLevelMG::NodeLevelMG const DisjointBoxLayout &    a_grids,
const DisjointBoxLayout *    a_gridsCoarsePtr,
const Box &    a_domain,
Real    a_dx,
int    a_refToCoarse,
const NodeMaskLevelOp *const    a_opin,
int    a_nCoarserLevels
 

NodeLevelMG::~NodeLevelMG  
 

Destructor.

NodeLevelMG::NodeLevelMG NodeLevelMG &    a_L,
int    a_refToCoarse,
const NodeMaskLevelOp   a_opin
 

Constructor for coarsened version of object. Calls {\bf define} function with identical arguments.


Member Function Documentation

void NodeLevelMG::clear  
 

void NodeLevelMG::clearMemory   [protected]
 

void NodeLevelMG::define const NodeLevelMG &    a_L,
int    a_refToCoarse,
const NodeMaskLevelOp   a_opin
 

Function to define coarsened version of an object.

{\bf Arguments:}\ a_L: original object.\ a_refToCoarse: refinement ratio from this object to a_L.\ a_opin: operator L used in solution of L(phi)=rho.\

void NodeLevelMG::define const DisjointBoxLayout &    a_grids,
const DisjointBoxLayout *    a_gridsCoarsePtr,
const Box &    a_domain,
Real    a_dx,
int    a_refToCoarse,
const NodeMaskLevelOp *const    a_opin,
int    a_nCoarserLevels
 

void NodeLevelMG::define const DisjointBoxLayout &    a_grids,
const DisjointBoxLayout *    a_gridsCoarsePtr,
const ProblemDomain &    a_domain,
Real    a_dx,
int    a_refToCoarse,
const NodeMaskLevelOp *const    a_opin,
int    a_nCoarserLevels
 

Full define function.

{\bf Arguments:}\ a_grids: Grids on which solution will be computed.\ a_gridsCoarsePtr: pointer to next coarser grids, or NULL if there is no coarser level.\ a_domain: domain of solution level.\ a_dx: grid spacing at solution level.\ a_refToCoarse: refinement ratio to next coarser level. Not used if there is no coarser level.\ a_opin: operator L used in solution of L(phi)=rho.\ a_nCoarserLevels: number of coarser levels.\

bool NodeLevelMG::isDefined   const
 

{\bf access functions}

Returns true if this object was created with the defining constructor or if define() has been called.

NodeLevelMG* NodeLevelMG::lCoarsePtr  
 

NodeMaskLevelOp* NodeLevelMG::levelOpPtr  
 

void NodeLevelMG::mgRelax LevelData< NodeFArrayBox > &    a_phi,
const LevelData< NodeFArrayBox > &    a_rhs,
bool    a_bottomsolveflag
 

{\bf data modification functions}

Invoke relaxation step. Default is pure multigrid V-cycle, suitable for use in multilevel solver application; otherwise, use approximate solver such as CG at bottom level. It is assumed that the problem has already been put in residual-correction form. In particular, only the homogeneous form of the physical and coarse-fine boundary conditions need be invoked.

{\bf Arguments:}\ a_phi (modified): phi on this level.\ a_rhs (not modified): right-hand side on this level.\ a_bottomsolveflag: whether to use bottom solver at coarsest level.\

{\bf This:}\ Modified are m_resid, m_crseResid, and m_crseCorr.\

void NodeLevelMG::setDefaultValues   [protected]
 

void NodeLevelMG::setnumBottomGSRB int    a_numBottomGSRB
 

{\bf parameter-setting functions}

Set number of smoothings on the bottom level; Default == 16.

void NodeLevelMG::setnumSmoothDown int    a_numSmoothDown
 

Set number of smoothings on way down V-cycle; Default == 4.

void NodeLevelMG::setnumSmoothUp int    a_numSmoothUp
 

Set number of smoothings on way up V-cycle; Default == 4.

void NodeLevelMG::setVerbose bool    a_verbose [inline]
 

Set whether the solver gives output while solving. Default is true.


Member Data Documentation

NodeMaskAverage NodeLevelMG::m_averageOp [protected]
 

DisjointBoxLayout NodeLevelMG::m_coarsenedGrids [protected]
 

LevelData<NodeFArrayBox> NodeLevelMG::m_crseCorr [protected]
 

LevelData<NodeFArrayBox> NodeLevelMG::m_crseResid [protected]
 

ProblemDomain NodeLevelMG::m_domain [protected]
 

Real NodeLevelMG::m_dx [protected]
 

DisjointBoxLayout NodeLevelMG::m_grids [protected]
 

const DisjointBoxLayout* NodeLevelMG::m_gridsCoarsePtr [protected]
 

bool NodeLevelMG::m_isDefined [protected]
 

NodeLevelMG* NodeLevelMG::m_lCoarsePtr [protected]
 

NodeMaskLevelOp* NodeLevelMG::m_levelopPtr [protected]
 

NodeMGInterp NodeLevelMG::m_mginterp [protected]
 

int NodeLevelMG::m_nCoarserLevels [protected]
 

int NodeLevelMG::m_numBottomGSRB [protected]
 

int NodeLevelMG::m_numSmoothDown [protected]
 

int NodeLevelMG::m_numSmoothUp [protected]
 

int NodeLevelMG::m_refToCoarsened [protected]
 

LevelData<NodeFArrayBox> NodeLevelMG::m_resid [protected]
 

bool NodeLevelMG::m_verbose [protected]
 


The documentation for this class was generated from the following file:
Generated on Tue Apr 15 18:32:09 2003 for AMRNodeElliptic by doxygen1.2.16