Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
NonDQuadrature Class Reference

Derived nondeterministic class that generates N-dimensional numerical quadrature points for evaluation of expectation integrals over uncorrelated standard normals/uniforms/exponentials/betas/gammas. More...

Inheritance diagram for NonDQuadrature:
NonDIntegration NonD Analyzer Iterator

List of all members.

Public Member Functions

 NonDQuadrature (Model &model, const UShortArray &quad_order, const RealVector &dim_pref)
 alternate constructor for instantiations "on the fly" based on a quadrature order specification
 NonDQuadrature (Model &model, int num_filt_samples, const RealVector &dim_pref)
 alternate constructor for instantiations "on the fly" based on the size of a filtered tensor product sample set
const Pecos::UShortArray & quadrature_order () const
 return Pecos::TensorProductDriver::quadOrder
void filtered_samples (size_t samples)
 set numFilteredSamples
void compute_minimum_quadrature_order ()
 calculate smallest dimQuadOrderRef with at least numFilteredSamples
void compute_minimum_quadrature_order (size_t min_samples, const RealVector &dim_pref, UShortArray &dim_quad_order)
 calculate smallest dim_quad_order with at least min_samples

Protected Member Functions

 NonDQuadrature (Model &model)
 constructor
 ~NonDQuadrature ()
 destructor
void initialize_grid (const std::vector< Pecos::BasisPolynomial > &poly_basis)
void get_parameter_sets (Model &model)
 Returns one block of samples (ndim * num_samples)
void reset ()
 restore initial state for repeated sub-iterator executions
void sampling_reset (int min_samples, bool all_data_flag, bool stats_flag)
void increment_grid ()
 increment SSG level/TPQ order
void increment_grid_preference (const RealVector &dim_pref)
 increment SSG level/TPQ order and update anisotropy
void increment_refinement_sequence ()
 increment sequenceIndex and update active orders/levels
int num_samples () const
 get the current number of samples

Private Member Functions

void increment_grid (UShortArray &dim_quad_order)
 convenience function used to make increment_grid() more modular
void increment_grid_preference (const RealVector &dim_pref, UShortArray &dim_quad_order)
 convenience function used to make increment_grid_preference() more modular
void filter_parameter_sets ()
 prune allSamples back to size numFilteredSamples, retaining points with highest product weight
void anisotropic_preference (unsigned short quad_order_spec, const RealVector &dim_pref_spec, UShortArray &quad_order)
 initialize quad_order vector based on quad_order_spec scalar and dim_pref_spec vector
void anisotropic_preference (const RealVector &dim_pref, UShortArray &quad_order_ref)
 update quad_order_ref based on an updated dimension preference, enforcing previous values as a lower bound
void initialize_dimension_quadrature_order (unsigned short quad_order_spec, const RealVector &dim_pref_spec, UShortArray &dim_quad_order)
 initialize dim_quad_order from quad_order_spec and dim_pref_spec
void nested_quadrature_order (const UShortArray &quad_order_ref)
 update Pecos::TensorProductDriver::quadOrder from dimQuadOrderRef to account for nested rule constraints
void increment_dimension_quadrature_order (UShortArray &dim_quad_order)
 increment each dim_quad_order entry by 1
void increment_dimension_quadrature_order (const RealVector &dim_pref, UShortArray &dim_quad_order)
 increment the dim_quad_order entry with maximum preference by 1 and then rebalance

Private Attributes

Pecos::TensorProductDriver * tpqDriver
 convenience pointer to the numIntDriver representation
bool nestedRules
 for studies involving refinement strategies, allow for use of nested quadrature rules such as Gauss-Patterson
UShortArray quadOrderSpec
 a sequence of scalar quadrature orders, one per refinement level
UShortArray dimQuadOrderRef
 reference point for Pecos::TensorProductDriver::quadOrder: the original user specification for the number of Gauss points per dimension, plus any refinements posted by increment_grid()
