PHX::EvaluatorManager< Traits > Class Template Reference

Class to sort which Evaluators should be called and the order in which to call them such that all dependencies are met. More...

#include <Phalanx_Evaluator_Manager.hpp>

List of all members.

Public Member Functions

 EvaluatorManager (const std::string &evaluator_type_name="???")
void requireField (const PHX::FieldTag &v)
 Require a variable to be evaluated.
void registerEvaluator (const Teuchos::RCP< PHX::Evaluator< Traits > > &p)
 Registers a variable provider with the manager.
void sortAndOrderEvaluators ()
void postRegistrationSetup (typename Traits::SetupData d, PHX::FieldManager< Traits > &vm)
void evaluateFields (typename Traits::EvalData d)
 Compute the required variables for the fill on the specific element.
void preEvaluate (typename Traits::PreEvalData d)
 This routine is called before each residual/Jacobian fill.
void postEvaluate (typename Traits::PostEvalData d)
 This routine is called after each residual/Jacobian fill.
void setEvaluationTypeName (const std::string &evaluation_type_name)
const std::vector
< Teuchos::RCP< PHX::FieldTag > > & 
getFieldTags ()
bool sortingCalled () const
void writeGraphvizFile (const std::string filename, bool writeEvaluatedFields, bool writeDependentFields, bool debugRegisteredEvaluators) const
void print (std::ostream &os) const
 Printing.

Protected Member Functions

void createProviderEvaluationOrder ()
 Create and arrange the dependency list in the correct order it should be evaluated.

Protected Attributes

std::vector< Teuchos::RCP
< PHX::FieldTag > > 
fields_
 Fields required by the user.
std::string evaluation_type_name_
bool sorting_called_
 Flag to tell the setup has been called.
Evaluator Objects

std::vector< Teuchos::RCP
< PHX::Evaluator< Traits > > > 
varProviders
std::vector< std::vector
< Teuchos::RCP< PHX::FieldTag > > > 
providerVariables
std::vector< std::vector
< Teuchos::RCP< PHX::FieldTag > > > 
providerRequirements
std::vector< std::string > providerNames
Evaluation Order Objects

Stores information about the order that providers need to be called to evaluate fields correctly.

std::vector< int > providerEvalOrderIndex

Detailed Description

template<typename Traits>
class PHX::EvaluatorManager< Traits >

Class to sort which Evaluators should be called and the order in which to call them such that all dependencies are met.


Member Function Documentation

template<typename Traits >
void PHX::EvaluatorManager< Traits >::postEvaluate ( typename Traits::PostEvalData  d  )  [inline]

This routine is called after each residual/Jacobian fill.

This routine is called ONCE on the provider after the fill loop over elements is completed. This allows us to evaluate any post fill data. An example is to print out some statistics such as the maximum grid peclet number in a cell.

template<typename Traits >
void PHX::EvaluatorManager< Traits >::postRegistrationSetup ( typename Traits::SetupData  d,
PHX::FieldManager< Traits > &  vm 
) [inline]

Calls post registration setup on all variable providers.

template<typename Traits >
void PHX::EvaluatorManager< Traits >::preEvaluate ( typename Traits::PreEvalData  d  )  [inline]

This routine is called before each residual/Jacobian fill.

This routine is called ONCE on the provider before the fill loop over elements is started. This allows us to reset global objects between each fill. An example is to reset a provider that monitors the maximum grid peclet number in a cell. This call would zero out the maximum for a new fill.

template<typename Traits >
void PHX::EvaluatorManager< Traits >::registerEvaluator ( const Teuchos::RCP< PHX::Evaluator< Traits > > &  p  )  [inline]

Registers a variable provider with the manager.

Todo:
RPP: need to add a check to make sure multiple providers can't supply the same variable.

template<typename Traits >
void PHX::EvaluatorManager< Traits >::sortAndOrderEvaluators (  )  [inline]

Sets up all field dependencies. This should only be called once all variables and DOFs have been added and all providers have been registered. Sorts variable and creates dependency lists and evaluation order


The documentation for this class was generated from the following files:
 All Classes Functions Variables Typedefs Friends
Generated on Wed Apr 13 10:05:54 2011 for Phalanx by  doxygen 1.6.3