Optimo  0.1.0
A C++ header library for optimization
 All Classes Functions Variables Pages
optimo::solvers::GradientDescentLS< Scalar > Class Template Reference

Standard Gradient Descent method. More...

#include <gradient_descent.h>

Inheritance diagram for optimo::solvers::GradientDescentLS< Scalar >:
optimo::solvers::Solver< Scalar >

Public Member Functions

 GradientDescentLS (const int n, const Scalar alpha=1e-3)
 Constructor. More...
TERMINATION_TYPE operator() (const ProblemLS< Scalar > &problem, Eigen::Matrix< Scalar, Eigen::Dynamic, 1 > *x, Scalar *min_value)
 Solve the problem.

Additional Inherited Members

- Public Attributes inherited from optimo::solvers::Solver< Scalar >
 Solver parameters.

Detailed Description

template<typename Scalar>
class optimo::solvers::GradientDescentLS< Scalar >

Standard Gradient Descent method.

This class implements the following procedure:

  1. Computes a descent direction \(\mathbf{g}_k=-\nabla f_0(\mathbf{x}_k)\)
  2. Stop if the norm of the gradient is \(\|\mathbf{g}_k\|\leq\epsilon\)
  3. Take a step in the descent direction

    \[ \mathbf{x}_{k + 1} = \mathbf{x}_k + \alpha\mathbf{g}_k \]

where \(\alpha\) is the step size.

Constructor & Destructor Documentation

template<typename Scalar >
optimo::solvers::GradientDescentLS< Scalar >::GradientDescentLS ( const int  n,
const Scalar  alpha = 1e-3 


nNumber of variables
alphaStep size

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