GRINS-0.6.0
|
#include <vorticity.h>
Public Member Functions | |
Vorticity (const std::string &qoi_name) | |
Constructor. More... | |
virtual | ~Vorticity () |
virtual QoIBase * | clone () const |
Required to provide clone (deep-copy) for adding QoI object to libMesh objects. More... | |
virtual bool | assemble_on_interior () const |
Does the QoI need an element interior assembly loop? More... | |
virtual bool | assemble_on_sides () const |
Does the QoI need a domain boundary assembly loop? More... | |
virtual void | init (const GetPot &input, const MultiphysicsSystem &system) |
Initialize local variables. More... | |
virtual void | init_context (AssemblyContext &context) |
virtual void | element_qoi (AssemblyContext &context, const unsigned int qoi_index) |
Compute the qoi value. More... | |
virtual void | element_qoi_derivative (AssemblyContext &context, const unsigned int qoi_index) |
Compute the qoi derivative with respect to the solution. More... | |
virtual void | side_qoi (AssemblyContext &context, const unsigned int qoi_index) |
Compute the qoi value on the domain boundary. More... | |
virtual void | side_qoi_derivative (AssemblyContext &context, const unsigned int qoi_index) |
Compute the qoi derivative with respect to the solution on the domain boundary. More... | |
virtual void | parallel_op (const libMesh::Parallel::Communicator &communicator, libMesh::Number &sys_qoi, libMesh::Number &local_qoi) |
Call the parallel operation for this QoI and cache the value. More... | |
virtual void | thread_join (libMesh::Number &qoi, const libMesh::Number &other_qoi) |
Call the operation to accumulate this QoI from multiple threads. More... | |
virtual void | output_qoi (std::ostream &out) const |
Basic output for computed QoI's. More... | |
libMesh::Number | value () const |
Returns the current QoI value. More... | |
const std::string & | name () const |
Returns the name of this QoI. More... | |
virtual void | set_parameter (libMesh::Number ¶m_variable, const GetPot &input, const std::string ¶m_name, libMesh::Number param_default) |
Each subclass can simultaneously read a parameter value from. More... | |
virtual void | register_parameter (const std::string ¶m_name, libMesh::ParameterMultiPointer< libMesh::Number > ¶m_pointer) const |
Each subclass will register its copy of an independent. More... | |
Protected Attributes | |
VariableIndex | _u_var |
u-velocity component variable index More... | |
VariableIndex | _v_var |
v-velocity component variable index More... | |
std::set< libMesh::subdomain_id_type > | _subdomain_ids |
List of sumdomain ids for which we want to compute this QoI. More... | |
std::string | _qoi_name |
libMesh::Number | _qoi_value |
Private Member Functions | |
Vorticity () | |
User never call default constructor. More... | |
Vorticity QoI.
This class implement a vorticity QoI that can be used to both compute QoI values and drive QoI-based adaptive refinement. Currently, this QoI is only implemented in 2D and will error if it detects a three-dimensional problem.
Definition at line 42 of file vorticity.h.
GRINS::Vorticity::Vorticity | ( | const std::string & | qoi_name | ) |
Constructor.
Constructor takes GetPot object to read any input options associated with this QoI
Definition at line 41 of file vorticity.C.
|
virtual |
Definition at line 47 of file vorticity.C.
|
private |
User never call default constructor.
Referenced by clone().
|
inlinevirtual |
Does the QoI need an element interior assembly loop?
This is pure virtual to force to user to specify.
Implements GRINS::QoIBase.
Definition at line 98 of file vorticity.h.
|
inlinevirtual |
Does the QoI need a domain boundary assembly loop?
This is pure virtual to force to user to specify.
Implements GRINS::QoIBase.
Definition at line 104 of file vorticity.h.
|
virtual |
Required to provide clone (deep-copy) for adding QoI object to libMesh objects.
Implements GRINS::QoIBase.
Definition at line 52 of file vorticity.C.
References Vorticity().
|
virtual |
Compute the qoi value.
Currently, only implemented for 2D. Assumes that the vorticity will be computed over area of input subdomain id. Vorticity computed as
Reimplemented from GRINS::QoIBase.
Definition at line 99 of file vorticity.C.
References _subdomain_ids, _u_var, and _v_var.
|
virtual |
Compute the qoi derivative with respect to the solution.
Currently, only implemented for 2D. Assumes that the vorticity will be computed over area of input subdomain id.
Reimplemented from GRINS::QoIBase.
Definition at line 127 of file vorticity.C.
References _subdomain_ids, _u_var, and _v_var.
|
virtual |
Initialize local variables.
Any local variables that need information from libMesh get initialized here. For example, variable indices.
Reimplemented from GRINS::QoIBase.
Definition at line 57 of file vorticity.C.
References _subdomain_ids, _u_var, _v_var, GRINS::u_var_name_default, and GRINS::v_var_name_default.
|
virtual |
Reimplemented from GRINS::QoIBase.
Definition at line 83 of file vorticity.C.
References _u_var, and _v_var.
|
inlineinherited |
Returns the name of this QoI.
Definition at line 143 of file qoi_base.h.
References GRINS::QoIBase::_qoi_name.
Referenced by GRINS::SteadyVisualization::output_adjoint(), and GRINS::UnsteadyVisualization::output_adjoint().
|
virtualinherited |
Basic output for computed QoI's.
If fancier output is desired, override this method.
Definition at line 107 of file qoi_base.C.
References GRINS::QoIBase::_qoi_name, and GRINS::QoIBase::_qoi_value.
|
virtualinherited |
Call the parallel operation for this QoI and cache the value.
By default, this is just a sum. Override if QoI is more complex.
Definition at line 87 of file qoi_base.C.
References GRINS::QoIBase::_qoi_value.
|
virtualinherited |
Each subclass will register its copy of an independent.
Reimplemented in GRINS::AxisymmetricHeatTransfer< Conductivity >, GRINS::LowMachNavierStokesBase< Viscosity, SpecificHeat, ThermalConductivity >, GRINS::IncompressibleNavierStokesBase< Viscosity >, GRINS::BoussinesqBuoyancySPGSMStabilization< Viscosity >, GRINS::HeatConduction< Conductivity >, GRINS::HeatTransferBase< Conductivity >, and GRINS::BoussinesqBuoyancyAdjointStabilization< Viscosity >.
Definition at line 50 of file parameter_user.C.
Referenced by GRINS::BoussinesqBuoyancyAdjointStabilization< Viscosity >::register_parameter(), GRINS::HeatTransferBase< Conductivity >::register_parameter(), GRINS::HeatConduction< Conductivity >::register_parameter(), GRINS::BoussinesqBuoyancySPGSMStabilization< Viscosity >::register_parameter(), GRINS::IncompressibleNavierStokesBase< Viscosity >::register_parameter(), GRINS::LowMachNavierStokesBase< Viscosity, SpecificHeat, ThermalConductivity >::register_parameter(), and GRINS::AxisymmetricHeatTransfer< Conductivity >::register_parameter().
|
virtualinherited |
Each subclass can simultaneously read a parameter value from.
Definition at line 35 of file parameter_user.C.
References GRINS::ParameterUser::_my_name, and GRINS::ParameterUser::_my_parameters.
Referenced by GRINS::AveragedFanAdjointStabilization< Viscosity >::AveragedFanAdjointStabilization(), GRINS::AveragedTurbineAdjointStabilization< Viscosity >::AveragedTurbineAdjointStabilization(), GRINS::BoussinesqBuoyancyAdjointStabilization< Viscosity >::BoussinesqBuoyancyAdjointStabilization(), GRINS::BoussinesqBuoyancyBase::BoussinesqBuoyancyBase(), GRINS::BoussinesqBuoyancySPGSMStabilization< Viscosity >::BoussinesqBuoyancySPGSMStabilization(), GRINS::ConstantConductivity::ConstantConductivity(), GRINS::ConstantPrandtlConductivity::ConstantPrandtlConductivity(), GRINS::ConstantSourceFunction::ConstantSourceFunction(), GRINS::ConstantSourceTerm::ConstantSourceTerm(), GRINS::ConstantSpecificHeat::ConstantSpecificHeat(), GRINS::ConstantViscosity::ConstantViscosity(), GRINS::ElasticCable< StressStrainLaw >::ElasticCable(), GRINS::ElasticCableConstantGravity::ElasticCableConstantGravity(), GRINS::ElasticMembrane< StressStrainLaw >::ElasticMembrane(), GRINS::ElasticMembraneConstantPressure::ElasticMembraneConstantPressure(), GRINS::HeatConduction< Conductivity >::HeatConduction(), GRINS::HeatTransferBase< Conductivity >::HeatTransferBase(), GRINS::IncompressibleNavierStokesBase< Viscosity >::IncompressibleNavierStokesBase(), GRINS::AverageNusseltNumber::init(), GRINS::MooneyRivlin::MooneyRivlin(), GRINS::ReactingLowMachNavierStokesBase< Mixture, Evaluator >::ReactingLowMachNavierStokesBase(), GRINS::HookesLaw1D::read_input_options(), GRINS::HookesLaw::read_input_options(), GRINS::AxisymmetricBoussinesqBuoyancy::read_input_options(), and GRINS::VelocityDragAdjointStabilization< Viscosity >::VelocityDragAdjointStabilization().
|
virtualinherited |
Compute the qoi value on the domain boundary.
Override this method if your QoI is defined on the domain boundary
Reimplemented in GRINS::AverageNusseltNumber.
Definition at line 75 of file qoi_base.C.
|
virtualinherited |
Compute the qoi derivative with respect to the solution on the domain boundary.
Override this method if your QoI is defined on the domain boundary
Reimplemented in GRINS::AverageNusseltNumber.
Definition at line 81 of file qoi_base.C.
|
virtualinherited |
Call the operation to accumulate this QoI from multiple threads.
By default, this is just a sum. Override if QoI is more complex.
Definition at line 100 of file qoi_base.C.
|
inlineinherited |
Returns the current QoI value.
Definition at line 137 of file qoi_base.h.
References GRINS::QoIBase::_qoi_value.
|
protectedinherited |
Definition at line 131 of file qoi_base.h.
Referenced by GRINS::QoIBase::name(), and GRINS::QoIBase::output_qoi().
|
protectedinherited |
Definition at line 133 of file qoi_base.h.
Referenced by GRINS::QoIBase::output_qoi(), GRINS::QoIBase::parallel_op(), and GRINS::QoIBase::value().
|
protected |
List of sumdomain ids for which we want to compute this QoI.
Definition at line 89 of file vorticity.h.
Referenced by element_qoi(), element_qoi_derivative(), and init().
|
protected |
u-velocity component variable index
Definition at line 83 of file vorticity.h.
Referenced by element_qoi(), element_qoi_derivative(), init(), and init_context().
|
protected |
v-velocity component variable index
Definition at line 86 of file vorticity.h.
Referenced by element_qoi(), element_qoi_derivative(), init(), and init_context().