Unfit  3.1.1
Data fitting and optimization software
Public Member Functions | List of all members
Unfit::UnitTests::SampleCostFunction7 Class Reference

#include <NelderMeadTestFunctions.hpp>

Inheritance diagram for Unfit::UnitTests::SampleCostFunction7:
Unfit::GenericCostFunction

Public Member Functions

std::vector< double > operator() (const std::vector< double > &x)
 
- Public Member Functions inherited from Unfit::GenericCostFunction
virtual ~GenericCostFunction ()
 

Detailed Description

The Sample function 7 is defined as

1/((x-1.05)yz)

Number of dimensions = 3 Global minimum does not exist Initial guess is thus not required

Reference: nil

Member Function Documentation

◆ operator()()

std::vector<double> Unfit::UnitTests::SampleCostFunction7::operator() ( const std::vector< double > &  x)
inlinevirtual

We overload the operator as is required in GenericCostFunction to calculate the cost of the Sample function 7 as defined above.

Behaviour: cost = 1/(x-1.05)(yz)

Intended use : SampleCostFunction7 func; double cost = func(const std::vector<double> x);

NOTE that the returned cost is the sqare root of the evaluation due to the fact the Nelder Mead class will square the cost.

Parameters:

Parameters
x(input) vector containing values of the four variables
Returns
cost

Implements Unfit::GenericCostFunction.


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