NOX  Development
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | List of all members
NOX::LineSearch::SafeguardedStep Class Reference

A line search that determines the step size by capping the magnitue of specific entries of the direction vector. The limits are specified by a user defined vector. More...

#include <NOX_LineSearch_SafeguardedStep.H>

Inheritance diagram for NOX::LineSearch::SafeguardedStep:
Inheritance graph
[legend]
Collaboration diagram for NOX::LineSearch::SafeguardedStep:
Collaboration graph
[legend]

Public Member Functions

 SafeguardedStep (const Teuchos::RCP< NOX::GlobalData > &gd, Teuchos::ParameterList &params)
 Constructor.
 
bool reset (const Teuchos::RCP< NOX::GlobalData > &gd, Teuchos::ParameterList &params)
 
bool compute (NOX::Abstract::Group &newgrp, double &step, const NOX::Abstract::Vector &dir, const NOX::Solver::Generic &s)
 Perform a line search. More...
 
Teuchos::RCP< const
Teuchos::ParameterList
getValidParameters ()
 
- Public Member Functions inherited from NOX::LineSearch::Generic
 Generic ()
 Default constructor.
 
virtual ~Generic ()
 Destructor.
 

Detailed Description

A line search that determines the step size by capping the magnitue of specific entries of the direction vector. The limits are specified by a user defined vector.

Member Function Documentation

bool NOX::LineSearch::SafeguardedStep::compute ( NOX::Abstract::Group grp,
double &  step,
const NOX::Abstract::Vector dir,
const NOX::Solver::Generic s 
)
virtual

Perform a line search.

On input:

Parameters
grpThe initial solution vector, $x_{\rm old}$.
dirA vector of directions to be used in the line search, $d$.
sThe nonlinear solver.

On output:

Parameters
stepThe distance the direction was scaled, $ \lambda $.
grpThe grp is updated with a new solution, $ x_{\rm new} $, resulting from the linesearch. Normally, for a single direction line search, this is computed as:

\[ x_{\rm new} = x_{\rm old} + \lambda d. \]

Ideally, $ \|F(x_{\rm new})\| < \|F(x_{\rm old})\| $ (e.g the final direction is a descent direction).

Note that the dir object is a std::vector. For typical line searches as described in the above equation, this vector is of size one. We have used a std::vector to allow for special cases of multi-directional line searches such as the Bader/Schnabel curvillinear line search.

Return value is true for a successful line search computation.

Implements NOX::LineSearch::Generic.

References NOX::Abstract::Group::computeX(), NOX::Utils::Details, NOX::Abstract::Group::getX(), NOX::Utils::InnerIteration, NOX::Abstract::Vector::MaxNorm, NOX::Abstract::Vector::norm(), NOX::Abstract::Vector::print(), and NOX::Abstract::Vector::scale().


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