Definition: ObjectiveFunction.h:43
Definition: Optimiser.h:31
std::shared_ptr< ObjectiveFunction > objectiveFunction
Shared pointer to the objective function.
Definition: Optimiser.h:122
PrecisionType * GetBestPoint()
Definition: Optimiser.cpp:105
std::string outputIntermediateGradientFolder
Folder to which the intermediated objective function gradients will be saved.
Definition: Optimiser.h:128
const unsigned int maxNumberOfLineIterations
The maximum number of iterations used for the line-serach along the gradient.
Definition: Optimiser.h:117
void MoveCurrentPointAlongGradient(PrecisionType stepSize)
Definition: Optimiser.cpp:140
unsigned int numberOfDOFs
The number of degrees of freedom.
Definition: Optimiser.h:121
PrecisionType * currentPoint
The current point, p in numerical recipes.
Definition: Optimiser.h:124
float PrecisionType
Definition: Optimiser.h:33
unsigned int currentIterationNumber
Tracker of the current iteration number.
Definition: Optimiser.h:115
PrecisionType currentObjectiveFunctionValue
The current objective function value corresponding to the current iteration.
Definition: Optimiser.h:112
PrecisionType * gradient
The array xi in numerical recipes.
Definition: Optimiser.h:123
PrecisionType * bestPoint
The best point achieved, p in numerical recipes.
Definition: Optimiser.h:125
PrecisionType bestObjectiveFunctionValue
The best objective function value achieved.
Definition: Optimiser.h:113
unsigned int maxNumberOfIterations
The maximum number of allowed iterations.
Definition: Optimiser.h:116
PrecisionType GetBestObjectiveFunctionValue()
Definition: Optimiser.cpp:83
PrecisionType maxLineSearchStepSize
The maximum step size used for the line-search. Has to be initialised in derived class.
Definition: Optimiser.h:118
void SetObjectiveFunction(std::shared_ptr< ObjectiveFunction > &objectiveFunctionIn)
Definition: Optimiser.cpp:72
PrecisionType initialObjectiveFunctionValue
The objective function value at the starting point of the optimisation.
Definition: Optimiser.h:114
bool usePreEvaluatedEvaluatedObjectiveFunctionValue
Indicator if the first objective function value calculation can be skipped.
Definition: Optimiser.h:127
PrecisionType minLineSearchStepSize
The minimum step size used for the line-search. Has to be initialised in derived class.
Definition: Optimiser.h:119
void SetOutputIntermediateGradientFolder(const std::string &outputFolderIn, const std::string &outPrefix)
Definition: Optimiser.h:88
virtual ~Optimiser()
Definition: Optimiser.cpp:59
void SetPreviouslyEvaluatedObjectiveFunctionValue(PrecisionType objectiveFunctionValue)
Definition: Optimiser.cpp:128
unsigned int numberOfIterationsPerformed
The total number of iterations performed.
Definition: Optimiser.h:120
void SetMaxIterations(unsigned int maxIterations)
Definition: Optimiser.h:76
virtual void Initialise()=0
virtual void Optimise(PrecisionType *startingPoint)=0
void PerformLineSearch(PrecisionType maxLength, PrecisionType smallLength, PrecisionType &startLength)
Definition: Optimiser.cpp:157
PrecisionType preEvaluatedObjectiveFunctionValue
A pre-calculated objective function value that will be used during the optimisation if usePreEvaluate...
Definition: Optimiser.h:126
PrecisionType GetInitialObjectiveFunctionValue()
Definition: Optimiser.cpp:95
void ResetCurrentIterationNumber()
Definition: Optimiser.cpp:116
std::string outputIntermediateGradientPrefix
String holding additional information to differentiate the output from different levels.
Definition: Optimiser.h:129
Optimiser()
Definition: Optimiser.cpp:32