ASPECT
Public Types | Public Member Functions | Protected Attributes | List of all members
aspect::MaterialModel::Interface< dim > Class Template Referenceabstract
Inheritance diagram for aspect::MaterialModel::Interface< dim >:
Inheritance graph
[legend]

Public Types

typedef MaterialModel::MaterialModelInputs< dim > MaterialModelInputs
 
typedef MaterialModel::MaterialModelOutputs< dim > MaterialModelOutputs
 

Public Member Functions

virtual ~Interface ()
 
virtual void initialize ()
 
virtual void update ()
 
virtual void evaluate (const MaterialModel::MaterialModelInputs< dim > &in, MaterialModel::MaterialModelOutputs< dim > &out) const =0
 
virtual void create_additional_named_outputs (MaterialModelOutputs &outputs) const
 
virtual void fill_additional_material_model_inputs (MaterialModel::MaterialModelInputs< dim > &input, const LinearAlgebra::BlockVector &solution, const FEValuesBase< dim > &fe_values, const Introspection< dim > &introspection) const
 
Qualitative properties one can ask a material model
const NonlinearDependence::ModelDependenceget_model_dependence () const
 
virtual bool is_compressible () const =0
 
Reference quantities
virtual double reference_viscosity () const =0
 

Protected Attributes

NonlinearDependence::ModelDependence model_dependence
 

Functions used in dealing with run-time parameters

virtual void parse_parameters (ParameterHandler &prm)
 
static void declare_parameters (ParameterHandler &prm)
 

Detailed Description

template<int dim>
class aspect::MaterialModel::Interface< dim >

A base class for parameterizations of material models. Classes derived from this class will need to implement functions that provide material parameters such as the viscosity, density, etc, typically as a function of position, temperature and pressure at that location.

Implementing a material model requires you to override evaluate() and fill the output argument struct instead of implementing the functions viscosity(), density(), etc.. In this case, all other functions are being ignored.

In all cases, model_dependence values, is_compressible(), reference_viscosity() need to be implemented.

Definition at line 935 of file interface.h.

Member Typedef Documentation

§ MaterialModelInputs

A typedef to import the MaterialModelInputs name into the current class. This typedef primarily exists as a backward compatibility measure given that the referenced structure used to be a member of the current class.

Definition at line 944 of file interface.h.

§ MaterialModelOutputs

A typedef to import the MaterialModelOutputs name into the current class. This typedef primarily exists as a backward compatibility measure given that the referenced structure used to be a member of the current class.

Definition at line 951 of file interface.h.

Constructor & Destructor Documentation

§ ~Interface()

template<int dim>
virtual aspect::MaterialModel::Interface< dim >::~Interface ( )
virtual

Destructor. Made virtual to enforce that derived classes also have virtual destructors.

Member Function Documentation

§ initialize()

template<int dim>
virtual void aspect::MaterialModel::Interface< dim >::initialize ( )
virtual

§ update()

template<int dim>
virtual void aspect::MaterialModel::Interface< dim >::update ( )
virtual

Called at the beginning of each time step and allows the material model to update internal data structures.

Reimplemented in aspect::MaterialModel::Steinberger< dim >, and aspect::MaterialModel::DepthDependent< dim >.

§ get_model_dependence()

template<int dim>
const NonlinearDependence::ModelDependence& aspect::MaterialModel::Interface< dim >::get_model_dependence ( ) const

Return a structure that describes how each of the model's output variables (such as viscosity, density, etc) depend on the input variables pressure, temperature, strain rate, and compositional fields.

§ is_compressible()

template<int dim>
virtual bool aspect::MaterialModel::Interface< dim >::is_compressible ( ) const
pure virtual

§ reference_viscosity()

template<int dim>
virtual double aspect::MaterialModel::Interface< dim >::reference_viscosity ( ) const
pure virtual

