LinearComboFunction Class Reference

Linear Combination of Two Function !! More...

Inheritance diagram for LinearComboFunction:

Public Member Functions

 LinearComboFunction ()
 Standard constructor.
 
 LinearComboFunction (double w1, OutputFunction *f, double w2, OutputFunction *g)
 Construct a Linear Combination of two functions.
 
virtual ~LinearComboFunction ()
 Destructor.
 
virtual void apply (DoubleVector &inputs, DoubleVector &outputs)
 Implement the updating method
it computes: y <- w1*first(input,output) + w2*second(input,outputs)
 
virtual void clusterSetted ()
 recursive call setCluster on first and second function setted
 
virtual void configure (ConfigurationParameters &params, QString prefix)
 Configures the object using a ConfigurationParameters object.
 
OutputFunctiongetFirstFunction ()
 Return the first function of LinearComboFunction.
 
double getFirstWeight ()
 Return the first weight of LinearComboFunction.
 
OutputFunctiongetSecondFunction ()
 Return the second function of CompositeFunction.
 
double getSecondWeight ()
 Return the second weight of LinearComboFunction.
 
virtual void save (ConfigurationParameters &params, QString prefix)
 Save the actual status of parameters into the ConfigurationParameters object passed.
 
bool setFirstFunction (OutputFunction *f)
 Set the first function of LinearComboFunction.
 
bool setFirstWeight (double v)
 Set the first weight of LinearComboFunction.
 
bool setSecondFunction (OutputFunction *g)
 Set the second function of CompositeFunction.
 
bool setSecondWeight (double v)
 Set the second weight of LinearComboFunction.
 
- Public Member Functions inherited from OutputFunction
 OutputFunction ()
 Constructor.
 
virtual ~OutputFunction ()
 Destructor.
 
double apply (double input)
 Calculate the outputs of a single neuron.
 
virtual bool derivate (const DoubleVector &inputs, const DoubleVector &outputs, DoubleVector &derivates) const
 Compute the derivate of the function represent
Given the input of neurons and the corresponding output of neurons, it calculate the derivate.
 
void setCluster (Cluster *cl)
 Set the Cluster which it is inserted
This is automatically called, and in normal case you don't have to call it directly.
 
- Public Member Functions inherited from ParameterSettableWithConfigureFunction
void addObserver (RuntimeParameterObserver *obs)
 
getRuntimeParameter (QString paramName)
 
virtual ParameterSettableUIgetUIManager ()
 
 ParameterSettable ()
 
virtual void postConfigureInitialization ()
 
void removeObserver (RuntimeParameterObserver *obs)
 
void setRuntimeParameter (QString paramName, T newvalue)
 
QString typeName () const
 
- Public Member Functions inherited from ParameterSettable
void addObserver (RuntimeParameterObserver *obs)
 
getRuntimeParameter (QString paramName)
 
void removeObserver (RuntimeParameterObserver *obs)
 
void setRuntimeParameter (QString paramName, T newvalue)
 
QString typeName () const
 

Additional Inherited Members

- Public Types inherited from ParameterSettableWithConfigureFunction
enum  Property
 
- Static Public Member Functions inherited from ParameterSettableWithConfigureFunction
static void describe (QString type)
 
static QString fullParameterDescriptionPath (QString type, QString param)
 
static QString fullSubgroupDescriptionPath (QString type, QString sub)
 
- Public Attributes inherited from ParameterSettableWithConfigureFunction
 AllowMultiple
 
 Default
 
 IsList
 
 IsMandatory
 
- Static Public Attributes inherited from ParameterSettableWithConfigureFunction
static const double Infinity
 
static const int MaxInteger
 
static const int MinInteger
 
- Protected Member Functions inherited from ParameterSettableWithConfigureFunction
void notifyChangesToParam (QString paramName)
 
- Static Protected Member Functions inherited from ParameterSettableWithConfigureFunction
static Descriptor addTypeDescription (QString type, QString shortHelp, QString longHelp=QString(""))
 
static void setGraphicalEditor (QString type)
 
- Protected Attributes inherited from OutputFunction
Clusterclusterv
 Cluster on which the OutputFunction is inserted.
 

Detailed Description

Linear Combination of Two Function !!

Note
Component OutputFunction objects are destroyed by the LinearComboFunction object to which they belong.

Definition at line 553 of file liboutputfunctions.h.

Constructor & Destructor Documentation

Standard constructor.

Definition at line 679 of file liboutputfunctions.cpp.

LinearComboFunction ( double  w1,
OutputFunction f,
double  w2,
OutputFunction g 
)

Construct a Linear Combination of two functions.

Definition at line 686 of file liboutputfunctions.cpp.

~LinearComboFunction ( )
virtual

Destructor.

Definition at line 692 of file liboutputfunctions.cpp.

Member Function Documentation

void apply ( DoubleVector inputs,
DoubleVector outputs 
)
virtual

Implement the updating method
it computes: y <- w1*first(input,output) + w2*second(input,outputs)

Implements OutputFunction.

Definition at line 696 of file liboutputfunctions.cpp.

void clusterSetted ( )
virtual

recursive call setCluster on first and second function setted

Reimplemented from OutputFunction.

Definition at line 742 of file liboutputfunctions.cpp.

References OutputFunction::clusterv, Cluster::numNeurons(), and DoubleVector::resize().

void configure ( ConfigurationParameters params,
QString  prefix 
)
virtual

Configures the object using a ConfigurationParameters object.

Parameters
paramsthe configuration parameters object with parameters to use
prefixthe prefix to use to access the object configuration parameters. This is guaranteed to end with the separator character when called by the factory, so you don't need to add one

Implements ParameterSettableWithConfigureFunction.

Definition at line 748 of file liboutputfunctions.cpp.

References ConfigurationParameters::getObjectFromParameter(), and ConfigurationParameters::getValue().

OutputFunction * getFirstFunction ( )

Return the first function of LinearComboFunction.

Definition at line 710 of file liboutputfunctions.cpp.

double getFirstWeight ( )

Return the first weight of LinearComboFunction.

Definition at line 719 of file liboutputfunctions.cpp.

OutputFunction * getSecondFunction ( )

Return the second function of CompositeFunction.

Definition at line 729 of file liboutputfunctions.cpp.

double getSecondWeight ( )

Return the second weight of LinearComboFunction.

Definition at line 738 of file liboutputfunctions.cpp.

void save ( ConfigurationParameters params,
QString  prefix 
)
virtual

Save the actual status of parameters into the ConfigurationParameters object passed.

Parameters
paramsthe configuration parameters object on which save actual parameters
prefixthe prefix to use to access the object configuration parameters.

Implements ParameterSettableWithConfigureFunction.

Definition at line 780 of file liboutputfunctions.cpp.

References ConfigurationParameters::createParameter(), and ConfigurationParameters::startObjectParameters().

bool setFirstFunction ( OutputFunction f)

Set the first function of LinearComboFunction.

Definition at line 704 of file liboutputfunctions.cpp.

References OutputFunction::clusterv.

bool setFirstWeight ( double  v)

Set the first weight of LinearComboFunction.

Definition at line 714 of file liboutputfunctions.cpp.

bool setSecondFunction ( OutputFunction g)

Set the second function of CompositeFunction.

Definition at line 723 of file liboutputfunctions.cpp.

References OutputFunction::clusterv.

bool setSecondWeight ( double  v)

Set the second weight of LinearComboFunction.

Definition at line 733 of file liboutputfunctions.cpp.


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