ASPECT
|
Public Member Functions | |
MaterialModelInputs (const unsigned int n_points, const unsigned int n_comp) | |
MaterialModelInputs (const DataPostprocessorInputs::Vector< dim > &input_data, const Introspection< dim > &introspection, const bool compute_strain_rate=true) | |
MaterialModelInputs (const FEValuesBase< dim, dim > &fe_values, const typename DoFHandler< dim >::active_cell_iterator &cell, const Introspection< dim > &introspection, const LinearAlgebra::BlockVector &solution_vector, const bool compute_strain_rate=true) | |
MaterialModelInputs (const MaterialModelInputs &source) | |
MaterialModelInputs (MaterialModelInputs &&) noexcept=default | |
MaterialModelInputs & | operator= (const MaterialModelInputs &source)=delete |
MaterialModelInputs & | operator= (MaterialModelInputs &&)=default |
void | reinit (const FEValuesBase< dim, dim > &fe_values, const typename DoFHandler< dim >::active_cell_iterator &cell, const Introspection< dim > &introspection, const LinearAlgebra::BlockVector &solution_vector, const bool compute_strain_rate=true) |
unsigned int | n_evaluation_points () const |
bool | requests_property (const MaterialProperties::Property &property) const |
template<class AdditionalInputType > | |
AdditionalInputType * | get_additional_input () |
template<class AdditionalInputType > | |
const AdditionalInputType * | get_additional_input () const |
Public Attributes | |
std::vector< Point< dim > > | position |
std::vector< double > | temperature |
std::vector< double > | pressure |
std::vector< Tensor< 1, dim > > | pressure_gradient |
std::vector< Tensor< 1, dim > > | velocity |
std::vector< std::vector< double > > | composition |
std::vector< SymmetricTensor< 2, dim > > | strain_rate |
DoFHandler< dim >::active_cell_iterator | current_cell |
MaterialProperties::Property | requested_properties |
std::vector< std::unique_ptr< AdditionalMaterialInputs< dim > > > | additional_inputs |
A data structure with all inputs for the MaterialModel::Interface::evaluate() method. The vectors all have the same length and refer to different evaluation points (given in position).
Definition at line 245 of file interface.h.
aspect::MaterialModel::MaterialModelInputs< dim >::MaterialModelInputs | ( | const unsigned int | n_points, |
const unsigned int | n_comp | ||
) |
Constructor. Initialize the various arrays of this structure with the given number of quadrature points and (finite element) components.
n_points | The number of quadrature points for which input quantities will be provided. |
n_comp | The number of vector quantities (in the order in which the Introspection class reports them) for which input will be provided. |
aspect::MaterialModel::MaterialModelInputs< dim >::MaterialModelInputs | ( | const DataPostprocessorInputs::Vector< dim > & | input_data, |
const Introspection< dim > & | introspection, | ||
const bool | compute_strain_rate = true |
||
) |
Constructor. Initialize the arrays of the structure with the number of points in the input_data
structure, and fills them appropriately.
input_data | The data used to populate the material model input quantities. |
introspection | A reference to the simulator introspection object. |
compute_strain_rate | If set to true , then the object that is currently created will also store the strain rates at all evaluation points. This is an expensive operation. If set to false , then the strain_rate array is going to be empty, and strain rates are not evaluated. As a consequence, strain rates are then also not available to functions that take this MaterialModelInputs object as input, for example to compute strain rate-dependent viscosities. |
aspect::MaterialModel::MaterialModelInputs< dim >::MaterialModelInputs | ( | const FEValuesBase< dim, dim > & | fe_values, |
const typename DoFHandler< dim >::active_cell_iterator & | cell, | ||
const Introspection< dim > & | introspection, | ||
const LinearAlgebra::BlockVector & | solution_vector, | ||
const bool | compute_strain_rate = true |
||
) |
Constructor. Initializes the various arrays of this structure with the FEValues and introspection objects and the solution_vector. This constructor calls the function reinit to populate the newly created arrays.
fe_values | An FEValuesBase object used to evaluate the finite elements. |
cell | The currently active cell for the fe_values object. |
introspection | A reference to the simulator introspection object. |
solution_vector | The finite element vector from which to construct the inputs. |
compute_strain_rate | If set to true , then the object that is currently created will also store the strain rates at all evaluation points. This is an expensive operation. If set to false , then the strain_rate array is going to be empty, and strain rates are not evaluated. As a consequence, strain rates are then also not available to functions that take this MaterialModelInputs object as input, for example to compute strain rate-dependent viscosities. |
aspect::MaterialModel::MaterialModelInputs< dim >::MaterialModelInputs | ( | const MaterialModelInputs< dim > & | source | ) |
Copy constructor. This constructor copies all data members of the source object except for the additional input data (of type AdditionalMaterialInputs) pointers, stored in the source.additional_inputs
member variable.
This is because these pointers can not be copied (they are unique to the source
object). Since they can also not be recreated without the original code that created these objects in the first place, this constructor throws an exception if the source
object had any additional input data objects associated with it.
|
defaultnoexcept |
Move constructor. This constructor simply moves all members.
|
delete |
Copy operator. Copying these objects is expensive and consequently prohibited
|
default |
Move operator.
void aspect::MaterialModel::MaterialModelInputs< dim >::reinit | ( | const FEValuesBase< dim, dim > & | fe_values, |
const typename DoFHandler< dim >::active_cell_iterator & | cell, | ||
const Introspection< dim > & | introspection, | ||
const LinearAlgebra::BlockVector & | solution_vector, | ||
const bool | compute_strain_rate = true |
||
) |
Function to re-initialize and populate the pre-existing arrays created by the constructor MaterialModelInputs. The arguments here have the same meaning as in the constructor of this class.
unsigned int aspect::MaterialModel::MaterialModelInputs< dim >::n_evaluation_points | ( | ) | const |
Function that returns the number of points at which the material model is to be evaluated.
bool aspect::MaterialModel::MaterialModelInputs< dim >::requests_property | ( | const MaterialProperties::Property & | property | ) | const |
Function that returns if the caller requests an evaluation of the handed over property
. This is optional, because calculating some properties can be more expensive than the other material model properties and not all are needed for all applications.
AdditionalInputType * aspect::MaterialModel::MaterialModelInputs< dim >::get_additional_input | ( | ) |
Given an additional material model input class as explicitly specified template argument, returns a pointer to this additional material model input object if it is used in the current simulation. Ownership of the pointed-to object remains with the current object.
If the input does not exist, i.e., if there is no additional input object of the specified type, then a null pointer is returned.
Definition at line 1459 of file interface.h.
const AdditionalInputType * aspect::MaterialModel::MaterialModelInputs< dim >::get_additional_input | ( | ) | const |
A version of the previous function that is used when the object being queried is const
.
Definition at line 1473 of file interface.h.
std::vector<Point<dim> > aspect::MaterialModel::MaterialModelInputs< dim >::position |
Vector with global positions where the material has to be evaluated in evaluate().
Definition at line 366 of file interface.h.
std::vector<double> aspect::MaterialModel::MaterialModelInputs< dim >::temperature |
Temperature values at the points given in the position vector.
Definition at line 371 of file interface.h.
std::vector<double> aspect::MaterialModel::MaterialModelInputs< dim >::pressure |
Pressure values at the points given in the position vector.
Definition at line 376 of file interface.h.
std::vector<Tensor<1,dim> > aspect::MaterialModel::MaterialModelInputs< dim >::pressure_gradient |
Pressure gradients at the points given in the position vector. This is important for the heating models.
Definition at line 382 of file interface.h.
std::vector<Tensor<1,dim> > aspect::MaterialModel::MaterialModelInputs< dim >::velocity |
Velocity values at the points given in the position vector. This value is mostly important in the case of determining whether material crossed a certain region (e.g. a phase boundary). The timestep that is needed for this check can be requested from SimulatorAccess.
Definition at line 391 of file interface.h.
std::vector<std::vector<double> > aspect::MaterialModel::MaterialModelInputs< dim >::composition |
Values of the compositional fields at the points given in the position vector: composition[i][c] is the compositional field c at point i.
Definition at line 398 of file interface.h.
std::vector<SymmetricTensor<2,dim> > aspect::MaterialModel::MaterialModelInputs< dim >::strain_rate |
Strain rate at the points given in the position vector. Only the viscosity may depend on these values. This std::vector can be set to size 0 if the viscosity is not needed.
Definition at line 412 of file interface.h.
DoFHandler<dim>::active_cell_iterator aspect::MaterialModel::MaterialModelInputs< dim >::current_cell |
Optional cell object that contains these quadrature points. This allows for evaluating properties at the cell vertices and interpolating to the quadrature points, or to query the cell for material ids, neighbors, or other information that is not available solely from the locations. Note that not all calling functions will set this cell iterator. In these cases it will be an invalid iterator constructed using the default constructor, so make sure that your material model either fails with a proper error message, or provides an alternative calculation for these cases. You can detect this with
Definition at line 429 of file interface.h.
MaterialProperties::Property aspect::MaterialModel::MaterialModelInputs< dim >::requested_properties |
A member variable that stores which properties the material model should compute. You can check specific properties using the requests_property function and usually do not need to access this variable directly. For documentation on the internal storage of this variable see the documentation for MaterialProperties::Property.
Definition at line 438 of file interface.h.
std::vector<std::unique_ptr<AdditionalMaterialInputs<dim> > > aspect::MaterialModel::MaterialModelInputs< dim >::additional_inputs |
Vector of shared pointers to additional material model input objects that can be added to MaterialModelInputs. By default, no inputs are added.
Definition at line 464 of file interface.h.