Return a reference value typical of the viscosities that appear in this model. This value is not actually used in the material description itself, but is used in scaling variables to the same numerical order of magnitude when solving linear systems. Specifically, the reference viscosity appears in the factor scaling the pressure against the velocity. It is also used in computing dimension-less quantities. You may want to take a look at the Kronbichler, Heister, Bangerth 2012 paper that describes the design of ASPECT for a description of this pressure scaling.

Note
The reference viscosity should take into account the complete constitutive relationship, defined as the scalar viscosity times the constitutive tensor. In most cases, the constitutive tensor will simply be the identity tensor (this is the default case), but this may become important for material models with anisotropic viscosities, if the constitutive tensor is not normalized.

Implemented in aspect::MaterialModel::GrainSize< dim >, aspect::MaterialModel::Steinberger< dim >, aspect::MaterialModel::Viscoelastic< dim >, aspect::MaterialModel::ViscoPlastic< dim >, aspect::MaterialModel::Averaging< dim >, aspect::MaterialModel::DruckerPrager< dim >, aspect::MaterialModel::DiffusionDislocation< dim >, aspect::MaterialModel::Compositing< dim >, aspect::MaterialModel::DynamicFriction< dim >, aspect::MaterialModel::DepthDependent< dim >, aspect::MaterialModel::Multicomponent< dim >, aspect::MaterialModel::MeltSimple< dim >, aspect::MaterialModel::SimpleCompressible< dim >, aspect::MaterialModel::AsciiReferenceProfile< dim >, aspect::MaterialModel::LatentHeat< dim >, aspect::MaterialModel::LatentHeatMelt< dim >, aspect::MaterialModel::MeltGlobal< dim >, aspect::MaterialModel::CompositionReaction< dim >, aspect::MaterialModel::PerpleXLookup< dim >, aspect::MaterialModel::Nondimensional< dim >, aspect::MaterialModel::Simple< dim >, and aspect::MaterialModel::Simpler< dim >.

§ evaluate()

template<int dim>
virtual void aspect::MaterialModel::Interface< dim >::evaluate ( const MaterialModel::MaterialModelInputs< dim > &  in,
MaterialModel::MaterialModelOutputs< dim > &  out 
) const
pure virtual

§ declare_parameters()

template<int dim>
static void aspect::MaterialModel::Interface< dim >::declare_parameters ( ParameterHandler prm)
static

Declare the parameters this class takes through input files. The default implementation of this function does not describe any parameters. Consequently, derived classes do not have to overload this function if they do not take any runtime parameters.

§ parse_parameters()

template<int dim>
virtual void aspect::MaterialModel::Interface< dim >::parse_parameters ( ParameterHandler prm)
virtual

§ create_additional_named_outputs()

template<int dim>
virtual void aspect::MaterialModel::Interface< dim >::create_additional_named_outputs ( MaterialModelOutputs outputs) const
virtual

§ fill_additional_material_model_inputs()

template<int dim>
virtual void aspect::MaterialModel::Interface< dim >::fill_additional_material_model_inputs ( MaterialModel::MaterialModelInputs< dim > &  input,
const LinearAlgebra::BlockVector solution,
const FEValuesBase< dim > &  fe_values,
const Introspection< dim > &  introspection 
) const
virtual

Fill the additional material model inputs that have been attached by the individual heating or material models in the create_additional_material_model_inputs function. This is done by looping over all material model inputs that have been created and calling their respective member functions.

Member Data Documentation

§ model_dependence

template<int dim>
NonlinearDependence::ModelDependence aspect::MaterialModel::Interface< dim >::model_dependence
protected

A structure that describes how each of the model's output variables (such as viscosity, density, etc) depend on the input variables pressure, temperature, strain rate, and compositional fields.

The constructor of this class calls the default constructor of this member variable which in turn initializes the object to invalid values. Derived classes then need to fill it either in their constructor (if they already know the correct dependencies at that time) or at the end of their parse_parameter() functions where they know the correct material parameters they will use.

Definition at line 1104 of file interface.h.


The documentation for this class was generated from the following file: