MLPACK
1.0.11
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
src
mlpack
core
optimizers
aug_lagrangian
aug_lagrangian_function.hpp
Go to the documentation of this file.
1
22
#ifndef __MLPACK_CORE_OPTIMIZERS_AUG_LAGRANGIAN_AUG_LAGRANGIAN_FUNCTION_HPP
23
#define __MLPACK_CORE_OPTIMIZERS_AUG_LAGRANGIAN_AUG_LAGRANGIAN_FUNCTION_HPP
24
25
#include <
mlpack/core.hpp
>
26
27
namespace
mlpack {
28
namespace
optimization {
29
47
template
<
typename
LagrangianFunction>
48
class
AugLagrangianFunction
49
{
50
public
:
58
AugLagrangianFunction
(LagrangianFunction&
function
);
59
68
AugLagrangianFunction
(LagrangianFunction&
function
,
69
const
arma::vec&
lambda
,
70
const
double
sigma
);
79
double
Evaluate
(
const
arma::mat& coordinates)
const
;
80
87
void
Gradient
(
const
arma::mat& coordinates, arma::mat& gradient)
const
;
88
95
const
arma::mat&
GetInitialPoint
()
const
;
96
98
const
arma::vec&
Lambda
()
const
{
return
lambda
; }
100
arma::vec&
Lambda
() {
return
lambda
; }
101
103
double
Sigma
()
const
{
return
sigma
; }
105
double
&
Sigma
() {
return
sigma
; }
106
108
const
LagrangianFunction&
Function
()
const
{
return
function
; }
110
LagrangianFunction&
Function
() {
return
function
; }
111
112
// convert the obkect into a string
113
std::string
ToString
()
const
;
114
115
private
:
117
LagrangianFunction&
function
;
118
120
arma::vec
lambda
;
122
double
sigma
;
123
};
124
125
};
// namespace optimization
126
};
// namespace mlpack
127
128
// Include basic implementation.
129
#include "aug_lagrangian_function_impl.hpp"
130
131
#endif // __MLPACK_CORE_OPTIMIZERS_AUG_LAGRANGIAN_AUG_LAGRANGIAN_FUNCTION_HPP
132
Generated by
1.8.3.1