SG++-Doxygen-Documentation
sgpp::base::StencilHierarchisationLinear Class Reference

Class that implements the hierarchisation on a linear sparse grid. More...

#include <StencilHierarchisationLinear.hpp>

Public Member Functions

void operator() (DataVector &source, DataVector &result, grid_iterator &index, size_t dim)
 Implements operator() needed by the sweep class during the grid traversal. More...
 
 StencilHierarchisationLinear (GridStorage &storage, OperationStencilHierarchisation::IndexStencil &surplusStencil, OperationStencilHierarchisation::IndexStencil &neighborStencil, OperationStencilHierarchisation::WeightStencil &weightStencil)
 Constructor, must be bind to a grid. More...
 
 ~StencilHierarchisationLinear ()
 Destructor. More...
 

Protected Types

typedef GridStorage::grid_iterator grid_iterator
 

Protected Member Functions

void rec (DataVector &source, DataVector &result, grid_iterator &index, size_t dim, int seql, int seqr)
 Recursive hierarchisaton algorithm, this algorithms works in-place -> source should be equal to result. More...
 

Protected Attributes

OperationStencilHierarchisation::IndexStencil_neighborStencil
 
OperationStencilHierarchisation::IndexStencil_surplusStencil
 
OperationStencilHierarchisation::WeightStencil_weightStencil
 
GridStoragestorage
 the grid object More...
 

Detailed Description

Class that implements the hierarchisation on a linear sparse grid.

Therefore the ()operator has to be implement in order to use the sweep algorithm for the grid traversal

Member Typedef Documentation

Constructor & Destructor Documentation

sgpp::base::StencilHierarchisationLinear::StencilHierarchisationLinear ( GridStorage storage,
OperationStencilHierarchisation::IndexStencil surplusStencil,
OperationStencilHierarchisation::IndexStencil neighborStencil,
OperationStencilHierarchisation::WeightStencil weightStencil 
)

Constructor, must be bind to a grid.

Parameters
storagethe grid storage object of the the grid, on which the hierarchisation should be executed
surplusStencilstorage holding the grid point indices which have neighbors
neighborStencilstorage holding the grid point indices which are the neighbors
weightStencilstorage holding the weight in order to calculate the surplus at each node using it's neighbors
sgpp::base::StencilHierarchisationLinear::~StencilHierarchisationLinear ( )

Destructor.

Member Function Documentation

void sgpp::base::StencilHierarchisationLinear::operator() ( DataVector source,
DataVector result,
grid_iterator index,
size_t  dim 
)

Implements operator() needed by the sweep class during the grid traversal.

This function is applied to the whole grid.

Parameters
sourcethis DataVector holds the node base coefficients of the function that should be applied to the sparse grid
resultthis DataVector holds the linear base coefficients of the sparse grid's ansatz-functions
indexa iterator object of the grid
dimcurrent fixed dimension of the 'execution direction'

References rec().

void sgpp::base::StencilHierarchisationLinear::rec ( DataVector source,
DataVector result,
grid_iterator index,
size_t  dim,
int  seql,
int  seqr 
)
protected

Recursive hierarchisaton algorithm, this algorithms works in-place -> source should be equal to result.

Parameters
sourcethis DataVector holds the node base coefficients of the function that should be applied to the sparse grid
resultresult this DataVector holds the linear base coefficients of the sparse grid's ansatz-functions
indexa iterator object of the grid
dimcurrent fixed dimension of the 'execution direction'
seqlleft grid point index of the current region regarded in this step of the recursion
seqrright grid point index of the current region regarded in this step of the recursion

References _neighborStencil, _surplusStencil, _weightStencil, python.statsfileInfo::f, sgpp::base::HashGridIterator::hint(), sgpp::base::HashGridStorage::isInvalidSequenceNumber(), sgpp::base::HashGridIterator::leftChild(), sgpp::base::HashGridIterator::seq(), sgpp::base::HashGridIterator::stepRight(), storage, and sgpp::base::HashGridIterator::up().

Referenced by operator()().

Member Data Documentation

OperationStencilHierarchisation::IndexStencil& sgpp::base::StencilHierarchisationLinear::_neighborStencil
protected

Referenced by rec().

OperationStencilHierarchisation::IndexStencil& sgpp::base::StencilHierarchisationLinear::_surplusStencil
protected

Referenced by rec().

OperationStencilHierarchisation::WeightStencil& sgpp::base::StencilHierarchisationLinear::_weightStencil
protected

Referenced by rec().

GridStorage& sgpp::base::StencilHierarchisationLinear::storage
protected

the grid object

Referenced by rec().


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