Last change
on this file since 2104 was
1573,
checked in by lou, 9 years ago
|
Change to EPL license notice.
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Author Date Id Revision
|
File size:
1.4 KB
|
Line | |
---|
1 | /* $Id: CbcFeasibilityBase.hpp 1573 2011-01-05 01:12:36Z forrest $ */ |
---|
2 | // Copyright (C) 2005, 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 | #ifndef CbcFeasibilityBase_H |
---|
7 | #define CbcFeasibilityBase_H |
---|
8 | |
---|
9 | |
---|
10 | //############################################################################# |
---|
11 | /* There are cases where the user wants to control how CBC sees the problems feasibility. |
---|
12 | The user may want to examine the problem and say : |
---|
13 | a) The default looks OK |
---|
14 | b) Pretend this problem is Integer feasible |
---|
15 | c) Pretend this problem is infeasible even though it looks feasible |
---|
16 | |
---|
17 | This simple class allows user to do that. |
---|
18 | |
---|
19 | */ |
---|
20 | |
---|
21 | class CbcModel; |
---|
22 | class CbcFeasibilityBase { |
---|
23 | public: |
---|
24 | // Default Constructor |
---|
25 | CbcFeasibilityBase () {} |
---|
26 | |
---|
27 | /** |
---|
28 | On input mode: |
---|
29 | 0 - called after a solve but before any cuts |
---|
30 | -1 - called after strong branching |
---|
31 | Returns : |
---|
32 | 0 - no opinion |
---|
33 | -1 pretend infeasible |
---|
34 | 1 pretend integer solution |
---|
35 | */ |
---|
36 | virtual int feasible(CbcModel * , int ) { |
---|
37 | return 0; |
---|
38 | } |
---|
39 | |
---|
40 | virtual ~CbcFeasibilityBase() {} |
---|
41 | |
---|
42 | // Copy constructor |
---|
43 | CbcFeasibilityBase ( const CbcFeasibilityBase & ) {} |
---|
44 | |
---|
45 | // Assignment operator |
---|
46 | CbcFeasibilityBase & operator=( const CbcFeasibilityBase& ) { |
---|
47 | return *this; |
---|
48 | } |
---|
49 | |
---|
50 | /// Clone |
---|
51 | virtual CbcFeasibilityBase * clone() const { |
---|
52 | return new CbcFeasibilityBase(*this); |
---|
53 | } |
---|
54 | }; |
---|
55 | #endif |
---|
56 | |
---|
Note: See
TracBrowser
for help on using the repository browser.