source: stable/2.6/Cbc/README @ 2464

Last change on this file since 2464 was 353, checked in by andreasw, 13 years ago

added warning that information might be out of date

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.0 KB
Line 
1NOTE: The information in this file might not yet include the changes introduced with the switch to the autotools.
2
3To build Cbc see INSTALL file
4
5To use Cbc you need the Cbc, Cgl, Coin and Osi libraries.  You
6will probably need Clp as well.
7
8If you are using Clp as your solver then you can make the unitTest and standalone executable by doing
9
10make solve in this directory.  This creates an executable solve.
11
12solve takes various options - try solve and then ? to get some idea of what you can do.
13solve file will do branch and bound if file is integer mps file and will do dual if non-integer mps file
14options start with - (although the code will also try without -) e.g.
15
16solve file -cuts root -solve will import file and do branch and bound with cuts only at root
17
18- by itself goes to interactive mode.
19
20If you wish to use the Cbc solver from AMPL there is a bit of work involved.  You
21will need to uncomment COIN_ampl in Makefiles/makefile.location - and also
22download the ampl glue code - see Makefiles/Makefile.location for http.  Then solve
23will assume it is being called from AMPL if the first two arguments are xxx.nl -AMPL.
24Of course "solve" is not a good name (cbc is much better but already used) so copy
25"solve" to "cbc" in ampl accessible path.
26Options may be set by e.g. option cbc_options "cuts=off log=0"
27No keywords are recognized by ampl parsing so above format should be used.
28All options are as found by "cbc(solve) " and then ?
29Current ugliness is that ampl glue code assumes "=" (on undefined keywords) so to maximize you
30would have to say "maximize=".  I will add to AMPL keywords if this interface gets much use.
31
32If you are not using Clp then fewer options are available -
33make the unitTest and standalone executable by doing
34
35make unitTest in this directory.  This creates an executable cbc.
36
37Running cbc gives you some hints.  Just do
38
39cbc -
40 
41and then try ? or setting various stuff.
42
43On Linux cbc can do file completion and line editing. 
44
45There are samples in ./Samples.  Use make DRIVER=xxxxxx where xxxxxx.cpp is driver file to
46create an executable - testit.
47
48The two simplest samples are:
49
50sample.cpp  This is a simple program to read an mps file.and solve the
51                integer problem.
52
53sample2.cpp.  This is the benchmark driver for the competition.  It overrides
54                the default branching methods and adds a (mildly useless)
55                heuristic.  It is intended to show you how to add your
56                own methods.  See CbcCompareUser.hpp for how to modify
57                choice of node from tree.  See CbcBranchUser.?pp for
58                how to modify which variable is chosen at a node.  For
59                more complex stuff such as new types of branches see
60                CbcBranchBase and CbcBranchActual in directory Cbc.
61                To see how to add heuristics see CbcHeuristicUser.?pp.
62
63                To add cut generators - define them as in Cgl and then just
64                add them as in sample2.cpp
65
66                The script "runtimes" in Samples directory will
67                run some or all of test set.  The version checked in
68                does some - just take off # to run.  An optional time
69                in minutes can be passed.
70
71
72
Note: See TracBrowser for help on using the repository browser.