size_t numFilteredSamples
 size of a filtered set of tensor quadrature points; used by the regression PCE approach known as "probabilistic collocation"

Detailed Description

Derived nondeterministic class that generates N-dimensional numerical quadrature points for evaluation of expectation integrals over uncorrelated standard normals/uniforms/exponentials/betas/gammas.

This class is used by NonDPolynomialChaos, but could also be used for general numerical integration of moments. It employs Gauss-Hermite, Gauss-Legendre, Gauss-Laguerre, Gauss-Jacobi and generalized Gauss-Laguerre quadrature for use with normal, uniform, exponential, beta, and gamma density functions and integration bounds. The abscissas and weights for one-dimensional integration are extracted from the appropriate OrthogonalPolynomial class and are extended to n-dimensions using a tensor product approach.


Constructor & Destructor Documentation

NonDQuadrature ( Model model,
const UShortArray &  quad_order,
const RealVector &  dim_pref 
)

alternate constructor for instantiations "on the fly" based on a quadrature order specification

This alternate constructor is used for on-the-fly generation and evaluation of numerical quadrature points.

References NonDIntegration::numIntDriver, and NonDQuadrature::tpqDriver.

NonDQuadrature ( Model model,
int  num_filt_samples,
const RealVector &  dim_pref 
)

alternate constructor for instantiations "on the fly" based on the size of a filtered tensor product sample set

This alternate constructor is used for on-the-fly generation and evaluation of numerical quadrature points.

References NonDIntegration::numIntDriver, and NonDQuadrature::tpqDriver.

NonDQuadrature ( Model model) [protected]

constructor

This constructor is called for a standard letter-envelope iterator instantiation. In this case, set_db_list_nodes has been called and probDescDB can be queried for settings from the method specification. It is not currently used, as there is not yet a separate nond_quadrature method specification.

References NonDIntegration::check_variables(), ProblemDescDB::get_bool(), ProblemDescDB::get_short(), Iterator::maxConcurrency, NonD::natafTransform, NonDQuadrature::nestedRules, NonDIntegration::numIntDriver, Iterator::probDescDB, NonDQuadrature::reset(), and NonDQuadrature::tpqDriver.


Member Function Documentation

void initialize_grid ( const std::vector< Pecos::BasisPolynomial > &  poly_basis) [protected, virtual]
void sampling_reset ( int  min_samples,
bool  all_data_flag,
bool  stats_flag 
) [protected, virtual]

used by DataFitSurrModel::build_global() to publish the minimum number of points needed from the quadrature routine in order to build a particular global approximation.

Reimplemented from Iterator.

References NonDQuadrature::compute_minimum_quadrature_order(), NonDIntegration::dimPrefSpec, NonDQuadrature::dimQuadOrderRef, NonDQuadrature::nested_quadrature_order(), NonDQuadrature::nestedRules, Iterator::numContinuousVars, and NonDQuadrature::tpqDriver.

int num_samples ( ) const [inline, protected, virtual]

get the current number of samples

Return current number of evaluation points. Since the calculation of samples, collocation points, etc. might be costly, provide a default implementation here that backs out from the maxConcurrency. May be (is) overridden by derived classes.

Reimplemented from Iterator.

References NonDQuadrature::numFilteredSamples, and NonDQuadrature::tpqDriver.

void anisotropic_preference ( unsigned short  quad_order_spec,
const RealVector &  dim_pref_spec,
UShortArray &  dim_quad_order 
) [private]

initialize quad_order vector based on quad_order_spec scalar and dim_pref_spec vector

This version of anisotropic_preference() converts a scalar quad_order_spec and a dim_pref vector into a quad_order vector. It is used for initialization and does not enforce a reference lower bound.

References Iterator::numContinuousVars.

Referenced by NonDQuadrature::increment_dimension_quadrature_order(), and NonDQuadrature::initialize_dimension_quadrature_order().


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