LTI-Lib latest version v1.9 - last update 10 Apr 2010

lti::linearKernel Class Reference

This class defines a linear kernel functor. More...

#include <ltiLinearKernel.h>

Inheritance diagram for lti::linearKernel:
Inheritance graph
[legend]
Collaboration diagram for lti::linearKernel:
Collaboration graph
[legend]

List of all members.

Classes

class  parameters
 the parameters for the class distanceFunctor More...

Public Member Functions

 linearKernel ()
 linearKernel (const linearKernel &other)
virtual const char * getTypeName () const
virtual double apply (const vector< double > &a, const vector< double > &b) const
virtual functorclone () const
const parametersgetParameters () const

Detailed Description

This class defines a linear kernel functor.

It is the simplest possible kernel, and returns the scalar product of the two vectors (i.e. k(x,y) = x.dot(y)).

This mainly serves as a example kernel function. For solving really relevant problems, you need more complex functions.


Constructor & Destructor Documentation

lti::linearKernel::linearKernel (  ) 

default constructor

lti::linearKernel::linearKernel ( const linearKernel other  ) 

copy constructor

Parameters:
other the object to be copied

Member Function Documentation

virtual double lti::linearKernel::apply ( const vector< double > &  a,
const vector< double > &  b 
) const [virtual]

calculate the distance between the vectors a and b

Parameters:
a the first vector<T>
b the second vector<T>
Returns:
the kernel function value of the vectors

Implements lti::kernelFunctor< double >.

virtual functor* lti::linearKernel::clone (  )  const [virtual]

returns a pointer to a clone of this functor.

Reimplemented from lti::kernelFunctor< double >.

const parameters& lti::linearKernel::getParameters (  )  const

returns used parameters

Reimplemented from lti::kernelFunctor< double >.

virtual const char* lti::linearKernel::getTypeName (  )  const [virtual]

returns the name of this type ("linearKernel")

Reimplemented from lti::kernelFunctor< double >.


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

Generated on Sat Apr 10 15:26:52 2010 for LTI-Lib by Doxygen 1.6.1