Warehouse for storing initial conditions. More...
#include <InitialConditionWarehouse.h>
Public Member Functions | |
InitialConditionWarehouse () | |
void | initialSetup (THREAD_ID tid) |
Initial setup. More... | |
void | addObject (std::shared_ptr< InitialConditionBase > object, THREAD_ID tid, bool recurse=true) |
Add object to the warehouse. More... | |
std::set< std::string > | getDependObjects () const |
Get a list of dependent UserObjects for this exec type. More... | |
unsigned int | size (THREAD_ID tid=0) const |
Return how many kernels we store in the current warehouse. More... | |
std::set< SubdomainID > | getActiveBlocks (THREAD_ID tid=0) const |
Return a set of active SubdomainsIDs. More... | |
virtual void | updateActive (THREAD_ID tid=0) |
Updates the active objects storage. More... | |
void | sort (THREAD_ID tid=0) |
Sort the objects using the DependencyResolver. More... | |
void | subdomainsCovered (std::set< SubdomainID > &subdomains_covered, std::set< std::string > &unique_variables, THREAD_ID tid=0) const |
Populates a set of covered subdomains and the associated variable names. More... | |
THREAD_ID | numThreads () const |
Return the number of threads. More... | |
std::string | activeObjectsToFormattedString (THREAD_ID tid=0, const std::string &prefix="[DBG]") const |
Output the active content of the warehouse to a string, meant to be output to the console. More... | |
const std::vector< std::shared_ptr< InitialConditionBase > > & | getObjects (THREAD_ID tid=0) const |
Retrieve complete vector to the all/block/boundary restricted objects for a given thread. More... | |
const std::map< SubdomainID, std::vector< std::shared_ptr< InitialConditionBase > > > & | getBlockObjects (THREAD_ID tid=0) const |
const std::vector< std::shared_ptr< InitialConditionBase > > & | getBlockObjects (SubdomainID id, THREAD_ID tid=0) const |
const std::map< BoundaryID, std::vector< std::shared_ptr< InitialConditionBase > > > & | getBoundaryObjects (THREAD_ID tid=0) const |
const std::vector< std::shared_ptr< InitialConditionBase > > & | getBoundaryObjects (BoundaryID id, THREAD_ID tid=0) const |
const std::vector< std::shared_ptr< InitialConditionBase > > & | getActiveObjects (THREAD_ID tid=0) const |
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread. More... | |
const std::map< SubdomainID, std::vector< std::shared_ptr< InitialConditionBase > > > & | getActiveBlockObjects (THREAD_ID tid=0) const |
const std::vector< std::shared_ptr< InitialConditionBase > > & | getActiveBlockObjects (SubdomainID id, THREAD_ID tid=0) const |
const std::map< BoundaryID, std::vector< std::shared_ptr< InitialConditionBase > > > & | getActiveBoundaryObjects (THREAD_ID tid=0) const |
const std::vector< std::shared_ptr< InitialConditionBase > > & | getActiveBoundaryObjects (BoundaryID id, THREAD_ID tid=0) const |
bool | hasObjects (THREAD_ID tid=0) const |
Convenience functions for determining if objects exist. More... | |
bool | hasActiveObjects (THREAD_ID tid=0) const |
bool | hasActiveBlockObjects (THREAD_ID tid=0) const |
bool | hasActiveBlockObjects (SubdomainID id, THREAD_ID tid=0) const |
bool | hasActiveBoundaryObjects (THREAD_ID tid=0) const |
bool | hasActiveBoundaryObjects (BoundaryID id, THREAD_ID tid=0) const |
bool | hasBoundaryObjects (BoundaryID id, THREAD_ID tid=0) const |
bool | hasActiveObject (const std::string &name, THREAD_ID tid=0) const |
Convenience functions for checking/getting specific objects. More... | |
std::shared_ptr< InitialConditionBase > | getObject (const std::string &name, THREAD_ID tid=0) const |
std::shared_ptr< InitialConditionBase > | getActiveObject (const std::string &name, THREAD_ID tid=0) const |
void | updateVariableDependency (std::set< MooseVariableFieldBase * > &needed_moose_vars, THREAD_ID tid=0) const |
Update variable dependency vector. More... | |
void | updateBlockVariableDependency (SubdomainID id, std::set< MooseVariableFieldBase * > &needed_moose_vars, THREAD_ID tid=0) const |
void | updateBoundaryVariableDependency (std::set< MooseVariableFieldBase * > &needed_moose_vars, THREAD_ID tid=0) const |
void | updateBoundaryVariableDependency (BoundaryID id, std::set< MooseVariableFieldBase * > &needed_moose_vars, THREAD_ID tid=0) const |
void | updateBlockFEVariableCoupledVectorTagDependency (SubdomainID id, std::set< TagID > &needed_fe_var_vector_tags, THREAD_ID tid=0) const |
Update FE variable coupleable vector tag vector. More... | |
void | updateBoundaryFEVariableCoupledVectorTagDependency (BoundaryID id, std::set< TagID > &needed_fe_var_vector_tags, THREAD_ID tid=0) const |
void | updateMatPropDependency (std::unordered_set< unsigned int > &needed_mat_props, THREAD_ID tid=0) const |
Update material property dependency vector. More... | |
void | updateBlockMatPropDependency (SubdomainID id, std::unordered_set< unsigned int > &needed_mat_props, THREAD_ID tid=0) const |
void | updateBoundaryMatPropDependency (std::unordered_set< unsigned int > &needed_mat_props, THREAD_ID tid=0) const |
void | updateBoundaryMatPropDependency (BoundaryID id, std::unordered_set< unsigned int > &needed_mat_props, THREAD_ID tid=0) const |
Protected Member Functions | |
void | checkThreadID (THREAD_ID tid) const |
Calls assert on thread id. More... | |
Static Protected Member Functions | |
static void | updateActiveHelper (std::vector< std::shared_ptr< InitialConditionBase >> &active, const std::vector< std::shared_ptr< InitialConditionBase >> &all) |
Helper method for updating active vectors. More... | |
static void | sortHelper (std::vector< std::shared_ptr< InitialConditionBase >> &objects) |
Helper method for sorting vectors of objects. More... | |
static void | updateVariableDependencyHelper (std::set< MooseVariableFieldBase * > &needed_moose_vars, const std::vector< std::shared_ptr< InitialConditionBase >> &objects) |
Helper method for updating variable dependency vector. More... | |
static void | updateFEVariableCoupledVectorTagDependencyHelper (std::set< TagID > &needed_fe_var_vector_tags, const std::vector< std::shared_ptr< InitialConditionBase >> &objects) |
Helper method for updating FE variable coupleable vector tag vector. More... | |
static void | updateMatPropDependencyHelper (std::unordered_set< unsigned int > &needed_mat_props, const std::vector< std::shared_ptr< InitialConditionBase >> &objects) |
Helper method for updating material property dependency vector. More... | |
Protected Attributes | |
const THREAD_ID | _num_threads |
Convenience member storing the number of threads used for storage (1 or libMesh::n_threads) More... | |
std::vector< std::vector< std::shared_ptr< InitialConditionBase > > > | _all_objects |
Storage container for the ALL pointers (THREAD_ID on outer vector) More... | |
std::vector< std::vector< std::shared_ptr< InitialConditionBase > > > | _active_objects |
All active objects (THREAD_ID on outer vector) More... | |
std::vector< std::map< SubdomainID, std::vector< std::shared_ptr< InitialConditionBase > > > > | _all_block_objects |
std::vector< std::map< SubdomainID, std::vector< std::shared_ptr< InitialConditionBase > > > > | _active_block_objects |
Active block restricted objects (THREAD_ID on outer vector) More... | |
std::vector< std::map< BoundaryID, std::vector< std::shared_ptr< InitialConditionBase > > > > | _all_boundary_objects |
std::vector< std::map< BoundaryID, std::vector< std::shared_ptr< InitialConditionBase > > > > | _active_boundary_objects |
Active boundary restricted objects (THREAD_ID on outer vector) More... | |
std::vector< std::map< std::string, std::set< BoundaryID > > > | _boundary_ics |
std::vector< std::map< std::string, std::set< SubdomainID > > > | _block_ics |
Warehouse for storing initial conditions.
Definition at line 20 of file InitialConditionWarehouse.h.
InitialConditionWarehouse::InitialConditionWarehouse | ( | ) |
Definition at line 16 of file InitialConditionWarehouse.C.
|
inherited |
Output the active content of the warehouse to a string, meant to be output to the console.
tid | the thread id |
prefix | a string to prepend to the string |
Definition at line 761 of file MooseObjectWarehouseBase.h.
|
virtual |
Add object to the warehouse.
Reimplemented from MooseObjectWarehouseBase< InitialConditionBase >.
Definition at line 32 of file InitialConditionWarehouse.C.
Referenced by FEProblemBase::addInitialCondition().
|
inlineprotectedinherited |
Calls assert on thread id.
Definition at line 792 of file MooseObjectWarehouseBase.h.
|
inlineinherited |
Definition at line 427 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 435 of file MooseObjectWarehouseBase.h.
|
inherited |
Return a set of active SubdomainsIDs.
Definition at line 535 of file MooseObjectWarehouseBase.h.
|
inlineinherited |
Definition at line 408 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 416 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 524 of file MooseObjectWarehouseBase.h.
|
inlineinherited |
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread.
tid | The thread id to retrieve objects from |
Definition at line 400 of file MooseObjectWarehouseBase.h.
Referenced by getDependObjects().
|
inlineinherited |
Definition at line 381 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 389 of file MooseObjectWarehouseBase.h.
|
inlineinherited |
Definition at line 354 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 370 of file MooseObjectWarehouseBase.h.
std::set< std::string > InitialConditionWarehouse::getDependObjects | ( | ) | const |
Get a list of dependent UserObjects for this exec type.
Definition at line 90 of file InitialConditionWarehouse.C.
Referenced by FEProblemBase::initialSetup().
|
inherited |
Definition at line 513 of file MooseObjectWarehouseBase.h.
|
inlineinherited |
Retrieve complete vector to the all/block/boundary restricted objects for a given thread.
tid | The thread id to retrieve objects from |
Definition at line 346 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 462 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 473 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 482 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 493 of file MooseObjectWarehouseBase.h.
|
inherited |
Convenience functions for checking/getting specific objects.
Definition at line 502 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 454 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 362 of file MooseObjectWarehouseBase.h.
|
inherited |
Convenience functions for determining if objects exist.
Definition at line 446 of file MooseObjectWarehouseBase.h.
Initial setup.
Definition at line 24 of file InitialConditionWarehouse.C.
Referenced by FEProblemBase::initialSetup().
|
inlineinherited |
Return the number of threads.
Definition at line 177 of file MooseObjectWarehouseBase.h.
|
inherited |
Return how many kernels we store in the current warehouse.
Definition at line 266 of file MooseObjectWarehouseBase.h.
|
inherited |
Sort the objects using the DependencyResolver.
Definition at line 575 of file MooseObjectWarehouseBase.h.
|
staticprotectedinherited |
Helper method for sorting vectors of objects.
Definition at line 772 of file MooseObjectWarehouseBase.h.
|
inherited |
Populates a set of covered subdomains and the associated variable names.
Definition at line 748 of file MooseObjectWarehouseBase.h.
|
virtualinherited |
Updates the active objects storage.
Definition at line 546 of file MooseObjectWarehouseBase.h.
|
staticprotectedinherited |
Helper method for updating active vectors.
Definition at line 561 of file MooseObjectWarehouseBase.h.
|
inherited |
Update FE variable coupleable vector tag vector.
Definition at line 654 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 699 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 602 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 664 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 710 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 720 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 613 of file MooseObjectWarehouseBase.h.
|
inherited |
Definition at line 626 of file MooseObjectWarehouseBase.h.
|
staticprotectedinherited |
Helper method for updating FE variable coupleable vector tag vector.
Definition at line 674 of file MooseObjectWarehouseBase.h.
|
inherited |
Update material property dependency vector.
Definition at line 690 of file MooseObjectWarehouseBase.h.
|
staticprotectedinherited |
Helper method for updating material property dependency vector.
Definition at line 731 of file MooseObjectWarehouseBase.h.
|
inherited |
Update variable dependency vector.
Definition at line 593 of file MooseObjectWarehouseBase.h.
|
staticprotectedinherited |
Helper method for updating variable dependency vector.
Definition at line 637 of file MooseObjectWarehouseBase.h.
|
protectedinherited |
Active block restricted objects (THREAD_ID on outer vector)
Definition at line 201 of file MooseObjectWarehouseBase.h.
|
protectedinherited |
Active boundary restricted objects (THREAD_ID on outer vector)
Definition at line 207 of file MooseObjectWarehouseBase.h.
|
protectedinherited |
All active objects (THREAD_ID on outer vector)
Definition at line 195 of file MooseObjectWarehouseBase.h.
Referenced by initialSetup().
|
protectedinherited |
Definition at line 198 of file MooseObjectWarehouseBase.h.
|
protectedinherited |
Definition at line 204 of file MooseObjectWarehouseBase.h.
|
protectedinherited |
Storage container for the ALL pointers (THREAD_ID on outer vector)
Definition at line 192 of file MooseObjectWarehouseBase.h.
|
protected |
Definition at line 45 of file InitialConditionWarehouse.h.
Referenced by addObject().
|
protected |
Variable name to block/boundary IDs for error checking
Definition at line 44 of file InitialConditionWarehouse.h.
Referenced by addObject().
|
protectedinherited |
Convenience member storing the number of threads used for storage (1 or libMesh::n_threads)
Definition at line 189 of file MooseObjectWarehouseBase.h.