#include <APPSPACK_Point.hpp>
Collaboration diagram for APPSPACK::Point:
A trial point contains an x-vector either waiting to be evaluated or that is already evaluated. Each Point is unique and has an associated unique tag. Copying is disallowed.
Definition at line 54 of file APPSPACK_Point.hpp.
Public Types | |
enum | State { Unevaluated, Infeasible, CachedInsufficientDecrease, Cached, EvaluatedInsufficientDecrease, Evaluated } |
The evaluation state of the trial point. More... | |
Public Member Functions | |
Constructors | |
Point (const Vector &x_in, const Value &f_in, double step_in, double alpha_in) | |
Point (const Vector &x_in, double step_in, const Point &parent, int idx_in) | |
Destructors | |
~Point () | |
Accessors | |
const Vector & | getX () const |
const Value & | getF () const |
int | getTag () const |
int | getParentTag () const |
int | getIndex () const |
double | getStep () const |
Manipulators | |
void | setCachedFunctionValue (const Value &f_in, const string &msg_in) |
void | setEvaluatedFunctionValue (const Value &f_in, const string &msg_in) |
void | setInfeasible () |
Comparisons | |
bool | operator< (const Point &other) const |
Printing | |
ostream & | leftshift (ostream &stream) const |
Print out the point to the given stream. | |
Private Member Functions | |
void | operator= (const Point &source) |
Disallowed. | |
Point (const Point &source) | |
Disallow copy constructor. | |
bool | isSufficientDecrease () const |
Check for sufficient decrease as compared to the parent's function value. | |
Private Attributes | |
const Vector | x |
The x vector. | |
Value | f |
The function value, f(x). | |
const int | tag |
Integer tag value. | |
const double | step |
The step that was used to create this point. | |
string | msg |
Message string. | |
const int | parentTag |
Integer tag of parent. | |
const int | idx |
Index of corresponding direction. | |
const Value | parentValue |
Parent function value. | |
const double | alpha |
Value of the sufficient decrease parameter. | |
const double | rho |
Value of ![]() | |
State | state |
Trial point state. | |
Static Private Attributes | |
int | staticCount = 0 |
Static counter used to generate unique tags. |
|
The evaluation state of the trial point.
|
|
Construct a trial point with no parent. This constructor is only used for the initial guess.
References staticCount, and APPSPACK::Vector. |
|
Construct a trial point with a parent.
References staticCount, and APPSPACK::Vector. |
|
Destructor Definition at line 76 of file APPSPACK_Point.cpp. |
|
Disallow copy constructor.
|
|
Return x. Needed for extracting points to send to user function evaluator. Definition at line 80 of file APPSPACK_Point.cpp. References APPSPACK::Vector, and x. Referenced by APPSPACK::Directions::computeNewDirections(), APPSPACK::Conveyor::exchange(), APPSPACK::Solver::generateTrialPoints(), and APPSPACK::Solver::getBestX(). |
|
Return f(x). Definition at line 85 of file APPSPACK_Point.cpp. References f. Referenced by APPSPACK::Solver::getBestF(), APPSPACK::Solver::isBestF(), and APPSPACK::Solver::processNewBestPoint(). |
|
Get the tag of this trial point. Definition at line 89 of file APPSPACK_Point.cpp. References tag. Referenced by APPSPACK::Conveyor::exchange(), APPSPACK::Solver::generateTrialPoints(), and APPSPACK::Solver::processEvaluatedTrialPoints(). |
|
Get parent's tag. Definition at line 94 of file APPSPACK_Point.cpp. References parentTag. Referenced by APPSPACK::Solver::processEvaluatedTrialPoints(). |
|
Get index of direction the generated this trial point. Definition at line 99 of file APPSPACK_Point.cpp. References idx. Referenced by APPSPACK::Solver::processEvaluatedTrialPoints(). |
|
Return the step associated with this trial point. Definition at line 104 of file APPSPACK_Point.cpp. References step. Referenced by APPSPACK::Directions::computeNewDirections(). |
|
Store the cached function value in f. Automatically checks for sufficient decrease and sets state appropriately. Definition at line 109 of file APPSPACK_Point.cpp. References Cached, CachedInsufficientDecrease, f, isSufficientDecrease(), msg, and state. Referenced by APPSPACK::Conveyor::exchange(). |
|
Store the evaluated function value in f. Automatically checks for sufficient decrease and sets state appropriately. Definition at line 116 of file APPSPACK_Point.cpp. References Evaluated, EvaluatedInsufficientDecrease, f, isSufficientDecrease(), msg, and state. Referenced by APPSPACK::Conveyor::exchange(). |
|
The trial point is infeasbile. Set state appropriately. Definition at line 123 of file APPSPACK_Point.cpp. References Infeasible, and state. |
|
Basically, the evaluation is based on comparing the two function values. To complicate matters, however, we may not have to valid function values, which leads to all sorts of special cases. Further, if two different points have equal function values, we break ties based on the tag. We apply the following logic, in order, to determine if this point is less than the other.
|
|
Print out the point to the given stream. Definition at line 165 of file APPSPACK_Point.cpp. References f, APPSPACK::Print::formatPositiveDouble(), msg, state, step, tag, and x. Referenced by operator<<(). |
|
Disallowed.
|
|
Check for sufficient decrease as compared to the parent's function value. Definition at line 155 of file APPSPACK_Point.cpp. References f, APPSPACK::Value::isSufficientDecrease(), parentValue, and rho. Referenced by setCachedFunctionValue(), and setEvaluatedFunctionValue(). |
|
Static counter used to generate unique tags. Definition at line 41 of file APPSPACK_Point.cpp. Referenced by Point(). |
|
The x vector. Definition at line 227 of file APPSPACK_Point.hpp. Referenced by getX(), and leftshift(). |
|
The function value, f(x). Definition at line 230 of file APPSPACK_Point.hpp. Referenced by getF(), isSufficientDecrease(), leftshift(), operator<(), setCachedFunctionValue(), and setEvaluatedFunctionValue(). |
|
Integer tag value. Definition at line 233 of file APPSPACK_Point.hpp. Referenced by getTag(), leftshift(), and operator<(). |
|
The step that was used to create this point. Definition at line 236 of file APPSPACK_Point.hpp. Referenced by getStep(), and leftshift(). |
|
Message string. Definition at line 239 of file APPSPACK_Point.hpp. Referenced by leftshift(), setCachedFunctionValue(), and setEvaluatedFunctionValue(). |
|
Integer tag of parent.
Referenced by getParentTag(). |
|
Index of corresponding direction. Definition at line 246 of file APPSPACK_Point.hpp. Referenced by getIndex(). |
|
Parent function value. Definition at line 249 of file APPSPACK_Point.hpp. Referenced by isSufficientDecrease(). |
|
Value of the sufficient decrease parameter. This is used in the calculation of rho. This value is set in the Point constructors. A user specified value may be provided by specifying the the "Sufficient Decrease Factor" parameter in the Parameter::List passed to APPSPACK::Solver::Solver(); see Solver Parameters. Definition at line 260 of file APPSPACK_Point.hpp. |
|
Value of The amount of decrease required is given by,
Here Referenced by isSufficientDecrease(). |
|
Trial point state. Definition at line 273 of file APPSPACK_Point.hpp. Referenced by leftshift(), operator<(), setCachedFunctionValue(), setEvaluatedFunctionValue(), and setInfeasible(). |
© Sandia Corporation | Site Contact | Privacy and Security
Generated on Wed Dec 14 18:41:05 2005 for APPSPACK 4.0.2 by
1.3.8 written by Dimitri van Heesch,
© 1997-2002