Open CASCADE Technology
7.1.0.beta
|
Given two distinct initial points, BracketMinimum implements the computation of three points (a, b, c) which bracket the minimum of the function and verify A less than B, B less than C and F(A) less than F(B), F(B) less than (C). More...
#include <math_BracketMinimum.hxx>
Public Member Functions | |
math_BracketMinimum (math_Function &F, const Standard_Real A, const Standard_Real B) | |
Given two initial values this class computes a bracketing triplet of abscissae Ax, Bx, Cx (such that Bx is between Ax and Cx, F(Bx) is less than both F(Bx) and F(Cx)) the Brent minimization is done on the function F. More... | |
math_BracketMinimum (math_Function &F, const Standard_Real A, const Standard_Real B, const Standard_Real FA) | |
Given two initial values this class computes a bracketing triplet of abscissae Ax, Bx, Cx (such that Bx is between Ax and Cx, F(Bx) is less than both F(Bx) and F(Cx)) the Brent minimization is done on the function F. This constructor has to be used if F(A) is known. More... | |
math_BracketMinimum (math_Function &F, const Standard_Real A, const Standard_Real B, const Standard_Real FA, const Standard_Real FB) | |
Given two initial values this class computes a bracketing triplet of abscissae Ax, Bx, Cx (such that Bx is between Ax and Cx, F(Bx) is less than both F(Bx) and F(Cx)) the Brent minimization is done on the function F. This constructor has to be used if F(A) and F(B) are known. More... | |
Standard_Boolean | IsDone () const |
Returns true if the computations are successful, otherwise returns false. More... | |
void | Values (Standard_Real &A, Standard_Real &B, Standard_Real &C) const |
Returns the bracketed triplet of abscissae. Exceptions StdFail_NotDone if the algorithm fails (and IsDone returns false). More... | |
void | FunctionValues (Standard_Real &FA, Standard_Real &FB, Standard_Real &FC) const |
returns the bracketed triplet function values. Exceptions StdFail_NotDone if the algorithm fails (and IsDone returns false). More... | |
void | Dump (Standard_OStream &o) const |
Prints on the stream o information on the current state of the object. Is used to redefine the operator <<. More... | |
Protected Member Functions | |
void | Perform (math_Function &F, const Standard_Real A, const Standard_Real B) |
Is used internally by the constructors. More... | |
Given two distinct initial points, BracketMinimum implements the computation of three points (a, b, c) which bracket the minimum of the function and verify A less than B, B less than C and F(A) less than F(B), F(B) less than (C).
math_BracketMinimum::math_BracketMinimum | ( | math_Function & | F, |
const Standard_Real | A, | ||
const Standard_Real | B | ||
) |
Given two initial values this class computes a bracketing triplet of abscissae Ax, Bx, Cx (such that Bx is between Ax and Cx, F(Bx) is less than both F(Bx) and F(Cx)) the Brent minimization is done on the function F.
math_BracketMinimum::math_BracketMinimum | ( | math_Function & | F, |
const Standard_Real | A, | ||
const Standard_Real | B, | ||
const Standard_Real | FA | ||
) |
Given two initial values this class computes a bracketing triplet of abscissae Ax, Bx, Cx (such that Bx is between Ax and Cx, F(Bx) is less than both F(Bx) and F(Cx)) the Brent minimization is done on the function F. This constructor has to be used if F(A) is known.
math_BracketMinimum::math_BracketMinimum | ( | math_Function & | F, |
const Standard_Real | A, | ||
const Standard_Real | B, | ||
const Standard_Real | FA, | ||
const Standard_Real | FB | ||
) |
Given two initial values this class computes a bracketing triplet of abscissae Ax, Bx, Cx (such that Bx is between Ax and Cx, F(Bx) is less than both F(Bx) and F(Cx)) the Brent minimization is done on the function F. This constructor has to be used if F(A) and F(B) are known.
void math_BracketMinimum::Dump | ( | Standard_OStream & | o | ) | const |
Prints on the stream o information on the current state of the object. Is used to redefine the operator <<.
void math_BracketMinimum::FunctionValues | ( | Standard_Real & | FA, |
Standard_Real & | FB, | ||
Standard_Real & | FC | ||
) | const |
returns the bracketed triplet function values. Exceptions StdFail_NotDone if the algorithm fails (and IsDone returns false).
Standard_Boolean math_BracketMinimum::IsDone | ( | ) | const |
Returns true if the computations are successful, otherwise returns false.
|
protected |
Is used internally by the constructors.
void math_BracketMinimum::Values | ( | Standard_Real & | A, |
Standard_Real & | B, | ||
Standard_Real & | C | ||
) | const |
Returns the bracketed triplet of abscissae. Exceptions StdFail_NotDone if the algorithm fails (and IsDone returns false).