Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members   Related Pages  

GridConstructionX Class Reference

Class to implement variables on a SAMR grid. More...

Inheritance diagram for GridConstructionX:

Inheritance graph
[legend]
Collaboration diagram for GridConstructionX:

Collaboration graph
[legend]
List of all members.

Public Methods

 GridConstructionX (const string &object_name, tbox_Pointer< SAMRAI::tbox_Database > database)
 Constructor. More...

int registerVariablesWithPlotter (SAMRAI::tbox_Pointer< SAMRAI::plot_CartesianVizamraiDataWriterX > viz_writer)
 Tell a plotter which data to write for this class. More...

 GridConstructionX (const string &object_name, tbox_Pointer< SAMRAI::tbox_Database > database)
 Constructor. More...

int registerVariablesWithPlotter (SAMRAI::tbox_Pointer< SAMRAI::plot_CartesianVizamraiDataWriterX > viz_writer)
 Tell a plotter which data to write for this class. More...

SAMRAI::mesh_StandardTagAndInitStrategyX virtuals
virtual void initializeLevelData (const tbox_Pointer< SAMRAI::hier_PatchHierarchyX > hierarchy, const int level_number, const double init_data_time, const bool can_be_refined, const bool initial_time, const tbox_Pointer< SAMRAI::hier_PatchLevelX > old_level=tbox_Pointer< SAMRAI::hier_PatchLevelX >((0)), const bool allocate_data=true)
 Allocate and initialize data for a new level in the patch hierarchy. More...

virtual void resetHierarchyConfiguration (const SAMRAI::tbox_Pointer< SAMRAI::hier_PatchHierarchyX > hierarchy, const int coarsest_level, const int finest_level)
SAMRAI::mesh_StandardTagAndInitStrategyX virtuals
virtual void initializeLevelData (const tbox_Pointer< SAMRAI::hier_PatchHierarchyX > hierarchy, const int level_number, const double init_data_time, const bool can_be_refined, const bool initial_time, const tbox_Pointer< SAMRAI::hier_PatchLevelX > old_level=tbox_Pointer< SAMRAI::hier_PatchLevelX >((0)), const bool allocate_data=true)
 Allocate and initialize data for a new level in the patch hierarchy. More...

virtual void resetHierarchyConfiguration (const SAMRAI::tbox_Pointer< SAMRAI::hier_PatchHierarchyX > hierarchy, const int coarsest_level, const int finest_level)

Private Attributes

Private state variables for solution.
Included in this group are examples of the types of variables that can live on a SAMRAI mesh.

Nevermind the significance of d_context_all for now. Contexts are not usefully employed in this tutorial.

SAMRAI::hier_VariableContext d_context_all
 Context for everything. More...

SAMRAI::pdat_CellVariableX<
double > 
d_constitutive
 Constitutive variable. More...

SAMRAI::pdat_CellVariableX<
double > 
d_scalar
 Scalar variable. More...

SAMRAI::pdat_CellVariableX<
double > 
d_vector
 Vector variable. More...

Private state variables for solution.
Included in this group are examples of the types of variables that can live on a SAMRAI mesh.

Nevermind the significance of d_context_all for now. Contexts are not usefully employed in this tutorial.

SAMRAI::pdat_CellVariableX<
double > 
d_constitutive
 Constitutive variable. More...

SAMRAI::pdat_CellVariableX<
double > 
d_scalar
 Scalar variable. More...

SAMRAI::pdat_CellVariableX<
double > 
d_vector
 Vector variable. More...


Detailed Description

Class to implement variables on a SAMR grid.

This class demonstrates how to construct a grid, create variables on it and write the variables out for plotting.

This class inherits and implements virtual functions from SAMRAI::mesh_StandardTagAndInitStrategyX to initialize data on the SAMR grid.

Definition at line 45 of file GridConstructionX.h.sed.


Constructor & Destructor Documentation

GridConstructionX::GridConstructionX const string &    object_name,
tbox_Pointer< SAMRAI::tbox_Database   database
 

Constructor.

Requirements:

  • the referenced objects
Actions:
  • Initialize the viz_writer to serve this object
Parameters:
object_name  Ojbect name
database  Input database

GridConstructionX::GridConstructionX const string &    object_name,
tbox_Pointer< SAMRAI::tbox_Database   database
 

Constructor.

Requirements:

  • the referenced objects
Actions:
  • Initialize the viz_writer to serve this object
Parameters:
object_name  Ojbect name
database  Input database


Member Function Documentation

