|
Thyra Package Browser (Single Doxygen Collection) Version of the Day
|
Simple dampended Newton solver using a Armijo line search :-) More...
#include <Thyra_DampenedNewtonNonlinearSolver.hpp>

Public Types | |
| typedef Teuchos::ScalarTraits < Scalar > | ST |
| | |
| typedef ST::magnitudeType | ScalarMag |
| | |
| typedef Teuchos::ScalarTraits < ScalarMag > | SMT |
| | |
Public Member Functions | |
| STANDARD_MEMBER_COMPOSITION_MEMBERS (ScalarMag, defaultTol) | |
| The default solution tolerance. | |
| STANDARD_MEMBER_COMPOSITION_MEMBERS (int, defaultMaxNewtonIterations) | |
| The default maximum number of iterations. | |
| STANDARD_MEMBER_COMPOSITION_MEMBERS (bool, useDampenedLineSearch) | |
| The default maximum number of iterations. | |
| STANDARD_MEMBER_COMPOSITION_MEMBERS (Scalar, armijoConstant) | |
| Set the armijo constant for the line search. | |
| STANDARD_MEMBER_COMPOSITION_MEMBERS (int, maxLineSearchIterations) | |
| Set the maximum number of backtracking line search iterations to take. | |
| DampenedNewtonNonlinearSolver (const ScalarMag defaultTol=1e-2, const int defaultMaxNewtonIterations=1000, const bool useDampenedLineSearch=true, const Scalar armijoConstant=1e-4, const int maxLineSearchIterations=20) | |
| | |
Static Public Member Functions | |
| static RCP< const Teuchos::ParameterList > | getValidSolveCriteriaExtraParameters () |
| | |
Private Attributes | |
| RCP< Teuchos::ParameterList > | paramList_ |
| RCP< const ModelEvaluator < Scalar > > | model_ |
| RCP< LinearOpWithSolveBase < Scalar > > | J_ |
| RCP< VectorBase< Scalar > > | current_x_ |
| bool | J_is_current_ |
Overridden from ParameterListAcceptor | |
| void | setParameterList (RCP< Teuchos::ParameterList > const ¶mList) |
| | |
| RCP< Teuchos::ParameterList > | getNonconstParameterList () |
| | |
| RCP< Teuchos::ParameterList > | unsetParameterList () |
| | |
| RCP< const Teuchos::ParameterList > | getParameterList () const |
| | |
| RCP< const Teuchos::ParameterList > | getValidParameters () const |
| | |
Overridden from NonlinearSolverBase | |
| void | setModel (const RCP< const ModelEvaluator< Scalar > > &model) |
| | |
| RCP< const ModelEvaluator < Scalar > > | getModel () const |
| | |
| SolveStatus< Scalar > | solve (VectorBase< Scalar > *x, const SolveCriteria< Scalar > *solveCriteria, VectorBase< Scalar > *delta) |
| | |
| RCP< const VectorBase< Scalar > > | get_current_x () const |
| | |
| bool | is_W_current () const |
| | |
| RCP< LinearOpWithSolveBase < Scalar > > | get_nonconst_W (const bool forceUpToDate) |
| | |
| RCP< const LinearOpWithSolveBase< Scalar > > | get_W () const |
| | |
| void | set_W_is_current (bool W_is_current) |
| | |
Simple dampended Newton solver using a Armijo line search :-)
This class derives from Teuchos::VerboseObject and therefore will send output to *this->getOStream() if !Teuchos::isNull(this->getOStream()). The amount of output sent to *this->getOStream() depends on the verbosity level returned by this->getVerbLevel():
Teuchos::VERB_DEFAULT: Same as Teuchos::VERB_LOW. Teuchos::VERB_NONE: Output nothing Teuchos::VERB_LOW: Ouput only two lines of output for each Newton iteration Teuchos::VERB_MEDIUM: Output lines for each Newton iteration and line search iteration Teuchos::VERB_HIGH: Output more details about the Newton and line search iterations (good for basic debugging) Teuchos::VERB_EXTREME: Dump all the matrices and vectors that are computed. ToDo: Finish documentation.
Definition at line 67 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| typedef Teuchos::ScalarTraits<Scalar> Thyra::DampenedNewtonNonlinearSolver< Scalar >::ST |
Definition at line 71 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| typedef ST::magnitudeType Thyra::DampenedNewtonNonlinearSolver< Scalar >::ScalarMag |
Definition at line 73 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| typedef Teuchos::ScalarTraits<ScalarMag> Thyra::DampenedNewtonNonlinearSolver< Scalar >::SMT |
Definition at line 75 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| Thyra::DampenedNewtonNonlinearSolver< Scalar >::DampenedNewtonNonlinearSolver | ( | const ScalarMag | defaultTol = 1e-2, |
| const int | defaultMaxNewtonIterations = 1000, |
||
| const bool | useDampenedLineSearch = true, |
||
| const Scalar | armijoConstant = 1e-4, |
||
| const int | maxLineSearchIterations = 20 |
||
| ) |
Definition at line 163 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| Thyra::DampenedNewtonNonlinearSolver< Scalar >::STANDARD_MEMBER_COMPOSITION_MEMBERS | ( | ScalarMag | , |
| defaultTol | |||
| ) |
The default solution tolerance.
| Thyra::DampenedNewtonNonlinearSolver< Scalar >::STANDARD_MEMBER_COMPOSITION_MEMBERS | ( | int | , |
| defaultMaxNewtonIterations | |||
| ) |
The default maximum number of iterations.
| Thyra::DampenedNewtonNonlinearSolver< Scalar >::STANDARD_MEMBER_COMPOSITION_MEMBERS | ( | bool | , |
| useDampenedLineSearch | |||
| ) |
The default maximum number of iterations.
| Thyra::DampenedNewtonNonlinearSolver< Scalar >::STANDARD_MEMBER_COMPOSITION_MEMBERS | ( | Scalar | , |
| armijoConstant | |||
| ) |
Set the armijo constant for the line search.
| Thyra::DampenedNewtonNonlinearSolver< Scalar >::STANDARD_MEMBER_COMPOSITION_MEMBERS | ( | int | , |
| maxLineSearchIterations | |||
| ) |
Set the maximum number of backtracking line search iterations to take.
| RCP< const Teuchos::ParameterList > Thyra::DampenedNewtonNonlinearSolver< Scalar >::getValidSolveCriteriaExtraParameters | ( | ) | [static] |
Definition at line 180 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| void Thyra::DampenedNewtonNonlinearSolver< Scalar >::setParameterList | ( | RCP< Teuchos::ParameterList > const & | paramList | ) |
Definition at line 195 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| RCP< Teuchos::ParameterList > Thyra::DampenedNewtonNonlinearSolver< Scalar >::getNonconstParameterList | ( | ) |
Definition at line 212 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| RCP< Teuchos::ParameterList > Thyra::DampenedNewtonNonlinearSolver< Scalar >::unsetParameterList | ( | ) |
Definition at line 219 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| RCP< const Teuchos::ParameterList > Thyra::DampenedNewtonNonlinearSolver< Scalar >::getParameterList | ( | ) | const |
Definition at line 228 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| RCP< const Teuchos::ParameterList > Thyra::DampenedNewtonNonlinearSolver< Scalar >::getValidParameters | ( | ) | const |
Definition at line 235 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| void Thyra::DampenedNewtonNonlinearSolver< Scalar >::setModel | ( | const RCP< const ModelEvaluator< Scalar > > & | model | ) | [virtual] |
Implements Thyra::NonlinearSolverBase< Scalar >.
Definition at line 252 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
Referenced by main().
| RCP< const ModelEvaluator< Scalar > > Thyra::DampenedNewtonNonlinearSolver< Scalar >::getModel | ( | ) | const [virtual] |
Implements Thyra::NonlinearSolverBase< Scalar >.
Definition at line 265 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| SolveStatus< Scalar > Thyra::DampenedNewtonNonlinearSolver< Scalar >::solve | ( | VectorBase< Scalar > * | x, |
| const SolveCriteria< Scalar > * | solveCriteria, | ||
| VectorBase< Scalar > * | delta | ||
| ) | [virtual] |
Implements Thyra::NonlinearSolverBase< Scalar >.
Definition at line 272 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
References Thyra::SolveStatus< Scalar >::achievedTol, Thyra::assign(), Thyra::VectorBase< Scalar >::clone_v(), Thyra::eval_f(), Thyra::eval_f_W(), Thyra::SolveCriteria< Scalar >::extraParameters, Thyra::SolveStatus< Scalar >::message, Thyra::NOTRANS, Thyra::SolveCriteria< Scalar >::requestedTol, Thyra::SOLVE_MEASURE_NORM_RESIDUAL, Thyra::SOLVE_MEASURE_NORM_RHS, Thyra::SOLVE_STATUS_CONVERGED, Thyra::SOLVE_STATUS_UNCONVERGED, Thyra::SolveCriteria< Scalar >::solveMeasureType, Thyra::SolveStatus< Scalar >::solveStatus, Thyra::VectorBase< Scalar >::space(), THYRA_ASSERT_VEC_SPACES, Thyra::SolveMeasureType::useDefault(), Thyra::V_S(), Thyra::Vp_StV(), Thyra::Vp_V(), and Thyra::Vt_S().
| RCP< const VectorBase< Scalar > > Thyra::DampenedNewtonNonlinearSolver< Scalar >::get_current_x | ( | ) | const [virtual] |
Reimplemented from Thyra::NonlinearSolverBase< Scalar >.
Definition at line 477 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| bool Thyra::DampenedNewtonNonlinearSolver< Scalar >::is_W_current | ( | ) | const [virtual] |
Reimplemented from Thyra::NonlinearSolverBase< Scalar >.
Definition at line 483 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| RCP< LinearOpWithSolveBase< Scalar > > Thyra::DampenedNewtonNonlinearSolver< Scalar >::get_nonconst_W | ( | const bool | forceUpToDate | ) | [virtual] |
Reimplemented from Thyra::NonlinearSolverBase< Scalar >.
Definition at line 490 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| RCP< const LinearOpWithSolveBase< Scalar > > Thyra::DampenedNewtonNonlinearSolver< Scalar >::get_W | ( | ) | const [virtual] |
Reimplemented from Thyra::NonlinearSolverBase< Scalar >.
Definition at line 500 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
| void Thyra::DampenedNewtonNonlinearSolver< Scalar >::set_W_is_current | ( | bool | W_is_current | ) | [virtual] |
Reimplemented from Thyra::NonlinearSolverBase< Scalar >.
Definition at line 506 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
RCP<Teuchos::ParameterList> Thyra::DampenedNewtonNonlinearSolver< Scalar >::paramList_ [private] |
Definition at line 151 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
RCP<const ModelEvaluator<Scalar> > Thyra::DampenedNewtonNonlinearSolver< Scalar >::model_ [private] |
Definition at line 152 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
RCP<LinearOpWithSolveBase<Scalar> > Thyra::DampenedNewtonNonlinearSolver< Scalar >::J_ [private] |
Definition at line 153 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
RCP<VectorBase<Scalar> > Thyra::DampenedNewtonNonlinearSolver< Scalar >::current_x_ [private] |
Definition at line 154 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
bool Thyra::DampenedNewtonNonlinearSolver< Scalar >::J_is_current_ [private] |
Definition at line 155 of file Thyra_DampenedNewtonNonlinearSolver.hpp.
1.7.4