00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #include "CouenneFixPoint.hpp"
00012 #include <string>
00013
00014 using namespace Couenne;
00015
00017 CouenneFixPoint::CouenneFixPoint (CouenneProblem *p,
00018 const Ipopt::SmartPtr<Ipopt::OptionsList> options):
00019 problem_ (p),
00020 firstCall_ (true),
00021 CPUtime_ (0.),
00022 nTightened_ (0),
00023 perfIndicator_ (p, "Fixed Point LP") {
00024
00025 std::string s;
00026 options -> GetStringValue ("fixpoint_bt_model", s, "couenne.");
00027 extendedModel_ = (s == "extended");
00028 }
00029
00030
00032 CouenneFixPoint::CouenneFixPoint (const CouenneFixPoint &rhs):
00033 extendedModel_ (rhs.extendedModel_),
00034 problem_ (rhs.problem_),
00035 firstCall_ (rhs.firstCall_),
00036 CPUtime_ (rhs.CPUtime_),
00037 nTightened_ (rhs.nTightened_),
00038 perfIndicator_ (rhs.perfIndicator_) {}
00039
00040
00042 CouenneFixPoint::~CouenneFixPoint () {}
00043
00044
00046 void CouenneFixPoint::registerOptions (Ipopt::SmartPtr <Bonmin::RegisteredOptions> roptions) {
00047
00048 roptions -> AddLowerBoundedIntegerOption
00049 ("fixpoint_bt",
00050 "The frequency (in terms of nodes) at which Fix Point Bound Tightening is performed.",
00051 -99, 0,
00052 "A frequency of 0 (default) means these cuts are never generated. "
00053 "Any positive number n instructs Couenne to generate them at every n nodes of the B&B tree. "
00054 "A negative number -n means that generation should be attempted at the root node, and if successful it can be repeated at every n nodes, otherwise it is stopped altogether."
00055 );
00056
00057 roptions -> AddStringOption2
00058 ("fixpoint_bt_model",
00059 "Choose whether to add an extended fixpoint LP model or a more compact one.",
00060 "compact",
00061 "extended", "Extended model with variables for lower/upper bounds of right-hand sides (see paper by Belotti, Cafieri, Lee, Liberti)",
00062 "compact", "Compact equivalent model obtained by projecting lower/upper bounds of rhs",
00063 "The \"extended\" option is for debugging purposes; the compact formulation is equivalent and this option should be used");
00064 }