.TH "mlpack::optimization::AugLagrangianFunction< LagrangianFunction >" 3 "Tue Sep 9 2014" "Version 1.0.10" "MLPACK" \" -*- nroff -*- .ad l .nh .SH NAME mlpack::optimization::AugLagrangianFunction< LagrangianFunction > \- .PP This is a utility class used by \fBAugLagrangian\fP, meant to wrap a LagrangianFunction into a function usable by a simple optimizer like L-BFGS\&. .SH SYNOPSIS .br .PP .SS "Public Member Functions" .in +1c .ti -1c .RI "\fBAugLagrangianFunction\fP (LagrangianFunction &\fBfunction\fP)" .br .RI "\fIInitialize the \fBAugLagrangianFunction\fP, but don't set the Lagrange multipliers or penalty parameters yet\&. \fP" .ti -1c .RI "\fBAugLagrangianFunction\fP (LagrangianFunction &\fBfunction\fP, const arma::vec &\fBlambda\fP, const double \fBsigma\fP)" .br .RI "\fIInitialize the \fBAugLagrangianFunction\fP with the given LagrangianFunction, Lagrange multipliers, and initial penalty parameter\&. \fP" .ti -1c .RI "double \fBEvaluate\fP (const arma::mat &coordinates) const " .br .RI "\fIEvaluate the objective function of the Augmented Lagrangian function, which is the standard Lagrangian function evaluation plus a penalty term, which penalizes unsatisfied constraints\&. \fP" .ti -1c .RI "const LagrangianFunction & \fBFunction\fP () const " .br .RI "\fIGet the Lagrangian function\&. \fP" .ti -1c .RI "LagrangianFunction & \fBFunction\fP ()" .br .RI "\fIModify the Lagrangian function\&. \fP" .ti -1c .RI "const arma::mat & \fBGetInitialPoint\fP () const " .br .RI "\fIGet the initial point of the optimization (supplied by the LagrangianFunction)\&. \fP" .ti -1c .RI "void \fBGradient\fP (const arma::mat &coordinates, arma::mat &gradient) const " .br .RI "\fIEvaluate the gradient of the Augmented Lagrangian function\&. \fP" .ti -1c .RI "const arma::vec & \fBLambda\fP () const " .br .RI "\fIGet the Lagrange multipliers\&. \fP" .ti -1c .RI "arma::vec & \fBLambda\fP ()" .br .RI "\fIModify the Lagrange multipliers\&. \fP" .ti -1c .RI "double \fBSigma\fP () const " .br .RI "\fIGet sigma (the penalty parameter)\&. \fP" .ti -1c .RI "double & \fBSigma\fP ()" .br .RI "\fIModify sigma (the penalty parameter)\&. \fP" .ti -1c .RI "std::string \fBToString\fP () const " .br .in -1c .SS "Private Attributes" .in +1c .ti -1c .RI "LagrangianFunction & \fBfunction\fP" .br .RI "\fIInstantiation of the function to be optimized\&. \fP" .ti -1c .RI "arma::vec \fBlambda\fP" .br .RI "\fIThe Lagrange multipliers\&. \fP" .ti -1c .RI "double \fBsigma\fP" .br .RI "\fIThe penalty parameter\&. \fP" .in -1c .SH "Detailed Description" .PP .SS "templateclass mlpack::optimization::AugLagrangianFunction< LagrangianFunction >" This is a utility class used by \fBAugLagrangian\fP, meant to wrap a LagrangianFunction into a function usable by a simple optimizer like L-BFGS\&. Given a LagrangianFunction which follows the format outlined in the documentation for \fBAugLagrangian\fP, this class provides \fBEvaluate()\fP, \fBGradient()\fP, and \fBGetInitialPoint()\fP functions which allow this class to be used with a simple optimizer like L-BFGS\&. .PP This class can be specialized for your particular implementation -- commonly, a faster method for computing the overall objective and gradient of the augmented Lagrangian function can be implemented than the naive, default implementation given\&. Use class template specialization and re-implement all of the methods (unfortunately, C++ specialization rules mean you have to re-implement everything)\&. .PP \fBTemplate Parameters:\fP .RS 4 \fILagrangianFunction\fP Lagrangian function to be used\&. .RE .PP .PP Definition at line 48 of file aug_lagrangian_function\&.hpp\&. .SH "Constructor & Destructor Documentation" .PP .SS "template \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::\fBAugLagrangianFunction\fP (LagrangianFunction &function)" .PP Initialize the \fBAugLagrangianFunction\fP, but don't set the Lagrange multipliers or penalty parameters yet\&. Make sure you set the Lagrange multipliers before you use this\&.\&.\&. .PP \fBParameters:\fP .RS 4 \fIfunction\fP Lagrangian function\&. .RE .PP .SS "template \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::\fBAugLagrangianFunction\fP (LagrangianFunction &function, const arma::vec &lambda, const doublesigma)" .PP Initialize the \fBAugLagrangianFunction\fP with the given LagrangianFunction, Lagrange multipliers, and initial penalty parameter\&. .PP \fBParameters:\fP .RS 4 \fIfunction\fP Lagrangian function\&. .br \fIlambda\fP Initial Lagrange multipliers\&. .br \fIsigma\fP Initial penalty parameter\&. .RE .PP .SH "Member Function Documentation" .PP .SS "template double \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Evaluate (const arma::mat &coordinates) const" .PP Evaluate the objective function of the Augmented Lagrangian function, which is the standard Lagrangian function evaluation plus a penalty term, which penalizes unsatisfied constraints\&. .PP \fBParameters:\fP .RS 4 \fIcoordinates\fP Coordinates to evaluate function at\&. .RE .PP \fBReturns:\fP .RS 4 Objective function\&. .RE .PP .SS "template const LagrangianFunction& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Function () const\fC [inline]\fP" .PP Get the Lagrangian function\&. .PP Definition at line 108 of file aug_lagrangian_function\&.hpp\&. .SS "template LagrangianFunction& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Function ()\fC [inline]\fP" .PP Modify the Lagrangian function\&. .PP Definition at line 110 of file aug_lagrangian_function\&.hpp\&. .SS "template const arma::mat& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::GetInitialPoint () const" .PP Get the initial point of the optimization (supplied by the LagrangianFunction)\&. .PP \fBReturns:\fP .RS 4 Initial point\&. .RE .PP .SS "template void \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Gradient (const arma::mat &coordinates, arma::mat &gradient) const" .PP Evaluate the gradient of the Augmented Lagrangian function\&. .PP \fBParameters:\fP .RS 4 \fIcoordinates\fP Coordinates to evaluate gradient at\&. .br \fIgradient\fP Matrix to store gradient into\&. .RE .PP .SS "template const arma::vec& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Lambda () const\fC [inline]\fP" .PP Get the Lagrange multipliers\&. .PP Definition at line 98 of file aug_lagrangian_function\&.hpp\&. .SS "template arma::vec& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Lambda ()\fC [inline]\fP" .PP Modify the Lagrange multipliers\&. .PP Definition at line 100 of file aug_lagrangian_function\&.hpp\&. .SS "template double \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Sigma () const\fC [inline]\fP" .PP Get sigma (the penalty parameter)\&. .PP Definition at line 103 of file aug_lagrangian_function\&.hpp\&. .SS "template double& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::Sigma ()\fC [inline]\fP" .PP Modify sigma (the penalty parameter)\&. .PP Definition at line 105 of file aug_lagrangian_function\&.hpp\&. .SS "template std::string \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::ToString () const" .SH "Member Data Documentation" .PP .SS "template LagrangianFunction& \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::function\fC [private]\fP" .PP Instantiation of the function to be optimized\&. .PP Definition at line 117 of file aug_lagrangian_function\&.hpp\&. .SS "template arma::vec \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::lambda\fC [private]\fP" .PP The Lagrange multipliers\&. .PP Definition at line 120 of file aug_lagrangian_function\&.hpp\&. .PP Referenced by mlpack::optimization::AugLagrangianFunction< mlpack::optimization::LRSDPFunction >::Lambda()\&. .SS "template double \fBmlpack::optimization::AugLagrangianFunction\fP< LagrangianFunction >::sigma\fC [private]\fP" .PP The penalty parameter\&. .PP Definition at line 122 of file aug_lagrangian_function\&.hpp\&. .PP Referenced by mlpack::optimization::AugLagrangianFunction< mlpack::optimization::LRSDPFunction >::Sigma()\&. .SH "Author" .PP Generated automatically by Doxygen for MLPACK from the source code\&.