Dakota
Version
Explore and Predict with Confidence
|
Container class encapsulating variables data that can be shared among a set of Variables instances. More...
Public Member Functions | |
SharedVariablesData () | |
default constructor | |
SharedVariablesData (const ProblemDescDB &problem_db, const ShortShortPair &view) | |
standard constructor | |
SharedVariablesData (const ShortShortPair &view, const std::map< unsigned short, size_t > &vars_comps, const BitArray &all_relax_di=BitArray(), const BitArray &all_relax_dr=BitArray()) | |
medium weight constructor providing detailed variable counts | |
SharedVariablesData (const ShortShortPair &view, const SizetArray &vars_comps_totals, const BitArray &all_relax_di=BitArray(), const BitArray &all_relax_dr=BitArray()) | |
lightweight constructor providing variable count totals | |
SharedVariablesData (const SharedVariablesData &svd) | |
copy constructor | |
~SharedVariablesData () | |
destructor | |
SharedVariablesData & | operator= (const SharedVariablesData &svd) |
assignment operator | |
SharedVariablesData | copy () const |
create a deep copy of the current object, copy both core and view data, and return by value | |
SharedVariablesData | copy (const ShortShortPair &view) const |
create a deep copy of the current object, copy its core data, update the view, and return by value | |
void | all_counts (size_t &num_acv, size_t &num_adiv, size_t &num_adsv, size_t &num_adrv) const |
compute all variables sums from SharedVariablesDataRep::variablesCompsTotals and SharedVariablesDataRep::allRelaxedDiscrete{Int,Real} | |
void | design_counts (size_t &num_cdv, size_t &num_ddiv, size_t &num_ddsv, size_t &num_ddrv) const |
compute design variables sums from SharedVariablesDataRep::variablesCompsTotals and SharedVariablesDataRep::allRelaxedDiscrete{Int,Real} | |
void | aleatory_uncertain_counts (size_t &num_cauv, size_t &num_dauiv, size_t &num_dausv, size_t &num_daurv) const |
compute aleatory uncertain variables sums from SharedVariablesDataRep::variablesCompsTotals and SharedVariablesDataRep::allRelaxedDiscrete{Int,Real} | |
void | epistemic_uncertain_counts (size_t &num_ceuv, size_t &num_deuiv, size_t &num_deusv, size_t &num_deurv) const |
compute epistemic uncertain variables sums from SharedVariablesDataRep::variablesCompsTotals and SharedVariablesDataRep::allRelaxedDiscrete{Int,Real} | |
void | uncertain_counts (size_t &num_cuv, size_t &num_duiv, size_t &num_dusv, size_t &num_durv) const |
compute uncertain variables sums from SharedVariablesDataRep::variablesCompsTotals and SharedVariablesDataRep::allRelaxedDiscrete{Int,Real} | |
void | state_counts (size_t &num_csv, size_t &num_dsiv, size_t &num_dssv, size_t &num_dsrv) const |
compute state variables sums from SharedVariablesDataRep::variablesCompsTotals and SharedVariablesDataRep::allRelaxedDiscrete{Int,Real} | |
void | active_subsets (bool &cdv, bool &ddv, bool &cauv, bool &dauv, bool &ceuv, bool &deuv, bool &csv, bool &dsv) const |
define active variable subsets based on active view | |
void | inactive_subsets (bool &cdv, bool &ddv, bool &cauv, bool &dauv, bool &ceuv, bool &deuv, bool &csv, bool &dsv) const |
define active variable subsets based on active view | |
void | complement_subsets (bool &cdv, bool &ddv, bool &cauv, bool &dauv, bool &ceuv, bool &deuv, bool &csv, bool &dsv) const |
define active variable subsets based on active view | |
size_t | cv_index_to_all_index (size_t cv_index) const |
convert index within active continuous variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | icv_index_to_all_index (size_t ccv_index) const |
convert index within inactive continuous variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | ccv_index_to_all_index (size_t ccv_index) const |
convert index within complement of active continuous variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | acv_index_to_all_index (size_t acv_index) const |
convert index within all continuous variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | div_index_to_all_index (size_t div_index) const |
convert index within active discrete integer variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | idiv_index_to_all_index (size_t div_index) const |
convert index within inactive discrete integer variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | cdiv_index_to_all_index (size_t div_index) const |
convert index within complement of active discrete integer variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | adiv_index_to_all_index (size_t adiv_index) const |
convert index within all discrete integer variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | dsv_index_to_all_index (size_t dsv_index) const |
convert index within active discrete string variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | idsv_index_to_all_index (size_t dsv_index) const |
convert index within inactive discrete string variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | cdsv_index_to_all_index (size_t dsv_index) const |
convert index within complement of active discrete string variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | adsv_index_to_all_index (size_t adsv_index) const |
convert index within all discrete string variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | drv_index_to_all_index (size_t drv_index) const |
convert index within active discrete real variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | idrv_index_to_all_index (size_t drv_index) const |
convert index within inactive discrete real variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | cdrv_index_to_all_index (size_t drv_index) const |
convert index within complement of active discrete real variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | adrv_index_to_all_index (size_t adrv_index) const |
convert index within all discrete real variables to index within aggregated variables (all continous, discrete {int,string,real}) | |
size_t | cv_index_to_active_index (size_t cv_index) const |
convert index within active continuous variables to index within aggregated active variables (active continous, discrete {int,string,real}) | |
size_t | div_index_to_active_index (size_t div_index) const |
convert index within active discrete integer variables to index within aggregated active variables (active continous, discrete {int,string,real}) | |
size_t | dsv_index_to_active_index (size_t dsv_index) const |
convert index within active discrete string variables to index within aggregated active variables (active continous, discrete {int,string,real}) | |
size_t | drv_index_to_active_index (size_t drv_index) const |
convert index within active discrete real variables to index within aggregated active variables (active continous, discrete {int,string,real}) | |
size_t | ccv_index_to_acv_index (size_t ccv_index) const |
convert index within complement of active continuous variables to index within all continuous variables | |
size_t | cdiv_index_to_adiv_index (size_t div_index) const |
convert index within complement of active discrete integer variables to index within all discrete integer variables | |
size_t | cdsv_index_to_adsv_index (size_t dsv_index) const |
convert index within complement of active discrete string variables to index within all discrete string variables | |
size_t | cdrv_index_to_adrv_index (size_t drv_index) const |
convert index within complement of active discrete real variables to index within all discrete real variables | |
BitArray | active_to_all_mask () const |
create a BitArray indicating the active subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | cv_to_all_mask () const |
create a BitArray indicating the active continuous subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | icv_to_all_mask () const |
create a BitArray indicating the inactive continuous subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | ccv_to_all_mask () const |
create a BitArray indicating the complement continuous subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | acv_to_all_mask () const |
create a BitArray indicating the all continuous subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | div_to_all_mask () const |
create a BitArray indicating the active discrete int subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | idiv_to_all_mask () const |
create a BitArray indicating the inactive discrete int subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | cdiv_to_all_mask () const |
create a BitArray indicating the complement discrete int subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | adiv_to_all_mask () const |
create a BitArray indicating the all discrete int subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | dsv_to_all_mask () const |
create a BitArray indicating the active discrete string subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | idsv_to_all_mask () const |
create a BitArray indicating the inactive discrete string subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | cdsv_to_all_mask () const |
create a BitArray indicating the complement discrete string subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | adsv_to_all_mask () const |
create a BitArray indicating the all discrete string subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | drv_to_all_mask () const |
create a BitArray indicating the active discrete real subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | idrv_to_all_mask () const |
create a BitArray indicating the inactive discrete real subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | cdrv_to_all_mask () const |
create a BitArray indicating the complement discrete real subset of all {continuous,discrete {int,string,real}} variables | |
BitArray | adrv_to_all_mask () const |
create a BitArray indicating the all discrete real subset of all {continuous,discrete {int,string,real}} variables | |
void | initialize_active_start_counts () |
initialize start index and counts for active variables | |
void | initialize_inactive_start_counts () |
initialize start index and counts for inactive variables | |
void | initialize_active_components () |
initialize the active components totals given active variable counts | |
void | initialize_inactive_components () |
initialize the inactive components totals given inactive variable counts | |
const BitArray & | all_relaxed_discrete_int () const |
return allRelaxedDiscreteInt | |
const BitArray & | all_relaxed_discrete_real () const |
return allRelaxedDiscreteReal | |
StringMultiArrayView | all_continuous_labels (size_t start, size_t num_items) const |
get num_items continuous labels beginning at index start | |
void | all_continuous_labels (StringMultiArrayConstView cv_labels, size_t start, size_t num_items) |
set num_items continuous labels beginning at index start | |
void | all_continuous_label (const String &cv_label, size_t index) |
set continuous label at index start | |
StringMultiArrayView | all_discrete_int_labels (size_t start, size_t num_items) const |
get num_items discrete integer labels beginning at index start | |
void | all_discrete_int_labels (StringMultiArrayConstView div_labels, size_t start, size_t num_items) |
set num_items discrete integer labels beginning at index start | |
void | all_discrete_int_label (const String &div_label, size_t index) |
set discrete integer label at index start | |
StringMultiArrayView | all_discrete_string_labels (size_t start, size_t num_items) const |
get num_items discrete string labels beginning at index start | |
void | all_discrete_string_labels (StringMultiArrayConstView dsv_labels, size_t start, size_t num_items) |
set num_items discrete string labels beginning at index start | |
void | all_discrete_string_label (const String &dsv_label, size_t index) |
set discrete string label at index start | |
StringMultiArrayView | all_discrete_real_labels (size_t start, size_t num_items) const |
get num_items discrete real labels beginning at index start | |
void | all_discrete_real_labels (StringMultiArrayConstView drv_labels, size_t start, size_t num_items) |
set num_items discrete real labels beginning at index start | |
void | all_discrete_real_label (const String &drv_label, size_t index) |
set discrete real label at index start | |
void | assemble_all_labels (StringArray &all_labels) const |
assemble all variable labels (continuous and discrete {int,string,real}) in standard (input specification-based) order | |
UShortMultiArrayConstView | all_continuous_types (size_t start, size_t num_items) const |
get num_items continuous types beginning at index start | |
void | all_continuous_types (UShortMultiArrayConstView cv_types, size_t start, size_t num_items) |
set num_items continuous types beginning at index start | |
void | all_continuous_type (unsigned short cv_type, size_t index) |
set continuous type at index | |
UShortMultiArrayConstView | all_discrete_int_types (size_t start, size_t num_items) const |
get num_items discrete integer types beginning at index start | |
void | all_discrete_int_types (UShortMultiArrayConstView div_types, size_t start, size_t num_items) |
set num_items discrete integer types beginning at index start | |
void | all_discrete_int_type (unsigned short div_type, size_t index) |
set discrete integer type at index | |
UShortMultiArrayConstView | all_discrete_string_types (size_t start, size_t num_items) const |
get num_items discrete string types beginning at index start | |
void | all_discrete_string_types (UShortMultiArrayConstView dsv_types, size_t start, size_t num_items) |
set num_items discrete string types beginning at index start | |
void | all_discrete_string_type (unsigned short dsv_type, size_t index) |
set discrete string type at index | |
UShortMultiArrayConstView | all_discrete_real_types (size_t start, size_t num_items) const |
get num_items discrete real types beginning at index start | |
void | all_discrete_real_types (UShortMultiArrayConstView drv_types, size_t start, size_t num_items) |
set num_items discrete real types beginning at index start | |
void | all_discrete_real_type (unsigned short drv_type, size_t index) |
set discrete real type at index | |
SizetMultiArrayConstView | all_continuous_ids (size_t start, size_t num_items) const |
get num_items continuous ids beginning at index start | |
void | all_continuous_ids (SizetMultiArrayConstView cv_ids, size_t start, size_t num_items) |
set num_items continuous ids beginning at index start | |
void | all_continuous_id (size_t id, size_t index) |
set num_items continuous ids beginning at index start | |
SizetMultiArrayConstView | all_discrete_int_ids (size_t start, size_t num_items) const |
get num_items discrete int ids beginning at index start | |
SizetMultiArrayConstView | all_discrete_string_ids (size_t start, size_t num_items) const |
get num_items discrete string ids beginning at index start | |
SizetMultiArrayConstView | all_discrete_real_ids (size_t start, size_t num_items) const |
get num_items discrete real ids beginning at index start | |
const String & | id () const |
return the user-provided or default Variables identifier | |
const SizetArray & | components_totals () const |
return variable type counts for {continuous,discrete integer,discrete real} {design,aleatory uncertain,epistemic uncertain,state} | |
const SizetArray & | active_components_totals () const |
return active variable type counts for {continuous,discrete integer,discrete real} {design,aleatory uncertain,epistemic uncertain,state} | |
const SizetArray & | inactive_components_totals () const |
return inactive variable type counts for {continuous,discrete integer,discrete real} {design,aleatory uncertain,epistemic uncertain,state} | |
size_t | vc_lookup (unsigned short key) const |
retrieve the variables type count within svdRep->variablesComponents corresponding to (a fine-grain variables type) key | |
const ShortShortPair & | view () const |
retreive the Variables view | |
void | view (const ShortShortPair &view_pr) const |
assign the Variables view | |
void | active_view (short view1) const |
set the active Variables view | |
void | inactive_view (short view2) const |
set the inactive Variables view | |
size_t | cv () const |
get number of active continuous vars | |
size_t | cv_start () const |
get start index of active continuous vars | |
size_t | div () const |
get number of active discrete int vars | |
size_t | div_start () const |
get start index of active discrete int vars | |
size_t | dsv () const |
get number of active discrete string vars | |
size_t | dsv_start () const |
get start index of active discrete string vars | |
size_t | drv () const |
get number of active discrete real vars | |
size_t | drv_start () const |
get start index of active discrete real vars | |
size_t | icv () const |
get number of inactive continuous vars | |
size_t | icv_start () const |
get start index of inactive continuous vars | |
size_t | idiv () const |
get number of inactive discrete int vars | |
size_t | idiv_start () const |
get start index of inactive discrete int vars | |
size_t | idsv () const |
get number of inactive discrete string vars | |
size_t | idsv_start () const |
get start index of inactive discr string vars | |
size_t | idrv () const |
get number of inactive discrete real vars | |
size_t | idrv_start () const |
get start index of inactive discrete real vars | |
size_t | acv () const |
get total number of continuous vars | |
size_t | adiv () const |
get total number of discrete int vars | |
size_t | adsv () const |
get total number of discrete string vars | |
size_t | adrv () const |
get total number of discrete real vars | |
void | cv (size_t ncv) |
set number of active continuous vars | |
void | cv_start (size_t cvs) |
set start index of active continuous vars | |
void | div (size_t ndiv) |
set number of active discrete int vars | |
void | div_start (size_t divs) |
set start index of active discrete int vars | |
void | dsv (size_t ndsv) |
set number of active discrete string vars | |
void | dsv_start (size_t dsvs) |
set start index of active discr string vars | |
void | drv (size_t ndrv) |
set number of active discrete real vars | |
void | drv_start (size_t drvs) |
set start index of active discrete real vars | |
void | icv (size_t nicv) |
set number of inactive continuous vars | |
void | icv_start (size_t icvs) |
set start index of inactive continuous vars | |
void | idiv (size_t nidiv) |
set number of inactive discrete int vars | |
void | idiv_start (size_t idivs) |
set start index of inactive discr int vars | |
void | idsv (size_t nidsv) |
set number of inactive discr string vars | |
void | idsv_start (size_t idsvs) |
set start index of inact discr string vars | |
void | idrv (size_t nidrv) |
set number of inactive discrete real vars | |
void | idrv_start (size_t idrvs) |
set start index of inact discr real vars | |
Private Member Functions | |
template<class Archive > | |
void | serialize (Archive &ar, const unsigned int version) |
serialize through the pointer, which requires object tracking: write and read are symmetric for this class | |
Private Attributes | |
std::shared_ptr< SharedVariablesDataRep > | svdRep |
pointer to the body (handle-body idiom) | |
Friends | |
class | boost::serialization::access |
allow boost access to serialize this class | |
Container class encapsulating variables data that can be shared among a set of Variables instances.
An array of Variables objects (e.g., Analyzer::allVariables) contains repeated configuration data (id's, labels, counts). SharedVariablesData employs a handle-body idiom to allow this shared data to be managed in a single object with many references to it, one per Variables object in the array. This allows scaling to larger sample sets.