Ignore:
Timestamp:
May 10, 2005 11:40:19 AM (14 years ago)
Author:
rlh
Message:

updated the user guide

File:
1 edited

Legend:

Unmodified
Added
Removed
  • html/trunk/Cbc/ch03s04.html

    r554 r557  
    1 <html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>Advanced use of solver</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"><link rel="home" href="index.html" title="CBC User Guide"><link rel="up" href="ch03.html" title="Chapter 3. 
    2   Other Classes and examples
    3   "><link rel="previous" href="ch03s03.html" title="Branching"><link rel="next" href="ch04.html" title="Chapter 4. 
    4   Building and Modifying a Model
    5   "></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Advanced use of solver</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch03s03.html">Prev</a> </td><th width="60%" align="center">Chapter 3. 
    6   Other Classes and examples
    7   </th><td width="20%" align="right"> <a accesskey="n" href="ch04.html">Next</a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="solver"></a>Advanced use of solver</h2></div></div><div></div></div><p>
     1<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
     2<html xmlns="http://www.w3.org/1999/xhtml"><head><title>Advanced use of solver</title><meta name="generator" content="DocBook XSL Stylesheets V1.61.2"/><link rel="home" href="index.html" title="CBC User Guide"/><link rel="up" href="ch03.html" title="Chapter 3. &#10;  Other Classes and Examples&#10;  "/><link rel="previous" href="ch03s03.html" title="Branching"/><link rel="next" href="ch04.html" title="Chapter 4. &#10;  Building and Modifying a Model&#10;  "/></head><body><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Advanced use of solver</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch03s03.html">Prev</a> </td><th width="60%" align="center">Chapter 3. 
     3  Other Classes and Examples
     4  </th><td width="20%" align="right"> <a accesskey="n" href="ch04.html">Next</a></td></tr></table><hr/></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="solver"/>Advanced use of solver</h2></div></div><div/></div><p>
    85  Coin Branch and Cut uses a generic OsiSolverInterface and its <tt class="function">resolve</tt> capability.
    96  This does not give much flexibility so advanced users can inherit from the interface
     
    1411   <tt class="filename">CbcSolver2.cpp</tt>
    1512  (this code can be found in the CBC Samples directory, see
    16   <a href="ch05.html" title="Chapter 5. 
    17 More Samples
    18 ">Chapter 5, <i>
     13  <a href="ch05.html" title="Chapter 5. &#10;More Samples&#10;">Chapter 5, <i>
    1914More Samples
    2015</i></a>).
     
    2217  this is a simpler place to start.  The example derives from OsiClpSolverInterface and the code
    2318  is:
    24   </p><div class="example"><a name="id2903439"></a><p class="title"><b>Example 3.10. initialSolve</b></p><pre class="programlisting">
     19  </p><div class="example"><a id="id3369462"/><p class="title"><b>Example 3.10. initialSolve</b></p><pre class="programlisting">
    2520   
    2621  // modelPtr_ is of type ClpSimplex *
     
    4237a variable was active in a solution.  For the first few times normal dual is called and
    4338node_ array is updated.
    44 </p><div class="example"><a name="id2903488"></a><p class="title"><b>Example 3.11. First few solves</b></p><pre class="programlisting">
     39</p><div class="example"><a id="id3369511"/><p class="title"><b>Example 3.11. First few solves</b></p><pre class="programlisting">
    4540   
    4641  if (count_&lt;10) {
     
    6459solves.  As fast0507 is a set covering problem we can also take out any rows which are
    6560already covered.
    66   </p><div class="example"><a name="id2903514"></a><p class="title"><b>Example 3.12. Create small problem</b></p><pre class="programlisting">
     61  </p><div class="example"><a id="id3369538"/><p class="title"><b>Example 3.12. Create small problem</b></p><pre class="programlisting">
    6762   
    6863    int * whichRow = new int[numberRows]; // Array to say which rows used
     
    163158then we see if there are any negative reduced costs and if there are then we have to go to the
    164159full problem and use primal to clean up.
    165   </p><div class="example"><a name="id2903555"></a><p class="title"><b>Example 3.13. Check optimal solution</b></p><pre class="programlisting">
     160  </p><div class="example"><a id="id3369578"/><p class="title"><b>Example 3.13. Check optimal solution</b></p><pre class="programlisting">
    166161   
    167162    temp-&gt;setDualObjectiveLimit(1.0e50); // Switch off dual cutoff as problem is restricted
     
    219214   <tt class="filename">ClpQuadInterface.cpp</tt>
    220215  (this code can be found in the CBC Samples directory, see
    221   <a href="ch05.html" title="Chapter 5. 
    222 More Samples
    223 ">Chapter 5, <i>
     216  <a href="ch05.html" title="Chapter 5. &#10;More Samples&#10;">Chapter 5, <i>
    224217More Samples
    225218</i></a>).
    226   </p><div class="example"><a name="id2903598"></a><p class="title"><b>Example 3.14. Solve a quadratic mip</b></p><pre class="programlisting">
     219  </p><div class="example"><a id="id3369621"/><p class="title"><b>Example 3.14. Solve a quadratic mip</b></p><pre class="programlisting">
    227220   
    228221  // save cutoff
     
    247240  modelPtr_-&gt;setObjectivePointer(saveObjective);
    248241     
    249   </pre></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch03s03.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch03.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="ch04.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Branching </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 4. 
     242  </pre></div></div><div class="navfooter"><hr/><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch03s03.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch03.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="ch04.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Branching </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 4. 
    250243  Building and Modifying a Model
    251244  </td></tr></table></div></body></html>
Note: See TracChangeset for help on using the changeset viewer.