SG++-Doxygen-Documentation
sgpp::pde::UpDownOneOpDimWithShadow Class Referenceabstract

Implements the Up/Down scheme with one dimension with a special operation. More...

#include <UpDownOneOpDimWithShadow.hpp>

Inheritance diagram for sgpp::pde::UpDownOneOpDimWithShadow:
sgpp::base::OperationMatrix sgpp::pde::OperationLaplacePrewavelet

Public Member Functions

virtual void mult (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result)
 starts the Multiplication with the matrix More...
 
 UpDownOneOpDimWithShadow (sgpp::base::GridStorage *storage, sgpp::base::GridStorage *shadowStorage)
 Constructor. More...
 
virtual ~UpDownOneOpDimWithShadow ()
 Destructor. More...
 
- Public Member Functions inherited from sgpp::base::OperationMatrix
 OperationMatrix ()
 Constructor. More...
 
virtual ~OperationMatrix ()
 Destructor. More...
 

Protected Types

typedef sgpp::base::GridStorage::grid_iterator grid_iterator
 

Protected Member Functions

virtual void down (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result, size_t dim)=0
 std 1D down operation More...
 
virtual void downOpDim (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result, size_t dim)=0
 special 1D down operation that is only executed in one direction More...
 
void expandGrid ()
 This functions adds all grid points of the shadow storage into the actual grid. More...
 
void shrinkGrid ()
 Removes the previously added shadow grid points from the actual grid. More...
 
virtual void specialOP (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result, size_t dim, size_t op_dim)
 All calculations for op_dim. More...
 
virtual void up (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result, size_t dim)=0
 std 1D up operation More...
 
void updown (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result, size_t dim, size_t op_dim)
 Recursive procedure for updown(). More...
 
virtual void upOpDim (sgpp::base::DataVector &alpha, sgpp::base::DataVector &result, size_t dim)=0
 special 1D up operation that is only executed in one direction More...
 

Protected Attributes

sgpp::base::GridStorageshadowStorage
 
sgpp::base::GridStoragestorage
 Pointer to the grid's storage object. More...
 

Detailed Description

Implements the Up/Down scheme with one dimension with a special operation.

Before the actual operation starts, all grid points from the shadow storage are copied into the actual grid. After the calculation, all shadow grid points are deleted, the result vector is adapted accordingly.

Member Typedef Documentation

◆ grid_iterator

Constructor & Destructor Documentation

◆ UpDownOneOpDimWithShadow()

sgpp::pde::UpDownOneOpDimWithShadow::UpDownOneOpDimWithShadow ( sgpp::base::GridStorage storage,
sgpp::base::GridStorage shadowStorage 
)

Constructor.

Parameters
storagethe grid's sgpp::base::GridStorage object
shadowStorageshadow storage

References shadowStorage, and storage.

◆ ~UpDownOneOpDimWithShadow()

sgpp::pde::UpDownOneOpDimWithShadow::~UpDownOneOpDimWithShadow ( )
virtual

Destructor.

Member Function Documentation

◆ down()

virtual void sgpp::pde::UpDownOneOpDimWithShadow::down ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result,
size_t  dim 
)
protectedpure virtual

std 1D down operation

Parameters
dimdimension in which to apply the down-part
alphavector of coefficients
resultvector to store the results in

Implemented in sgpp::pde::OperationLaplacePrewavelet.

Referenced by updown().

◆ downOpDim()

virtual void sgpp::pde::UpDownOneOpDimWithShadow::downOpDim ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result,
size_t  dim 
)
protectedpure virtual

special 1D down operation that is only executed in one direction

Parameters
alphathe coefficients of the gridpoints
resultvector with the result of this operation
dimthe dimension in that down-Gradient is applied

Implemented in sgpp::pde::OperationLaplacePrewavelet.

Referenced by specialOP().

◆ expandGrid()

void sgpp::pde::UpDownOneOpDimWithShadow::expandGrid ( )
protected

This functions adds all grid points of the shadow storage into the actual grid.

References sgpp::base::HashGridStorage::getPoint(), sgpp::base::HashGridStorage::getSize(), python.statsfileInfo::i, sgpp::base::HashGridStorage::insert(), shadowStorage, and storage.

Referenced by mult().

◆ mult()

void sgpp::pde::UpDownOneOpDimWithShadow::mult ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result 
)
virtual

starts the Multiplication with the matrix

Parameters
alphaDataVector that contains the ansatzfunctions' coefficients
resultDataVector into which the result of the Laplace operation is stored

Implements sgpp::base::OperationMatrix.

References expandGrid(), sgpp::base::HashGridStorage::getDimension(), sgpp::base::HashGridStorage::getSize(), sgpp::base::DataVector::getSize(), python.statsfileInfo::i, sgpp::base::DataVector::setAll(), shrinkGrid(), storage, and updown().

◆ shrinkGrid()

void sgpp::pde::UpDownOneOpDimWithShadow::shrinkGrid ( )
protected

Removes the previously added shadow grid points from the actual grid.

Thus, the grid is the same shape as before the call of mult.

References sgpp::base::HashGridStorage::deleteLast(), sgpp::base::HashGridStorage::getSize(), python.statsfileInfo::i, shadowStorage, and storage.

Referenced by mult().

◆ specialOP()

void sgpp::pde::UpDownOneOpDimWithShadow::specialOP ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result,
size_t  dim,
size_t  op_dim 
)
protectedvirtual

All calculations for op_dim.

Parameters
alphathe coefficients of the grid points
resultthe result of the operations
dimthe current dimension in the recursion
op_dimthe dimension in that a special operation is applied

References sgpp::base::DataVector::add(), downOpDim(), sgpp::base::DataVector::getSize(), sgpp::base::DataVector::setAll(), updown(), and upOpDim().

Referenced by updown().

◆ up()

virtual void sgpp::pde::UpDownOneOpDimWithShadow::up ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result,
size_t  dim 
)
protectedpure virtual

std 1D up operation

Parameters
dimdimension in which to apply the up-part
alphavector of coefficients
resultvector to store the results in

Implemented in sgpp::pde::OperationLaplacePrewavelet.

Referenced by updown().

◆ updown()

void sgpp::pde::UpDownOneOpDimWithShadow::updown ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result,
size_t  dim,
size_t  op_dim 
)
protected

Recursive procedure for updown().

Parameters
dimthe current dimension
op_dimthe dimension in which a special operation is applied
alphavector of coefficients
resultvector to store the results in

References sgpp::base::DataVector::add(), down(), sgpp::base::DataVector::getSize(), sgpp::base::DataVector::setAll(), specialOP(), and up().

Referenced by mult(), and specialOP().

◆ upOpDim()

virtual void sgpp::pde::UpDownOneOpDimWithShadow::upOpDim ( sgpp::base::DataVector alpha,
sgpp::base::DataVector result,
size_t  dim 
)
protectedpure virtual

special 1D up operation that is only executed in one direction

Parameters
alphathe coefficients of the gridpoints
resultvector with the result of this operation
dimthe dimension in that up-Gradient is applied

Implemented in sgpp::pde::OperationLaplacePrewavelet.

Referenced by specialOP().

Member Data Documentation

◆ shadowStorage

sgpp::base::GridStorage* sgpp::pde::UpDownOneOpDimWithShadow::shadowStorage
protected

◆ storage


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