NOX  Development
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | List of all members
LOCA::StepSize::AbstractStrategy Class Referenceabstract

Abstract interface class for step size control strategies. More...

#include <LOCA_StepSize_AbstractStrategy.H>

Inheritance diagram for LOCA::StepSize::AbstractStrategy:
Inheritance graph
[legend]

Public Member Functions

 AbstractStrategy ()
 Constructor.
 
virtual ~AbstractStrategy ()
 Destructor.
 
virtual
NOX::Abstract::Group::ReturnType 
computeStepSize (LOCA::MultiContinuation::AbstractStrategy &curGroup, const LOCA::MultiContinuation::ExtendedVector &predictor, const NOX::Solver::Generic &solver, const LOCA::Abstract::Iterator::StepStatus &stepStatus, const LOCA::Abstract::Iterator &stepper, double &stepSize)=0
 Compute step size. More...
 
virtual double getPrevStepSize () const =0
 Return the previous step size.
 
virtual double getStartStepSize () const =0
 Return the initial step size.
 

Detailed Description

Abstract interface class for step size control strategies.

AbstractStrategy defines an abstract interface for step size control strategies. It is used by LOCA::Stepper to the step size for each continuation step.

The interface currently defines three pure virtual methods, computeStepSize() to compute the step size, getPrevSteSize() to get the step size from the previous step, and getStartStepSize() to get the initial step size. Derived classes should implement this method for a particular strategy. Constructors for derived classes should be of the form:

class Derived : public AbstractStrategy {
public:
Derived(
const Teuchos::RCP<LOCA::GlobalData>& global_data,
const Teuchos::RCP<Teuchos::ParameterList>& stepsizeParams);
...
};

where global_data is the LOCA global data object, topParams is the parsed top-level parameter list, and stepsizeParams is a parameter list of step size control parameters.

This class and its children follow the Strategy pattern as defined in Erich Gamma, et al. "Design Patterns: Elements of Reusable Object-Oriented Software." Addison Wesley, Boston, MA, 1995.

Member Function Documentation

virtual NOX::Abstract::Group::ReturnType LOCA::StepSize::AbstractStrategy::computeStepSize ( LOCA::MultiContinuation::AbstractStrategy curGroup,
const LOCA::MultiContinuation::ExtendedVector predictor,
const NOX::Solver::Generic solver,
const LOCA::Abstract::Iterator::StepStatus stepStatus,
const LOCA::Abstract::Iterator stepper,
double &  stepSize 
)
pure virtual

Compute step size.

Parameters
curGroup[in] Current continuation group
predictor[in] Current predictor direction
solver[in] Solver from previous step
stepStatus[in] Status of previous step
stepper[in] Stepper
stepSize[out] Computed step size
Returns
ReturnType code indicating success or failure

Implemented in LOCA::StepSize::Constant, and LOCA::StepSize::Adaptive.


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