All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends Macros Pages
Public Member Functions | List of all members
paal::local_search::gain_cut_small_improves< Gain, ValueType > Class Template Reference

This is the gain adapter which accepts gains improving the current solution by more than epsilon. This adapter should be used only when ChooseFirstBetter strategy is applied. More...

#include <custom_components.hpp>

Public Member Functions

 gain_cut_small_improves (Gain gain, ValueType currOpt, double epsilon)
 Constructor,. More...
 
template<typename... Args>
ValueType operator() (Args &&...args)
 transfers arguments to original gain, if the value is to small it is changed to 0. More...
 
void set_epsilon (double e)
 sets epsilon More...
 
void set_current_opt (ValueType opt)
 sets current Opt More...
 

Detailed Description

template<typename Gain, typename ValueType>
class paal::local_search::gain_cut_small_improves< Gain, ValueType >

This is the gain adapter which accepts gains improving the current solution by more than epsilon. This adapter should be used only when ChooseFirstBetter strategy is applied.

Template Parameters
Gain
ValueType

Definition at line 96 of file custom_components.hpp.

Constructor & Destructor Documentation

template<typename Gain , typename ValueType >
paal::local_search::gain_cut_small_improves< Gain, ValueType >::gain_cut_small_improves ( Gain  gain,
ValueType  currOpt,
double  epsilon 
)
inline

Constructor,.

Parameters
gain- original gain functor
currOpt- current optimum
epsilon- gain limit, gains smaller than epsilon * currOpt are cut

Definition at line 105 of file custom_components.hpp.

Member Function Documentation

template<typename Gain , typename ValueType >
template<typename... Args>
ValueType paal::local_search::gain_cut_small_improves< Gain, ValueType >::operator() ( Args &&...  args)
inline

transfers arguments to original gain, if the value is to small it is changed to 0.

Template Parameters
Args
Parameters
args
Returns

Definition at line 117 of file custom_components.hpp.

template<typename Gain , typename ValueType >
void paal::local_search::gain_cut_small_improves< Gain, ValueType >::set_current_opt ( ValueType  opt)
inline

sets current Opt

Parameters
opt

Definition at line 138 of file custom_components.hpp.

template<typename Gain , typename ValueType >
void paal::local_search::gain_cut_small_improves< Gain, ValueType >::set_epsilon ( double  e)
inline

sets epsilon

Parameters
e

Definition at line 131 of file custom_components.hpp.


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