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

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

#include <HierarchisationLinearStretched.hpp>

Inheritance diagram for sgpp::base::HierarchisationLinearStretched:
sgpp::base::HierarchisationLinearStretchedBoundary

Public Member Functions

 HierarchisationLinearStretched (GridStorage &storage)
 Constructor, must be bind to a grid. More...
 
virtual void operator() (DataVector &source, DataVector &result, grid_iterator &index, size_t dim)
 Implements operator() needed by the sweep class during the grid traversal. More...
 
virtual ~HierarchisationLinearStretched ()
 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, double fl, double fr)
 Recursive hierarchisation algorithm, this algorithms works in-place -> source should be equal to result. More...
 

Protected Attributes

GridStoragestorage
 the grid object More...
 
Stretchingstretch
 the stretching 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

◆ grid_iterator

Constructor & Destructor Documentation

◆ HierarchisationLinearStretched()

sgpp::base::HierarchisationLinearStretched::HierarchisationLinearStretched ( GridStorage storage)
explicit

Constructor, must be bind to a grid.

Parameters
storagethe grid storage object of the the grid, on which the hierarchisation should be executed

◆ ~HierarchisationLinearStretched()

sgpp::base::HierarchisationLinearStretched::~HierarchisationLinearStretched ( )
virtual

Destructor.

Member Function Documentation

◆ operator()()

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

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'

Reimplemented in sgpp::base::HierarchisationLinearStretchedBoundary.

References rec().

◆ rec()

void sgpp::base::HierarchisationLinearStretched::rec ( DataVector source,
DataVector result,
grid_iterator index,
size_t  dim,
double  fl,
double  fr 
)
protected

Recursive hierarchisation 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
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'
flleft value of the current region regarded in this step of the recursion
frright value of the current region regarded in this step of the recursion

References sgpp::base::HashGridIterator::get(), sgpp::base::Stretching::getAdjacentPositions(), sgpp::base::HashGridIterator::hint(), sgpp::base::HashGridStorage::isInvalidSequenceNumber(), sgpp::base::HashGridIterator::leftChild(), sgpp::base::HashGridIterator::seq(), sgpp::base::HashGridIterator::stepRight(), storage, stretch, and sgpp::base::HashGridIterator::up().

Referenced by operator()(), and sgpp::base::HierarchisationLinearStretchedBoundary::operator()().

Member Data Documentation

◆ storage

GridStorage& sgpp::base::HierarchisationLinearStretched::storage
protected

◆ stretch

Stretching* sgpp::base::HierarchisationLinearStretched::stretch
protected

the stretching object

Referenced by rec().


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