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

Public Member Functions

 NamedAdditionalMaterialOutputs (const std::vector< std::string > &output_names)
 
virtual ~NamedAdditionalMaterialOutputs ()
 
const std::vector< std::string > & get_names () const
 
virtual std::vector< double > get_nth_output (const unsigned int idx) const =0
 
virtual void average (const MaterialAveraging::AveragingOperation, const FullMatrix< double > &, const FullMatrix< double > &)
 
- Public Member Functions inherited from aspect::MaterialModel::AdditionalMaterialOutputs< dim >
virtual ~AdditionalMaterialOutputs ()
 

Private Attributes

const std::vector< std::string > names
 

Detailed Description

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

Some material models can compute things that are not used anywhere in the physics modules of ASPECT, but that may be of interest for visualization purposes. An example would be a material model that can compute seismic velocities – these are irrelevant to the rest of ASPECT, but would be nice to have for postprocessing.

This class is a base class for material models to provide this kind of information. It follows the scheme laid out by AdditionalMaterialModelOutputs but also provides an interface by which consumers of these objects (e.g., the Postprocess::Visualization::NamedAdditionalOutputs class) can query the names and values material models have put into these additional outputs. (Because every material model can decide by itself which – if any – additional outputs it produces, there are no standard names. Consequently, the material models have to describe what values and how many values they can produce.)

This class is then this base class for additional named material model outputs to be added to the MaterialModel::MaterialModelOutputs structure.

Definition at line 693 of file interface.h.

Constructor & Destructor Documentation

§ NamedAdditionalMaterialOutputs()

template<int dim>
aspect::MaterialModel::NamedAdditionalMaterialOutputs< dim >::NamedAdditionalMaterialOutputs ( const std::vector< std::string > &  output_names)

Constructor.

Parameters
output_namesA list of names for the additional output variables this object will store. The length of the list also indicates how many additional output variables objects of derived classes will store.

§ ~NamedAdditionalMaterialOutputs()

Destructor.

Member Function Documentation

§ get_names()

template<int dim>
const std::vector<std::string>& aspect::MaterialModel::NamedAdditionalMaterialOutputs< dim >::get_names ( ) const

Return a reference to the vector of names of the additional outputs.

§ get_nth_output()

template<int dim>
virtual std::vector<double> aspect::MaterialModel::NamedAdditionalMaterialOutputs< dim >::get_nth_output ( const unsigned int  idx) const
pure virtual

§ average()

template<int dim>
virtual void aspect::MaterialModel::NamedAdditionalMaterialOutputs< dim >::average ( const MaterialAveraging::AveragingOperation  ,
const FullMatrix< double > &  ,
const FullMatrix< double > &   
)
inlinevirtual

Reimplemented from aspect::MaterialModel::AdditionalMaterialOutputs< dim >.

Definition at line 723 of file interface.h.

Member Data Documentation

§ names

template<int dim>
const std::vector<std::string> aspect::MaterialModel::NamedAdditionalMaterialOutputs< dim >::names
private

Definition at line 729 of file interface.h.


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