SG++-Doxygen-Documentation
sgpp::base::CoarseningFunctor Class Referenceabstract

Abstract class that defines the interfaces that coarsening functors have to provide. More...

#include <CoarseningFunctor.hpp>

Inheritance diagram for sgpp::base::CoarseningFunctor:
sgpp::base::SurplusCoarseningFunctor sgpp::base::SurplusVolumeCoarseningFunctor

Public Types

typedef double value_type
 

Public Member Functions

 CoarseningFunctor ()
 Constructor. More...
 
virtual double getCoarseningThreshold () const =0
 Returns the threshold value. More...
 
virtual size_t getRemovementsNum () const
 Returns the maximal number of points that should be removed. More...
 
virtual double operator() (GridStorage &storage, size_t seq)=0
 This should be returning a coarsening value for every grid point. More...
 
virtual double start () const =0
 This should return the initial value of coarsening criterion (e.g. More...
 
virtual ~CoarseningFunctor ()
 Destructor. More...
 

Detailed Description

Abstract class that defines the interfaces that coarsening functors have to provide.

Member Typedef Documentation

◆ value_type

Constructor & Destructor Documentation

◆ CoarseningFunctor()

sgpp::base::CoarseningFunctor::CoarseningFunctor ( )
inline

Constructor.

◆ ~CoarseningFunctor()

virtual sgpp::base::CoarseningFunctor::~CoarseningFunctor ( )
inlinevirtual

Destructor.

References operator()(), and start().

Member Function Documentation

◆ getCoarseningThreshold()

virtual double sgpp::base::CoarseningFunctor::getCoarseningThreshold ( ) const
pure virtual

Returns the threshold value.

Only the grid points with absolute value of coarsening criterion (e.g. alpha) less or equal to this threshold will be removed

Returns
threshold value for refinement. Default value: 0.

Implemented in sgpp::base::SurplusVolumeCoarseningFunctor, and sgpp::base::SurplusCoarseningFunctor.

Referenced by sgpp::base::HashCoarsening::free_coarsen_NFirstOnly(), and getRemovementsNum().

◆ getRemovementsNum()

virtual size_t sgpp::base::CoarseningFunctor::getRemovementsNum ( ) const
inlinevirtual

Returns the maximal number of points that should be removed.

The maximal number of points to removed is set in the constructor of implementation class.

Returns
number of points that should removed. Default value: 1.

Reimplemented in sgpp::base::SurplusVolumeCoarseningFunctor, and sgpp::base::SurplusCoarseningFunctor.

References getCoarseningThreshold().

Referenced by sgpp::base::HashCoarsening::free_coarsen_NFirstOnly().

◆ operator()()

virtual double sgpp::base::CoarseningFunctor::operator() ( GridStorage storage,
size_t  seq 
)
pure virtual

This should be returning a coarsening value for every grid point.

The point with the lowest value will be removed first.

Parameters
storagereference to the grids storage object
seqsequence number in the coefficients array
Returns
refinement value

Implemented in sgpp::base::SurplusVolumeCoarseningFunctor, and sgpp::base::SurplusCoarseningFunctor.

Referenced by ~CoarseningFunctor().

◆ start()

virtual double sgpp::base::CoarseningFunctor::start ( ) const
pure virtual

This should return the initial value of coarsening criterion (e.g.

alpha or error).

Returns
the initial value

Implemented in sgpp::base::SurplusVolumeCoarseningFunctor, and sgpp::base::SurplusCoarseningFunctor.

Referenced by sgpp::base::HashCoarsening::free_coarsen_NFirstOnly(), and ~CoarseningFunctor().


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