wiki:Node

Version 4 (modified by trac, 12 years ago) ( diff )

Back to Definitions

The Node Type

The Node type is the basic structure of the BearCLAW application, and is defined in the treeops.f90 file. BearClAW uses nodes to assemble a hierarchical representation of the AMR grid structure, with each node representing a new AMR cell. Associated grid data is attached to each node via a reference to a NodeInfo structure.

A slideshow containing a graphical representation of the Node structure can be found here.


Attributes

* indicates a pointer.


  • NodeInfo* Info: Points to the NodeInfo object containing the AMR grid data associated with the given node.
  • Node* Parent: Points to the node's parent. In AMR terms, the parent grid contains the grids of all its children and has a lower resolution.
  • Node* Child: Points to the node's eldest child (i.e., the first child node created for this node).
  • Node* Sibling: Points to the node's youngest elder sibling (meaning the last node created by the current node's parent).
  • Node* Neighbor: Will point to the youngest elder sibling of the current node. If the current node is the oldest, however, it will point to the youngest sibling of another parent one level higher (assuming there is one).


  • Integer level: The depth of the grid, which corresponds to (grid resolution level - 1). All of a node's siblings and neighbors will have the same level, which will be one higher than the level of the node's parent.
  • Integer ChildNo: The node's index relative to its siblings. A node with a ChildNo of 1 is the eldest child node of its parent.
  • Integer NrOfChildren: The number of children a node has. NrOfChildren is also the ChildNo of a node's youngest child.
  • Integer LeafDist: The distance from the node to the nearest leaf.
  • Integer NodeNo: The node's index number, used mainly for debugging purposes. This is assigned at the node's creation.
Note: See TracWiki for help on using the wiki.