virtual void GridConstructionX::initializeLevelData const tbox_Pointer< SAMRAI::hier_PatchHierarchyX   hierarchy,
const int    level_number,
const double    init_data_time,
const bool    can_be_refined,
const bool    initial_time,
const tbox_Pointer< SAMRAI::hier_PatchLevelX   old_level = tbox_Pointer< SAMRAI::hier_PatchLevelX >((0)),
const bool    allocate_data = true
[virtual]
 

Allocate and initialize data for a new level in the patch hierarchy.

This is where you implement the code for initialize data on the grid. Nevermind when it is called or where in the program that happens. All the information you need to initialize the grid are in the arguments.

See also:
SAMRAI::mesh_StandardTagAndInitStrategyX::initializeLevelData()
Parameters:
hierarchy  Hierarchy to initialize
level_number  Level to initialize
initial_time  Whether level is being introduced for the first time
old_level  Level to copy data from

virtual void GridConstructionX::initializeLevelData const tbox_Pointer< SAMRAI::hier_PatchHierarchyX   hierarchy,
const int    level_number,
const double    init_data_time,
const bool    can_be_refined,
const bool    initial_time,
const tbox_Pointer< SAMRAI::hier_PatchLevelX   old_level = tbox_Pointer< SAMRAI::hier_PatchLevelX >((0)),
const bool    allocate_data = true
[virtual]
 

Allocate and initialize data for a new level in the patch hierarchy.

This is where you implement the code for initialize data on the grid. Nevermind when it is called or where in the program that happens. All the information you need to initialize the grid are in the arguments.

See also:
SAMRAI::mesh_StandardTagAndInitStrategyX::initializeLevelData()
Parameters:
hierarchy  Hierarchy to initialize
level_number  Level to initialize
initial_time  Whether level is being introduced for the first time
old_level  Level to copy data from

int GridConstructionX::registerVariablesWithPlotter SAMRAI::tbox_Pointer< SAMRAI::plot_CartesianVizamraiDataWriterX   viz_writer
 

Tell a plotter which data to write for this class.

Parameters:
viz_writer  Vizramrai writer

int GridConstructionX::registerVariablesWithPlotter SAMRAI::tbox_Pointer< SAMRAI::plot_CartesianVizamraiDataWriterX   viz_writer
 

Tell a plotter which data to write for this class.

Parameters:
viz_writer  Vizramrai writer

Referenced by main().

virtual void GridConstructionX::resetHierarchyConfiguration const SAMRAI::tbox_Pointer< SAMRAI::hier_PatchHierarchyX   hierarchy,
const int    coarsest_level,
const int    finest_level
[inline, virtual]
 

Definition at line 98 of file GridConstructionX.h.sed.

virtual void GridConstructionX::resetHierarchyConfiguration const SAMRAI::tbox_Pointer< SAMRAI::hier_PatchHierarchyX   hierarchy,
const int    coarsest_level,
const int    finest_level
[inline, virtual]
 

Definition at line 98 of file GridConstructionX.h.sed.

References d_context_all.


Member Data Documentation

SAMRAI::pdat_CellVariableX<double> GridConstructionX::d_constitutive [private]
 

Constitutive variable.

This could be some grid-fixed variable (such as permitivity and permeability in the case of electromagnetics). We will actually set it so something that is usefull in this tutorial: the level and patch numbers.

Definition at line 149 of file GridConstructionX.h.sed.

SAMRAI::pdat_CellVariableX<double> GridConstructionX::d_constitutive [private]
 

Constitutive variable.

This could be some grid-fixed variable (such as permitivity and permeability in the case of electromagnetics). We will actually set it so something that is usefull in this tutorial: the level and patch numbers.

Definition at line 149 of file GridConstructionX.h.sed.

SAMRAI::hier_VariableContext GridConstructionX::d_context_all [private]
 

Context for everything.

Special contexts are not used here, so get just one context for everythying.

Definition at line 139 of file GridConstructionX.h.sed.

Referenced by resetHierarchyConfiguration().

SAMRAI::pdat_CellVariableX<double> GridConstructionX::d_scalar [private]
 

Scalar variable.

Definition at line 154 of file GridConstructionX.h.sed.

SAMRAI::pdat_CellVariableX<double> GridConstructionX::d_scalar [private]
 

Scalar variable.

Definition at line 154 of file GridConstructionX.h.sed.

SAMRAI::pdat_CellVariableX<double> GridConstructionX::d_vector [private]
 

Vector variable.

Definition at line 159 of file GridConstructionX.h.sed.

SAMRAI::pdat_CellVariableX<double> GridConstructionX::d_vector [private]
 

Vector variable.

Definition at line 159 of file GridConstructionX.h.sed.


The documentation for this class was generated from the following files:
Generated on Wed Apr 17 12:51:47 2002 for samtut by doxygen1.2.12 written by Dimitri van Heesch, © 1997-2001