DART
6.10.1
|
#include <Function.hpp>
Public Member Functions | |
Function (const std::string &_name="function") | |
Constructor. More... | |
virtual | ~Function () |
Destructor. More... | |
virtual void | setName (const std::string &newName) |
Sets the name of this Function. More... | |
const std::string & | getName () const |
Returns the name of this Function. More... | |
virtual double | eval (const Eigen::VectorXd &x)=0 |
Evaluates and returns the objective function at the point x. More... | |
virtual void | evalGradient (const Eigen::VectorXd &_x, Eigen::Map< Eigen::VectorXd > _grad) |
Evaluates and returns the objective function at the point x. More... | |
void | evalGradient (const Eigen::VectorXd &_x, Eigen::VectorXd &_grad) |
Evaluates and return the objective function at the point x. More... | |
virtual void | evalHessian (const Eigen::VectorXd &_x, Eigen::Map< Eigen::VectorXd, Eigen::RowMajor > _Hess) |
Evaluates and return the objective function at the point x. More... | |
Protected Attributes | |
std::string | mName |
Name of this function. More... | |
|
explicit |
Constructor.
|
virtual |
Destructor.
|
pure virtual |
Evaluates and returns the objective function at the point x.
Implemented in dart::optimizer::ModularFunction, dart::dynamics::InverseKinematics::Constraint, dart::dynamics::InverseKinematics::Objective, dart::dynamics::HierarchicalIK::Constraint, dart::dynamics::HierarchicalIK::Objective, dart::constraint::BalanceConstraint, and dart::optimizer::NullFunction.
|
virtual |
Evaluates and returns the objective function at the point x.
Reimplemented in dart::optimizer::NullFunction, dart::optimizer::ModularFunction, dart::dynamics::InverseKinematics::Constraint, dart::dynamics::InverseKinematics::Objective, dart::dynamics::HierarchicalIK::Constraint, dart::dynamics::HierarchicalIK::Objective, and dart::constraint::BalanceConstraint.
void dart::optimizer::Function::evalGradient | ( | const Eigen::VectorXd & | _x, |
Eigen::VectorXd & | _grad | ||
) |
Evaluates and return the objective function at the point x.
If you have a raw array that the gradient will be passed in, then use evalGradient(const Eigen::VectorXd&, Eigen::Map<Eigen::VectorXd>) for better performance.
|
virtual |
Evaluates and return the objective function at the point x.
Reimplemented in dart::optimizer::NullFunction, and dart::optimizer::ModularFunction.
const std::string & dart::optimizer::Function::getName | ( | ) | const |
Returns the name of this Function.
|
virtual |
Sets the name of this Function.
|
protected |
Name of this function.