SG++-Doxygen-Documentation
sgpp::combigrid::LevelInfo Class Reference

Stores necessary information about the computation status of a level. More...

#include <LevelHelpers.hpp>

Public Member Functions

 LevelInfo (size_t numPredecessors, size_t maxNewPoints, size_t numPoints)
 Creates a new level in its earliest stage. More...
 
 LevelInfo (double norm, size_t maxNewPoints, size_t numPoints)
 Creates a new level in its latest stage, where everything has already been computed. More...
 
void setPriority (MultiIndexQueue &queue, double priority)
 Updates the priority of this level in the priority queue. More...
 

Public Attributes

ComputationStage computationStage
 The stage of computation of this level. More...
 
std::shared_ptr< MultiIndexQueue::handle_typehandle
 Handle to the queue entry if there is any. More...
 
size_t maxNewPoints
 Number of new function evaluations (grid points) that have to be done to add this level. More...
 
double norm
 Norm of the difference (Delta) of this level (if already computed, zero otherwise). More...
 
size_t numNotCompletedPredecessors
 Number of predecessor levels which are not in status ComputationStage::COMPLETED. More...
 
size_t numNotStartedPredecessors
 Number of predecessor levels which are in status ComputationStage::NOT_STARTED. More...
 
size_t numPoints
 Number of grid points in this level. More...
 
double priority
 priority of the level used for adaptive refinement More...
 

Detailed Description

Stores necessary information about the computation status of a level.

This is necessary for adaptive level generation.

Constructor & Destructor Documentation

◆ LevelInfo() [1/2]

sgpp::combigrid::LevelInfo::LevelInfo ( size_t  numPredecessors,
size_t  maxNewPoints,
size_t  numPoints 
)
inlineexplicit

Creates a new level in its earliest stage.

This means that it is not ready for computation yet.

◆ LevelInfo() [2/2]

sgpp::combigrid::LevelInfo::LevelInfo ( double  norm,
size_t  maxNewPoints,
size_t  numPoints 
)
inlineexplicit

Creates a new level in its latest stage, where everything has already been computed.

Member Function Documentation

◆ setPriority()

void sgpp::combigrid::LevelInfo::setPriority ( MultiIndexQueue queue,
double  priority 
)
inline

Updates the priority of this level in the priority queue.

References sgpp::combigrid::QueueEntry::priority, and sgpp::combigrid::BinaryHeap< T, Comparator >::update().

Member Data Documentation

◆ computationStage

ComputationStage sgpp::combigrid::LevelInfo::computationStage

The stage of computation of this level.

◆ handle

std::shared_ptr<MultiIndexQueue::handle_type> sgpp::combigrid::LevelInfo::handle

Handle to the queue entry if there is any.

Via this handle, the QueueEntry can be retrieved and its priority can be updated.

◆ maxNewPoints

size_t sgpp::combigrid::LevelInfo::maxNewPoints

Number of new function evaluations (grid points) that have to be done to add this level.

◆ norm

double sgpp::combigrid::LevelInfo::norm

Norm of the difference (Delta) of this level (if already computed, zero otherwise).

Referenced by python.uq.dists.MultivariateNormal.MultivariateNormal::pdf().

◆ numNotCompletedPredecessors

size_t sgpp::combigrid::LevelInfo::numNotCompletedPredecessors

Number of predecessor levels which are not in status ComputationStage::COMPLETED.

◆ numNotStartedPredecessors

size_t sgpp::combigrid::LevelInfo::numNotStartedPredecessors

Number of predecessor levels which are in status ComputationStage::NOT_STARTED.

If this is > 0, then the computation for this level may not be started (to avoid evaluating the function multiple times at the same point).

◆ numPoints

size_t sgpp::combigrid::LevelInfo::numPoints

Number of grid points in this level.

◆ priority

double sgpp::combigrid::LevelInfo::priority

priority of the level used for adaptive refinement


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