Public Member Functions | Protected Attributes | Private Member Functions

Albany::ScalarResponseFunction Class Reference

Interface for scalar response functions. More...

#include <Albany_ScalarResponseFunction.hpp>

Inheritance diagram for Albany::ScalarResponseFunction:
Inheritance graph
[legend]
Collaboration diagram for Albany::ScalarResponseFunction:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ScalarResponseFunction (const Teuchos::RCP< const Epetra_Comm > &comm_)
 Default constructor.
virtual ~ScalarResponseFunction ()
 Destructor.
virtual unsigned int numResponses () const =0
 Get the number of responses.
virtual Teuchos::RCP< const
Epetra_Comm > 
getComm () const
 Get the comm.
virtual void evaluateGradient (const double current_time, const Epetra_Vector *xdot, const Epetra_Vector *xdotdot, const Epetra_Vector &x, const Teuchos::Array< ParamVec > &p, ParamVec *deriv_p, Epetra_Vector *g, Epetra_MultiVector *dg_dx, Epetra_MultiVector *dg_dxdot, Epetra_MultiVector *dg_dxdotdot, Epetra_MultiVector *dg_dp)=0
 Evaluate gradient = dg/dx, dg/dxdot, dg/dp.
Implementation of AbstractResponseFunction virtual methods

virtual void setup ()
 Setup response function.
virtual bool isScalarResponse () const
 Is this response function "scalar" valued, i.e., has a replicated local response map.
virtual Teuchos::RCP
< Epetra_Operator > 
createGradientOp () const
 Create operator for gradient.
virtual Teuchos::RCP< const
Epetra_Map > 
responseMap () const
 Get the map associate with this response.
virtual void evaluateDerivative (const double current_time, const Epetra_Vector *xdot, const Epetra_Vector *xdotdot, const Epetra_Vector &x, const Teuchos::Array< ParamVec > &p, ParamVec *deriv_p, Epetra_Vector *g, const EpetraExt::ModelEvaluator::Derivative &dg_dx, const EpetraExt::ModelEvaluator::Derivative &dg_dxdot, const EpetraExt::ModelEvaluator::Derivative &dg_dxdotdot, const EpetraExt::ModelEvaluator::Derivative &dg_dp)
 Evaluate derivative dg/dx, dg/dxdot, dg/dp.

Protected Attributes

Teuchos::RCP< const Epetra_Comm > comm
 Comm for forming response map.

Private Member Functions

 ScalarResponseFunction (const ScalarResponseFunction &)
 Private to prohibit copying.
ScalarResponseFunctionoperator= (const ScalarResponseFunction &)
 Private to prohibit copying.

Detailed Description

Interface for scalar response functions.

Implements a few methods of AbstractResponseFunction specifically for "scalar" valued responses, i.e., those that just return a few values. In this case, the derivative is a multi-vector and the response map is simpler.

Definition at line 22 of file Albany_ScalarResponseFunction.hpp.


Constructor & Destructor Documentation

Albany::ScalarResponseFunction::ScalarResponseFunction ( const Teuchos::RCP< const Epetra_Comm > &  comm_  )  [inline]

Default constructor.

Definition at line 27 of file Albany_ScalarResponseFunction.hpp.

virtual Albany::ScalarResponseFunction::~ScalarResponseFunction (  )  [inline, virtual]

Destructor.

Definition at line 31 of file Albany_ScalarResponseFunction.hpp.

Albany::ScalarResponseFunction::ScalarResponseFunction ( const ScalarResponseFunction  )  [private]

Private to prohibit copying.


Member Function Documentation

virtual unsigned int Albany::ScalarResponseFunction::numResponses (  )  const [pure virtual]
virtual Teuchos::RCP<const Epetra_Comm> Albany::ScalarResponseFunction::getComm (  )  const [inline, virtual]

Get the comm.

Definition at line 37 of file Albany_ScalarResponseFunction.hpp.

virtual void Albany::ScalarResponseFunction::evaluateGradient ( const double  current_time,
const Epetra_Vector *  xdot,
const Epetra_Vector *  xdotdot,
const Epetra_Vector &  x,
const Teuchos::Array< ParamVec > &  p,
ParamVec deriv_p,
Epetra_Vector *  g,
Epetra_MultiVector *  dg_dx,
Epetra_MultiVector *  dg_dxdot,
Epetra_MultiVector *  dg_dxdotdot,
Epetra_MultiVector *  dg_dp 
) [pure virtual]
virtual void Albany::ScalarResponseFunction::setup (  )  [inline, virtual]
virtual bool Albany::ScalarResponseFunction::isScalarResponse (  )  const [inline, virtual]

Is this response function "scalar" valued, i.e., has a replicated local response map.

Implements Albany::AbstractResponseFunction.

Definition at line 99 of file Albany_ScalarResponseFunction.hpp.

Teuchos::RCP< Epetra_Operator > Albany::ScalarResponseFunction::createGradientOp (  )  const [virtual]

Create operator for gradient.

Here we just throw an error. We could actually support this a coupled of ways if we wanted to.

Implements Albany::AbstractResponseFunction.

Definition at line 23 of file Albany_ScalarResponseFunction.cpp.

Teuchos::RCP< const Epetra_Map > Albany::ScalarResponseFunction::responseMap (  )  const [virtual]

Get the map associate with this response.

Implements Albany::AbstractResponseFunction.

Definition at line 13 of file Albany_ScalarResponseFunction.cpp.

void Albany::ScalarResponseFunction::evaluateDerivative ( const double  current_time,
const Epetra_Vector *  xdot,
const Epetra_Vector *  xdotdot,
const Epetra_Vector &  x,
const Teuchos::Array< ParamVec > &  p,
ParamVec deriv_p,
Epetra_Vector *  g,
const EpetraExt::ModelEvaluator::Derivative &  dg_dx,
const EpetraExt::ModelEvaluator::Derivative &  dg_dxdot,
const EpetraExt::ModelEvaluator::Derivative &  dg_dxdotdot,
const EpetraExt::ModelEvaluator::Derivative &  dg_dp 
) [virtual]

Evaluate derivative dg/dx, dg/dxdot, dg/dp.

Implements Albany::AbstractResponseFunction.

Definition at line 34 of file Albany_ScalarResponseFunction.cpp.

ScalarResponseFunction& Albany::ScalarResponseFunction::operator= ( const ScalarResponseFunction  )  [private]

Private to prohibit copying.


Member Data Documentation

Teuchos::RCP<const Epetra_Comm> Albany::ScalarResponseFunction::comm [protected]

Comm for forming response map.

Reimplemented in QCAD::SaddleValueResponseFunction.

Definition at line 173 of file Albany_ScalarResponseFunction.hpp.


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