<html><body>
<p>Mikhail,<br>
<br>
The error from valgrind is a genuine error if you enter branch and bound twice - thanks.<br>
<br>
The main problem is that too much information has been set up after a call to branchAndBound (which also causes valgrind error).  One thing was that the value of best solution has been set to -3e10 so solution on second entry of -2e10 is rejected.<br>
<br>
The simplest thing to do is change your driver to make changes to one copy and then create another model for each entry to branchAndBound -<br>
<br>
<br>
#include &quot;OsiCbcSolverInterface.hpp&quot;<br>
#include &lt;iostream&gt;<br>
using namespace std;<br>
<br>
int main()<br>
{<br>
  OsiCbcSolverInterface testSave;<br>
  testSave.readMps(&quot;mik.mps&quot;);<br>
  OsiCbcSolverInterface test=testSave;<br>
  test.branchAndBound();<br>
  int ind[] = {0};<br>
  double val[] = {1.0};<br>
  testSave.addRow(CoinShallowPackedVector(1,ind,val),-1e10,4504.05);<br>
  test=testSave;<br>
  test.branchAndBound();<br>
  return 0;<br>
}<br>
<br>
John Forrest<br>
<br>
<img width="16" height="16" src="cid:1__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt="Inactive hide details for Mikhail Nediak ---07/10/2008 08:46:56 PM---Hi,  I am using Cbc-2.1.0 via OSI on a 64-bit version of F"><font color="#424282">Mikhail Nediak ---07/10/2008 08:46:56 PM---Hi,  I am using Cbc-2.1.0 via OSI on a 64-bit version of Fedora Core 7. Cbc was compiled with debug</font><br>
<br>

<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr valign="top"><td width="1%"><img width="96" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2" color="#5F5F5F">From:</font></td><td width="100%"><img width="1" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2">Mikhail Nediak &lt;MNediak@business.queensu.ca&gt;</font></td></tr>

<tr valign="top"><td width="1%"><img width="96" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2" color="#5F5F5F">To:</font></td><td width="100%"><img width="1" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2">cbc@list.coin-or.org</font></td></tr>

<tr valign="top"><td width="1%"><img width="96" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2" color="#5F5F5F">Date:</font></td><td width="100%"><img width="1" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2">07/10/2008 08:46 PM</font></td></tr>

<tr valign="top"><td width="1%"><img width="96" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2" color="#5F5F5F">Subject:</font></td><td width="100%"><img width="1" height="1" src="cid:2__=0ABBFE10DFDF5B0C8f9e8a93df938@us.ibm.com" border="0" alt=""><br>
<font size="2">[Cbc] Possible bug in Cbc-2.1.0</font></td></tr>
</table>
<hr width="100%" size="2" align="left" noshade style="color:#8091A5; "><br>
<br>
<br>
Hi,<br>
<br>
I am using Cbc-2.1.0 via OSI on a 64-bit version of Fedora Core 7. Cbc was compiled with debug info on.<br>
<br>
I solve the problem with branchAndBound(), modify it by adding a feasible constraint and then call branchAndBound() again. The solver complains about infeasibility and, moreover, shows a memory handling issue when run through valgrind. A bug?<br>
<br>
I attach an example reproducing the problem and an accompanying mps file.<br>
<br>
Thanks,<br>
Mikhail<br>
<br>
<br>
<br>
</body></html>