mlpack  master
Public Member Functions | List of all members
mlpack::optimization::test::GDTestFunction Class Reference

Very, very simple test function which is the composite of three other functions. More...

Public Member Functions

 GDTestFunction ()
 Nothing to do for the constructor. More...
 
double Evaluate (const arma::mat &coordinates) const
 Evaluate a function. More...
 
arma::mat GetInitialPoint () const
 Get the starting point. More...
 
void Gradient (const arma::mat &coordinates, arma::mat &gradient) const
 Evaluate the gradient of a function. More...
 

Detailed Description

Very, very simple test function which is the composite of three other functions.

The gradient is not very steep far away from the optimum, so a larger step size may be required to optimize it in a reasonable number of iterations.

Definition at line 25 of file test_function.hpp.

Constructor & Destructor Documentation

mlpack::optimization::test::GDTestFunction::GDTestFunction ( )
inline

Nothing to do for the constructor.

Definition at line 29 of file test_function.hpp.

Member Function Documentation

double mlpack::optimization::test::GDTestFunction::Evaluate ( const arma::mat &  coordinates) const

Evaluate a function.

Referenced by GetInitialPoint().

arma::mat mlpack::optimization::test::GDTestFunction::GetInitialPoint ( ) const
inline

Get the starting point.

Definition at line 32 of file test_function.hpp.

References Evaluate(), and Gradient().

void mlpack::optimization::test::GDTestFunction::Gradient ( const arma::mat &  coordinates,
arma::mat &  gradient 
) const

Evaluate the gradient of a function.

Referenced by GetInitialPoint().


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