source: trunk/Cbc/src/CbcSubProblem.hpp @ 1899

Last change on this file since 1899 was 1899, checked in by stefan, 5 years ago

fixup svn properties

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.2 KB
Line 
1// $Id: CbcSubProblem.hpp 1899 2013-04-09 18:12:08Z stefan $
2// Copyright (C) 2002, International Business Machines
3// Corporation and others.  All Rights Reserved.
4// This code is licensed under the terms of the Eclipse Public License (EPL).
5
6// Edwin 11/10/2009-- carved out of CbcBranchActual
7
8#ifndef CbcSubProblem_H
9#define CbcSubProblem_H
10
11#ifdef COIN_HAS_CLP
12#include "ClpSimplex.hpp"
13#include "ClpNode.hpp"
14
15/** Defines a general subproblem
16    Basis will be made more compact later
17*/
18class CoinWarmStartDiff;
19class CbcSubProblem {
20
21public:
22
23    /// Default constructor
24    CbcSubProblem ();
25
26    /// Constructor from model
27    CbcSubProblem (const OsiSolverInterface * solver,
28                   const double * lowerBefore,
29                   const double * upperBefore,
30                   const unsigned char * status,
31                   int depth);
32
33    /// Copy constructor
34    CbcSubProblem ( const CbcSubProblem &);
35
36    /// Assignment operator
37    CbcSubProblem & operator= (const CbcSubProblem& rhs);
38
39    /// Destructor
40    virtual ~CbcSubProblem ();
41
42    /// Take over
43  void takeOver ( CbcSubProblem &, bool cleanup);
44    /// Apply subproblem (1=bounds, 2=basis, 3=both)
45    void apply(OsiSolverInterface * model, int what = 3) const;
46
47public:
48    /// Value of objective
49    double objectiveValue_;
50    /// Sum of infeasibilities
51    double sumInfeasibilities_;
52    /// Branch value
53    double branchValue_;
54    /// Dj on branching variable at end
55    double djValue_;
56    /** Which variable (top bit if upper bound changing)
57        next bit if changing on down branch only */
58    int * variables_;
59    /// New bound
60    double * newBounds_;
61    /// Status
62    mutable CoinWarmStartBasis * status_;
63    /// Depth
64    int depth_;
65    /// Number of Extra bound changes
66    int numberChangedBounds_;
67    /// Number of infeasibilities
68    int numberInfeasibilities_;
69    /** Status 1 bit going up on first, 2 bit set first branch infeasible on second, 4 bit redundant branch,
70        bits after 256 give reason for stopping (just last node)
71        0 - solution
72        1 - infeasible
73        2 - maximum depth
74        >2 - error or max time or something
75    */
76    int problemStatus_;
77    /// Variable branched on
78    int branchVariable_;
79};
80
81#endif //COIN_HAS_CLP
82#endif
83
Note: See TracBrowser for help on using the repository browser.