Minotaur 0.4.1
Docs for developers
Glob.h
Go to the documentation of this file.
1//
2// Minotaur -- It's only 1/2 bull
3//
4// (C)opyright 2009 - 2025 The Minotaur Team.
5//
6
13#ifndef GLOB_H
14#define GLOB_H
15
16#include "AMPLInterface.h"
17#include "BranchAndBound.h"
18#include "Brancher.h"
19#include "NLPEngine.h"
20#include "Presolver.h"
21#include "Solver.h"
22#include "Types.h"
23
24namespace Minotaur
25{
30class Glob : public Solver
31{
32public:
34 Glob(EnvPtr env);
35
37 ~Glob();
38
40 void doSetup();
41
43 void showHelp() const;
44
46 int showInfo();
47
49 virtual int solve(ProblemPtr p);
50
52 virtual SolveStatus getStatus();
53
55 virtual DoubleVector getSolution();
56
57 // virtual SolutionPtr getSol() {return sol_;};
58 virtual SolutionPtr getSol() {return sol_;};
60 double getUb();
61
63 double getLb();
64
65private:
66 const static std::string me_;
67 double objSense_;
68 ProblemPtr inst_;
69 ProblemPtr newp_;
70 SolveStatus status_;
71 SolutionPtr sol_;
72
73 BranchAndBound* createBab_(EnginePtr e, HandlerVector& handlers);
74 PresolverPtr createPres_(HandlerVector& handlers);
75 void fwd2Bnb_(VarVector *orig_v);
76 void fwd2QG_();
77 BrancherPtr getBrancher_(HandlerVector handlers, Engine* e);
78 LPEnginePtr getEngine_();
79 NLPEnginePtr getNLPEngine_();
80 void setInitialOptions_();
81 int transform_(ProblemPtr& newp, HandlerVector& handlers, LPEnginePtr engine);
82 void writeStatus_(BranchAndBound* bab);
83};
84} // namespace Minotaur
85#endif
Declare the AMPLInterface class fo reading problems from AMPL.
Declare the BranchAndBound class for branch-and-bound-algorithm, BabStats class for statistics and Ba...
Declare the base class Brancher for finding and creating branches in Branch-and-Bound.
Declare NLPEngine Class for solving nonlinear problems using a nonlinear solver.
Declare Presolver class for presolving.
Define the abstract base class Solver.
Declare important 'types' used in Minotaur.
Implement a generic branch-and-bound algorithm on a single cpu.
Definition: BranchAndBound.h:38
A brancher is used to find suitable branches for a given node. e.g. LexicoBrancher....
Definition: Brancher.h:33
Definition: Engine.h:34
Definition: Environment.h:28
Definition: Glob.h:31
virtual int solve(ProblemPtr p)
Solve the problem.
Definition: Glob.cpp:334
virtual DoubleVector getSolution()
get status of the last solve.
Definition: Glob.cpp:309
void showHelp() const
show help messages
Definition: Glob.cpp:510
double getUb()
Return the upper bound for the optimal value.
Glob(EnvPtr env)
Default constructor.
Definition: Glob.cpp:59
virtual SolveStatus getStatus()
get status of the last solve.
Definition: Glob.cpp:315
~Glob()
Destroy.
Definition: Glob.cpp:70
virtual SolutionPtr getSol()
get solution of the last solve
Definition: Glob.h:58
void doSetup()
Starting setup for glob.
Definition: Glob.cpp:77
int showInfo()
Display information.
Definition: Glob.cpp:523
double getLb()
Return the lower bound for the optimal value.
Definition: LPEngine.h:29
Definition: NLPEngine.h:37
Definition: Presolver.h:39
Definition: Problem.h:74
Definition: Solution.h:30
Definition: Solver.h:28
Definition: ActiveNodeStore.h:20
SolveStatus
Different states an algorithm like branch-and-bound can be in.
Definition: Types.h:158

Minotaur source code documented by Doxygen 1.9.4 on Mon Aug 4 2025