Flow123d  jenkins-Flow123d-linux-release-multijob-282
Public Member Functions | Static Public Attributes | Private Member Functions | Private Attributes | List of all members
BIHNode Class Reference

#include <bih_node.hh>

Public Member Functions

void set_leaf (unsigned int begin, unsigned int end, double bound, unsigned int depth)
 
void set_non_leaf (unsigned int left, unsigned int right, unsigned int axis)
 
bool is_leaf () const
 return true if node is leaf More...
 
unsigned char depth () const
 return depth of leaf node More...
 
unsigned int leaf_begin () const
 
unsigned int leaf_end () const
 
unsigned int leaf_size () const
 
unsigned int axis () const
 return axes (coordination of splitting) of inner node More...
 
double bound () const
 
unsigned int child (unsigned int i_child) const
 Return index of child node. More...
 

Static Public Attributes

static const unsigned int child_count = 2
 count of subareas - don't change More...
 
static const unsigned char dimension = 3
 count of dimensions More...
 

Private Member Functions

void set_depth (unsigned int depth)
 

Private Attributes

unsigned int child_ [child_count]
 child nodes indexes More...
 
double bound_
 
unsigned char axis_
 

Detailed Description

!

Copyright (C) 2007 Technical University of Liberec. All rights reserved.

Please make a following refer to Flow123d on your project site if you use the program for any purpose, especially for academic research: Flow123d, Research Centre: Advanced Remedial Technologies, Technical University of Liberec, Czech Republic

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 021110-1307, USA.

Id:
bih_node.hh 1567 2012-02-28 13:24:58Z jan.brezina
Revision:
1567
LastChangedBy:
jan.brezina
LastChangedDate:
2012-02-28 14:24:58 +0100 (Tue, 28 Feb 2012)

Definition at line 37 of file bih_node.hh.

Member Function Documentation

unsigned int BIHNode::axis ( ) const
inline

return axes (coordination of splitting) of inner node

Definition at line 102 of file bih_node.hh.

Here is the caller graph for this function:

double BIHNode::bound ( ) const
inline

Definition at line 108 of file bih_node.hh.

Here is the caller graph for this function:

unsigned int BIHNode::child ( unsigned int  i_child) const
inline

Return index of child node.

Definition at line 114 of file bih_node.hh.

Here is the caller graph for this function:

unsigned char BIHNode::depth ( ) const
inline

return depth of leaf node

Definition at line 72 of file bih_node.hh.

Here is the caller graph for this function:

bool BIHNode::is_leaf ( ) const
inline

return true if node is leaf

Definition at line 67 of file bih_node.hh.

Here is the caller graph for this function:

unsigned int BIHNode::leaf_begin ( ) const
inline

Definition at line 78 of file bih_node.hh.

Here is the caller graph for this function:

unsigned int BIHNode::leaf_end ( ) const
inline

Definition at line 84 of file bih_node.hh.

Here is the caller graph for this function:

unsigned int BIHNode::leaf_size ( ) const
inline

Get count of elements stored in

Returns
Count of elements contained in node

Definition at line 95 of file bih_node.hh.

Here is the caller graph for this function:

void BIHNode::set_depth ( unsigned int  depth)
inlineprivate

Set depth of node to axes_ class members

Parameters
depthDepth of node in tree.

Definition at line 129 of file bih_node.hh.

void BIHNode::set_leaf ( unsigned int  begin,
unsigned int  end,
double  bound,
unsigned int  depth 
)
inline

Set leaf node.

Definition at line 48 of file bih_node.hh.

void BIHNode::set_non_leaf ( unsigned int  left,
unsigned int  right,
unsigned int  axis 
)
inline

Set non-leaf node.

Definition at line 58 of file bih_node.hh.

Member Data Documentation

unsigned char BIHNode::axis_
private

Value stores coordination of splitting area for inner nodes or depth for leaf nodes

  • values 0,1,2 indicate inner node of tree and coordination of splitting area
  • values 3 and greater indicate leaf node of tree and store depth of node (depth = axes_ - 3)

Definition at line 148 of file bih_node.hh.

double BIHNode::bound_
private

A non-leaf node has two childs (left and right). Their bounding boxes are created from the bounding box of parent so that in one direction the left child set max to its bound_ and the right child set its min to bound_. This way we can always repcreate bounding box of every node when traversing the tree from the root.

Definition at line 141 of file bih_node.hh.

unsigned int BIHNode::child_[child_count]
private

child nodes indexes

Definition at line 134 of file bih_node.hh.

const unsigned int BIHNode::child_count = 2
static

count of subareas - don't change

Definition at line 41 of file bih_node.hh.

const unsigned char BIHNode::dimension = 3
static

count of dimensions

Definition at line 43 of file bih_node.hh.


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