ConstrainedOptPack::VariableBoundsTester Class Reference

Tests that a set of variables are within their bounds. More...

#include <ConstrainedOptPack_VariableBoundsTester.hpp>

List of all members.

Public Member Functions

 STANDARD_MEMBER_COMPOSITION_MEMBERS (value_type, warning_tol)
 
 STANDARD_MEMBER_COMPOSITION_MEMBERS (value_type, error_tol)
 
 VariableBoundsTester (value_type warning_tol=1e-10, value_type error_tol=1e-5)
 
virtual ~VariableBoundsTester ()
 
virtual bool check_in_bounds (std::ostream *out, bool print_all_warnings, bool print_vectors, const Vector &xL, const char xL_name[], const Vector &xU, const char xU_name[], const Vector &x, const char x_name[])
 Check that the variables are within bounds.

Detailed Description

Tests that a set of variables are within their bounds.

    xL <= x <= xU
  

The relative error for each comparison is rel_err(i) = (xL(i)-x(i))/(1+||x||inf) or rel_err(i) = (x(i)-xU(i))/(1+||x||inf). If rel_err(i) >= error_tol, then the tests will be terminated immediately. All of the rel_err(i) >= warning_tol will be printed.

Definition at line 49 of file ConstrainedOptPack_VariableBoundsTester.hpp.


Constructor & Destructor Documentation

ConstrainedOptPack::VariableBoundsTester::VariableBoundsTester ( value_type  warning_tol = 1e-10,
value_type  error_tol = 1e-5 
)

Definition at line 34 of file ConstrainedOptPack_VariableBoundsTester.cpp.

virtual ConstrainedOptPack::VariableBoundsTester::~VariableBoundsTester (  )  [inline, virtual]

Definition at line 65 of file ConstrainedOptPack_VariableBoundsTester.hpp.


Member Function Documentation

ConstrainedOptPack::VariableBoundsTester::STANDARD_MEMBER_COMPOSITION_MEMBERS ( value_type  ,
warning_tol   
)

ConstrainedOptPack::VariableBoundsTester::STANDARD_MEMBER_COMPOSITION_MEMBERS ( value_type  ,
error_tol   
)

bool ConstrainedOptPack::VariableBoundsTester::check_in_bounds ( std::ostream *  out,
bool  print_all_warnings,
bool  print_vectors,
const Vector xL,
const char  xL_name[],
const Vector xU,
const char  xU_name[],
const Vector x,
const char  x_name[] 
) [virtual]

Check that the variables are within bounds.

Parameters:
print_all_warnings [in] If true, then all errors greater than warning_tol will be printed.
xL [in] Sparse lower bound vector (xL.size()==x.size())
xL_name [in] The name of the vector xL (null terminated string).
xU [in] Sparse upper bound vector (xU.size()==x.size())
xU_name [in] The name of the vector xU (null terminated string).
x [in] Variable to test that it is in bounds.
x_name [in] The name of the vector x (null terminated string).
Returns:
true if all of the errors are greater than the error tolerances, otherwise it returns false

Definition at line 42 of file ConstrainedOptPack_VariableBoundsTester.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Generated on Wed Apr 13 10:17:36 2011 for MOOCHO (Single Doxygen Collection) by  doxygen 1.6.3