TransformedObjectiveFunction Class Reference

objective function with a linear transformation applied to the search space $ R^n $ More...

#include <ObjectiveFunction.h>

Inheritance diagram for TransformedObjectiveFunction:

ObjectiveFunctionVS< double > ObjectiveFunctionT< T * > ObjectiveFunction Cigar CIGTAB1 DiffPowRotated ELLI1 Paraboloid RosenbrockRotated SchwefelEllipsoidRotated Tablet Twoaxis

List of all members.

Public Member Functions

 TransformedObjectiveFunction (ObjectiveFunctionVS< double > &base, unsigned d=0)
 Constructor.
 TransformedObjectiveFunction (ObjectiveFunctionVS< double > &base, const Array< double > &transformation)
 Constructor.
 ~TransformedObjectiveFunction ()
 Destructor.
void init (const Array< double > &transformation)
 Explicitly set the transformation.
void initRandomRotation (unsigned d=0)
 Create a random orthogonal transformation.
const Matrix & Transformation () const
 Retreive the transformation matrix.
void result (const Array< double > &point, std::vector< double > &value)
 objective function evaluation
void result (const std::vector< double > &point, std::vector< double > &value)
 objective function evaluation
void result (double *const &point, std::vector< double > &value)
 objective function evaluation
bool ProposeStartingPoint (double *&point) const
 propose a transformed starting point
void transform (Array< double > &point) const
 point is multiplied with m_Transformation
void transform (std::vector< double > &point) const
 point is multiplied with m_Transformation
void transform (double *point) const
 point is multiplied with m_Transformation
bool utopianFitness (std::vector< double > &value) const
 call to utopianFitness of the base objective function
bool nadirFitness (std::vector< double > &value) const
 call to nadirFitness of the base objective function
unsigned int objectives () const
 return the number of objectives to optimize

Protected Member Functions

void transform (const double *in, std::vector< double > &out) const
 transform in, resulting in out
void transformInverse (const std::vector< double > &in, double *out) const
 inverse transform in, resulting in out

Protected Attributes

ObjectiveFunctionVS< double > & baseObjective
 non-transformed objective function
Matrix m_Transformation
 transformation matrix


Detailed Description

objective function with a linear transformation applied to the search space $ R^n $

This specialized class represents an objective function with a linear transformation of the search vector space.

Definition at line 425 of file ObjectiveFunction.h.


Constructor & Destructor Documentation

TransformedObjectiveFunction::TransformedObjectiveFunction ( ObjectiveFunctionVS< double > &  base,
unsigned  d = 0 
)

Constructor.

Definition at line 141 of file ObjectiveFunction.cpp.

References initRandomRotation().

TransformedObjectiveFunction::TransformedObjectiveFunction ( ObjectiveFunctionVS< double > &  base,
const Array< double > &  transformation 
)

TransformedObjectiveFunction::~TransformedObjectiveFunction (  ) 

Destructor.

Definition at line 156 of file ObjectiveFunction.cpp.


Member Function Documentation

void TransformedObjectiveFunction::init ( const Array< double > &  transformation  ) 

Explicitly set the transformation.

Definition at line 161 of file ObjectiveFunction.cpp.

References baseObjective, ObjectiveFunctionVS< T >::init(), ObjectiveFunctionVS< double >::m_dimension, and m_Transformation.

Referenced by TransformedObjectiveFunction().

void TransformedObjectiveFunction::initRandomRotation ( unsigned  d = 0  ) 

bool TransformedObjectiveFunction::nadirFitness ( std::vector< double > &  value  )  const [virtual]

call to nadirFitness of the base objective function

Reimplemented from ObjectiveFunctionVS< double >.

Definition at line 222 of file ObjectiveFunction.cpp.

References baseObjective, and ObjectiveFunctionVS< T >::nadirFitness().

unsigned int TransformedObjectiveFunction::objectives (  )  const [virtual]

return the number of objectives to optimize

Implements ObjectiveFunction.

Reimplemented in ELLI1, and CIGTAB1.

Definition at line 227 of file ObjectiveFunction.cpp.

References baseObjective, and ObjectiveFunction::objectives().

bool TransformedObjectiveFunction::ProposeStartingPoint ( double *&  point  )  const

propose a transformed starting point

Reimplemented in ELLI1, and CIGTAB1.

Examples:
SchwefelEllipsoidCMSA.cpp.

Definition at line 205 of file ObjectiveFunction.cpp.

References baseObjective, ObjectiveFunctionVS< double >::m_dimension, and transformInverse().

void TransformedObjectiveFunction::result ( double *const &  point,
std::vector< double > &  value 
)

objective function evaluation

Definition at line 198 of file ObjectiveFunction.cpp.

References baseObjective, ObjectiveFunctionVS< double >::m_dimension, ObjectiveFunction::m_timesCalled, and transform().

void TransformedObjectiveFunction::result ( const std::vector< double > &  point,
std::vector< double > &  value 
) [inline]

objective function evaluation

Definition at line 453 of file ObjectiveFunction.h.

References ObjectiveFunctionVS< double >::m_dimension, and result().

void TransformedObjectiveFunction::result ( const Array< double > &  point,
std::vector< double > &  value 
) [inline]

objective function evaluation

Definition at line 446 of file ObjectiveFunction.h.

References ObjectiveFunctionVS< double >::m_dimension.

Referenced by result().

void TransformedObjectiveFunction::transform ( const double *  in,
std::vector< double > &  out 
) const [protected]

transform in, resulting in out

Definition at line 232 of file ObjectiveFunction.cpp.

References ObjectiveFunctionVS< double >::m_dimension, and m_Transformation.

void TransformedObjectiveFunction::transform ( double *  point  )  const [inline]

point is multiplied with m_Transformation

Definition at line 484 of file ObjectiveFunction.h.

References ObjectiveFunctionVS< double >::m_dimension, and transform().

void TransformedObjectiveFunction::transform ( std::vector< double > &  point  )  const [inline]

point is multiplied with m_Transformation

Definition at line 475 of file ObjectiveFunction.h.

References ObjectiveFunctionVS< double >::m_dimension, and transform().

void TransformedObjectiveFunction::transform ( Array< double > &  point  )  const [inline]

point is multiplied with m_Transformation

Definition at line 466 of file ObjectiveFunction.h.

References ObjectiveFunctionVS< double >::m_dimension.

Referenced by result(), and transform().

const Matrix& TransformedObjectiveFunction::Transformation (  )  const [inline]

Retreive the transformation matrix.

Definition at line 443 of file ObjectiveFunction.h.

References m_Transformation.

void TransformedObjectiveFunction::transformInverse ( const std::vector< double > &  in,
double *  out 
) const [protected]

inverse transform in, resulting in out

Definition at line 242 of file ObjectiveFunction.cpp.

References ObjectiveFunctionVS< double >::m_dimension, and m_Transformation.

Referenced by ProposeStartingPoint().

bool TransformedObjectiveFunction::utopianFitness ( std::vector< double > &  value  )  const [virtual]

call to utopianFitness of the base objective function

Reimplemented from ObjectiveFunctionVS< double >.

Definition at line 217 of file ObjectiveFunction.cpp.

References baseObjective, and ObjectiveFunctionVS< T >::utopianFitness().


Member Data Documentation

non-transformed objective function

Definition at line 508 of file ObjectiveFunction.h.

Referenced by init(), initRandomRotation(), nadirFitness(), objectives(), ProposeStartingPoint(), result(), TransformedObjectiveFunction(), and utopianFitness().


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