#include <LOCA_MultiPredictor_Tangent.H>
Public Member Functions | |
Tangent (const Teuchos::RCP< LOCA::GlobalData > &global_data, const Teuchos::RCP< Teuchos::ParameterList > &predParams, const Teuchos::RCP< Teuchos::ParameterList > &solverParams) | |
Constructor. | |
virtual | ~Tangent () |
Destructor. | |
Tangent (const Tangent &source, NOX::CopyType type=NOX::DeepCopy) | |
Copy constructor. | |
virtual LOCA::MultiPredictor::AbstractStrategy & | operator= (const LOCA::MultiPredictor::AbstractStrategy &source) |
Assignment operator. | |
virtual Teuchos::RCP < LOCA::MultiPredictor::AbstractStrategy > | clone (NOX::CopyType type=NOX::DeepCopy) const |
Clone function. | |
virtual NOX::Abstract::Group::ReturnType | compute (bool baseOnSecant, const vector< double > &stepSize, LOCA::MultiContinuation::ExtendedGroup &grp, const LOCA::MultiContinuation::ExtendedVector &prevXVec, const LOCA::MultiContinuation::ExtendedVector &xVec) |
Compute the predictor given the current and previous solution vectors. Set baseOnSecant to false if the predictor orientation should not be based on the secant vector (first or last steps of a continuation run). | |
virtual NOX::Abstract::Group::ReturnType | evaluate (const vector< double > &stepSize, const LOCA::MultiContinuation::ExtendedVector &xVec, LOCA::MultiContinuation::ExtendedMultiVector &result) const |
Evaluate predictor with step size stepSize . | |
virtual NOX::Abstract::Group::ReturnType | computeTangent (LOCA::MultiContinuation::ExtendedMultiVector &tangent) |
Compute tangent to predictor and store in tangent . | |
virtual bool | isTangentScalable () const |
Is the tangent vector for this predictor scalable. | |
Protected Attributes | |
Teuchos::RCP< LOCA::GlobalData > | globalData |
LOCA global data object. | |
Teuchos::RCP < Teuchos::ParameterList > | linSolverParams |
Stores linear solver parameters. | |
Teuchos::RCP < NOX::Abstract::MultiVector > | fdfdp |
Stores derivative of residual w.r.t. parameters. | |
Teuchos::RCP < LOCA::MultiContinuation::ExtendedMultiVector > | tangent |
Stores tangent vector. | |
Teuchos::RCP < LOCA::MultiContinuation::ExtendedVector > | secant |
Stores secant vector for setting orientation. | |
bool | initialized |
Flag indicating whether vectors have been initialized. |
This class implements a predictor strategy based on computing the tangent to the continuation curve. If is the vector of continuation parameters, then the solution component of the tangent vectors
are computed by solving
The parameter component is set to the identity matrix.
Definition at line 67 of file LOCA_MultiPredictor_Tangent.H.
LOCA::MultiPredictor::Tangent::Tangent | ( | const Teuchos::RCP< LOCA::GlobalData > & | global_data, | |
const Teuchos::RCP< Teuchos::ParameterList > & | predParams, | |||
const Teuchos::RCP< Teuchos::ParameterList > & | solverParams | |||
) |
Constructor.
global_data | [in] Global data object | |
predParams | [in] Predictor parameters. Currently no parameters are used by the Tangent predictor. | |
solverParams | [in] Linear solver parameters used in linear solve to compute tangent vectors ![]() |
Definition at line 52 of file LOCA_MultiPredictor_Tangent.C.
Referenced by clone().
LOCA::MultiPredictor::Tangent::~Tangent | ( | ) | [virtual] |
LOCA::MultiPredictor::Tangent::Tangent | ( | const Tangent & | source, | |
NOX::CopyType | type = NOX::DeepCopy | |||
) |
Copy constructor.
Definition at line 69 of file LOCA_MultiPredictor_Tangent.C.
References fdfdp, initialized, secant, and tangent.
LOCA::MultiPredictor::AbstractStrategy & LOCA::MultiPredictor::Tangent::operator= | ( | const LOCA::MultiPredictor::AbstractStrategy & | source | ) | [virtual] |
Assignment operator.
Implements LOCA::MultiPredictor::AbstractStrategy.
Definition at line 89 of file LOCA_MultiPredictor_Tangent.C.
References NOX::DeepCopy, fdfdp, globalData, initialized, linSolverParams, secant, and tangent.
Teuchos::RCP< LOCA::MultiPredictor::AbstractStrategy > LOCA::MultiPredictor::Tangent::clone | ( | NOX::CopyType | type = NOX::DeepCopy |
) | const [virtual] |
Clone function.
Implements LOCA::MultiPredictor::AbstractStrategy.
Definition at line 113 of file LOCA_MultiPredictor_Tangent.C.
References Tangent().
NOX::Abstract::Group::ReturnType LOCA::MultiPredictor::Tangent::compute | ( | bool | baseOnSecant, | |
const vector< double > & | stepSize, | |||
LOCA::MultiContinuation::ExtendedGroup & | grp, | |||
const LOCA::MultiContinuation::ExtendedVector & | prevXVec, | |||
const LOCA::MultiContinuation::ExtendedVector & | xVec | |||
) | [virtual] |
Compute the predictor given the current and previous solution vectors. Set baseOnSecant to false if the predictor orientation should not be based on the secant vector (first or last steps of a continuation run).
This method actually implements the predictor solve described above
Implements LOCA::MultiPredictor::AbstractStrategy.
Definition at line 119 of file LOCA_MultiPredictor_Tangent.C.
References LOCA::MultiContinuation::ExtendedVector::clone(), LOCA::Extended::Vector::createMultiVector(), fdfdp, LOCA::MultiContinuation::ExtendedGroup::getContinuationParameterIDs(), LOCA::MultiContinuation::ExtendedGroup::getUnderlyingGroup(), globalData, initialized, linSolverParams, secant, LOCA::MultiPredictor::AbstractStrategy::setPredictorOrientation(), NOX::ShapeCopy, NOX::Utils::StepperDetails, and tangent.
NOX::Abstract::Group::ReturnType LOCA::MultiPredictor::Tangent::evaluate | ( | const vector< double > & | stepSize, | |
const LOCA::MultiContinuation::ExtendedVector & | xVec, | |||
LOCA::MultiContinuation::ExtendedMultiVector & | result | |||
) | const [virtual] |
Evaluate predictor with step size stepSize
.
This method computes result
[i] = xVec
[i] + stepSize
[i] * v[i] for each i, where v
[i] is the ith predictor direction.
Implements LOCA::MultiPredictor::AbstractStrategy.
Definition at line 204 of file LOCA_MultiPredictor_Tangent.C.
References NOX::Abstract::Group::Ok, and tangent.
NOX::Abstract::Group::ReturnType LOCA::MultiPredictor::Tangent::computeTangent | ( | LOCA::MultiContinuation::ExtendedMultiVector & | tangent | ) | [virtual] |
Compute tangent to predictor and store in tangent
.
Implements LOCA::MultiPredictor::AbstractStrategy.
Definition at line 219 of file LOCA_MultiPredictor_Tangent.C.
References NOX::Abstract::Group::Ok, and tangent.
bool LOCA::MultiPredictor::Tangent::isTangentScalable | ( | ) | const [virtual] |
Is the tangent vector for this predictor scalable.
For the tangent predictor, this always returns true.
Implements LOCA::MultiPredictor::AbstractStrategy.
Definition at line 228 of file LOCA_MultiPredictor_Tangent.C.
Teuchos::RCP<LOCA::GlobalData> LOCA::MultiPredictor::Tangent::globalData [protected] |
LOCA global data object.
Definition at line 136 of file LOCA_MultiPredictor_Tangent.H.
Referenced by compute(), and operator=().
Teuchos::RCP<Teuchos::ParameterList> LOCA::MultiPredictor::Tangent::linSolverParams [protected] |
Stores linear solver parameters.
Definition at line 139 of file LOCA_MultiPredictor_Tangent.H.
Referenced by compute(), and operator=().
Teuchos::RCP<NOX::Abstract::MultiVector> LOCA::MultiPredictor::Tangent::fdfdp [protected] |
Stores derivative of residual w.r.t. parameters.
Definition at line 142 of file LOCA_MultiPredictor_Tangent.H.
Referenced by compute(), operator=(), and Tangent().
Teuchos::RCP<LOCA::MultiContinuation::ExtendedMultiVector> LOCA::MultiPredictor::Tangent::tangent [protected] |
Stores tangent vector.
Definition at line 145 of file LOCA_MultiPredictor_Tangent.H.
Referenced by compute(), computeTangent(), evaluate(), operator=(), and Tangent().
Teuchos::RCP<LOCA::MultiContinuation::ExtendedVector> LOCA::MultiPredictor::Tangent::secant [protected] |
Stores secant vector for setting orientation.
Definition at line 148 of file LOCA_MultiPredictor_Tangent.H.
Referenced by compute(), operator=(), and Tangent().
bool LOCA::MultiPredictor::Tangent::initialized [protected] |
Flag indicating whether vectors have been initialized.
Definition at line 151 of file LOCA_MultiPredictor_Tangent.H.
Referenced by compute(), operator=(), and Tangent().