source: trunk/Couenne/src/main/BonCouenneInfo.cpp @ 5

Last change on this file since 5 was 1, checked in by coin, 12 years ago

Initial import

File size: 1.1 KB
Line 
1// (C) Copyright International Business Machines Corporation 2007
2// All Rights Reserved.
3// This code is published under the Common Public License.
4//
5// Authors :
6// Andreas Waechter, International Business Machines Corporation
7//
8// Date : 02/10/2008
9
10#include "BonCouenneInfo.hpp"
11
12namespace Bonmin
13{
14  /** Default constructor.*/
15  CouenneInfo::CouenneInfo(int type):
16      BabInfo(type)
17  {}
18
19  /** Constructor from OsiBabSolver.*/
20  CouenneInfo::CouenneInfo(const OsiBabSolver &other):
21      BabInfo(other)
22  {}
23
24  /** Copy constructor.*/
25  CouenneInfo::CouenneInfo(const CouenneInfo &other):
26      BabInfo(other)
27  {}
28
29  /** Destructor.*/
30  CouenneInfo::~CouenneInfo()
31  {}
32
33  /** Virtual copy constructor.*/
34  OsiAuxInfo *
35  CouenneInfo::clone() const
36  {
37    return new CouenneInfo(*this);
38  }
39
40  CouenneInfo::NlpSolution::NlpSolution(int n, const double* sol, double objval)
41    :
42    n_(n),
43    objVal_(objval)
44  {
45    sol_ = new double[n];
46    CoinCopyN(sol, n, sol_);
47  }
48
49  CouenneInfo::NlpSolution::~NlpSolution()
50  {
51    delete [] sol_;
52  }
53}/* end namespace Bonmin*/
54
Note: See TracBrowser for help on using the repository browser.