$extrastylesheet
Dakota
Version 6.2
|
Derived model class which performs a complete sub-iterator execution within every evaluation of the model. More...
Public Member Functions | |
NestedModel (ProblemDescDB &problem_db) | |
constructor | |
~NestedModel () | |
destructor | |
Protected Member Functions | |
void | derived_compute_response (const ActiveSet &set) |
portion of compute_response() specific to NestedModel | |
void | derived_asynch_compute_response (const ActiveSet &set) |
portion of asynch_compute_response() specific to NestedModel | |
const IntResponseMap & | derived_synchronize () |
portion of synchronize() specific to NestedModel | |
Iterator & | subordinate_iterator () |
return subIterator | |
Model & | subordinate_model () |
return subModel | |
void | derived_subordinate_models (ModelList &ml, bool recurse_flag) |
return subModel | |
Interface & | derived_interface () |
return optionalInterface | |
void | surrogate_response_mode (short mode) |
pass a bypass request on to the subModel for any lower-level surrogates | |
void | component_parallel_mode (short mode) |
update component parallel mode for supporting parallelism in optionalInterface and subModel | |
size_t | mi_parallel_level_index () const |
return subIteratorSched.miPLIndex | |
short | local_eval_synchronization () |
return optionalInterface synchronization setting | |
int | local_eval_concurrency () |
return optionalInterface asynchronous evaluation concurrency | |
bool | derived_master_overload () const |
flag which prevents overloading the master with a multiprocessor evaluation (forwarded to optionalInterface) | |
IntIntPair | estimate_partition_bounds (int max_eval_concurrency) |
estimate the minimum and maximum partition sizes that can be utilized by this Model | |
void | derived_init_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
set up optionalInterface and subModel for parallel operations | |
void | derived_init_serial () |
set up optionalInterface and subModel for serial operations. | |
void | derived_set_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
set active parallel configuration within subModel | |
void | derived_free_communicators (ParLevLIter pl_iter, int max_eval_concurrency, bool recurse_flag=true) |
deallocate communicator partitions for the NestedModel (forwarded to optionalInterface and subModel) | |
void | serve_run (ParLevLIter pl_iter, int max_eval_concurrency) |
Service optionalInterface and subModel job requests received from the master. Completes when a termination message is received from stop_servers(). | |
void | stop_servers () |
Executed by the master to terminate server operations for subModel and optionalInterface when iteration on the NestedModel is complete. | |
const String & | interface_id () const |
return the optionalInterface identifier | |
int | evaluation_id () const |
Return the current evaluation id for the NestedModel. | |
void | set_evaluation_reference () |
set the evaluation counter reference points for the NestedModel (request forwarded to optionalInterface and subModel) | |
void | fine_grained_evaluation_counters () |
request fine-grained evaluation reporting within optionalInterface and subModel | |
void | print_evaluation_summary (std::ostream &s, bool minimal_header=false, bool relative_count=true) const |
print the evaluation summary for the NestedModel (request forwarded to optionalInterface and subModel) | |
void | eval_tag_prefix (const String &eval_id_str) |
set the hierarchical eval ID tag prefix | |
void | initialize_iterator (int job_index) |
void | pack_parameters_buffer (MPIPackBuffer &send_buffer, int job_index) |
void | unpack_parameters_buffer (MPIUnpackBuffer &recv_buffer) |
void | unpack_parameters_initialize (MPIUnpackBuffer &recv_buffer) |
void | pack_results_buffer (MPIPackBuffer &send_buffer, int job_index) |
void | unpack_results_buffer (MPIUnpackBuffer &recv_buffer, int job_index) |
void | update_local_results (int job_index) |
Private Member Functions | |
void | update_sub_iterator () |
update subIterator with mapping data and set subIterator-based counts | |
void | initialize_iterator (const Variables &vars, const ActiveSet &set, int eval_id) |
lower level function shared by initialize_iterator(int) and unpack_parameters_initialize() | |
void | unpack (MPIUnpackBuffer &recv_buffer, Variables &vars, ActiveSet &set, int &eval_id) |
lower level function shared by unpack_parameters_buffer() and unpack_parameters_initialize() | |
void | resolve_real_variable_mapping (const String &map1, const String &map2, size_t curr_index, short &inactive_sm_view) |
for a named real mapping, resolve primary index and secondary target | |
void | resolve_integer_variable_mapping (const String &map1, const String &map2, size_t curr_index, short &inactive_sm_view) |
for a named integer mapping, resolve primary index and secondary target | |
void | resolve_string_variable_mapping (const String &map1, const String &map2, size_t curr_index, short &inactive_sm_view) |
for a named string mapping, resolve primary index and secondary target | |
size_t | sm_acv_index_map (size_t pacvm_index, short sacvm_target) |
offset pacvm_index based on sacvm_target to create mapped_index | |
size_t | sm_adiv_index_map (size_t padivm_index, short sadivm_target) |
offset padivm_index based on sadivm_target to create mapped_index | |
size_t | sm_adsv_index_map (size_t padsvm_index, short sadsvm_target) |
offset padsvm_index based on sadsvm_target to create mapped_index | |
size_t | sm_adrv_index_map (size_t padrvm_index, short sadrvm_target) |
offset padrvm_index based on sadrvm_target to create mapped_index | |
size_t | cv_index_map (size_t cv_index, const Variables &vars) |
offset cv_index to create index into aggregated primary/secondary arrays | |
size_t | div_index_map (size_t div_index, const Variables &vars) |
offset div_index to create index into aggregated primary/secondary arrays | |
size_t | dsv_index_map (size_t dsv_index, const Variables &vars) |
offset dsv_index to create index into aggregated primary/secondary arrays | |
size_t | drv_index_map (size_t drv_index, const Variables &vars) |
offset drv_index to create index into aggregated primary/secondary arrays | |
size_t | ccv_index_map (size_t ccv_index, const Variables &vars) |
offset active complement ccv_index to create index into all continuous arrays | |
size_t | cdiv_index_map (size_t cdiv_index, const Variables &vars) |
offset active complement cdiv_index to create index into all discrete int arrays | |
size_t | cdsv_index_map (size_t cdsv_index, const Variables &vars) |
offset active complement cdsv_index to create index into all discrete string arrays | |
size_t | cdrv_index_map (size_t cdrv_index, const Variables &vars) |
offset active complement cdrv_index to create index into all discrete real arrays | |
void | real_variable_mapping (const Real &r_var, size_t mapped_index, short svm_target) |
insert r_var into appropriate recipient | |
void | integer_variable_mapping (const int &i_var, size_t mapped_index, short svm_target) |
insert i_var into appropriate recipient | |
void | string_variable_mapping (const String &s_var, size_t mapped_index, short svm_target) |
insert s_var into appropriate recipient | |
void | set_mapping (const ActiveSet &mapped_set, ActiveSet &interface_set, bool &opt_interface_map, ActiveSet &sub_iterator_set, bool &sub_iterator_map) |
define the evaluation requirements for the optionalInterface (interface_set) and the subIterator (sub_iterator_set) from the total model evaluation requirements (mapped_set) | |
void | response_mapping (const Response &interface_response, const Response &sub_iterator_response, Response &mapped_response) |
combine the response from the optional interface evaluation with the response from the sub-iteration using the primaryCoeffs/secondaryCoeffs mappings to create the total response for the model | |
void | interface_response_overlay (const Response &opt_interface_response, Response &mapped_response) |
assign the response from the optional interface evaluation within the total response for the model | |
void | iterator_response_overlay (const Response &sub_iterator_response, Response &mapped_response) |
overlay the sub-iteration response within the total response for the model using the primaryCoeffs/secondaryCoeffs mappings | |
Response & | find_nested_response (int nested_cntr) |
locate existing or allocate new entry in nestedResponseMap | |
void | check_response_map (const ShortArray &mapped_asv) |
check function counts for the mapped_asv | |
void | update_inactive_view (short new_view, short &view) |
update inactive variables view for subIterator based on new_view | |
void | update_inactive_view (unsigned short type, short &view) |
update inactive variables view for subIterator based on type | |
void | update_sub_model (const Variables &vars, const Constraints &cons) |
update subModel with current variable values/bounds/labels | |
Private Attributes | |
int | nestedModelEvalCntr |
number of calls to derived_compute_response()/ derived_asynch_compute_response() | |
bool | firstUpdate |
boolean to trigger one-time updates on first call to update_sub_model() | |
IntResponseMap | nestedResponseMap |
used to return a map of nested responses (including subIterator and optionalInterface contributions) for aggregation and rekeying at the base class level | |
size_t | outerMIPLIndex |
the miPLIndex for the outer parallelism context, prior to any subIterator partitioning | |
Iterator | subIterator |
the sub-iterator that is executed on every evaluation of this model | |
String | subMethodPointer |
the sub-method pointer from the nested model specification | |
Model | subModel |
the sub-model used in sub-iterator evaluations | |
PRPQueue | subIteratorPRPQueue |
job queue for asynchronous execution of subIterator jobs | |
IteratorScheduler | subIteratorSched |
scheduling object for concurrent iterator parallelism | |
int | subIteratorJobCntr |
subIterator job counter since last synchronize() | |
IntIntMap | subIteratorIdMap |
mapping from subIterator evaluation counter to nested model counter (different when subIterator evaluations do not occur on every nested model evaluation due to variable ASV content) | |
size_t | numSubIterFns |
number of sub-iterator response functions prior to mapping | |
size_t | numSubIterMappedIneqCon |
number of top-level inequality constraints mapped from the sub-iteration results | |
size_t | numSubIterMappedEqCon |
number of top-level equality constraints mapped from the sub-iteration results | |
Interface | optionalInterface |
the optional interface contributes nonnested response data to the total model response | |
String | optInterfacePointer |
the optional interface pointer from the nested model specification | |
Response | optInterfaceResponse |
the response object resulting from optional interface evaluations | |
IntIntMap | optInterfaceIdMap |
mapping from optionalInterface evaluation counter to nested model counter (different when optionalInterface evaluations do not occur on every nested model evaluation due to variable ASV content) | |
size_t | numOptInterfPrimary |
number of primary response functions (objective/least squares/generic functions) resulting from optional interface evaluations | |
size_t | numOptInterfIneqCon |
number of inequality constraints resulting from optional interface evaluations | |
size_t | numOptInterfEqCon |
number of equality constraints resulting from the optional interface evaluations | |
SizetArray | active1ACVarMapIndices |
"primary" variable mappings for inserting active continuous currentVariables within all continuous subModel variables. If there are no secondary mappings defined, then the insertions replace the subModel variable values. | |
SizetArray | active1ADIVarMapIndices |
"primary" variable mappings for inserting active discrete int currentVariables within all discrete int subModel variables. No secondary mappings are defined for discrete int variables, so the active variables replace the subModel variable values. | |
SizetArray | active1ADSVarMapIndices |
"primary" variable mappings for inserting active discrete string currentVariables within all discrete string subModel variables. No secondary mappings are defined for discrete string variables, so the active variables replace the subModel variable values. | |
SizetArray | active1ADRVarMapIndices |
"primary" variable mappings for inserting active discrete real currentVariables within all discrete real subModel variables. No secondary mappings are defined for discrete real variables, so the active variables replace the subModel variable values. | |
ShortArray | active2ACVarMapTargets |
"secondary" variable mappings for inserting active continuous currentVariables into sub-parameters (e.g., distribution parameters for uncertain variables or bounds for continuous design/state variables) within all continuous subModel variables. | |
ShortArray | active2ADIVarMapTargets |
"secondary" variable mappings for inserting active discrete int currentVariables into sub-parameters (e.g., bounds for discrete design/state variables) within all discrete int subModel variables. | |
ShortArray | active2ADSVarMapTargets |
"secondary" variable mappings for inserting active discrete string currentVariables into sub-parameters (e.g., bounds for discrete design/state variables) within all discrete string subModel variables. | |
ShortArray | active2ADRVarMapTargets |
"secondary" variable mappings for inserting active discrete real currentVariables into sub-parameters (e.g., bounds for discrete design/state variables) within all discrete real subModel variables. | |
SizetArray | complement1ACVarMapIndices |
"primary" variable mappings for inserting the complement of the active continuous currentVariables within all continuous subModel variables | |
SizetArray | complement1ADIVarMapIndices |
"primary" variable mappings for inserting the complement of the active discrete int currentVariables within all discrete int subModel variables | |
SizetArray | complement1ADSVarMapIndices |
"primary" variable mappings for inserting the complement of the active discrete string currentVariables within all discrete string subModel variables | |
SizetArray | complement1ADRVarMapIndices |
"primary" variable mappings for inserting the complement of the active discrete real currentVariables within all discrete real subModel variables | |
BitArray | extraCVarsData |
flags for updating subModel continuous bounds and labels, one for each active continuous variable in currentVariables | |
BitArray | extraDIVarsData |
flags for updating subModel discrete int bounds and labels, one for each active discrete int variable in currentVariables | |
BitArray | extraDSVarsData |
flags for updating subModel discrete string labels, one for each active discrete string variable in currentVariables | |
BitArray | extraDRVarsData |
flags for updating subModel discrete real bounds and labels, one for each active discrete real variable in currentVariables | |
RealMatrix | primaryRespCoeffs |
"primary" response_mapping matrix applied to the sub-iterator response functions. For OUU, the matrix is applied to UQ statistics to create contributions to the top-level objective functions/least squares/ generic response terms. | |
RealMatrix | secondaryRespCoeffs |
"secondary" response_mapping matrix applied to the sub-iterator response functions. For OUU, the matrix is applied to UQ statistics to create contributions to the top-level inequality and equality constraints. | |
String | evalTagPrefix |
cached evalTag Prefix from parents to use at compute_response time | |
Friends | |
class | IteratorScheduler |
protect scheduler callback functions from general access |
Derived model class which performs a complete sub-iterator execution within every evaluation of the model.
The NestedModel class nests a sub-iterator execution within every model evaluation. This capability is most commonly used for optimization under uncertainty, in which a nondeterministic iterator is executed on every optimization function evaluation. The NestedModel also contains an optional interface, for portions of the model evaluation which are independent from the sub-iterator, and a set of mappings for combining sub-iterator and optional interface data into a top level response for the model.
void derived_compute_response | ( | const ActiveSet & | set | ) | [protected, virtual] |
portion of compute_response() specific to NestedModel
Update subModel's inactive variables with active variables from currentVariables, compute the optional interface and sub-iterator responses, and map these to the total model response.
Reimplemented from Model.
References NestedModel::active2ACVarMapTargets, Response::active_set(), ParallelLibrary::bcast(), ParallelLibrary::bcast_hs(), NestedModel::component_parallel_mode(), Model::currentResponse, Model::currentVariables, Interface::eval_tag_prefix(), Iterator::eval_tag_prefix(), NestedModel::evalTagPrefix, Model::hierarchicalTagging, NestedModel::interface_response_overlay(), NestedModel::iterator_response_overlay(), IteratorScheduler::iteratorCommSize, IteratorScheduler::iteratorScheduling, Interface::map(), IteratorScheduler::messagePass, IteratorScheduler::miPLIndex, Model::modelPCIter, NestedModel::nestedModelEvalCntr, NestedModel::optInterfaceResponse, NestedModel::optionalInterface, Model::outputLevel, ParallelLibrary::parallel_configuration_iterator(), Model::parallelLib, IteratorScheduler::peerAssignJobs, Response::reset(), Iterator::response_results(), Iterator::response_results_active_set(), Iterator::run(), IteratorScheduler::run_iterator(), NestedModel::set_mapping(), IteratorScheduler::stop_iterator_servers(), NestedModel::subIterator, NestedModel::subIteratorSched, NestedModel::update_sub_model(), and Model::userDefinedConstraints.
void derived_asynch_compute_response | ( | const ActiveSet & | set | ) | [protected, virtual] |
portion of asynch_compute_response() specific to NestedModel
Asynchronous execution of subIterator on subModel and, optionally, optionalInterface.
Reimplemented from Model.
References Response::active_set(), Model::currentResponse, Model::currentVariables, Interface::evaluation_id(), Interface::map(), Iterator::method_id(), NestedModel::nestedModelEvalCntr, NestedModel::optInterfaceIdMap, NestedModel::optInterfaceResponse, NestedModel::optionalInterface, Iterator::response_results(), Iterator::response_results_active_set(), NestedModel::set_mapping(), NestedModel::subIterator, NestedModel::subIteratorIdMap, NestedModel::subIteratorJobCntr, and NestedModel::subIteratorPRPQueue.
const IntResponseMap & derived_synchronize | ( | ) | [protected, virtual] |
portion of synchronize() specific to NestedModel
Recovery of asynchronous subIterator executions and, optionally, asynchronous optionalInterface mappings.
Reimplemented from Model.
References NestedModel::component_parallel_mode(), NestedModel::find_nested_response(), NestedModel::interface_response_overlay(), NestedModel::iterator_response_overlay(), Model::modelPCIter, NestedModel::nestedResponseMap, IteratorScheduler::numIteratorJobs, NestedModel::optInterfaceIdMap, NestedModel::optInterfacePointer, NestedModel::optionalInterface, ParallelLibrary::parallel_configuration_iterator(), Model::parallelLib, IteratorScheduler::schedule_iterators(), NestedModel::subIterator, NestedModel::subIteratorIdMap, NestedModel::subIteratorJobCntr, NestedModel::subIteratorPRPQueue, NestedModel::subIteratorSched, and Interface::synch().
short local_eval_synchronization | ( | ) | [inline, protected, virtual] |
return optionalInterface synchronization setting
Used in setting Model::asynchEvalFlag. subModel synchronization is used for setting asynchEvalFlag within subModel.
Reimplemented from Model.
References Interface::asynch_local_evaluation_concurrency(), Interface::interface_synchronization(), NestedModel::optInterfacePointer, and NestedModel::optionalInterface.
int local_eval_concurrency | ( | ) | [inline, protected, virtual] |
return optionalInterface asynchronous evaluation concurrency
Used in setting Model::evaluationCapacity. subModel concurrency is used for setting evaluationCapacity within subModel.
Reimplemented from Model.
References Interface::asynch_local_evaluation_concurrency(), NestedModel::optInterfacePointer, and NestedModel::optionalInterface.
bool derived_master_overload | ( | ) | const [inline, protected, virtual] |
flag which prevents overloading the master with a multiprocessor evaluation (forwarded to optionalInterface)
Derived master overload for subModel is handled separately in subModel.compute_response() within subIterator.run().
Reimplemented from Model.
References Iterator::is_null(), Interface::iterator_eval_dedicated_master(), IteratorScheduler::iteratorScheduling, Interface::multi_proc_eval(), NestedModel::optInterfacePointer, NestedModel::optionalInterface, IteratorScheduler::procsPerIterator, NestedModel::subIterator, and NestedModel::subIteratorSched.
void derived_init_communicators | ( | ParLevLIter | pl_iter, |
int | max_eval_concurrency, | ||
bool | recurse_flag = true |
||
) | [protected, virtual] |
set up optionalInterface and subModel for parallel operations
Asynchronous flags need to be initialized for the subModel. In addition, max_eval_concurrency is the outer level iterator concurrency, not the subIterator concurrency that subModel will see, and recomputing the message_lengths on the subModel is probably not a bad idea either. Therefore, recompute everything on subModel using init_communicators().
Reimplemented from Model.
References Response::active_set(), IteratorScheduler::configure(), Model::currentVariables, ProblemDescDB::get_db_method_node(), ProblemDescDB::get_db_model_node(), Interface::init_communicators(), IteratorScheduler::init_iterator(), Iterator::is_null(), IteratorScheduler::iterator_message_lengths(), IteratorScheduler::iteratorServerId, Model::messageLengths, IteratorScheduler::messagePass, Model::modelPCIter, IteratorScheduler::numIteratorServers, NestedModel::optInterfacePointer, NestedModel::optionalInterface, ParallelLibrary::parallel_configuration_iterator(), Model::parallelLib, IteratorScheduler::partition(), Model::probDescDB, MPIPackBuffer::reset(), Iterator::response_results(), ProblemDescDB::set_db_list_nodes(), ProblemDescDB::set_db_method_node(), ProblemDescDB::set_db_model_nodes(), MPIPackBuffer::size(), NestedModel::subIterator, NestedModel::subIteratorSched, NestedModel::subMethodPointer, NestedModel::subModel, IteratorScheduler::update(), and NestedModel::update_sub_iterator().
int evaluation_id | ( | ) | const [inline, protected, virtual] |
Return the current evaluation id for the NestedModel.
return the top level nested evaluation count. To get the lower level eval count, the subModel must be explicitly queried. This is consistent with the eval counter definitions in surrogate models.
Reimplemented from Model.
References NestedModel::nestedModelEvalCntr.
size_t cv_index_map | ( | size_t | cv_index, |
const Variables & | vars | ||
) | [private] |
offset cv_index to create index into aggregated primary/secondary arrays
maps index within active continuous variables to index within aggregated active continuous/discrete-int/discrete-string/discrete-real variables.
References SharedVariablesData::aleatory_uncertain_counts(), SharedVariablesData::design_counts(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t div_index_map | ( | size_t | div_index, |
const Variables & | vars | ||
) | [private] |
offset div_index to create index into aggregated primary/secondary arrays
maps index within active discrete int variables to index within aggregated active continuous/discrete-int/discrete-string/discrete-real variables.
References SharedVariablesData::aleatory_uncertain_counts(), Variables::cv(), SharedVariablesData::design_counts(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), SharedVariablesData::state_counts(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t dsv_index_map | ( | size_t | dsv_index, |
const Variables & | vars | ||
) | [private] |
offset dsv_index to create index into aggregated primary/secondary arrays
maps index within active discrete string variables to index within aggregated active continuous/discrete-int/discrete-string/discrete-string variables.
References SharedVariablesData::aleatory_uncertain_counts(), Variables::cv(), SharedVariablesData::design_counts(), Variables::div(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), SharedVariablesData::state_counts(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t drv_index_map | ( | size_t | drv_index, |
const Variables & | vars | ||
) | [private] |
offset drv_index to create index into aggregated primary/secondary arrays
maps index within active discrete real variables to index within aggregated active continuous/discrete-int/discrete-string/discrete-real variables.
References SharedVariablesData::aleatory_uncertain_counts(), Variables::cv(), SharedVariablesData::design_counts(), Variables::div(), Variables::dsv(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), SharedVariablesData::state_counts(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t ccv_index_map | ( | size_t | ccv_index, |
const Variables & | vars | ||
) | [private] |
offset active complement ccv_index to create index into all continuous arrays
maps index within complement of active continuous variables to index within all continuous variables.
References Dakota::abort_handler(), SharedVariablesData::aleatory_uncertain_counts(), SharedVariablesData::design_counts(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t cdiv_index_map | ( | size_t | cdiv_index, |
const Variables & | vars | ||
) | [private] |
offset active complement cdiv_index to create index into all discrete int arrays
maps index within complement of active discrete int variables to index within all discrete int variables.
References Dakota::abort_handler(), SharedVariablesData::aleatory_uncertain_counts(), SharedVariablesData::design_counts(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t cdsv_index_map | ( | size_t | cdsv_index, |
const Variables & | vars | ||
) | [private] |
offset active complement cdsv_index to create index into all discrete string arrays
maps index within complement of active discrete string variables to index within all discrete string variables.
References Dakota::abort_handler(), SharedVariablesData::aleatory_uncertain_counts(), SharedVariablesData::design_counts(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
size_t cdrv_index_map | ( | size_t | cdrv_index, |
const Variables & | vars | ||
) | [private] |
offset active complement cdrv_index to create index into all discrete real arrays
maps index within complement of active discrete real variables to index within all discrete real variables.
References Dakota::abort_handler(), SharedVariablesData::aleatory_uncertain_counts(), SharedVariablesData::design_counts(), SharedVariablesData::epistemic_uncertain_counts(), Variables::shared_data(), and SharedVariablesData::view().
Referenced by NestedModel::NestedModel(), and NestedModel::update_sub_model().
void response_mapping | ( | const Response & | opt_interface_response, |
const Response & | sub_iterator_response, | ||
Response & | mapped_response | ||
) | [inline, private] |
combine the response from the optional interface evaluation with the response from the sub-iteration using the primaryCoeffs/secondaryCoeffs mappings to create the total response for the model
In the OUU case,
optionalInterface fns = {f}, {g} (deterministic primary functions, constraints) subIterator fns = {S} (UQ response statistics) Problem formulation for mapped functions: minimize {f} + [W]{S} subject to {g_l} <= {g} <= {g_u} {a_l} <= [A]{S} <= {a_u} {g} == {g_t} [A]{S} == {a_t}
where [W] is the primary_mapping_matrix user input (primaryRespCoeffs class attribute), [A] is the secondary_mapping_matrix user input (secondaryRespCoeffs class attribute), {{g_l},{a_l}} are the top level inequality constraint lower bounds, {{g_u},{a_u}} are the top level inequality constraint upper bounds, and {{g_t},{a_t}} are the top level equality constraint targets.
NOTE: optionalInterface/subIterator primary fns (obj/lsq/generic fns) overlap but optionalInterface/subIterator secondary fns (ineq/eq constraints) do not. The [W] matrix can be specified so as to allow
If the need arises, could change constraint definition to allow overlap as well: {g_l} <= {g} + [A]{S} <= {g_u} with [A] usage the same as for [W] above.
In the UOO case, things are simpler, just compute statistics of each optimization response function: [W] = [I], {f}/{g}/[A] are empty.
References Response::active_set_request_vector(), NestedModel::check_response_map(), NestedModel::interface_response_overlay(), and NestedModel::iterator_response_overlay().
the sub-model used in sub-iterator evaluations
There are no restrictions on subModel, so arbitrary nestings are possible. This is commonly used to support surrogate-based optimization under uncertainty by having NestedModels contain SurrogateModels and vice versa.
Referenced by NestedModel::component_parallel_mode(), NestedModel::derived_init_communicators(), NestedModel::derived_init_serial(), NestedModel::derived_subordinate_models(), NestedModel::estimate_partition_bounds(), NestedModel::fine_grained_evaluation_counters(), NestedModel::integer_variable_mapping(), NestedModel::NestedModel(), NestedModel::print_evaluation_summary(), NestedModel::real_variable_mapping(), NestedModel::resolve_integer_variable_mapping(), NestedModel::resolve_real_variable_mapping(), NestedModel::resolve_string_variable_mapping(), NestedModel::serve_run(), NestedModel::set_mapping(), NestedModel::sm_acv_index_map(), NestedModel::sm_adiv_index_map(), NestedModel::string_variable_mapping(), NestedModel::subordinate_model(), NestedModel::surrogate_response_mode(), NestedModel::update_inactive_view(), and NestedModel::update_sub_model().