SG++-Doxygen-Documentation
sgpp::datadriven::OperationRegularizationDiagonal Class Referenceabstract

Implementation of the application of a diagonal matrix to a DataVector for regularization. More...

#include <OperationRegularizationDiagonal.hpp>

Inheritance diagram for sgpp::datadriven::OperationRegularizationDiagonal:
sgpp::base::OperationMatrix sgpp::datadriven::OperationRegularizationDiagonalLinearBoundary

Public Member Functions

virtual void mult (base::DataVector &alpha, base::DataVector &result)
 Multiplication with diagonal matrix. More...
 
 OperationRegularizationDiagonal (base::GridStorage *storage, int mode, double k)
 Constructor of OperationRegularizationDiagonal. More...
 
virtual ~OperationRegularizationDiagonal ()
 Destructor. More...
 
- Public Member Functions inherited from sgpp::base::OperationMatrix
 OperationMatrix ()
 Constructor. More...
 
virtual ~OperationMatrix ()
 Destructor. More...
 

Static Public Attributes

static const int ANISOTROPIC_PENALTY = 4
 
static const int H0HKLAPLACE = 2
 Diagonal scaling for pseudo-laplace, replacing \(L_2\) with \(H^0\) in 1d. More...
 
static const int HKMIX = 1
 Diagonal scaling for \(H^k_\textbf{mix}\)-norm (product of \(H^k\) 1D norms) More...
 
static const int ISOTROPIC_PENALTY = 3
 

Protected Member Functions

virtual void init ()
 Check for mode and run corresponding init. More...
 
virtual void initAnisotropicPenalty ()
 Initialize ANISOTROPIC_PENALTY, ignores constructor parameter k. More...
 
virtual void initH0HkLaplace (double k)=0
 Initialize H0HkLaplace. More...
 
virtual void initHkmix (double k)=0
 Initialize Hkmix. More...
 
virtual void initIsotropicPenalty ()
 Initialize ISOTROPIC_PENALTY, ignores constructor parameter k. More...
 

Protected Attributes

base::DataVector diagonal
 
double k
 
int mode
 
size_t size
 
base::GridStoragestorage
 

Detailed Description

Implementation of the application of a diagonal matrix to a DataVector for regularization.

This class implements several scaling possibilities.

Constructor & Destructor Documentation

◆ OperationRegularizationDiagonal()

sgpp::datadriven::OperationRegularizationDiagonal::OperationRegularizationDiagonal ( base::GridStorage storage,
int  mode,
double  k 
)

Constructor of OperationRegularizationDiagonal.

Constructor should most likely call init() in subclasses.

Parameters
storagePointer to grid's storage object
modeMode, specifying which regularization to use. Example: OperationRegularizationDiagonal::HKMIX.
kParameter for \(H^k\)

References sgpp::base::HashGridStorage::getSize(), and size.

◆ ~OperationRegularizationDiagonal()

virtual sgpp::datadriven::OperationRegularizationDiagonal::~OperationRegularizationDiagonal ( )
inlinevirtual

Destructor.

References alpha, and mult().

Member Function Documentation

◆ init()

void sgpp::datadriven::OperationRegularizationDiagonal::init ( )
protectedvirtual

◆ initAnisotropicPenalty()

void sgpp::datadriven::OperationRegularizationDiagonal::initAnisotropicPenalty ( )
protectedvirtual

Initialize ANISOTROPIC_PENALTY, ignores constructor parameter k.

Diagonal entries are \(\frac{1}{2}\log(1+(\frac{\max\{l_1,\dots,l_d\}}{\max\{\min\{l_1,\dots,l_d\},1\}})d)\).

References diagonal, chess::dim, sgpp::base::HashGridStorage::getDimension(), sgpp::base::HashGridPoint::getLevelMax(), sgpp::base::HashGridPoint::getLevelMin(), sgpp::base::HashGridStorage::getPoint(), python.statsfileInfo::i, size, and storage.

Referenced by init().

◆ initH0HkLaplace()

virtual void sgpp::datadriven::OperationRegularizationDiagonal::initH0HkLaplace ( double  k)
protectedpure virtual

Initialize H0HkLaplace.

Diagonal entries are \(\sum_{k=1}^d \langle \phi_k(x_k),\phi_k(x_k) \rangle_{H^k} \prod_{l\neq k} \langle \phi_k(x_k),\phi_k(x_k) \rangle_{H^0}\).

Parameters
kParameter k

Implemented in sgpp::datadriven::OperationRegularizationDiagonalLinearBoundary.

Referenced by init().

◆ initHkmix()

virtual void sgpp::datadriven::OperationRegularizationDiagonal::initHkmix ( double  k)
protectedpure virtual

Initialize Hkmix.

Diagonal entries are \(\prod_{k=1}^d \langle \phi_k(x_k),\phi_k(x_k) \rangle_{H^k}\).

Parameters
kParameter k

Implemented in sgpp::datadriven::OperationRegularizationDiagonalLinearBoundary.

Referenced by init().

◆ initIsotropicPenalty()

void sgpp::datadriven::OperationRegularizationDiagonal::initIsotropicPenalty ( )
protectedvirtual

Initialize ISOTROPIC_PENALTY, ignores constructor parameter k.

Diagonal entries are \(\frac{1}{\max\{l_1,\dots,l_d\}-\min\{l_1,\dots,l_d\}+1}d\).

References diagonal, chess::dim, sgpp::base::HashGridStorage::getDimension(), sgpp::base::HashGridPoint::getLevelMax(), sgpp::base::HashGridPoint::getLevelMin(), sgpp::base::HashGridStorage::getPoint(), python.statsfileInfo::i, size, and storage.

Referenced by init().

◆ mult()

void sgpp::datadriven::OperationRegularizationDiagonal::mult ( base::DataVector alpha,
base::DataVector result 
)
virtual

Multiplication with diagonal matrix.

Parameters
alphaSource vector
resultResult vector (entries are overwritten)

Implements sgpp::base::OperationMatrix.

References sgpp::base::DataVector::componentwise_mult(), sgpp::base::DataVector::copyFrom(), diagonal, sgpp::base::HashGridStorage::getSize(), init(), size, and storage.

Referenced by ~OperationRegularizationDiagonal().

Member Data Documentation

◆ ANISOTROPIC_PENALTY

const int sgpp::datadriven::OperationRegularizationDiagonal::ANISOTROPIC_PENALTY = 4
static

Referenced by init().

◆ diagonal

◆ H0HKLAPLACE

const int sgpp::datadriven::OperationRegularizationDiagonal::H0HKLAPLACE = 2
static

Diagonal scaling for pseudo-laplace, replacing \(L_2\) with \(H^0\) in 1d.

Referenced by init().

◆ HKMIX

const int sgpp::datadriven::OperationRegularizationDiagonal::HKMIX = 1
static

Diagonal scaling for \(H^k_\textbf{mix}\)-norm (product of \(H^k\) 1D norms)

Referenced by init().

◆ ISOTROPIC_PENALTY

const int sgpp::datadriven::OperationRegularizationDiagonal::ISOTROPIC_PENALTY = 3
static

Referenced by init().

◆ k

double sgpp::datadriven::OperationRegularizationDiagonal::k
protected

Referenced by init().

◆ mode

int sgpp::datadriven::OperationRegularizationDiagonal::mode
protected

Referenced by init().

◆ size

◆ storage


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