18 #ifndef __itkPowellOptimizer_h
19 #define __itkPowellOptimizer_h
85 itkSetMacro(Maximize,
bool);
86 itkBooleanMacro(Maximize);
87 itkGetConstReferenceMacro(Maximize,
bool);
91 itkSetMacro(MaximumIteration,
unsigned int);
92 itkGetConstReferenceMacro(MaximumIteration,
unsigned int);
96 itkSetMacro(MaximumLineIteration,
unsigned int);
97 itkGetConstMacro(MaximumLineIteration,
unsigned int);
102 itkSetMacro(StepLength,
double);
103 itkGetConstReferenceMacro(StepLength,
double);
108 itkSetMacro(StepTolerance,
double);
109 itkGetConstReferenceMacro(StepTolerance,
double);
115 itkSetMacro(ValueTolerance,
double);
116 itkGetConstReferenceMacro(ValueTolerance,
double);
120 itkGetConstReferenceMacro(CurrentCost,
MeasureType);
125 itkGetConstReferenceMacro(CurrentIteration,
unsigned int);
128 itkGetConstReferenceMacro(CurrentLineIteration,
unsigned int);
131 void StartOptimization();
136 void StopOptimization()
139 itkGetConstReferenceMacro(CatchGetValueException,
bool);
140 itkSetMacro(CatchGetValueException,
bool);
142 itkGetConstReferenceMacro(MetricWorstPossibleValue,
double);
143 itkSetMacro(MetricWorstPossibleValue,
double);
145 const std::string GetStopConditionDescription()
const;
151 void PrintSelf(std::ostream & os,
Indent indent)
const;
153 itkSetMacro(CurrentCost,
double);
157 void SetLine(
const ParametersType & origin,
163 double GetLineValue(
double x)
const;
165 double GetLineValue(
double x, ParametersType & tempCoord)
const;
169 void SetCurrentLinePoint(
double x,
double fx);
173 void Swap(
double *a,
double *b)
const;
177 void Shift(
double *a,
double *b,
double *c,
double d)
const;
188 virtual void LineBracket(
double *ax,
double *bx,
double *cx,
189 double *fa,
double *fb,
double *fc);
191 virtual void LineBracket(
double *ax,
double *bx,
double *cx,
192 double *fa,
double *fb,
double *fc,
193 ParametersType & tempCoord);
200 virtual void BracketedLineOptimize(
double ax,
double bx,
double cx,
201 double fa,
double fb,
double fc,
202 double *extX,
double *extVal);
204 virtual void BracketedLineOptimize(
double ax,
double bx,
double cx,
205 double fa,
double fb,
double fc,
206 double *extX,
double *extVal,
207 ParametersType & tempCoord);
209 itkGetMacro(SpaceDimension,
unsigned int);
210 void SetSpaceDimension(
unsigned int dim)
212 this->m_SpaceDimension = dim;
213 this->m_LineDirection.set_size(dim);
214 this->m_LineOrigin.set_size(dim);
215 this->m_CurrentPosition.set_size(dim);
219 itkSetMacro(CurrentIteration,
unsigned int);
221 itkGetMacro(Stop,
bool);
222 itkSetMacro(Stop,
bool);