Manages consistently variables, degrees of freedom, and coefficient vectors. More...
#include <system.h>
Classes | |
class | Assembly |
class | Constraint |
class | Initialization |
class | QOI |
class | QOIDerivative |
Public Types | |
typedef System | sys_type |
typedef Number(* | ValueFunctionPointer) (const Point &p, const Parameters &Parameters, const std::string &sys_name, const std::string &unknown_name) |
typedef Gradient(* | GradientFunctionPointer) (const Point &p, const Parameters ¶meters, const std::string &sys_name, const std::string &unknown_name) |
typedef std::map< std::string, NumericVector< Number > * >::iterator | vectors_iterator |
typedef std::map< std::string, NumericVector< Number > * >::const_iterator | const_vectors_iterator |
Public Member Functions | |
System (EquationSystems &es, const std::string &name, const unsigned int number) | |
virtual | ~System () |
sys_type & | system () |
virtual void | clear () |
void | init () |
virtual void | reinit () |
virtual void | reinit_constraints () |
bool | is_initialized () |
virtual void | update () |
virtual void | assemble () |
virtual void | assemble_qoi (const QoISet &qoi_indices=QoISet()) |
virtual void | assemble_qoi_derivative (const QoISet &qoi_indices=QoISet(), bool include_liftfunc=true, bool apply_constraints=true) |
virtual void | assemble_residual_derivatives (const ParameterVector ¶meters) |
virtual void | restrict_solve_to (const SystemSubset *subset, const SubsetSolveMode subset_solve_mode=SUBSET_ZERO) |
virtual void | solve () |
virtual std::pair< unsigned int, Real > | sensitivity_solve (const ParameterVector ¶meters) |
virtual std::pair< unsigned int, Real > | weighted_sensitivity_solve (const ParameterVector ¶meters, const ParameterVector &weights) |
virtual std::pair< unsigned int, Real > | adjoint_solve (const QoISet &qoi_indices=QoISet()) |
virtual std::pair< unsigned int, Real > | weighted_sensitivity_adjoint_solve (const ParameterVector ¶meters, const ParameterVector &weights, const QoISet &qoi_indices=QoISet()) |
bool | is_adjoint_already_solved () const |
void | set_adjoint_already_solved (bool setting) |
virtual void | qoi_parameter_sensitivity (const QoISet &qoi_indices, const ParameterVector ¶meters, SensitivityData &sensitivities) |
virtual void | adjoint_qoi_parameter_sensitivity (const QoISet &qoi_indices, const ParameterVector ¶meters, SensitivityData &sensitivities) |
virtual void | forward_qoi_parameter_sensitivity (const QoISet &qoi_indices, const ParameterVector ¶meters, SensitivityData &sensitivities) |
virtual void | qoi_parameter_hessian (const QoISet &qoi_indices, const ParameterVector ¶meters, SensitivityData &hessian) |
virtual void | qoi_parameter_hessian_vector_product (const QoISet &qoi_indices, const ParameterVector ¶meters, const ParameterVector &vector, SensitivityData &product) |
virtual bool | compare (const System &other_system, const Real threshold, const bool verbose) const |
const std::string & | name () const |
virtual std::string | system_type () const |
void | project_solution (FunctionBase< Number > *f, FunctionBase< Gradient > *g=nullptr) const |
void | project_solution (FEMFunctionBase< Number > *f, FEMFunctionBase< Gradient > *g=nullptr) const |
void | project_solution (ValueFunctionPointer fptr, GradientFunctionPointer gptr, const Parameters ¶meters) const |
void | project_vector (NumericVector< Number > &new_vector, FunctionBase< Number > *f, FunctionBase< Gradient > *g=nullptr, int is_adjoint=-1) const |
void | project_vector (NumericVector< Number > &new_vector, FEMFunctionBase< Number > *f, FEMFunctionBase< Gradient > *g=nullptr, int is_adjoint=-1) const |
void | project_vector (ValueFunctionPointer fptr, GradientFunctionPointer gptr, const Parameters ¶meters, NumericVector< Number > &new_vector, int is_adjoint=-1) const |
void | boundary_project_solution (const std::set< boundary_id_type > &b, const std::vector< unsigned int > &variables, FunctionBase< Number > *f, FunctionBase< Gradient > *g=nullptr) |
void | boundary_project_solution (const std::set< boundary_id_type > &b, const std::vector< unsigned int > &variables, ValueFunctionPointer fptr, GradientFunctionPointer gptr, const Parameters ¶meters) |
void | boundary_project_vector (const std::set< boundary_id_type > &b, const std::vector< unsigned int > &variables, NumericVector< Number > &new_vector, FunctionBase< Number > *f, FunctionBase< Gradient > *g=nullptr, int is_adjoint=-1) const |
void | boundary_project_vector (const std::set< boundary_id_type > &b, const std::vector< unsigned int > &variables, ValueFunctionPointer fptr, GradientFunctionPointer gptr, const Parameters ¶meters, NumericVector< Number > &new_vector, int is_adjoint=-1) const |
unsigned int | number () const |
void | update_global_solution (std::vector< Number > &global_soln) const |
void | update_global_solution (std::vector< Number > &global_soln, const processor_id_type dest_proc) const |
const MeshBase & | get_mesh () const |
MeshBase & | get_mesh () |
const DofMap & | get_dof_map () const |
DofMap & | get_dof_map () |
const EquationSystems & | get_equation_systems () const |
EquationSystems & | get_equation_systems () |
bool | active () const |
void | activate () |
void | deactivate () |
void | set_basic_system_only () |
vectors_iterator | vectors_begin () |
const_vectors_iterator | vectors_begin () const |
vectors_iterator | vectors_end () |
const_vectors_iterator | vectors_end () const |
NumericVector< Number > & | add_vector (const std::string &vec_name, const bool projections=true, const ParallelType type=PARALLEL) |
void | remove_vector (const std::string &vec_name) |
bool & | project_solution_on_reinit (void) |
bool | have_vector (const std::string &vec_name) const |
const NumericVector< Number > * | request_vector (const std::string &vec_name) const |
NumericVector< Number > * | request_vector (const std::string &vec_name) |
const NumericVector< Number > * | request_vector (const unsigned int vec_num) const |
NumericVector< Number > * | request_vector (const unsigned int vec_num) |
const NumericVector< Number > & | get_vector (const std::string &vec_name) const |
NumericVector< Number > & | get_vector (const std::string &vec_name) |
const NumericVector< Number > & | get_vector (const unsigned int vec_num) const |
NumericVector< Number > & | get_vector (const unsigned int vec_num) |
const std::string & | vector_name (const unsigned int vec_num) const |
const std::string & | vector_name (const NumericVector< Number > &vec_reference) const |
void | set_vector_as_adjoint (const std::string &vec_name, int qoi_num) |
int | vector_is_adjoint (const std::string &vec_name) const |
void | set_vector_preservation (const std::string &vec_name, bool preserve) |
bool | vector_preservation (const std::string &vec_name) const |
NumericVector< Number > & | add_adjoint_solution (unsigned int i=0) |
NumericVector< Number > & | get_adjoint_solution (unsigned int i=0) |
const NumericVector< Number > & | get_adjoint_solution (unsigned int i=0) const |
NumericVector< Number > & | add_sensitivity_solution (unsigned int i=0) |
NumericVector< Number > & | get_sensitivity_solution (unsigned int i=0) |
const NumericVector< Number > & | get_sensitivity_solution (unsigned int i=0) const |
NumericVector< Number > & | add_weighted_sensitivity_adjoint_solution (unsigned int i=0) |
NumericVector< Number > & | get_weighted_sensitivity_adjoint_solution (unsigned int i=0) |
const NumericVector< Number > & | get_weighted_sensitivity_adjoint_solution (unsigned int i=0) const |
NumericVector< Number > & | add_weighted_sensitivity_solution () |
NumericVector< Number > & | get_weighted_sensitivity_solution () |
const NumericVector< Number > & | get_weighted_sensitivity_solution () const |
NumericVector< Number > & | add_adjoint_rhs (unsigned int i=0) |
NumericVector< Number > & | get_adjoint_rhs (unsigned int i=0) |
const NumericVector< Number > & | get_adjoint_rhs (unsigned int i=0) const |
NumericVector< Number > & | add_sensitivity_rhs (unsigned int i=0) |
NumericVector< Number > & | get_sensitivity_rhs (unsigned int i=0) |
const NumericVector< Number > & | get_sensitivity_rhs (unsigned int i=0) const |
unsigned int | n_vectors () const |
virtual unsigned int | n_matrices () const |
unsigned int | n_vars () const |
unsigned int | n_variable_groups () const |
unsigned int | n_components () const |
dof_id_type | n_dofs () const |
dof_id_type | n_active_dofs () const |
dof_id_type | n_constrained_dofs () const |
dof_id_type | n_local_constrained_dofs () const |
dof_id_type | n_local_dofs () const |
unsigned int | add_variable (const std::string &var, const FEType &type, const std::set< subdomain_id_type > *const active_subdomains=nullptr) |
unsigned int | add_variable (const std::string &var, const Order order=FIRST, const FEFamily=LAGRANGE, const std::set< subdomain_id_type > *const active_subdomains=nullptr) |
unsigned int | add_variables (const std::vector< std::string > &vars, const FEType &type, const std::set< subdomain_id_type > *const active_subdomains=nullptr) |
unsigned int | add_variables (const std::vector< std::string > &vars, const Order order=FIRST, const FEFamily=LAGRANGE, const std::set< subdomain_id_type > *const active_subdomains=nullptr) |
const Variable & | variable (unsigned int var) const |
const VariableGroup & | variable_group (unsigned int vg) const |
bool | has_variable (const std::string &var) const |
const std::string & | variable_name (const unsigned int i) const |
unsigned short int | variable_number (const std::string &var) const |
void | get_all_variable_numbers (std::vector< unsigned int > &all_variable_numbers) const |
unsigned int | variable_scalar_number (const std::string &var, unsigned int component) const |
unsigned int | variable_scalar_number (unsigned int var_num, unsigned int component) const |
const FEType & | variable_type (const unsigned int i) const |
const FEType & | variable_type (const std::string &var) const |
bool | identify_variable_groups () const |
void | identify_variable_groups (const bool) |
Real | calculate_norm (const NumericVector< Number > &v, unsigned int var, FEMNormType norm_type, std::set< unsigned int > *skip_dimensions=nullptr) const |
Real | calculate_norm (const NumericVector< Number > &v, const SystemNorm &norm, std::set< unsigned int > *skip_dimensions=nullptr) const |
void | read_header (Xdr &io, const std::string &version, const bool read_header=true, const bool read_additional_data=true, const bool read_legacy_format=false) |
void | read_legacy_data (Xdr &io, const bool read_additional_data=true) |
template<typename ValType > | |
void | read_serialized_data (Xdr &io, const bool read_additional_data=true) |
void | read_serialized_data (Xdr &io, const bool read_additional_data=true) |
template<typename InValType > | |
std::size_t | read_serialized_vectors (Xdr &io, const std::vector< NumericVector< Number > *> &vectors) const |
std::size_t | read_serialized_vectors (Xdr &io, const std::vector< NumericVector< Number > *> &vectors) const |
template<typename InValType > | |
void | read_parallel_data (Xdr &io, const bool read_additional_data) |
void | read_parallel_data (Xdr &io, const bool read_additional_data) |
void | write_header (Xdr &io, const std::string &version, const bool write_additional_data) const |
void | write_serialized_data (Xdr &io, const bool write_additional_data=true) const |
std::size_t | write_serialized_vectors (Xdr &io, const std::vector< const NumericVector< Number > *> &vectors) const |
void | write_parallel_data (Xdr &io, const bool write_additional_data) const |
std::string | get_info () const |
void | attach_init_function (void fptr(EquationSystems &es, const std::string &name)) |
void | attach_init_object (Initialization &init) |
void | attach_assemble_function (void fptr(EquationSystems &es, const std::string &name)) |
void | attach_assemble_object (Assembly &assemble) |
void | attach_constraint_function (void fptr(EquationSystems &es, const std::string &name)) |
void | attach_constraint_object (Constraint &constrain) |
void | attach_QOI_function (void fptr(EquationSystems &es, const std::string &name, const QoISet &qoi_indices)) |
void | attach_QOI_object (QOI &qoi) |
void | attach_QOI_derivative (void fptr(EquationSystems &es, const std::string &name, const QoISet &qoi_indices, bool include_liftfunc, bool apply_constraints)) |
void | attach_QOI_derivative_object (QOIDerivative &qoi_derivative) |
virtual void | user_initialization () |
virtual void | user_assembly () |
virtual void | user_constrain () |
virtual void | user_QOI (const QoISet &qoi_indices) |
virtual void | user_QOI_derivative (const QoISet &qoi_indices=QoISet(), bool include_liftfunc=true, bool apply_constraints=true) |
virtual void | re_update () |
virtual void | restrict_vectors () |
virtual void | prolong_vectors () |
virtual void | disable_cache () |
Number | current_solution (const dof_id_type global_dof_number) const |
unsigned int | n_qois () const |
Number | point_value (unsigned int var, const Point &p, const bool insist_on_success=true) const |
Number | point_value (unsigned int var, const Point &p, const Elem &e) const |
Number | point_value (unsigned int var, const Point &p, const Elem *e) const |
Gradient | point_gradient (unsigned int var, const Point &p, const bool insist_on_success=true) const |
Gradient | point_gradient (unsigned int var, const Point &p, const Elem &e) const |
Gradient | point_gradient (unsigned int var, const Point &p, const Elem *e) const |
Tensor | point_hessian (unsigned int var, const Point &p, const bool insist_on_success=true) const |
Tensor | point_hessian (unsigned int var, const Point &p, const Elem &e) const |
Tensor | point_hessian (unsigned int var, const Point &p, const Elem *e) const |
void | local_dof_indices (const unsigned int var, std::set< dof_id_type > &var_indices) const |
void | zero_variable (NumericVector< Number > &v, unsigned int var_num) const |
bool & | hide_output () |
void | projection_matrix (SparseMatrix< Number > &proj_mat) const |
const Parallel::Communicator & | comm () const |
processor_id_type | n_processors () const |
processor_id_type | processor_id () const |
Static Public Member Functions | |
static std::string | get_info () |
static void | print_info (std::ostream &out=libMesh::out) |
static unsigned int | n_objects () |
static void | enable_print_counter_info () |
static void | disable_print_counter_info () |
Public Attributes | |
bool | assemble_before_solve |
bool | use_fixed_solution |
int | extra_quadrature_order |
std::unique_ptr< NumericVector< Number > > | solution |
std::unique_ptr< NumericVector< Number > > | current_local_solution |
Real | time |
std::vector< Number > | qoi |
Protected Types | |
typedef std::map< std::string, std::pair< unsigned int, unsigned int > > | Counts |
Protected Member Functions | |
virtual void | init_data () |
void | project_vector (NumericVector< Number > &, int is_adjoint=-1) const |
void | project_vector (const NumericVector< Number > &, NumericVector< Number > &, int is_adjoint=-1) const |
void | increment_constructor_count (const std::string &name) |
void | increment_destructor_count (const std::string &name) |
Protected Attributes | |
const Parallel::Communicator & | _communicator |
Static Protected Attributes | |
static Counts | _counts |
static Threads::atomic< unsigned int > | _n_objects |
static Threads::spin_mutex | _mutex |
static bool | _enable_print_counter = true |
Private Member Functions | |
System (const System &) | |
System & | operator= (const System &) |
Real | discrete_var_norm (const NumericVector< Number > &v, unsigned int var, FEMNormType norm_type) const |
template<typename iterator_type , typename InValType > | |
std::size_t | read_serialized_blocked_dof_objects (const dof_id_type n_objects, const iterator_type begin, const iterator_type end, const InValType dummy, Xdr &io, const std::vector< NumericVector< Number > *> &vecs, const unsigned int var_to_read=libMesh::invalid_uint) const |
unsigned int | read_SCALAR_dofs (const unsigned int var, Xdr &io, NumericVector< Number > *vec) const |
template<typename InValType > | |
numeric_index_type | read_serialized_vector (Xdr &io, NumericVector< Number > *vec) |
numeric_index_type | read_serialized_vector (Xdr &io, NumericVector< Number > &vec) |
template<typename iterator_type > | |
std::size_t | write_serialized_blocked_dof_objects (const std::vector< const NumericVector< Number > *> &vecs, const dof_id_type n_objects, const iterator_type begin, const iterator_type end, Xdr &io, const unsigned int var_to_write=libMesh::invalid_uint) const |
unsigned int | write_SCALAR_dofs (const NumericVector< Number > &vec, const unsigned int var, Xdr &io) const |
dof_id_type | write_serialized_vector (Xdr &io, const NumericVector< Number > &vec) const |
Manages consistently variables, degrees of freedom, and coefficient vectors.
This is the base class for classes which contain information related to any physical process that might be simulated. Such information may range from the actual solution values to algorithmic flags that may be used to control the numerical methods employed. In general, use an EquationSystems object to handle one or more of the children of this class.
Especially, this class manages the variables of the differential equation, the coefficient vectors and the DofMap
, and ensures that these are consistent. It provides storage for the solution. Furthermore, (de-) serialization functionality is provided.
typedef std::map<std::string, NumericVector<Number> *>::const_iterator libMesh::System::const_vectors_iterator |
|
protectedinherited |
Data structure to log the information. The log is identified by the class name.
Definition at line 117 of file reference_counter.h.
typedef Gradient(* libMesh::System::GradientFunctionPointer) (const Point &p, const Parameters ¶meters, const std::string &sys_name, const std::string &unknown_name) |
typedef System libMesh::System::sys_type |
typedef Number(* libMesh::System::ValueFunctionPointer) (const Point &p, const Parameters &Parameters, const std::string &sys_name, const std::string &unknown_name) |
typedef std::map<std::string, NumericVector<Number> *>::iterator libMesh::System::vectors_iterator |
libMesh::System::System | ( | EquationSystems & | es, |
const std::string & | name, | ||
const unsigned int | number | ||
) |
Constructor. Optionally initializes required data structures.
Definition at line 61 of file system.C.
|
virtual |
Destructor.
Definition at line 120 of file system.C.
References _assemble_system_function, _assemble_system_object, _constrain_system_function, _constrain_system_object, _init_system_function, _init_system_object, _qoi_evaluate_derivative_function, _qoi_evaluate_derivative_object, _qoi_evaluate_function, _qoi_evaluate_object, clear(), and libMesh::closed().
|
private |
This isn't a copyable object, so let's make sure nobody tries.
We won't even bother implementing this; we'll just make sure that the compiler doesn't implement a default.
Definition at line 102 of file system.C.
|
inline |
|
inline |
NumericVector< Number > & libMesh::System::add_adjoint_rhs | ( | unsigned int | i = 0 | ) |
Definition at line 1021 of file system.C.
References add_vector().
Referenced by libMesh::ExplicitSystem::assemble_qoi_derivative(), and libMesh::FEMSystem::assemble_qoi_derivative().
NumericVector< Number > & libMesh::System::add_adjoint_solution | ( | unsigned int | i = 0 | ) |
Definition at line 957 of file system.C.
References add_vector(), and set_vector_as_adjoint().
Referenced by libMesh::ImplicitSystem::adjoint_solve().
NumericVector< Number > & libMesh::System::add_sensitivity_rhs | ( | unsigned int | i = 0 | ) |
Definition at line 1051 of file system.C.
References add_vector().
Referenced by libMesh::ImplicitSystem::assemble_residual_derivatives().
NumericVector< Number > & libMesh::System::add_sensitivity_solution | ( | unsigned int | i = 0 | ) |
Definition at line 906 of file system.C.
References add_vector().
Referenced by libMesh::ImplicitSystem::sensitivity_solve().
unsigned int libMesh::System::add_variable | ( | const std::string & | var, |
const FEType & | type, | ||
const std::set< subdomain_id_type > *const | active_subdomains = nullptr |
||
) |
Adds the variable var
to the list of variables for this system.
Definition at line 1081 of file system.C.
References _variable_groups, _variable_numbers, _variables, add_variables(), libMesh::VariableGroup::append(), identify_variable_groups(), is_initialized(), n_variable_groups(), n_vars(), number(), variable_name(), and variable_type().
Referenced by libMesh::DifferentiableSystem::add_second_order_dot_vars(), add_variable(), libMesh::ErrorVector::plot_error(), and read_header().
unsigned int libMesh::System::add_variable | ( | const std::string & | var, |
const Order | order = FIRST , |
||
const FEFamily | family = LAGRANGE , |
||
const std::set< subdomain_id_type > *const | active_subdomains = nullptr |
||
) |
Adds the variable var
to the list of variables for this system. Same as before, but assumes LAGRANGE
as default value for FEType.family
.
Definition at line 1159 of file system.C.
References add_variable().
unsigned int libMesh::System::add_variables | ( | const std::vector< std::string > & | vars, |
const FEType & | type, | ||
const std::set< subdomain_id_type > *const | active_subdomains = nullptr |
||
) |
Adds the variable var
to the list of variables for this system.
Definition at line 1171 of file system.C.
References _variable_groups, _variable_numbers, _variables, is_initialized(), n_components(), n_vars(), number(), variable_name(), and variable_type().
Referenced by add_variable(), and add_variables().
unsigned int libMesh::System::add_variables | ( | const std::vector< std::string > & | vars, |
const Order | order = FIRST , |
||
const FEFamily | family = LAGRANGE , |
||
const std::set< subdomain_id_type > *const | active_subdomains = nullptr |
||
) |
Adds the variable var
to the list of variables for this system. Same as before, but assumes LAGRANGE
as default value for FEType.family
.
Definition at line 1224 of file system.C.
References add_variables().
NumericVector< Number > & libMesh::System::add_vector | ( | const std::string & | vec_name, |
const bool | projections = true , |
||
const ParallelType | type = PARALLEL |
||
) |
Adds the additional vector vec_name
to this system. All the additional vectors are similarly distributed, like the solution
, and initialized to zero.
By default vectors added by add_vector are projected to changed grids by reinit(). To zero them instead (more efficient), pass "false" as the second argument
Definition at line 661 of file system.C.
References _dof_map, _is_initialized, _vector_is_adjoint, _vector_projections, _vector_types, _vectors, libMesh::NumericVector< T >::build(), libMesh::ParallelObject::comm(), libMesh::GHOSTED, have_vector(), libMesh::NumericVector< T >::init(), n_dofs(), and n_local_dofs().
Referenced by add_adjoint_rhs(), add_adjoint_solution(), add_sensitivity_rhs(), add_sensitivity_solution(), libMesh::ExplicitSystem::add_system_rhs(), add_weighted_sensitivity_adjoint_solution(), add_weighted_sensitivity_solution(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::SecondOrderUnsteadySolver::init(), libMesh::UnsteadySolver::init(), libMesh::OptimizationSystem::init_data(), libMesh::ContinuationSystem::init_data(), libMesh::NewmarkSystem::NewmarkSystem(), read_header(), libMesh::FrequencySystem::set_frequencies(), libMesh::FrequencySystem::set_frequencies_by_range(), and libMesh::FrequencySystem::set_frequencies_by_steps().
NumericVector< Number > & libMesh::System::add_weighted_sensitivity_adjoint_solution | ( | unsigned int | i = 0 | ) |
Definition at line 989 of file system.C.
References add_vector(), and set_vector_as_adjoint().
Referenced by libMesh::ImplicitSystem::weighted_sensitivity_adjoint_solve().
NumericVector< Number > & libMesh::System::add_weighted_sensitivity_solution | ( | ) |
Definition at line 936 of file system.C.
References add_vector().
Referenced by libMesh::ImplicitSystem::weighted_sensitivity_solve().
|
inlinevirtual |
Solves for parameter sensitivities using the adjoint method.
This method is only implemented in some derived classes.
Reimplemented in libMesh::ImplicitSystem.
Definition at line 2316 of file system.h.
Referenced by qoi_parameter_sensitivity().
|
inlinevirtual |
Solves the adjoint system, for the specified qoi indices, or for every qoi if qoi_indices
is nullptr. Must be overridden in derived systems.
This method is only implemented in some derived classes.
Reimplemented in libMesh::ImplicitSystem, and libMesh::DifferentiableSystem.
Definition at line 2300 of file system.h.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::AdjointRefinementEstimator::estimate_error(), and libMesh::AdjointResidualErrorEstimator::estimate_error().
|
virtual |
Prepares matrix
and _dof_map
for matrix assembly. Does not actually assemble anything. For matrix assembly, use the assemble()
in derived classes. Should be overridden in derived classes.
Reimplemented in libMesh::LinearImplicitSystem, libMesh::EigenSystem, libMesh::DifferentiableSystem, libMesh::ImplicitSystem, libMesh::FrequencySystem, and libMesh::NewmarkSystem.
Definition at line 462 of file system.C.
References user_assembly().
Referenced by libMesh::ImplicitSystem::assemble(), libMesh::EigenSystem::assemble(), and libMesh::ExplicitSystem::solve().
Calls user qoi function. Can be overridden in derived classes.
Reimplemented in libMesh::FEMSystem, and libMesh::ExplicitSystem.
Definition at line 473 of file system.C.
References user_QOI().
Referenced by libMesh::ExplicitSystem::assemble_qoi().
|
virtual |
Calls user qoi derivative function. Can be overridden in derived classes.
Reimplemented in libMesh::FEMSystem, and libMesh::ExplicitSystem.
Definition at line 484 of file system.C.
References user_QOI_derivative().
Referenced by libMesh::ExplicitSystem::assemble_qoi_derivative().
|
inlinevirtual |
Calls residual parameter derivative function.
Library subclasses use finite differences by default.
This should assemble the sensitivity rhs vectors to hold -(partial R / partial p_i), making them ready to solve the forward sensitivity equation.
This method is only implemented in some derived classes.
Reimplemented in libMesh::ImplicitSystem.
void libMesh::System::attach_assemble_function | ( | void | fptrEquationSystems &es, const std::string &name | ) |
Register a user function to use in assembling the system matrix and RHS.
Definition at line 1777 of file system.C.
References _assemble_system_function, _assemble_system_object, and libMesh::out.
void libMesh::System::attach_assemble_object | ( | System::Assembly & | assemble_in | ) |
Register a user object to use in assembling the system matrix and RHS.
Definition at line 1796 of file system.C.
References _assemble_system_function, _assemble_system_object, and libMesh::out.
void libMesh::System::attach_constraint_function | ( | void | fptrEquationSystems &es, const std::string &name | ) |
Register a user function for imposing constraints.
Definition at line 1812 of file system.C.
References _constrain_system_function, _constrain_system_object, and libMesh::out.
void libMesh::System::attach_constraint_object | ( | System::Constraint & | constrain | ) |
Register a user object for imposing constraints.
Definition at line 1831 of file system.C.
References _constrain_system_function, _constrain_system_object, and libMesh::out.
void libMesh::System::attach_init_function | ( | void | fptrEquationSystems &es, const std::string &name | ) |
Register a user function to use in initializing the system.
Definition at line 1742 of file system.C.
References _init_system_function, _init_system_object, and libMesh::out.
void libMesh::System::attach_init_object | ( | System::Initialization & | init_in | ) |
Register a user class to use to initialize the system.
attach_init_function
. Definition at line 1761 of file system.C.
References _init_system_function, _init_system_object, and libMesh::out.
void libMesh::System::attach_QOI_derivative | ( | void | fptrEquationSystems &es, const std::string &name, const QoISet &qoi_indices, bool include_liftfunc, bool apply_constraints | ) |
Register a user function for evaluating derivatives of a quantity of interest with respect to test functions, whose values should be placed in System::rhs
Definition at line 1883 of file system.C.
References _qoi_evaluate_derivative_function, _qoi_evaluate_derivative_object, and libMesh::out.
void libMesh::System::attach_QOI_derivative_object | ( | QOIDerivative & | qoi_derivative | ) |
Register a user object for evaluating derivatives of a quantity of interest with respect to test functions, whose values should be placed in System::rhs
Definition at line 1902 of file system.C.
References _qoi_evaluate_derivative_function, _qoi_evaluate_derivative_object, and libMesh::out.
void libMesh::System::attach_QOI_function | ( | void | fptrEquationSystems &es, const std::string &name, const QoISet &qoi_indices | ) |
Register a user function for evaluating the quantities of interest, whose values should be placed in System::qoi
Definition at line 1847 of file system.C.
References _qoi_evaluate_function, _qoi_evaluate_object, and libMesh::out.
void libMesh::System::attach_QOI_object | ( | QOI & | qoi | ) |
Register a user object for evaluating the quantities of interest, whose values should be placed in System::qoi
Definition at line 1867 of file system.C.
References _qoi_evaluate_function, _qoi_evaluate_object, and libMesh::out.
void libMesh::System::boundary_project_solution | ( | const std::set< boundary_id_type > & | b, |
const std::vector< unsigned int > & | variables, | ||
FunctionBase< Number > * | f, | ||
FunctionBase< Gradient > * | g = nullptr |
||
) |
Projects arbitrary boundary functions onto a vector of degree of freedom values for the current system. Only degrees of freedom which affect the function's trace on a boundary in the set b
are affected. Only degrees of freedom associated with the variables listed in the vector variables
are projected. The function value f
and its gradient g
are user-provided cloneable functors. A gradient g
is only required/used for projecting onto finite element spaces with continuous derivatives. If non-default Parameters
are to be used, they can be provided in the parameters
argument.
This method projects an arbitrary boundary function onto the solution via L2 projections and nodal interpolations on each element.
Definition at line 985 of file system_projection.C.
void libMesh::System::boundary_project_solution | ( | const std::set< boundary_id_type > & | b, |
const std::vector< unsigned int > & | variables, | ||
ValueFunctionPointer | fptr, | ||
GradientFunctionPointer | gptr, | ||
const Parameters & | parameters | ||
) |
Projects arbitrary boundary functions onto a vector of degree of freedom values for the current system. Only degrees of freedom which affect the function's trace on a boundary in the set b
are affected. Only degrees of freedom associated with the variables listed in the vector variables
are projected. The function value fptr
and its gradient gptr
are represented by function pointers. A gradient gptr
is only required/used for projecting onto finite element spaces with continuous derivatives.
This method projects components of an arbitrary boundary function onto the solution via L2 projections and nodal interpolations on each element.
Definition at line 968 of file system_projection.C.
void libMesh::System::boundary_project_vector | ( | const std::set< boundary_id_type > & | b, |
const std::vector< unsigned int > & | variables, | ||
NumericVector< Number > & | new_vector, | ||
FunctionBase< Number > * | f, | ||
FunctionBase< Gradient > * | g = nullptr , |
||
int | is_adjoint = -1 |
||
) | const |
Projects arbitrary boundary functions onto a vector of degree of freedom values for the current system. Only degrees of freedom which affect the function's trace on a boundary in the set b
are affected. Only degrees of freedom associated with the variables listed in the vector variables
are projected. The function value f
and its gradient g
are user-provided cloneable functors. A gradient g
is only required/used for projecting onto finite element spaces with continuous derivatives. If non-default Parameters
are to be used, they can be provided in the parameters
argument.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
This method projects an arbitrary function via L2 projections and nodal interpolations on each element.
Definition at line 1021 of file system_projection.C.
References libMesh::NumericVector< T >::close(), and libMesh::Threads::parallel_for().
void libMesh::System::boundary_project_vector | ( | const std::set< boundary_id_type > & | b, |
const std::vector< unsigned int > & | variables, | ||
ValueFunctionPointer | fptr, | ||
GradientFunctionPointer | gptr, | ||
const Parameters & | parameters, | ||
NumericVector< Number > & | new_vector, | ||
int | is_adjoint = -1 |
||
) | const |
Projects arbitrary boundary functions onto a vector of degree of freedom values for the current system. Only degrees of freedom which affect the function's trace on a boundary in the set b
are affected. Only degrees of freedom associated with the variables listed in the vector variables
are projected. The function value fptr
and its gradient gptr
are represented by function pointers. A gradient gptr
is only required/used for projecting onto finite element spaces with continuous derivatives.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
This method projects an arbitrary boundary function via L2 projections and nodal interpolations on each element.
Definition at line 1003 of file system_projection.C.
Real libMesh::System::calculate_norm | ( | const NumericVector< Number > & | v, |
unsigned int | var, | ||
FEMNormType | norm_type, | ||
std::set< unsigned int > * | skip_dimensions = nullptr |
||
) | const |
var
in the vector v
, in the specified norm (e.g. L2, L_INF, H1) Definition at line 1378 of file system.C.
References libMesh::DISCRETE_L1, libMesh::DISCRETE_L2, libMesh::DISCRETE_L_INF, discrete_var_norm(), libMesh::L2, n_vars(), and libMesh::Real.
Referenced by libMesh::AdaptiveTimeSolver::calculate_norm(), and libMesh::UnsteadySolver::du().
Real libMesh::System::calculate_norm | ( | const NumericVector< Number > & | v, |
const SystemNorm & | norm, | ||
std::set< unsigned int > * | skip_dimensions = nullptr |
||
) | const |
v
, using component_norm
and component_scale
to choose and weight the norms of each variable. Definition at line 1400 of file system.C.
References _dof_map, _mesh, std::abs(), libMesh::TypeVector< T >::add_scaled(), libMesh::TypeTensor< T >::add_scaled(), libMesh::FEGenericBase< OutputType >::build(), libMesh::NumericVector< T >::build(), libMesh::ParallelObject::comm(), libMesh::FEType::default_quadrature_rule(), libMesh::DISCRETE_L1, libMesh::DISCRETE_L2, libMesh::DISCRETE_L_INF, discrete_var_norm(), libMesh::DofMap::dof_indices(), libMesh::MeshBase::elem_dimensions(), libMesh::FEGenericBase< OutputType >::get_d2phi(), get_dof_map(), libMesh::FEGenericBase< OutputType >::get_dphi(), libMesh::FEAbstract::get_JxW(), get_mesh(), libMesh::FEGenericBase< OutputType >::get_phi(), libMesh::H1, libMesh::H1_SEMINORM, libMesh::H2, libMesh::H2_SEMINORM, libMesh::SystemNorm::is_discrete(), libMesh::L1, libMesh::NumericVector< T >::l1_norm(), libMesh::L2, libMesh::NumericVector< T >::l2_norm(), libMesh::L_INF, libMesh::NumericVector< T >::linfty_norm(), libMesh::NumericVector< T >::localize(), std::max(), libMesh::Parallel::Communicator::max(), libMesh::QBase::n_points(), n_vars(), libMesh::TypeVector< T >::norm(), libMesh::TypeTensor< T >::norm(), libMesh::TensorTools::norm_sq(), libMesh::TypeVector< T >::norm_sq(), libMesh::TypeTensor< T >::norm_sq(), libMesh::Real, libMesh::FEAbstract::reinit(), libMesh::SERIAL, libMesh::NumericVector< T >::size(), libMesh::Parallel::Communicator::sum(), libMesh::SystemNorm::type(), libMesh::DofMap::variable_type(), libMesh::W1_INF_SEMINORM, libMesh::W2_INF_SEMINORM, libMesh::SystemNorm::weight(), and libMesh::SystemNorm::weight_sq().
|
virtual |
Clear all the data structures associated with the system.
Reimplemented in libMesh::OptimizationSystem, libMesh::NonlinearImplicitSystem, libMesh::RBConstruction, libMesh::ImplicitSystem, libMesh::LinearImplicitSystem, libMesh::EigenSystem, libMesh::TransientSystem< RBConstruction >, libMesh::DifferentiableSystem, libMesh::ContinuationSystem, libMesh::FrequencySystem, libMesh::RBConstructionBase< LinearImplicitSystem >, libMesh::RBConstructionBase< CondensedEigenSystem >, libMesh::RBSCMConstruction, libMesh::RBEIMConstruction, libMesh::ExplicitSystem, libMesh::TransientRBConstruction, and libMesh::NewmarkSystem.
Definition at line 205 of file system.C.
References _dof_map, _is_initialized, _variable_numbers, _variables, _vector_is_adjoint, _vector_projections, _vector_types, _vectors, current_local_solution, and solution.
Referenced by libMesh::ExplicitSystem::clear(), libMesh::EigenSystem::clear(), read_header(), and ~System().
|
inlineinherited |
Parallel::Communicator
object used by this mesh. Definition at line 89 of file parallel_object.h.
References libMesh::ParallelObject::_communicator.
Referenced by libMesh::__libmesh_petsc_diff_solver_jacobian(), libMesh::__libmesh_petsc_diff_solver_monitor(), libMesh::__libmesh_petsc_diff_solver_residual(), libMesh::__libmesh_tao_equality_constraints(), libMesh::__libmesh_tao_equality_constraints_jacobian(), libMesh::__libmesh_tao_gradient(), libMesh::__libmesh_tao_hessian(), libMesh::__libmesh_tao_inequality_constraints(), libMesh::__libmesh_tao_inequality_constraints_jacobian(), libMesh::__libmesh_tao_objective(), libMesh::MeshRefinement::_coarsen_elements(), libMesh::ExactSolution::_compute_error(), libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::BoundaryInfo::_find_id_maps(), libMesh::SlepcEigenSolver< T >::_petsc_shell_matrix_get_diagonal(), libMesh::PetscLinearSolver< T >::_petsc_shell_matrix_get_diagonal(), libMesh::SlepcEigenSolver< T >::_petsc_shell_matrix_mult(), libMesh::PetscLinearSolver< T >::_petsc_shell_matrix_mult(), libMesh::PetscLinearSolver< T >::_petsc_shell_matrix_mult_add(), libMesh::EquationSystems::_read_impl(), libMesh::MeshRefinement::_refine_elements(), libMesh::MeshRefinement::_smooth_flags(), libMesh::PetscDMWrapper::add_dofs_helper(), libMesh::PetscDMWrapper::add_dofs_to_section(), libMesh::ImplicitSystem::add_matrix(), add_vector(), libMesh::UnstructuredMesh::all_second_order(), libMesh::MeshTools::Modification::all_tri(), libMesh::LaplaceMeshSmoother::allgather_graph(), libMesh::FEMSystem::assemble_qoi(), libMesh::MeshCommunication::assign_global_indices(), libMesh::DofMap::attach_matrix(), libMesh::MeshTools::Generation::build_extrusion(), libMesh::BoundaryInfo::build_node_list_from_side_list(), libMesh::EquationSystems::build_parallel_elemental_solution_vector(), libMesh::EquationSystems::build_parallel_solution_vector(), libMesh::PetscDMWrapper::build_section(), libMesh::PetscDMWrapper::build_sf(), libMesh::MeshBase::cache_elem_dims(), calculate_norm(), libMesh::DofMap::check_dirichlet_bcid_consistency(), libMesh::PetscDMWrapper::check_section_n_dofs(), libMesh::Nemesis_IO_Helper::compute_num_global_elem_blocks(), libMesh::Nemesis_IO_Helper::compute_num_global_nodesets(), libMesh::Nemesis_IO_Helper::compute_num_global_sidesets(), libMesh::Problem_Interface::computeF(), libMesh::Problem_Interface::computeJacobian(), libMesh::Problem_Interface::computePreconditioner(), libMesh::ExodusII_IO::copy_elemental_solution(), libMesh::MeshTools::correct_node_proc_ids(), libMesh::MeshTools::create_bounding_box(), libMesh::MeshTools::create_nodal_bounding_box(), libMesh::MeshRefinement::create_parent_error_vector(), libMesh::MeshTools::create_processor_bounding_box(), libMesh::MeshTools::create_subdomain_bounding_box(), libMesh::MeshCommunication::delete_remote_elements(), libMesh::DofMap::distribute_dofs(), DMlibMeshFunction(), DMlibMeshJacobian(), DMlibMeshSetSystem_libMesh(), DMVariableBounds_libMesh(), libMesh::MeshRefinement::eliminate_unrefined_patches(), libMesh::EpetraVector< T >::EpetraVector(), libMesh::WeightedPatchRecoveryErrorEstimator::estimate_error(), libMesh::PatchRecoveryErrorEstimator::estimate_error(), libMesh::JumpErrorEstimator::estimate_error(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::ExactErrorEstimator::estimate_error(), libMesh::MeshRefinement::flag_elements_by_elem_fraction(), libMesh::MeshRefinement::flag_elements_by_error_fraction(), libMesh::MeshRefinement::flag_elements_by_nelem_target(), libMesh::CondensedEigenSystem::get_eigenpair(), libMesh::DofMap::get_info(), libMesh::ImplicitSystem::get_linear_solver(), libMesh::LocationMap< T >::init(), libMesh::TimeSolver::init(), libMesh::SystemSubsetBySubdomain::init(), libMesh::PetscDMWrapper::init_and_attach_petscdm(), libMesh::EigenSystem::init_data(), libMesh::EigenSystem::init_matrices(), libMesh::OptimizationSystem::initialize_equality_constraints_storage(), libMesh::OptimizationSystem::initialize_inequality_constraints_storage(), libMesh::MeshTools::libmesh_assert_consistent_distributed(), libMesh::MeshTools::libmesh_assert_consistent_distributed_nodes(), libMesh::MeshTools::libmesh_assert_contiguous_dof_ids(), libMesh::MeshTools::libmesh_assert_parallel_consistent_new_node_procids(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Elem >(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Node >(), libMesh::MeshTools::libmesh_assert_topology_consistent_procids< Node >(), libMesh::MeshTools::libmesh_assert_valid_boundary_ids(), libMesh::MeshTools::libmesh_assert_valid_dof_ids(), libMesh::MeshTools::libmesh_assert_valid_neighbors(), libMesh::DistributedMesh::libmesh_assert_valid_parallel_flags(), libMesh::DistributedMesh::libmesh_assert_valid_parallel_object_ids(), libMesh::DistributedMesh::libmesh_assert_valid_parallel_p_levels(), libMesh::MeshTools::libmesh_assert_valid_refinement_flags(), libMesh::MeshTools::libmesh_assert_valid_unique_ids(), libMesh::libmesh_petsc_snes_fd_residual(), libMesh::libmesh_petsc_snes_jacobian(), libMesh::libmesh_petsc_snes_mffd_residual(), libMesh::libmesh_petsc_snes_postcheck(), libMesh::libmesh_petsc_snes_residual(), libMesh::libmesh_petsc_snes_residual_helper(), libMesh::MeshRefinement::limit_level_mismatch_at_edge(), libMesh::MeshRefinement::limit_level_mismatch_at_node(), libMesh::MeshRefinement::limit_overrefined_boundary(), libMesh::MeshRefinement::limit_underrefined_boundary(), libMesh::MeshRefinement::make_coarsening_compatible(), libMesh::MeshCommunication::make_elems_parallel_consistent(), libMesh::MeshRefinement::make_flags_parallel_consistent(), libMesh::MeshCommunication::make_new_node_proc_ids_parallel_consistent(), libMesh::MeshCommunication::make_new_nodes_parallel_consistent(), libMesh::MeshCommunication::make_node_ids_parallel_consistent(), libMesh::MeshCommunication::make_node_proc_ids_parallel_consistent(), libMesh::MeshCommunication::make_node_unique_ids_parallel_consistent(), libMesh::MeshCommunication::make_nodes_parallel_consistent(), libMesh::MeshCommunication::make_p_levels_parallel_consistent(), libMesh::MeshRefinement::make_refinement_compatible(), libMesh::FEMSystem::mesh_position_set(), libMesh::DistributedMesh::n_active_elem(), libMesh::MeshTools::n_active_levels(), libMesh::BoundaryInfo::n_boundary_conds(), libMesh::BoundaryInfo::n_edge_conds(), libMesh::CondensedEigenSystem::n_global_non_condensed_dofs(), libMesh::MeshTools::n_levels(), libMesh::BoundaryInfo::n_nodeset_conds(), libMesh::MeshTools::n_p_levels(), libMesh::BoundaryInfo::n_shellface_conds(), libMesh::DistributedMesh::parallel_max_elem_id(), libMesh::DistributedMesh::parallel_max_node_id(), libMesh::ReplicatedMesh::parallel_max_unique_id(), libMesh::DistributedMesh::parallel_max_unique_id(), libMesh::DistributedMesh::parallel_n_elem(), libMesh::DistributedMesh::parallel_n_nodes(), libMesh::SparsityPattern::Build::parallel_sync(), libMesh::MeshTools::paranoid_n_levels(), libMesh::petsc_auto_fieldsplit(), point_gradient(), point_hessian(), point_value(), libMesh::MeshBase::prepare_for_use(), libMesh::Nemesis_IO::read(), libMesh::XdrIO::read(), libMesh::CheckpointIO::read_header(), libMesh::XdrIO::read_header(), read_header(), read_legacy_data(), read_SCALAR_dofs(), libMesh::XdrIO::read_serialized_bc_names(), libMesh::XdrIO::read_serialized_bcs_helper(), read_serialized_blocked_dof_objects(), libMesh::XdrIO::read_serialized_connectivity(), libMesh::XdrIO::read_serialized_nodes(), libMesh::XdrIO::read_serialized_nodesets(), libMesh::XdrIO::read_serialized_subdomain_names(), read_serialized_vector(), libMesh::MeshBase::recalculate_n_partitions(), libMesh::MeshRefinement::refine_and_coarsen_elements(), libMesh::DistributedMesh::renumber_dof_objects(), libMesh::CheckpointIO::select_split_config(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::PetscDMWrapper::set_point_range_in_section(), libMesh::PetscDiffSolver::setup_petsc_data(), libMesh::LaplaceMeshSmoother::smooth(), libMesh::split_mesh(), libMesh::MeshBase::subdomain_ids(), libMesh::BoundaryInfo::sync(), libMesh::MeshRefinement::test_level_one(), libMesh::MeshRefinement::test_unflagged(), libMesh::MeshTools::total_weight(), libMesh::MeshRefinement::uniformly_coarsen(), libMesh::NameBasedIO::write(), libMesh::XdrIO::write(), write_SCALAR_dofs(), libMesh::XdrIO::write_serialized_bcs_helper(), write_serialized_blocked_dof_objects(), libMesh::XdrIO::write_serialized_connectivity(), libMesh::XdrIO::write_serialized_nodes(), and libMesh::XdrIO::write_serialized_nodesets().
|
virtual |
true
when the other system contains identical data, up to the given threshold. Outputs some diagnostic info when verbose
is set. Definition at line 514 of file system.C.
References _is_initialized, _sys_name, _vectors, get_vector(), n_vectors(), name(), libMesh::out, and solution.
Referenced by libMesh::EquationSystems::compare().
Number libMesh::System::current_solution | ( | const dof_id_type | global_dof_number | ) | const |
Definition at line 194 of file system.C.
References _dof_map, and current_local_solution.
Referenced by libMesh::ExactSolution::_compute_error(), libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::HPCoarsenTest::add_projection(), libMesh::ExactErrorEstimator::estimate_error(), libMesh::WeightedPatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::PatchRecoveryErrorEstimator::EstimateError::operator()(), point_gradient(), point_hessian(), point_value(), libMesh::HPCoarsenTest::select_refinement(), libMesh::EnsightIO::write_scalar_ascii(), and libMesh::EnsightIO::write_vector_ascii().
|
inline |
|
inlinevirtual |
Avoids use of any cached data that might affect any solve result. Should be overridden in derived systems.
Reimplemented in libMesh::ImplicitSystem.
Definition at line 2275 of file system.h.
References assemble_before_solve.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error().
|
staticinherited |
Definition at line 106 of file reference_counter.C.
References libMesh::ReferenceCounter::_enable_print_counter.
Referenced by libMesh::LibMeshInit::LibMeshInit().
|
private |
Finds the discrete norm for the entries in the vector corresponding to Dofs associated with var.
Definition at line 1359 of file system.C.
References libMesh::DISCRETE_L1, libMesh::DISCRETE_L2, libMesh::DISCRETE_L_INF, local_dof_indices(), libMesh::NumericVector< T >::subset_l1_norm(), libMesh::NumericVector< T >::subset_l2_norm(), and libMesh::NumericVector< T >::subset_linfty_norm().
Referenced by calculate_norm().
|
staticinherited |
Methods to enable/disable the reference counter output from print_info()
Definition at line 100 of file reference_counter.C.
References libMesh::ReferenceCounter::_enable_print_counter.
|
inlinevirtual |
Solves for parameter sensitivities using the forward method.
This method is only implemented in some derived classes.
Reimplemented in libMesh::ImplicitSystem.
Definition at line 2325 of file system.h.
Referenced by qoi_parameter_sensitivity().
NumericVector< Number > & libMesh::System::get_adjoint_rhs | ( | unsigned int | i = 0 | ) |
Definition at line 1031 of file system.C.
References get_vector().
Referenced by libMesh::ImplicitSystem::adjoint_solve(), libMesh::ImplicitSystem::forward_qoi_parameter_sensitivity(), libMesh::ImplicitSystem::qoi_parameter_hessian(), libMesh::ImplicitSystem::qoi_parameter_hessian_vector_product(), and libMesh::ImplicitSystem::weighted_sensitivity_adjoint_solve().
const NumericVector< Number > & libMesh::System::get_adjoint_rhs | ( | unsigned int | i = 0 | ) | const |
Definition at line 1041 of file system.C.
References get_vector().
NumericVector< Number > & libMesh::System::get_adjoint_solution | ( | unsigned int | i = 0 | ) |
Definition at line 969 of file system.C.
References get_vector().
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::ImplicitSystem::adjoint_solve(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::AdjointResidualErrorEstimator::estimate_error(), libMesh::ImplicitSystem::qoi_parameter_hessian(), libMesh::ImplicitSystem::qoi_parameter_hessian_vector_product(), and libMesh::ImplicitSystem::weighted_sensitivity_adjoint_solve().
const NumericVector< Number > & libMesh::System::get_adjoint_solution | ( | unsigned int | i = 0 | ) | const |
Definition at line 979 of file system.C.
References get_vector().
void libMesh::System::get_all_variable_numbers | ( | std::vector< unsigned int > & | all_variable_numbers | ) | const |
Fills all_variable_numbers
with all the variable numbers for the variables that have been added to this system.
Definition at line 1258 of file system.C.
References _variable_numbers, and n_vars().
|
inline |
_dof_map
. Definition at line 2049 of file system.h.
References _dof_map.
Referenced by libMesh::__libmesh_petsc_diff_solver_jacobian(), libMesh::__libmesh_petsc_diff_solver_residual(), libMesh::ExactSolution::_compute_error(), libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::DifferentiableSystem::add_dot_var_dirichlet_bcs(), libMesh::HPCoarsenTest::add_projection(), libMesh::UnsteadySolver::adjoint_advance_timestep(), libMesh::ImplicitSystem::adjoint_solve(), libMesh::NewmarkSolver::advance_timestep(), libMesh::UnsteadySolver::advance_timestep(), libMesh::EquationSystems::allgather(), libMesh::EquationSystems::build_discontinuous_solution_vector(), libMesh::EquationSystems::build_parallel_elemental_solution_vector(), libMesh::EquationSystems::build_parallel_solution_vector(), libMesh::PetscDMWrapper::build_sf(), calculate_norm(), libMesh::Problem_Interface::computeF(), libMesh::Problem_Interface::computeJacobian(), libMesh::Problem_Interface::computePreconditioner(), DMCreateDomainDecomposition_libMesh(), DMCreateFieldDecomposition_libMesh(), DMlibMeshFunction(), DMlibMeshJacobian(), DMlibMeshSetSystem_libMesh(), libMesh::DofMap::enforce_constraints_exactly(), libMesh::JumpErrorEstimator::estimate_error(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::ExactErrorEstimator::estimate_error(), get_info(), libMesh::SystemSubsetBySubdomain::init(), libMesh::SecondOrderUnsteadySolver::init_data(), libMesh::UnsteadySolver::init_data(), libMesh::EigenSystem::init_matrices(), libMesh::ImplicitSystem::init_matrices(), libMesh::CondensedEigenSystem::initialize_condensed_dofs(), libMesh::OptimizationSystem::initialize_equality_constraints_storage(), libMesh::OptimizationSystem::initialize_inequality_constraints_storage(), libMesh::libmesh_petsc_snes_jacobian(), libMesh::libmesh_petsc_snes_postcheck(), libMesh::libmesh_petsc_snes_residual_helper(), local_dof_indices(), libMesh::DofMap::max_constraint_error(), libMesh::DGFEMContext::neighbor_side_fe_reinit(), libMesh::UnsteadySolver::old_nonlinear_solution(), libMesh::SecondOrderUnsteadySolver::old_solution_accel(), libMesh::SecondOrderUnsteadySolver::old_solution_rate(), libMesh::WeightedPatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::PatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::petsc_auto_fieldsplit(), libMesh::ErrorVector::plot_error(), point_gradient(), point_hessian(), point_value(), libMesh::FEMContext::pre_fe_reinit(), re_update(), read_parallel_data(), read_SCALAR_dofs(), libMesh::SecondOrderUnsteadySolver::reinit(), libMesh::UnsteadySolver::reinit(), libMesh::EigenSystem::reinit(), libMesh::ImplicitSystem::reinit(), reinit_constraints(), libMesh::EquationSystems::reinit_solutions(), libMesh::UnsteadySolver::retrieve_timestep(), libMesh::HPCoarsenTest::select_refinement(), libMesh::ImplicitSystem::sensitivity_solve(), libMesh::PetscDMWrapper::set_point_range_in_section(), libMesh::NewtonSolver::solve(), libMesh::PetscDiffSolver::solve(), libMesh::ImplicitSystem::weighted_sensitivity_adjoint_solve(), libMesh::ImplicitSystem::weighted_sensitivity_solve(), write_parallel_data(), libMesh::EnsightIO::write_scalar_ascii(), write_SCALAR_dofs(), and libMesh::EnsightIO::write_vector_ascii().
|
inline |
|
inline |
Definition at line 712 of file system.h.
References _equation_systems.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::NewmarkSystem::clear(), libMesh::FrequencySystem::clear_all(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::AdjointResidualErrorEstimator::estimate_error(), libMesh::ExactErrorEstimator::find_squared_element_error(), libMesh::ImplicitSystem::get_linear_solve_parameters(), libMesh::FrequencySystem::init_data(), libMesh::FrequencySystem::n_frequencies(), point_value(), libMesh::FrequencySystem::set_current_frequency(), libMesh::FrequencySystem::set_frequencies(), libMesh::FrequencySystem::set_frequencies_by_range(), libMesh::FrequencySystem::set_frequencies_by_steps(), libMesh::NewmarkSystem::set_newmark_parameters(), libMesh::NonlinearImplicitSystem::set_solver_parameters(), libMesh::CondensedEigenSystem::solve(), libMesh::EigenSystem::solve(), libMesh::FrequencySystem::solve(), libMesh::LinearImplicitSystem::solve(), and libMesh::WrappedFunction< Output >::WrappedFunction().
|
inline |
Definition at line 717 of file system.h.
References _equation_systems.
|
staticinherited |
Gets a string containing the reference information.
Definition at line 47 of file reference_counter.C.
References libMesh::ReferenceCounter::_counts, and libMesh::Quality::name().
Referenced by libMesh::ReferenceCounter::print_info().
std::string libMesh::System::get_info | ( | ) | const |
Definition at line 1658 of file system.C.
References libMesh::FEType::family, get_dof_map(), libMesh::DofMap::get_info(), libMesh::FEType::inf_map, n_constrained_dofs(), n_dofs(), n_local_constrained_dofs(), n_local_dofs(), n_matrices(), n_variable_groups(), libMesh::VariableGroup::n_variables(), n_vectors(), libMesh::VariableGroup::name(), name(), number(), libMesh::FEType::order, libMesh::FEType::radial_family, libMesh::FEType::radial_order, system_type(), libMesh::Variable::type(), libMesh::DofMap::variable_group(), and variable_group().
|
inline |
_mesh
. Definition at line 2033 of file system.h.
References _mesh.
Referenced by libMesh::ExactSolution::_compute_error(), libMesh::PetscDMWrapper::add_dofs_to_section(), libMesh::HPCoarsenTest::add_projection(), libMesh::FEMSystem::assemble_qoi(), libMesh::FEMSystem::assemble_qoi_derivative(), libMesh::FEMSystem::assembly(), calculate_norm(), DMCreateDomainDecomposition_libMesh(), DMCreateFieldDecomposition_libMesh(), DMlibMeshSetSystem_libMesh(), libMesh::WeightedPatchRecoveryErrorEstimator::estimate_error(), libMesh::PatchRecoveryErrorEstimator::estimate_error(), libMesh::JumpErrorEstimator::estimate_error(), libMesh::AdjointResidualErrorEstimator::estimate_error(), libMesh::ExactErrorEstimator::estimate_error(), libMesh::SystemSubsetBySubdomain::init(), init_data(), libMesh::EigenSystem::init_matrices(), libMesh::ImplicitSystem::init_matrices(), local_dof_indices(), libMesh::DofMap::max_constraint_error(), libMesh::FEMSystem::mesh_position_get(), libMesh::FEMSystem::mesh_position_set(), libMesh::WeightedPatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::PatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::petsc_auto_fieldsplit(), point_gradient(), point_hessian(), point_value(), libMesh::FEMSystem::postprocess(), read_header(), read_legacy_data(), read_parallel_data(), read_serialized_vector(), read_serialized_vectors(), libMesh::EigenSystem::reinit(), libMesh::ImplicitSystem::reinit(), libMesh::HPSingularity::select_refinement(), libMesh::HPCoarsenTest::select_refinement(), libMesh::PetscDMWrapper::set_point_range_in_section(), write_header(), write_parallel_data(), write_serialized_vector(), write_serialized_vectors(), and zero_variable().
|
inline |
NumericVector< Number > & libMesh::System::get_sensitivity_rhs | ( | unsigned int | i = 0 | ) |
assemble_residual_derivatives()
is called.When assembled, this vector should hold -(partial R / partial p_i)
Definition at line 1061 of file system.C.
References get_vector().
Referenced by libMesh::ImplicitSystem::adjoint_qoi_parameter_sensitivity(), and libMesh::ImplicitSystem::sensitivity_solve().
const NumericVector< Number > & libMesh::System::get_sensitivity_rhs | ( | unsigned int | i = 0 | ) | const |
Definition at line 1071 of file system.C.
References get_vector().
NumericVector< Number > & libMesh::System::get_sensitivity_solution | ( | unsigned int | i = 0 | ) |
Definition at line 916 of file system.C.
References get_vector().
Referenced by libMesh::ImplicitSystem::forward_qoi_parameter_sensitivity(), libMesh::ImplicitSystem::qoi_parameter_hessian(), and libMesh::ImplicitSystem::sensitivity_solve().
const NumericVector< Number > & libMesh::System::get_sensitivity_solution | ( | unsigned int | i = 0 | ) | const |
Definition at line 926 of file system.C.
References get_vector().
const NumericVector< Number > & libMesh::System::get_vector | ( | const std::string & | vec_name | ) | const |
vec_name
. Access is only granted when the vector is already properly initialized. Definition at line 774 of file system.C.
References _vectors.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::UnsteadySolver::adjoint_advance_timestep(), libMesh::NewmarkSolver::advance_timestep(), libMesh::AdaptiveTimeSolver::advance_timestep(), libMesh::UnsteadySolver::advance_timestep(), compare(), libMesh::NewmarkSolver::compute_initial_accel(), libMesh::UnsteadySolver::du(), libMesh::AdjointRefinementEstimator::estimate_error(), get_adjoint_rhs(), get_adjoint_solution(), get_sensitivity_rhs(), get_sensitivity_solution(), get_weighted_sensitivity_adjoint_solution(), get_weighted_sensitivity_solution(), libMesh::NewmarkSystem::initial_conditions(), libMesh::NewmarkSolver::project_initial_accel(), libMesh::SecondOrderUnsteadySolver::project_initial_rate(), libMesh::SecondOrderUnsteadySolver::reinit(), libMesh::UnsteadySolver::reinit(), libMesh::MemorySolutionHistory::retrieve(), libMesh::UnsteadySolver::retrieve_timestep(), libMesh::TwostepTimeSolver::solve(), libMesh::FrequencySystem::solve(), libMesh::NewmarkSystem::update_rhs(), and libMesh::NewmarkSystem::update_u_v_a().
NumericVector< Number > & libMesh::System::get_vector | ( | const std::string & | vec_name | ) |
vec_name
. Access is only granted when the vector is already properly initialized. Definition at line 787 of file system.C.
References _vectors.
const NumericVector< Number > & libMesh::System::get_vector | ( | const unsigned int | vec_num | ) | const |
vec_num
(where the vectors are counted starting with 0). Definition at line 800 of file system.C.
References vectors_begin(), and vectors_end().
NumericVector< Number > & libMesh::System::get_vector | ( | const unsigned int | vec_num | ) |
vec_num
(where the vectors are counted starting with 0). Definition at line 816 of file system.C.
References vectors_begin(), and vectors_end().
NumericVector< Number > & libMesh::System::get_weighted_sensitivity_adjoint_solution | ( | unsigned int | i = 0 | ) |
Definition at line 1001 of file system.C.
References get_vector().
Referenced by libMesh::ImplicitSystem::qoi_parameter_hessian_vector_product(), and libMesh::ImplicitSystem::weighted_sensitivity_adjoint_solve().
const NumericVector< Number > & libMesh::System::get_weighted_sensitivity_adjoint_solution | ( | unsigned int | i = 0 | ) | const |
Definition at line 1011 of file system.C.
References get_vector().
NumericVector< Number > & libMesh::System::get_weighted_sensitivity_solution | ( | ) |
Definition at line 943 of file system.C.
References get_vector().
Referenced by libMesh::ImplicitSystem::qoi_parameter_hessian_vector_product(), and libMesh::ImplicitSystem::weighted_sensitivity_solve().
const NumericVector< Number > & libMesh::System::get_weighted_sensitivity_solution | ( | ) | const |
Definition at line 950 of file system.C.
References get_vector().
bool libMesh::System::has_variable | ( | const std::string & | var | ) | const |
true
if a variable named var
exists in this System Definition at line 1236 of file system.C.
References _variable_numbers.
Referenced by libMesh::GMVIO::copy_nodal_solution().
|
inline |
true
if this System
has a vector associated with the given name, false
otherwise. Definition at line 2225 of file system.h.
References _vectors.
Referenced by add_vector().
|
inline |
true
, then EquationSystems::write
will ignore this system. Definition at line 1662 of file system.h.
References _hide_output.
|
inline |
true
when VariableGroup
structures should be automatically identified, false
otherwise. Definition at line 2201 of file system.h.
References _identify_variable_groups.
Referenced by add_variable().
|
inline |
Toggle automatic VariableGroup
identification.
Definition at line 2209 of file system.h.
References _identify_variable_groups.
|
inlineprotectedinherited |
Increments the construction counter. Should be called in the constructor of any derived class that will be reference counted.
Definition at line 181 of file reference_counter.h.
References libMesh::ReferenceCounter::_counts, libMesh::Quality::name(), and libMesh::Threads::spin_mtx.
Referenced by libMesh::ReferenceCountedObject< RBParametrized >::ReferenceCountedObject().
|
inlineprotectedinherited |
Increments the destruction counter. Should be called in the destructor of any derived class that will be reference counted.
Definition at line 194 of file reference_counter.h.
References libMesh::ReferenceCounter::_counts, libMesh::Quality::name(), and libMesh::Threads::spin_mtx.
Referenced by libMesh::ReferenceCountedObject< RBParametrized >::~ReferenceCountedObject().
void libMesh::System::init | ( | ) |
Initializes degrees of freedom on the current mesh. Sets the
Definition at line 237 of file system.C.
References _basic_system_only, init_data(), is_initialized(), n_vars(), and user_initialization().
|
protectedvirtual |
Initializes the data for the system.
Reimplemented in libMesh::DifferentiableSystem, libMesh::ImplicitSystem, libMesh::ContinuationSystem, libMesh::RBEIMConstruction, libMesh::FEMSystem, libMesh::OptimizationSystem, libMesh::FrequencySystem, libMesh::RBConstructionBase< LinearImplicitSystem >, libMesh::RBConstructionBase< CondensedEigenSystem >, libMesh::EigenSystem, and libMesh::LinearImplicitSystem.
Definition at line 262 of file system.C.
References _dof_map, _is_initialized, _vector_types, _vectors, current_local_solution, get_mesh(), libMesh::GHOSTED, mesh, n_dofs(), n_local_dofs(), n_variable_groups(), libMesh::PARALLEL, reinit_constraints(), libMesh::SERIAL, and solution.
Referenced by init(), libMesh::EigenSystem::init_data(), and libMesh::ImplicitSystem::init_data().
|
inline |
Accessor for the adjoint_already_solved boolean
Definition at line 388 of file system.h.
References adjoint_already_solved.
Referenced by libMesh::ImplicitSystem::adjoint_qoi_parameter_sensitivity(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::AdjointResidualErrorEstimator::estimate_error(), libMesh::ImplicitSystem::qoi_parameter_hessian(), and libMesh::ImplicitSystem::qoi_parameter_hessian_vector_product().
|
inline |
true
iff this system has been initialized. Definition at line 2089 of file system.h.
References _is_initialized.
Referenced by add_variable(), add_variables(), and init().
void libMesh::System::local_dof_indices | ( | const unsigned int | var, |
std::set< dof_id_type > & | var_indices | ||
) | const |
Fills the std::set with the degrees of freedom on the local processor corresponding the the variable number passed in.
Definition at line 1277 of file system.C.
References libMesh::DofMap::dof_indices(), libMesh::DofMap::end_dof(), libMesh::DofMap::first_dof(), get_dof_map(), and get_mesh().
Referenced by discrete_var_norm().
|
inline |
Definition at line 2217 of file system.h.
References n_constrained_dofs(), and n_dofs().
|
inline |
n_vars()
in the case of all scalar-valued variables. Definition at line 2121 of file system.h.
References _variables, libMesh::Variable::first_scalar_number(), and libMesh::Variable::n_components().
Referenced by add_variables().
dof_id_type libMesh::System::n_constrained_dofs | ( | ) | const |
Definition at line 157 of file system.C.
References _dof_map.
Referenced by get_info(), and n_active_dofs().
dof_id_type libMesh::System::n_dofs | ( | ) | const |
Definition at line 150 of file system.C.
References _dof_map.
Referenced by add_vector(), libMesh::AdjointRefinementEstimator::estimate_error(), get_info(), libMesh::SecondOrderUnsteadySolver::init_data(), libMesh::UnsteadySolver::init_data(), init_data(), libMesh::OptimizationSystem::initialize_equality_constraints_storage(), libMesh::OptimizationSystem::initialize_inequality_constraints_storage(), n_active_dofs(), libMesh::CondensedEigenSystem::n_global_non_condensed_dofs(), libMesh::FEMSystem::numerical_jacobian(), read_legacy_data(), libMesh::SecondOrderUnsteadySolver::reinit(), libMesh::UnsteadySolver::reinit(), and restrict_vectors().
dof_id_type libMesh::System::n_local_constrained_dofs | ( | ) | const |
Definition at line 172 of file system.C.
References _dof_map.
Referenced by get_info().
dof_id_type libMesh::System::n_local_dofs | ( | ) | const |
Definition at line 187 of file system.C.
References _dof_map, and libMesh::ParallelObject::processor_id().
Referenced by add_vector(), libMesh::PetscDMWrapper::build_section(), libMesh::AdjointRefinementEstimator::estimate_error(), get_info(), libMesh::SecondOrderUnsteadySolver::init_data(), libMesh::UnsteadySolver::init_data(), init_data(), libMesh::OptimizationSystem::initialize_equality_constraints_storage(), libMesh::OptimizationSystem::initialize_inequality_constraints_storage(), libMesh::SecondOrderUnsteadySolver::reinit(), libMesh::UnsteadySolver::reinit(), and restrict_vectors().
|
inlinevirtual |
This will return 0 by default but can be overridden.
Reimplemented in libMesh::ImplicitSystem, and libMesh::EigenSystem.
Definition at line 2239 of file system.h.
Referenced by get_info().
|
inlinestaticinherited |
Prints the number of outstanding (created, but not yet destroyed) objects.
Definition at line 83 of file reference_counter.h.
References libMesh::ReferenceCounter::_n_objects.
|
inlineinherited |
Definition at line 95 of file parallel_object.h.
References libMesh::ParallelObject::_communicator, and libMesh::Parallel::Communicator::size().
Referenced by libMesh::BoundaryInfo::_find_id_maps(), libMesh::PetscDMWrapper::add_dofs_to_section(), libMesh::DistributedMesh::add_elem(), libMesh::DistributedMesh::add_node(), libMesh::LaplaceMeshSmoother::allgather_graph(), libMesh::FEMSystem::assembly(), libMesh::AztecLinearSolver< T >::AztecLinearSolver(), libMesh::BoundaryInfo::build_node_list_from_side_list(), libMesh::EquationSystems::build_parallel_elemental_solution_vector(), libMesh::DistributedMesh::clear(), libMesh::Nemesis_IO_Helper::compute_border_node_ids(), libMesh::Nemesis_IO_Helper::construct_nemesis_filename(), libMesh::UnstructuredMesh::create_pid_mesh(), libMesh::MeshTools::create_processor_bounding_box(), libMesh::DofMap::distribute_dofs(), libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), libMesh::EnsightIO::EnsightIO(), libMesh::MeshBase::get_info(), libMesh::SystemSubsetBySubdomain::init(), libMesh::PetscDMWrapper::init_and_attach_petscdm(), libMesh::Nemesis_IO_Helper::initialize(), libMesh::DistributedMesh::insert_elem(), libMesh::MeshTools::libmesh_assert_contiguous_dof_ids(), libMesh::MeshTools::libmesh_assert_parallel_consistent_new_node_procids(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Elem >(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Node >(), libMesh::MeshTools::libmesh_assert_topology_consistent_procids< Node >(), libMesh::MeshTools::libmesh_assert_valid_boundary_ids(), libMesh::MeshTools::libmesh_assert_valid_dof_ids(), libMesh::MeshTools::libmesh_assert_valid_neighbors(), libMesh::MeshTools::libmesh_assert_valid_refinement_flags(), libMesh::DofMap::local_variable_indices(), libMesh::MeshRefinement::make_coarsening_compatible(), libMesh::MeshBase::n_active_elem_on_proc(), libMesh::MeshBase::n_elem_on_proc(), libMesh::MeshBase::n_nodes_on_proc(), libMesh::MeshBase::partition(), libMesh::PetscLinearSolver< T >::PetscLinearSolver(), point_gradient(), point_hessian(), point_value(), libMesh::NameBasedIO::read(), libMesh::Nemesis_IO::read(), libMesh::CheckpointIO::read(), libMesh::CheckpointIO::read_connectivity(), libMesh::XdrIO::read_header(), libMesh::CheckpointIO::read_nodes(), read_parallel_data(), read_SCALAR_dofs(), read_serialized_blocked_dof_objects(), read_serialized_vector(), libMesh::DistributedMesh::renumber_dof_objects(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::PetscDMWrapper::set_point_range_in_section(), libMesh::MeshRefinement::uniformly_coarsen(), libMesh::DistributedMesh::update_parallel_id_counts(), libMesh::GMVIO::write_binary(), libMesh::GMVIO::write_discontinuous_gmv(), write_parallel_data(), write_SCALAR_dofs(), libMesh::XdrIO::write_serialized_bcs_helper(), write_serialized_blocked_dof_objects(), libMesh::XdrIO::write_serialized_connectivity(), libMesh::XdrIO::write_serialized_nodes(), and libMesh::XdrIO::write_serialized_nodesets().
|
inline |
Number of currently active quantities of interest.
Definition at line 2278 of file system.h.
References qoi.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::ImplicitSystem::adjoint_qoi_parameter_sensitivity(), libMesh::ImplicitSystem::adjoint_solve(), libMesh::SensitivityData::allocate_data(), libMesh::SensitivityData::allocate_hessian_data(), libMesh::ExplicitSystem::assemble_qoi(), libMesh::FEMSystem::assemble_qoi(), libMesh::ExplicitSystem::assemble_qoi_derivative(), libMesh::FEMSystem::assemble_qoi_derivative(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::AdjointResidualErrorEstimator::estimate_error(), libMesh::ImplicitSystem::forward_qoi_parameter_sensitivity(), libMesh::FEMContext::pre_fe_reinit(), libMesh::ImplicitSystem::qoi_parameter_hessian(), libMesh::ImplicitSystem::qoi_parameter_hessian_vector_product(), libMesh::QoISet::size(), and libMesh::ImplicitSystem::weighted_sensitivity_adjoint_solve().
|
inline |
VariableGroup
variable groups in the system Definition at line 2113 of file system.h.
References _variable_groups.
Referenced by add_variable(), libMesh::FEMSystem::assembly(), get_info(), and init_data().
|
inline |
Definition at line 2105 of file system.h.
References _variables.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::PetscDMWrapper::add_dofs_helper(), libMesh::DiffContext::add_localized_vector(), add_variable(), add_variables(), libMesh::EquationSystems::build_discontinuous_solution_vector(), libMesh::EquationSystems::build_parallel_elemental_solution_vector(), libMesh::EquationSystems::build_parallel_solution_vector(), libMesh::PetscDMWrapper::build_section(), calculate_norm(), libMesh::DGFEMContext::DGFEMContext(), libMesh::DiffContext::DiffContext(), libMesh::JumpErrorEstimator::estimate_error(), libMesh::AdjointResidualErrorEstimator::estimate_error(), libMesh::ExactErrorEstimator::estimate_error(), libMesh::ErrorEstimator::estimate_errors(), libMesh::ExactSolution::ExactSolution(), get_all_variable_numbers(), init(), libMesh::FEMSystem::init_context(), libMesh::FEMContext::init_internal_data(), libMesh::DGFEMContext::neighbor_side_fe_reinit(), libMesh::WeightedPatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::PatchRecoveryErrorEstimator::EstimateError::operator()(), libMesh::petsc_auto_fieldsplit(), libMesh::FEMContext::pre_fe_reinit(), re_update(), read_legacy_data(), read_parallel_data(), read_serialized_blocked_dof_objects(), read_serialized_vector(), read_serialized_vectors(), libMesh::HPCoarsenTest::select_refinement(), libMesh::PetscDMWrapper::set_point_range_in_section(), libMesh::SystemSubsetBySubdomain::set_var_nums(), write_header(), write_parallel_data(), write_serialized_blocked_dof_objects(), write_serialized_vector(), write_serialized_vectors(), and zero_variable().
|
inline |
_vectors
map Definition at line 2233 of file system.h.
References _vectors.
Referenced by libMesh::ExplicitSystem::add_system_rhs(), compare(), get_info(), and write_header().
|
inline |
Definition at line 2017 of file system.h.
References _sys_name.
Referenced by compare(), libMesh::ContinuationSystem::ContinuationSystem(), DMlibMeshSetUpName_Private(), libMesh::ExactErrorEstimator::estimate_error(), libMesh::ExactSolution::ExactSolution(), libMesh::ExactErrorEstimator::find_squared_element_error(), get_info(), libMesh::ImplicitSystem::get_linear_solver(), libMesh::NewtonSolver::init(), libMesh::TimeSolver::init_data(), libMesh::petsc_auto_fieldsplit(), libMesh::TimeSolver::reinit(), libMesh::PetscDiffSolver::setup_petsc_data(), libMesh::FrequencySystem::solve(), libMesh::LinearImplicitSystem::solve(), libMesh::NonlinearImplicitSystem::solve(), user_assembly(), user_constrain(), user_initialization(), user_QOI(), user_QOI_derivative(), write_header(), write_parallel_data(), and write_serialized_data().
|
inline |
Definition at line 2025 of file system.h.
References _sys_number.
Referenced by libMesh::ExactSolution::_compute_error(), libMesh::PetscDMWrapper::add_dofs_helper(), add_variable(), add_variables(), libMesh::EquationSystems::build_parallel_solution_vector(), libMesh::ExodusII_IO::copy_elemental_solution(), libMesh::ExodusII_IO::copy_nodal_solution(), libMesh::AdjointRefinementEstimator::estimate_error(), libMesh::ExactErrorEstimator::find_squared_element_error(), get_info(), read_legacy_data(), read_parallel_data(), read_serialized_blocked_dof_objects(), libMesh::HPCoarsenTest::select_refinement(), libMesh::PetscDMWrapper::set_point_range_in_section(), write_parallel_data(), write_serialized_blocked_dof_objects(), and zero_variable().
Gradient libMesh::System::point_gradient | ( | unsigned int | var, |
const Point & | p, | ||
const bool | insist_on_success = true |
||
) | const |
var
at the physical point p
in the mesh, similarly to point_value. Definition at line 2100 of file system.C.
References libMesh::Parallel::Communicator::broadcast(), libMesh::ParallelObject::comm(), libMesh::PointLocatorBase::enable_out_of_mesh_mode(), get_dof_map(), get_mesh(), mesh, libMesh::Parallel::Communicator::min(), libMesh::ParallelObject::n_processors(), libMesh::ParallelObject::processor_id(), and libMesh::DofObject::processor_id().
Referenced by point_gradient().
Gradient libMesh::System::point_gradient | ( | unsigned int | var, |
const Point & | p, | ||
const Elem & | e | ||
) | const |
var
at the physical point p
in local Elem e
in the mesh, similarly to point_value. Definition at line 2154 of file system.C.
References libMesh::TypeVector< T >::add_scaled(), libMesh::FEGenericBase< OutputType >::build(), libMesh::Elem::contains_point(), current_solution(), libMesh::Elem::dim(), libMesh::DofMap::dof_indices(), get_dof_map(), libMesh::Elem::infinite(), libMesh::FEInterface::inverse_map(), libMesh::DofMap::is_evaluable(), and libMesh::DofMap::variable_type().
Gradient libMesh::System::point_gradient | ( | unsigned int | var, |
const Point & | p, | ||
const Elem * | e | ||
) | const |
Calls the version of point_gradient() which takes a reference. This function exists only to prevent people from calling the version of point_gradient() that has a boolean third argument, which would result in unnecessary PointLocator calls.
Definition at line 2210 of file system.C.
References point_gradient().
Tensor libMesh::System::point_hessian | ( | unsigned int | var, |
const Point & | p, | ||
const bool | insist_on_success = true |
||
) | const |
var
at the physical point p
in the mesh, similarly to point_value. Definition at line 2220 of file system.C.
References libMesh::Parallel::Communicator::broadcast(), libMesh::ParallelObject::comm(), libMesh::PointLocatorBase::enable_out_of_mesh_mode(), get_dof_map(), get_mesh(), mesh, libMesh::Parallel::Communicator::min(), libMesh::ParallelObject::n_processors(), libMesh::ParallelObject::processor_id(), and libMesh::DofObject::processor_id().
Referenced by point_hessian().
var
at the physical point p
in local Elem e
in the mesh, similarly to point_value. Definition at line 2273 of file system.C.
References libMesh::TypeTensor< T >::add_scaled(), libMesh::FEGenericBase< OutputType >::build(), libMesh::Elem::contains_point(), current_solution(), libMesh::Elem::dim(), libMesh::DofMap::dof_indices(), get_dof_map(), libMesh::Elem::infinite(), libMesh::FEInterface::inverse_map(), libMesh::DofMap::is_evaluable(), and libMesh::DofMap::variable_type().
Calls the version of point_hessian() which takes a reference. This function exists only to prevent people from calling the version of point_hessian() that has a boolean third argument, which would result in unnecessary PointLocator calls.
Definition at line 2329 of file system.C.
References point_hessian().
Number libMesh::System::point_value | ( | unsigned int | var, |
const Point & | p, | ||
const bool | insist_on_success = true |
||
) | const |
var
at the physical point p
in the mesh, without knowing a priori which element contains p
.MeshBase::sub_point_locator()
; users may or may not want to call MeshBase::clear_point_locator()
afterward. Also, point_locator() is expensive (N log N for initial construction, log N for evaluations). Avoid using this function in any context where you are already looping over elements.Because the element containing p
may lie on any processor, this function is parallel-only.
By default this method expects the point to reside inside the domain and will abort if no element can be found which contains p
. The optional parameter insist_on_success
can be set to false to allow the method to return 0 when the point is not located.
Definition at line 1993 of file system.C.
References libMesh::Parallel::Communicator::broadcast(), libMesh::ParallelObject::comm(), libMesh::PointLocatorBase::enable_out_of_mesh_mode(), get_dof_map(), get_mesh(), mesh, libMesh::Parallel::Communicator::min(), libMesh::ParallelObject::n_processors(), libMesh::ParallelObject::processor_id(), and libMesh::DofObject::processor_id().
Referenced by point_value().
var
at the physical point p
contained in local Elem e
This version of point_value can be run in serial, but assumes e
is in the local mesh partition or is algebraically ghosted.
Definition at line 2046 of file system.C.
References libMesh::FEInterface::compute_data(), libMesh::Elem::contains_point(), current_solution(), libMesh::Elem::dim(), get_dof_map(), get_equation_systems(), and libMesh::FEInterface::inverse_map().
Calls the version of point_value() which takes a reference. This function exists only to prevent people from calling the version of point_value() that has a boolean third argument, which would result in unnecessary PointLocator calls.
Definition at line 2092 of file system.C.
References point_value().
|
staticinherited |
Prints the reference information, by default to libMesh::out
.
Definition at line 87 of file reference_counter.C.
References libMesh::ReferenceCounter::_enable_print_counter, and libMesh::ReferenceCounter::get_info().
|
inlineinherited |
Definition at line 101 of file parallel_object.h.
References libMesh::ParallelObject::_communicator, and libMesh::Parallel::Communicator::rank().
Referenced by libMesh::BoundaryInfo::_find_id_maps(), libMesh::EquationSystems::_read_impl(), libMesh::PetscDMWrapper::add_dofs_to_section(), libMesh::DistributedMesh::add_elem(), libMesh::BoundaryInfo::add_elements(), libMesh::DofMap::add_neighbors_to_send_list(), libMesh::DistributedMesh::add_node(), libMesh::UnstructuredMesh::all_second_order(), libMesh::MeshTools::Modification::all_tri(), libMesh::FEMSystem::assembly(), libMesh::EquationSystems::build_discontinuous_solution_vector(), libMesh::Nemesis_IO_Helper::build_element_and_node_maps(), libMesh::InfElemBuilder::build_inf_elem(), libMesh::BoundaryInfo::build_node_list_from_side_list(), libMesh::EquationSystems::build_parallel_elemental_solution_vector(), libMesh::DistributedMesh::clear(), libMesh::ExodusII_IO_Helper::close(), libMesh::Nemesis_IO_Helper::compute_border_node_ids(), libMesh::Nemesis_IO_Helper::compute_communication_map_parameters(), libMesh::Nemesis_IO_Helper::compute_internal_and_border_elems_and_internal_nodes(), libMesh::Nemesis_IO_Helper::compute_node_communication_maps(), libMesh::Nemesis_IO_Helper::compute_num_global_elem_blocks(), libMesh::Nemesis_IO_Helper::compute_num_global_nodesets(), libMesh::Nemesis_IO_Helper::compute_num_global_sidesets(), libMesh::Nemesis_IO_Helper::construct_nemesis_filename(), libMesh::MeshTools::correct_node_proc_ids(), libMesh::ExodusII_IO_Helper::create(), libMesh::DistributedMesh::delete_elem(), libMesh::DistributedMesh::delete_node(), libMesh::MeshCommunication::delete_remote_elements(), libMesh::DofMap::distribute_dofs(), libMesh::DofMap::distribute_local_dofs_node_major(), libMesh::DofMap::distribute_local_dofs_var_major(), libMesh::DistributedMesh::DistributedMesh(), libMesh::DofMap::end_dof(), libMesh::DofMap::end_old_dof(), libMesh::EnsightIO::EnsightIO(), libMesh::MeshFunction::find_element(), libMesh::MeshFunction::find_elements(), libMesh::UnstructuredMesh::find_neighbors(), libMesh::DofMap::first_dof(), libMesh::DofMap::first_old_dof(), libMesh::Nemesis_IO_Helper::get_cmap_params(), libMesh::Nemesis_IO_Helper::get_eb_info_global(), libMesh::Nemesis_IO_Helper::get_elem_cmap(), libMesh::Nemesis_IO_Helper::get_elem_map(), libMesh::MeshBase::get_info(), libMesh::DofMap::get_info(), libMesh::Nemesis_IO_Helper::get_init_global(), libMesh::Nemesis_IO_Helper::get_init_info(), libMesh::Nemesis_IO_Helper::get_loadbal_param(), libMesh::Nemesis_IO_Helper::get_node_cmap(), libMesh::Nemesis_IO_Helper::get_node_map(), libMesh::Nemesis_IO_Helper::get_ns_param_global(), libMesh::Nemesis_IO_Helper::get_ss_param_global(), libMesh::SparsityPattern::Build::handle_vi_vj(), libMesh::SystemSubsetBySubdomain::init(), libMesh::ExodusII_IO_Helper::initialize(), libMesh::ExodusII_IO_Helper::initialize_element_variables(), libMesh::ExodusII_IO_Helper::initialize_global_variables(), libMesh::ExodusII_IO_Helper::initialize_nodal_variables(), libMesh::DistributedMesh::insert_elem(), libMesh::DofMap::is_evaluable(), libMesh::SparsityPattern::Build::join(), libMesh::DofMap::last_dof(), libMesh::MeshTools::libmesh_assert_consistent_distributed(), libMesh::MeshTools::libmesh_assert_consistent_distributed_nodes(), libMesh::MeshTools::libmesh_assert_contiguous_dof_ids(), libMesh::MeshTools::libmesh_assert_parallel_consistent_procids< Elem >(), libMesh::MeshTools::libmesh_assert_valid_neighbors(), libMesh::DistributedMesh::libmesh_assert_valid_parallel_object_ids(), libMesh::DofMap::local_variable_indices(), libMesh::MeshRefinement::make_coarsening_compatible(), libMesh::MeshBase::n_active_local_elem(), libMesh::BoundaryInfo::n_boundary_conds(), libMesh::BoundaryInfo::n_edge_conds(), libMesh::DofMap::n_local_dofs(), n_local_dofs(), libMesh::MeshBase::n_local_elem(), libMesh::MeshBase::n_local_nodes(), libMesh::BoundaryInfo::n_nodeset_conds(), libMesh::BoundaryInfo::n_shellface_conds(), libMesh::SparsityPattern::Build::operator()(), libMesh::DistributedMesh::own_node(), point_gradient(), point_hessian(), point_value(), libMesh::Nemesis_IO_Helper::put_cmap_params(), libMesh::Nemesis_IO_Helper::put_elem_cmap(), libMesh::Nemesis_IO_Helper::put_elem_map(), libMesh::Nemesis_IO_Helper::put_loadbal_param(), libMesh::Nemesis_IO_Helper::put_node_cmap(), libMesh::Nemesis_IO_Helper::put_node_map(), libMesh::NameBasedIO::read(), libMesh::Nemesis_IO::read(), libMesh::XdrIO::read(), libMesh::CheckpointIO::read(), libMesh::ExodusII_IO_Helper::read_elem_num_map(), libMesh::ExodusII_IO_Helper::read_global_values(), libMesh::CheckpointIO::read_header(), libMesh::XdrIO::read_header(), read_header(), read_legacy_data(), libMesh::ExodusII_IO_Helper::read_node_num_map(), read_parallel_data(), read_SCALAR_dofs(), libMesh::XdrIO::read_serialized_bc_names(), libMesh::XdrIO::read_serialized_bcs_helper(), read_serialized_blocked_dof_objects(), libMesh::XdrIO::read_serialized_connectivity(), read_serialized_data(), libMesh::XdrIO::read_serialized_nodes(), libMesh::XdrIO::read_serialized_nodesets(), libMesh::XdrIO::read_serialized_subdomain_names(), read_serialized_vector(), read_serialized_vectors(), libMesh::DistributedMesh::renumber_dof_objects(), libMesh::CheckpointIO::select_split_config(), libMesh::DofMap::set_nonlocal_dof_objects(), libMesh::PetscDMWrapper::set_point_range_in_section(), libMesh::LaplaceMeshSmoother::smooth(), libMesh::MeshTools::total_weight(), libMesh::MeshRefinement::uniformly_coarsen(), libMesh::Parallel::Packing< T >::unpack(), libMesh::DistributedMesh::update_parallel_id_counts(), libMesh::NameBasedIO::write(), libMesh::XdrIO::write(), libMesh::CheckpointIO::write(), libMesh::EquationSystems::write(), libMesh::GMVIO::write_discontinuous_gmv(), libMesh::ExodusII_IO::write_element_data(), libMesh::ExodusII_IO_Helper::write_element_values(), libMesh::ExodusII_IO_Helper::write_elements(), libMesh::ExodusII_IO::write_global_data(), libMesh::ExodusII_IO_Helper::write_global_values(), write_header(), libMesh::ExodusII_IO::write_information_records(), libMesh::ExodusII_IO_Helper::write_information_records(), libMesh::ExodusII_IO_Helper::write_nodal_coordinates(), libMesh::UCDIO::write_nodal_data(), libMesh::ExodusII_IO::write_nodal_data(), libMesh::ExodusII_IO::write_nodal_data_discontinuous(), libMesh::ExodusII_IO_Helper::write_nodal_values(), libMesh::Nemesis_IO_Helper::write_nodesets(), libMesh::ExodusII_IO_Helper::write_nodesets(), write_parallel_data(), write_SCALAR_dofs(), libMesh::XdrIO::write_serialized_bc_names(), libMesh::XdrIO::write_serialized_bcs_helper(), write_serialized_blocked_dof_objects(), libMesh::XdrIO::write_serialized_connectivity(), write_serialized_data(), libMesh::XdrIO::write_serialized_nodes(), libMesh::XdrIO::write_serialized_nodesets(), libMesh::XdrIO::write_serialized_subdomain_names(), write_serialized_vector(), write_serialized_vectors(), libMesh::Nemesis_IO_Helper::write_sidesets(), libMesh::ExodusII_IO_Helper::write_sidesets(), libMesh::ExodusII_IO::write_timestep(), libMesh::ExodusII_IO_Helper::write_timestep(), and libMesh::ExodusII_IO::write_timestep_discontinuous().
void libMesh::System::project_solution | ( | FunctionBase< Number > * | f, |
FunctionBase< Gradient > * | g = nullptr |
||
) | const |
Projects arbitrary functions onto the current solution. The function value f
and its gradient g
are user-provided cloneable functors. A gradient g
is only required/used for projecting onto finite element spaces with continuous derivatives. If non-default Parameters
are to be used, they can be provided in the parameters
argument.
This method projects an arbitrary function onto the solution via L2 projections and nodal interpolations on each element.
Definition at line 810 of file system_projection.C.
void libMesh::System::project_solution | ( | FEMFunctionBase< Number > * | f, |
FEMFunctionBase< Gradient > * | g = nullptr |
||
) | const |
Projects arbitrary functions onto the current solution. The function value f
and its gradient g
are user-provided cloneable functors. A gradient g
is only required/used for projecting onto finite element spaces with continuous derivatives. If non-default Parameters
are to be used, they can be provided in the parameters
argument.
This method projects an arbitrary function onto the solution via L2 projections and nodal interpolations on each element.
Definition at line 823 of file system_projection.C.
void libMesh::System::project_solution | ( | ValueFunctionPointer | fptr, |
GradientFunctionPointer | gptr, | ||
const Parameters & | parameters | ||
) | const |
This method projects an arbitrary function onto the solution via L2 projections and nodal interpolations on each element.
Definition at line 796 of file system_projection.C.
|
inline |
Tells the System whether or not to project the solution vector onto new grids when the system is reinitialized. The solution will be projected unless project_solution_on_reinit() = false is called.
Definition at line 794 of file system.h.
References _solution_projection.
Referenced by libMesh::UniformRefinementEstimator::_estimate_error(), libMesh::AdjointRefinementEstimator::estimate_error(), and libMesh::MemorySolutionHistory::store().
void libMesh::System::project_vector | ( | NumericVector< Number > & | new_vector, |
FunctionBase< Number > * | f, | ||
FunctionBase< Gradient > * | g = nullptr , |
||
int | is_adjoint = -1 |
||
) | const |
Projects arbitrary functions onto a vector of degree of freedom values for the current system. The function value f
and its gradient g
are user-provided cloneable functors. A gradient g
is only required/used for projecting onto finite element spaces with continuous derivatives. If non-default Parameters
are to be used, they can be provided in the parameters
argument.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
This method projects an arbitrary function via L2 projections and nodal interpolations on each element.
Definition at line 851 of file system_projection.C.
Referenced by libMesh::NewmarkSolver::project_initial_accel(), libMesh::SecondOrderUnsteadySolver::project_initial_rate(), and restrict_vectors().
void libMesh::System::project_vector | ( | NumericVector< Number > & | new_vector, |
FEMFunctionBase< Number > * | f, | ||
FEMFunctionBase< Gradient > * | g = nullptr , |
||
int | is_adjoint = -1 |
||
) | const |
Projects arbitrary functions onto a vector of degree of freedom values for the current system. The function value f
and its gradient g
are user-provided cloneable functors. A gradient g
is only required/used for projecting onto finite element spaces with continuous derivatives. If non-default Parameters
are to be used, they can be provided in the parameters
argument.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
This method projects an arbitrary function via L2 projections and nodal interpolations on each element.
Definition at line 877 of file system_projection.C.
References libMesh::NumericVector< T >::close(), libMesh::FEMFunctionBase< Output >::component(), libMesh::Utility::iota(), n_vars, libMesh::Threads::parallel_for(), libMesh::FEMContext::pre_fe_reinit(), libMesh::SCALAR, libMesh::DofMap::SCALAR_dof_indices(), and libMesh::NumericVector< T >::set().
void libMesh::System::project_vector | ( | ValueFunctionPointer | fptr, |
GradientFunctionPointer | gptr, | ||
const Parameters & | parameters, | ||
NumericVector< Number > & | new_vector, | ||
int | is_adjoint = -1 |
||
) | const |
Projects arbitrary functions onto a vector of degree of freedom values for the current system. The function value fptr
and its gradient gptr
are represented by function pointers. A gradient gptr
is only required/used for projecting onto finite element spaces with continuous derivatives.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
This method projects an arbitrary function via L2 projections and nodal interpolations on each element.
Definition at line 836 of file system_projection.C.
|
protected |
Projects the vector defined on the old mesh onto the new mesh.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
Definition at line 212 of file system_projection.C.
References libMesh::NumericVector< T >::clone().
|
protected |
Projects the vector defined on the old mesh onto the new mesh. The original vector is unchanged and the new vector is passed through the second argument.
Constrain the new vector using the requested adjoint rather than primal constraints if is_adjoint is non-negative.
void libMesh::System::projection_matrix | ( | SparseMatrix< Number > & | proj_mat | ) | const |
This method creates a projection matrix which corresponds to the operation of project_vector between old and new solution spaces.
Heterogeneous Dirichlet boundary conditions are not taken into account here; if this matrix is used for prolongation (mesh refinement) on a side with a heterogeneous BC, the newly created degrees of freedom on that side will still match the coarse grid approximation of the BC, not the fine grid approximation.
This method creates a projection matrix which corresponds to the operation of project_vector between old and new solution spaces.
Definition at line 730 of file system_projection.C.
References libMesh::Utility::iota(), n_vars, libMesh::Threads::parallel_for(), libMesh::SCALAR, libMesh::DofMap::SCALAR_dof_indices(), and libMesh::SparseMatrix< T >::set().
|
virtual |
Prolong vectors after the mesh has refined
Definition at line 380 of file system.C.
References restrict_vectors().
Referenced by libMesh::EquationSystems::reinit_solutions().
|
inlinevirtual |
For each of the system's quantities of interest q in qoi
[qoi_indices], and for a vector of parameters p, the parameter sensitivity Hessian H_ij is defined as H_ij = (d^2 q)/(d p_i d p_j) This Hessian is the output of this method, where for each q_i, H_jk is stored in hessian.second_derivative(i,j,k)
.
This method is only implemented in some derived classes.
Reimplemented in libMesh::ImplicitSystem.
|
inlinevirtual |
For each of the system's quantities of interest q in qoi
[qoi_indices], and for a vector of parameters p, the parameter sensitivity Hessian H_ij is defined as H_ij = (d^2 q)/(d p_i d p_j) The Hessian-vector product, for a vector v_k in parameter space, is S_j = H_jk v_k This product is the output of this method, where for each q_i, S_j is stored in sensitivities
[i][j].
This method is only implemented in some derived classes.
Reimplemented in libMesh::ImplicitSystem.
|
virtual |
Solves for the derivative of each of the system's quantities of interest q in qoi
[qoi_indices] with respect to each parameter in parameters
, placing the result for qoi i
and parameter j
into sensitivities
[i][j].
parameters
is a const vector, not a vector-of-const; parameter values in this vector need to be mutable for finite differencing to work.Automatically chooses the forward method for problems with more quantities of interest than parameters, or the adjoint method otherwise.
This method is only usable in derived classes which override an implementation.
Definition at line 498 of file system.C.
References adjoint_qoi_parameter_sensitivity(), forward_qoi_parameter_sensitivity(), libMesh::ParameterVector::size(), and libMesh::QoISet::size().
|
virtual |
Re-update the local values when the mesh has changed. This method takes the data updated by update()
and makes it up-to-date on the current mesh.
Reimplemented in libMesh::TransientSystem< RBConstruction >.
Definition at line 429 of file system.C.
References current_local_solution, get_dof_map(), libMesh::DofMap::get_send_list(), n_vars(), and solution.
void libMesh::System::read_header | ( | Xdr & | io, |
const std::string & | version, | ||
const bool | read_header = true , |
||
const bool | read_additional_data = true , |
||
const bool | read_legacy_format = false |
||
) |
Reads the basic data header for this System.
Definition at line 115 of file system_io.C.
References _additional_data_written, _written_var_indices, add_variable(), add_vector(), libMesh::Parallel::Communicator::broadcast(), clear(), libMesh::ParallelObject::comm(), libMesh::Xdr::data(), libMesh::FEType::family, get_mesh(), libMesh::OrderWrapper::get_order(), libMesh::FEType::inf_map, libMesh::MeshBase::mesh_dimension(), libMesh::MONOMIAL, libMesh::on_command_line(), libMesh::FEType::order, libMesh::out, libMesh::ParallelObject::processor_id(), libMesh::FEType::radial_family, libMesh::FEType::radial_order, libMesh::Xdr::reading(), variable_number(), libMesh::Xdr::version(), and libMesh::XYZ.
Referenced by libMesh::EquationSystems::_read_impl().
void libMesh::System::read_legacy_data | ( | Xdr & | io, |
const bool | read_additional_data = true |
||
) |
Reads additional data, namely vectors, for this System.
Definition at line 310 of file system_io.C.
References _additional_data_written, _vectors, _written_var_indices, libMesh::Parallel::Communicator::broadcast(), libMesh::ParallelObject::comm(), libMesh::Xdr::data(), get_mesh(), libMesh::DofObject::invalid_id, n_dofs(), n_vars(), number(), libMesh::ParallelObject::processor_id(), libMesh::Xdr::reading(), solution, and libMesh::zero.
void libMesh::System::read_parallel_data | ( | Xdr & | io, |
const bool | read_additional_data | ||
) |
Reads additional data, namely vectors, for this System. This method may safely be called on a distributed-memory mesh. This method will read an individual file for each processor in the simulation where the local solution components for that processor are stored.
This method implements the output of the vectors contained in this System object, embedded in the output of an EquationSystems<T_sys>.
9.) The global solution vector, re-ordered to be node-major (More on this later.)
for each additional vector in the object
10.) The global additional vector, re-ordered to be node-major (More on this later.)
Note that the actual IO is handled through the Xdr class (to be renamed later?) which provides a uniform interface to both the XDR (eXternal Data Representation) interface and standard ASCII output. Thus this one section of code will read XDR or ASCII files with no changes.
Definition at line 493 of file system_io.C.
References _additional_data_written, _vectors, _written_var_indices, libMesh::Xdr::data(), libMesh::FEType::family, get_dof_map(), get_mesh(), libMesh::DofObject::invalid_id, libMesh::Xdr::is_open(), libMesh::ParallelObject::n_processors(), n_vars(), number(), libMesh::ParallelObject::processor_id(), libMesh::Xdr::reading(), libMesh::SCALAR, libMesh::DofMap::SCALAR_dof_indices(), solution, libMesh::Variable::type(), and variable().