47 namespace ConstrainedOptPack {
55 :warning_tol_(warning_tol)
56 ,error_tol_(error_tol)
60 std::ostream*
out,
bool print_all_warnings,
bool print_vectors
61 ,
const Vector& xL,
const char xL_name[]
62 ,
const Vector& xU,
const char xU_name[]
63 ,
const Vector& x,
const char x_name[]
70 <<
"\n*** Checking that variables are in bounds\n";
72 VectorSpace::vec_mut_ptr_t zero = x.space().create_member(0.0);
73 std::pair<value_type,value_type>
77 *out <<
"\nWarning! the variables " << xL_name <<
" <= " << x_name <<
" <= " << xU_name
78 <<
" are out of bounds by more than warning_tol = " << warning_tol() <<
"\n";
82 *out <<
"\nError! the variables " << xL_name <<
" <= " << x_name <<
" <= " << xU_name
83 <<
" are out of bounds by more than error_tol = " << error_tol() <<
"\n";
VariableBoundsTester(value_type warning_tol=1e-10, value_type error_tol=1e-5)
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.
std::pair< value_type, value_type > max_near_feas_step(const Vector &x, const Vector &d, const Vector &xl, const Vector &xu, value_type max_bnd_viol)
Computes the maximum positive and negative step that can be taken that are within the relaxed bounds...
AbstractLinAlgPack::value_type value_type
const f_int f_dbl_prec const f_int f_int const f_int f_int const f_dbl_prec & u