MUQ  0.4.3
muq::Approximation::AdaptiveSmolyakPCE Class Reference

#include <AdaptiveSmolyakPCE.h>

Inheritance diagram for muq::Approximation::AdaptiveSmolyakPCE:

Detailed Description

Definition at line 13 of file AdaptiveSmolyakPCE.h.

Public Member Functions

 AdaptiveSmolyakPCE (std::shared_ptr< muq::Modeling::ModPiece > const &modelIn, std::vector< std::shared_ptr< Quadrature >> const &quad1dIn, std::vector< std::shared_ptr< IndexedScalarBasis >> const &polys1dIn)
 
virtual ~AdaptiveSmolyakPCE ()=default
 
- Public Member Functions inherited from muq::Approximation::SmolyakEstimator< std::shared_ptr< PolynomialChaosExpansion > >
 SmolyakEstimator (std::shared_ptr< muq::Modeling::ModPiece > const &modelIn)
 
virtual ~SmolyakEstimator ()=default
 
virtual std::shared_ptr< PolynomialChaosExpansionCompute (std::shared_ptr< muq::Utilities::MultiIndexSet > const &fixedSet, boost::property_tree::ptree options=boost::property_tree::ptree())
 
virtual std::shared_ptr< PolynomialChaosExpansionAdapt (boost::property_tree::ptree options)
 
virtual double Error () const
 
virtual unsigned int NumEvals () const
 
virtual std::vector< double > ErrorHistory () const
 
virtual std::vector< int > EvalHistory () const
 
virtual std::vector< double > TimeHistory () const
 
virtual std::vector< std::vector< Eigen::VectorXd > > PointHistory () const
 
virtual std::vector< std::vector< std::shared_ptr< muq::Utilities::MultiIndex > > > TermHistory () const
 

Constructor & Destructor Documentation

◆ AdaptiveSmolyakPCE()

AdaptiveSmolyakPCE::AdaptiveSmolyakPCE ( std::shared_ptr< muq::Modeling::ModPiece > const &  modelIn,
std::vector< std::shared_ptr< Quadrature >> const &  quad1dIn,
std::vector< std::shared_ptr< IndexedScalarBasis >> const &  polys1dIn 
)

Definition at line 11 of file AdaptiveSmolyakPCE.cpp.

◆ ~AdaptiveSmolyakPCE()

virtual muq::Approximation::AdaptiveSmolyakPCE::~AdaptiveSmolyakPCE ( )
virtualdefault

Member Function Documentation

◆ AddEstimates()

std::shared_ptr< PolynomialChaosExpansion > AdaptiveSmolyakPCE::AddEstimates ( double  w1,
std::shared_ptr< PolynomialChaosExpansion > const &  part1,
double  w2,
std::shared_ptr< PolynomialChaosExpansion > const &  part2 
) const
overrideprotectedvirtual

◆ ComputeMagnitude()

double AdaptiveSmolyakPCE::ComputeMagnitude ( std::shared_ptr< PolynomialChaosExpansion > const &  estimate) const
overrideprotectedvirtual

◆ ComputeOneTerm()

std::shared_ptr< PolynomialChaosExpansion > AdaptiveSmolyakPCE::ComputeOneTerm ( std::shared_ptr< muq::Utilities::MultiIndex > const &  multi,
std::vector< std::reference_wrapper< const Eigen::VectorXd >> const &  modEvals 
)
overrideprotectedvirtual

This function works in tandem with the OneTermPoints function. After the model has been evaluated at the points returned by OneTermPoints, this function will compute an estimate with the new model evaluations. In the quadrature setting, the estimate will be computed with a weighted sum of the model evaluations stored in the modEvals vector.

Implements muq::Approximation::SmolyakEstimator< std::shared_ptr< PolynomialChaosExpansion > >.

Definition at line 25 of file AdaptiveSmolyakPCE.cpp.

References muq::Approximation::PCEFactory::Compute(), and tensFactory.

◆ OneTermPoints()

std::vector< Eigen::VectorXd > AdaptiveSmolyakPCE::OneTermPoints ( std::shared_ptr< muq::Utilities::MultiIndex > const &  multi)
overrideprotectedvirtual

Computes the locations where the model will need to be evaluated in order to construct a single tensor-product estimate. For example, in the Smolyak quadrature setting, this function will return the quadrature points coming from the tensor product quadrature rule defined by the multiindex.

This function works in tandem with the ComputeOneTerm function, which takes model evaluations and actually returns the tensor product estimate. These two functions are split to allow the SmolyakEstimator to handle any job scheduling or caching that may be needed for parallel model evaluations.

Implements muq::Approximation::SmolyakEstimator< std::shared_ptr< PolynomialChaosExpansion > >.

Definition at line 20 of file AdaptiveSmolyakPCE.cpp.

References muq::Approximation::PCEFactory::QuadPts(), and tensFactory.

Member Data Documentation

◆ tensFactory

PCEFactory muq::Approximation::AdaptiveSmolyakPCE::tensFactory
protected

Definition at line 33 of file AdaptiveSmolyakPCE.h.

Referenced by ComputeOneTerm(), and OneTermPoints().


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