Base class for polynomial chaos expansions (PCE) and stochastic collocation (SC) More...
Public Member Functions | |
NonDExpansion (Model &model) | |
constructor | |
~NonDExpansion () | |
destructor | |
void | quantify_uncertainty () |
perform a forward uncertainty propagation using PCE/SC methods | |
void | print_results (std::ostream &s) |
print the final statistics | |
Protected Member Functions | |
virtual void | initialize_expansion () |
initialize random variable definitions and final stats arrays | |
virtual void | compute_expansion () |
form the expansion by calling uSpaceModel.build_approximation() | |
virtual void | print_coefficients (std::ostream &s) |
print expansion coefficients, as supported by derived instance | |
virtual void | print_moments (std::ostream &s) |
print expansion and numerical moments, as supported by derived instance | |
void | update_expansion () |
update the expansion by calling uSpaceModel.build_approximation(); avoids unnecessary overhead in compute_expansion() | |
void | construct_g_u_model (Model &g_u_model) |
recast iteratedModel from x-space to u-space to create g_u_model | |
void | construct_cubature (Iterator &u_space_sampler, Model &g_u_model, unsigned short cub_int_order) |
assign a NonDCubature instance within u_space_sampler | |
void | construct_quadrature (Iterator &u_space_sampler, Model &g_u_model, const UShortArray &quad_order) |
assign a NonDQuadrature instance within u_space_sampler | |
void | construct_sparse_grid (Iterator &u_space_sampler, Model &g_u_model, unsigned short ssg_level, const RealVector &ssg_dim_pref) |
assign a NonDSparsegrid instance within u_space_sampler | |
void | construct_lhs (Iterator &u_space_sampler, Model &g_u_model) |
assign a NonDLHSSampling instance within u_space_sampler | |
void | initialize_u_space_model () |
initialize uSpaceModel polynomial approximations with PCE/SC data | |
void | construct_expansion_sampler () |
construct the expansionSampler operating on uSpaceModel | |
void | compute_statistics () |
calculate analytic and numerical statistics from the expansion | |
void | update_final_statistics () |
update finalStatistics | |
Protected Attributes | |
Model | uSpaceModel |
Model representing the approximate response function in u-space, after u-space recasting and orthogonal polynomial data fit recursions. | |
short | expansionCoeffsApproach |
method for collocation point generation and subsequent calculation of the expanion coefficients | |
size_t | numUncertainQuant |
number of invocations of quantify_uncertainty() | |
int | numSamplesOnModel |
number of truth samples performed on g_u_model to form the expansion | |
int | numSamplesOnExpansion |
number of approximation samples performed on the polynomial expansion in order to estimate probabilities | |
bool | useDerivsFlag |
flag for use_derivatives specification, indicating usage of derivative data (with respect to expansion variables) to enhance the calculation of the stochastic expansion. | |
Private Member Functions | |
void | average_total_sobol (RealVector &avg_sobol) |
compute average of total Sobol' indices from VBD for use as an anisotropy indicator | |
void | average_decay_rates (RealVector &avg_decay) |
compute average of spectral coefficient decay rates for use as an anisotropy indicator | |
void | initialize_sets () |
initialization of adaptive refinement using generalized sparse grids | |
Real | increment_sets () |
perform an adaptive refinement increment using generalized sparse grids | |
void | finalize_sets () |
finalization of adaptive refinement using generalized sparse grids | |
Real | compute_covariance_metric (const RealSymMatrix &resp_covar_ref) |
compute 2-norm of change in response covariance | |
Real | compute_final_statistics_metric (const RealVector &final_stats_ref) |
compute 2-norm of change in final statistics | |
void | compute_covariance () |
calculate respCovariance | |
void | print_covariance (std::ostream &s) |
print respCovariance | |
void | print_sobol_indices (std::ostream &s) |
print global sensitivity indices | |
void | print_local_sensitivity (std::ostream &s) |
print local sensitivities evaluated at initialPtU | |
void | compute_print_increment_results () |
manage print of results following a refinement increment | |
void | compute_print_iteration_results (bool initialize) |
manage print of results following a refinement increment | |
void | compute_print_converged_results () |
manage print of results following convergence of iterative refinement | |
Private Attributes | |
short | ruleNestingOverride |
user override of rule nesting: NO_OVERRIDE, NESTED, or NON_NESTED | |
short | stochExpRefineType |
refinement type: NO_REFINEMENT, UNIFORM_P_REFINEMENT, or ADAPTIVE_P_REFINEMENT | |
short | stochExpRefineControl |
refinement control: DEFAULT_CONTROL, TOTAL_SOBOL, SPECTRAL_DECAY, or GENERALIZED_SPARSE | |
bool | impSampling |
flag to use LHS sampling or MMAIS sampling on the expansion | |
Iterator | expansionSampler |
Iterator used for sampling on the uSpaceModel to generate approximate probability/reliability/response level statistics. Currently this is an LHS sampling instance, but AIS could also be used. | |
Iterator | importanceSampler |
Iterator used to refine the approximate probability estimates generated by the expansionSampler using importance sampling. | |
RealVector | initialPtU |
stores the initial variables data in u-space | |
RealMatrix | expGradsMeanX |
derivative of the expansion with respect to the x-space variables evaluated at the means (used as uncertainty importance metrics) | |
RealSymMatrix | respCovariance |
symmetric matrix of analytic response covariance | |
bool | expSampling |
flag to indicate calculation of numerical statistics by sampling on the expansion | |
short | vbdControl |
enumeration for controlling VBD calculation and output: NO_VBD, UNIVARIATE_VBD, or ALL_VBD | |
Real | vbdDropTol |
tolerance for omitting output of small VBD indices |
Base class for polynomial chaos expansions (PCE) and stochastic collocation (SC)
The NonDExpansion class provides a base class for methods that use polynomial expansions to approximate the effect of parameter uncertainties on response functions of interest.
void compute_statistics | ( | ) | [protected] |
calculate analytic and numerical statistics from the expansion
Calculate analytic and numerical statistics from the expansion and log results within final_stats for use in OUU.
References Dakota::abort_handler(), Iterator::active_set(), Response::active_set_derivative_vector(), Response::active_set_request_vector(), Iterator::all_responses(), Iterator::all_samples(), Model::approximation_data(), Model::approximations(), NonD::cdfFlag, PecosApproximation::compute_component_effects(), PecosApproximation::compute_moments(), PecosApproximation::compute_total_effects(), NonD::computedGenRelLevels, NonD::computedProbLevels, NonD::computedRelLevels, NonD::computedRespLevels, Model::continuous_variable_ids(), Model::continuous_variables(), Dakota::copy_data(), PecosApproximation::expansion_coefficient_flag(), NonDExpansion::expansionSampler, NonDExpansion::expGradsMeanX, NonDExpansion::expSampling, NonD::finalStatistics, Response::function_gradient(), Response::function_value(), Response::function_values(), PecosApproximation::get_covariance(), PecosApproximation::get_mean_gradient(), NonDAdaptImpSampling::get_probability(), PecosApproximation::get_variance_gradient(), NonDExpansion::importanceSampler, NonDExpansion::impSampling, Iterator::initial_points(), NonDAdaptImpSampling::initialize(), NonD::initialize_distribution_mappings(), NonD::initialize_random_variables(), NonDExpansion::initialPtU, Iterator::iteratedModel, Iterator::iterator_rep(), PecosApproximation::moments(), NonD::natafTransform, NonD::numContDesVars, NonD::numContEpistUncVars, Iterator::numContinuousVars, NonD::numContStateVars, Iterator::numFunctions, NonDExpansion::numSamplesOnExpansion, Iterator::outputLevel, ActiveSet::request_vector(), NonD::requestedGenRelLevels, NonD::requestedProbLevels, NonD::requestedRelLevels, NonD::requestedRespLevels, NonDExpansion::respCovariance, NonD::respLevelTarget, Iterator::response_results(), Iterator::run_iterator(), NonDExpansion::stochExpRefineControl, NonDExpansion::stochExpRefineType, Iterator::subIteratorFlag, NonD::totalLevelRequests, NonDSampling::update_final_statistics(), NonDExpansion::uSpaceModel, and NonDExpansion::vbdControl.
Referenced by NonDExpansion::compute_final_statistics_metric(), NonDExpansion::compute_print_converged_results(), NonDExpansion::compute_print_increment_results(), and NonDExpansion::compute_print_iteration_results().
Real compute_final_statistics_metric | ( | const RealVector & | final_stats_ref | ) | [private] |
compute 2-norm of change in final statistics
computes a "goal-oriented" refinement metric employing finalStatistics
References NonDExpansion::compute_statistics(), NonD::finalStatistics, Response::function_values(), Iterator::numFunctions, NonD::requestedGenRelLevels, NonD::requestedProbLevels, NonD::requestedRelLevels, and NonD::requestedRespLevels.
Referenced by NonDExpansion::increment_sets().
bool useDerivsFlag [protected] |
flag for use_derivatives
specification, indicating usage of derivative data (with respect to expansion variables) to enhance the calculation of the stochastic expansion.
This is part of the method specification since the instantiation of the global data fit surrogate is implicit with no user specification. This behavior is distinct from the usage of response derivatives with respect to auxilliary variables (design, epistemic) for computing derivatives of aleatory expansion statistics with respect to these variables.
Referenced by NonDExpansion::compute_expansion(), NonDExpansion::NonDExpansion(), and NonDPolynomialChaos::NonDPolynomialChaos().