#include <BonFilterSolver.hpp>
Classes | |
struct | cachedInfo |
Cached information for reoptimizing. More... | |
class | UnsolvedFilterError |
Public Types | |
typedef FilterTypes::fint | fint |
Fortran type for integer used in filter. More... | |
typedef FilterTypes::real | real |
Fortran type for double.used in filter. More... | |
![]() | |
enum | ReturnStatus { iterationLimit = -3, timeLimit = 5, doesNotConverge = -8, computationError = -2, notEnoughFreedom = -1, illDefinedProblem = -4, illegalOption =-5, externalException =-6, exception =-7, solvedOptimal = 1, solvedOptimalTol =2, provenInfeasible =3, unbounded = 4, numReturnCodes } |
Standard return statuses for a solver. More... | |
Public Member Functions | |
virtual UnsolvedError * | newUnsolvedError (int num, Ipopt::SmartPtr< TMINLP2TNLP > problem, std::string name) |
FilterSolver (bool createEmpty=false) | |
Default constructor. More... | |
FilterSolver (Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions, Ipopt::SmartPtr< Ipopt::OptionsList > options, Ipopt::SmartPtr< Ipopt::Journalist > journalist, const std::string &prefix) | |
Constructor with passed journalist, roptions, options. More... | |
FilterSolver (Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions, Ipopt::SmartPtr< Ipopt::OptionsList > options, Ipopt::SmartPtr< Ipopt::Journalist > journalist) | |
Constructor with passed journalist, roptions, options. More... | |
FilterSolver (const FilterSolver &other) | |
Copy constructor. More... | |
virtual | ~FilterSolver () |
destructor More... | |
virtual bool | Initialize (std::string params_file) |
Initialize the TNLPSolver (read options from params_file) More... | |
virtual bool | Initialize (std::istream &is) |
Initialize the TNLPSolver (read options from istream is) More... | |
virtual Ipopt::SmartPtr < TNLPSolver > | clone () |
Virtual copy constructor. More... | |
virtual double | CPUTime () |
Get the CpuTime of the last optimization. More... | |
virtual int | IterationCount () |
Get the iteration count of the last optimization. More... | |
virtual void | setOutputToDefault () |
turn off all output from the solver More... | |
virtual void | forceSolverOutput (int log_level) |
turn on all output from the solver More... | |
virtual std::string & | solverName () |
Get the solver name. More... | |
void | registerOptions () |
Register this solver options into passed roptions. More... | |
virtual int | errorCode () const |
Error code (solver specific). More... | |
Solve methods | |
virtual ReturnStatus | OptimizeTNLP (const Ipopt::SmartPtr< Ipopt::TNLP > &tnlp) |
Solves a problem expresses as a TNLP. More... | |
virtual ReturnStatus | ReOptimizeTNLP (const Ipopt::SmartPtr< Ipopt::TNLP > &tnlp) |
Resolves a problem expresses as a TNLP. More... | |
virtual bool | setWarmStart (const CoinWarmStart *warm, Ipopt::SmartPtr< TMINLP2TNLP > tnlp) |
Set the warm start in the solver. More... | |
virtual CoinWarmStart * | getUsedWarmStart (Ipopt::SmartPtr< TMINLP2TNLP > tnlp) const |
Get warm start used in last optimization. More... | |
virtual CoinWarmStart * | getWarmStart (Ipopt::SmartPtr< TMINLP2TNLP > tnlp) const |
Get the warm start form the solver. More... | |
virtual CoinWarmStart * | getEmptyWarmStart () const |
Solves a problem expresses as a TNLP. More... | |
virtual bool | warmStartIsValid (const CoinWarmStart *ws) const |
Check that warm start object is valid. More... | |
virtual void | enableWarmStart () |
Solves a problem expresses as a TNLP. More... | |
virtual void | disableWarmStart () |
Solves a problem expresses as a TNLP. More... | |
![]() | |
TNLPSolver () | |
default Constructor More... | |
TNLPSolver (Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions, Ipopt::SmartPtr< Ipopt::OptionsList > options, Ipopt::SmartPtr< Ipopt::Journalist > journalist, const std::string &prefix) | |
Constructor with options initialization. More... | |
virtual | ~TNLPSolver () |
Virtual destructor. More... | |
Ipopt::SmartPtr < Ipopt::Journalist > | journalist () |
Get a pointer to a journalist. More... | |
Ipopt::SmartPtr < Bonmin::RegisteredOptions > | roptions () |
Get a pointer to RegisteredOptions (generally used to add new ones) More... | |
Ipopt::SmartPtr< const Ipopt::OptionsList > | options () const |
Get the options (for getting their values). More... | |
Ipopt::SmartPtr < Ipopt::OptionsList > | options () |
Get the options (for getting and setting their values). More... | |
const char * | prefix () |
Get the prefix. More... | |
bool | isRecoverable (ReturnStatus &r) |
Say if an optimization status for a problem which failed is recoverable (problem may be solvable). More... | |
void | setup_global_time_limit (double time_limit) |
Setup for a global time limit for solver. More... | |
bool | isError (ReturnStatus &r) |
Say if return status is an error. More... | |
Static Public Member Functions | |
static void | registerOptions (Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions) |
Register this solver options into passed roptions. More... | |
![]() | |
static void | RegisterOptions (Ipopt::SmartPtr< Bonmin::RegisteredOptions > roptions) |
Register this solver options into passed roptions. More... | |
Private Member Functions | |
Private function members. | |
TNLPSolver::ReturnStatus | callOptimizer () |
Perform optimization using data structure in cache. More... | |
Static Private Member Functions | |
static void | TMat2RowPMat (bool symmetric, fint n, fint m, int nnz, const Ipopt::Index *iRow, const Ipopt::Index *iCol, int *permutation2, fint *lws, int nnz_offset, int n_offset, Ipopt::TNLP::IndexStyleEnum index_style) |
Converting TMatrices into row-ordered matrices. More... | |
Private Attributes | |
Coin::SmartPtr< FilterWarmStart > | warmF_ |
Coin::SmartPtr< cachedInfo > | cached_ |
Cached information on last problem optimized for reoptimization. More... | |
int | default_log_level_ |
To record default log level. More... | |
Static Private Attributes | |
static std::string | solverName_ = "filter SQP" |
Friends | |
struct | BqpdSolver::cachedInfo |
Additional Inherited Members | |
![]() | |
bool | zeroDimension (const Ipopt::SmartPtr< Ipopt::TNLP > &tnlp, ReturnStatus &optimization_status) |
Determine if problem is of dimension zero and if it is check if solution is feasible. More... | |
void | initializeOptionsAndJournalist () |
Initializes options and journalist. More... | |
TNLPSolver (const TNLPSolver &other) | |
Copy Constructor. More... | |
![]() | |
Ipopt::SmartPtr < Ipopt::Journalist > | journalist_ |
Storage of Journalist for output. More... | |
Ipopt::SmartPtr < Ipopt::OptionsList > | options_ |
List of Options. More... | |
Ipopt::SmartPtr < Bonmin::RegisteredOptions > | roptions_ |
Registered Options. More... | |
std::string | prefix_ |
Prefix to use for reading bonmin's options. More... | |
double | start_time_ |
Global start time. More... | |
double | time_limit_ |
Global time limit. More... | |
int | default_log_level_ |
To record default log level. More... | |
Definition at line 20 of file BonFilterSolver.hpp.
Fortran type for integer used in filter.
Definition at line 46 of file BonFilterSolver.hpp.
Fortran type for double.used in filter.
Definition at line 48 of file BonFilterSolver.hpp.
Bonmin::FilterSolver::FilterSolver | ( | bool | createEmpty = false | ) |
Default constructor.
Definition at line 270 of file BonFilterSolver.cpp.
Bonmin::FilterSolver::FilterSolver | ( | Ipopt::SmartPtr< Bonmin::RegisteredOptions > | roptions, |
Ipopt::SmartPtr< Ipopt::OptionsList > | options, | ||
Ipopt::SmartPtr< Ipopt::Journalist > | journalist, | ||
const std::string & | prefix | ||
) |
Constructor with passed journalist, roptions, options.
Definition at line 277 of file BonFilterSolver.cpp.
Bonmin::FilterSolver::FilterSolver | ( | Ipopt::SmartPtr< Bonmin::RegisteredOptions > | roptions, |
Ipopt::SmartPtr< Ipopt::OptionsList > | options, | ||
Ipopt::SmartPtr< Ipopt::Journalist > | journalist | ||
) |
Constructor with passed journalist, roptions, options.
Definition at line 286 of file BonFilterSolver.cpp.
Bonmin::FilterSolver::FilterSolver | ( | const FilterSolver & | other | ) |
Copy constructor.
Definition at line 295 of file BonFilterSolver.cpp.
|
virtual |
destructor
Definition at line 310 of file BonFilterSolver.cpp.
|
inlinevirtual |
Implements Bonmin::TNLPSolver.
Definition at line 51 of file BonFilterSolver.hpp.
|
virtual |
Initialize the TNLPSolver (read options from params_file)
Implements Bonmin::TNLPSolver.
Definition at line 314 of file BonFilterSolver.cpp.
|
virtual |
Initialize the TNLPSolver (read options from istream is)
Implements Bonmin::TNLPSolver.
Definition at line 343 of file BonFilterSolver.cpp.
|
virtual |
Solves a problem expresses as a TNLP.
Implements Bonmin::TNLPSolver.
Definition at line 364 of file BonFilterSolver.cpp.
|
virtual |
Resolves a problem expresses as a TNLP.
Solves a problem expressed as a TNLP.
Implements Bonmin::TNLPSolver.
Definition at line 375 of file BonFilterSolver.cpp.
|
virtual |
Set the warm start in the solver.
Implements Bonmin::TNLPSolver.
Definition at line 738 of file BonFilterSolver.cpp.
|
inlinevirtual |
Get warm start used in last optimization.
Implements Bonmin::TNLPSolver.
Definition at line 102 of file BonFilterSolver.hpp.
|
virtual |
Get the warm start form the solver.
Implements Bonmin::TNLPSolver.
Definition at line 759 of file BonFilterSolver.cpp.
|
virtual |
Solves a problem expresses as a TNLP.
Implements Bonmin::TNLPSolver.
Definition at line 767 of file BonFilterSolver.cpp.
|
virtual |
Check that warm start object is valid.
Implements Bonmin::TNLPSolver.
Definition at line 775 of file BonFilterSolver.cpp.
|
inlinevirtual |
Solves a problem expresses as a TNLP.
Implements Bonmin::TNLPSolver.
Definition at line 118 of file BonFilterSolver.hpp.
|
inlinevirtual |
Solves a problem expresses as a TNLP.
Implements Bonmin::TNLPSolver.
Definition at line 121 of file BonFilterSolver.hpp.
|
virtual |
Virtual copy constructor.
Implements Bonmin::TNLPSolver.
Definition at line 304 of file BonFilterSolver.cpp.
|
inlinevirtual |
Get the CpuTime of the last optimization.
Implements Bonmin::TNLPSolver.
Definition at line 132 of file BonFilterSolver.hpp.
|
inlinevirtual |
Get the iteration count of the last optimization.
Implements Bonmin::TNLPSolver.
Definition at line 138 of file BonFilterSolver.hpp.
|
inlinevirtual |
turn off all output from the solver
Implements Bonmin::TNLPSolver.
Definition at line 144 of file BonFilterSolver.hpp.
turn on all output from the solver
Implements Bonmin::TNLPSolver.
Definition at line 149 of file BonFilterSolver.hpp.
|
inlinevirtual |
Get the solver name.
Implements Bonmin::TNLPSolver.
Definition at line 155 of file BonFilterSolver.hpp.
|
inline |
Register this solver options into passed roptions.
Definition at line 161 of file BonFilterSolver.hpp.
|
inlinevirtual |
Error code (solver specific).
Implements Bonmin::TNLPSolver.
Definition at line 167 of file BonFilterSolver.hpp.
|
static |
Register this solver options into passed roptions.
Definition at line 247 of file BonFilterSolver.cpp.
|
private |
Perform optimization using data structure in cache.
Solves a problem expresses as a TNLP.
Definition at line 574 of file BonFilterSolver.cpp.
|
staticprivate |
Converting TMatrices into row-ordered matrices.
Definition at line 173 of file BonFilterSolver.cpp.
|
friend |
Definition at line 24 of file BonFilterSolver.hpp.
|
private |
Definition at line 179 of file BonFilterSolver.hpp.
|
private |
Cached information on last problem optimized for reoptimization.
Definition at line 333 of file BonFilterSolver.hpp.
|
staticprivate |
Definition at line 336 of file BonFilterSolver.hpp.
|
private |
To record default log level.
Definition at line 339 of file BonFilterSolver.hpp.