Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

CbcSerendipity Class Reference

heuristic - just picks up any good solution found by solver - see OsiBabSolver More...

#include <CbcHeuristic.hpp>

Inheritance diagram for CbcSerendipity:

CbcHeuristic List of all members.

Public Member Functions

 CbcSerendipity ()
 CbcSerendipity (CbcModel &model)
 CbcSerendipity (const CbcSerendipity &)
 ~CbcSerendipity ()
virtual CbcHeuristicclone () const
 Clone.
virtual void generateCpp (FILE *fp)
 Create C++ lines to get to current state.
virtual void setModel (CbcModel *model)
 update model
virtual int solution (double &objectiveValue, double *newSolution)
 returns 0 if no solution, 1 if valid solution.
virtual void resetModel (CbcModel *model)
 Resets stuff if model changes.

Private Member Functions

CbcSerendipityoperator= (const CbcSerendipity &rhs)
 Illegal Assignment operator.

Detailed Description

heuristic - just picks up any good solution found by solver - see OsiBabSolver

Definition at line 154 of file CbcHeuristic.hpp.


Constructor & Destructor Documentation

CbcSerendipity::CbcSerendipity  ) 
 

CbcSerendipity::CbcSerendipity CbcModel model  ) 
 

CbcSerendipity::CbcSerendipity const CbcSerendipity  ) 
 

CbcSerendipity::~CbcSerendipity  ) 
 


Member Function Documentation

virtual CbcHeuristic* CbcSerendipity::clone  )  const [virtual]
 

Clone.

Implements CbcHeuristic.

virtual void CbcSerendipity::generateCpp FILE *  fp  )  [virtual]
 

Create C++ lines to get to current state.

Reimplemented from CbcHeuristic.

virtual void CbcSerendipity::setModel CbcModel model  )  [virtual]
 

update model

Reimplemented from CbcHeuristic.

virtual int CbcSerendipity::solution double &  objectiveValue,
double *  newSolution
[virtual]
 

returns 0 if no solution, 1 if valid solution.

Sets solution values if good, sets objective value (only if good) We leave all variables which are at one at this node of the tree to that value and will initially set all others to zero. We then sort all variables in order of their cost divided by the number of entries in rows which are not yet covered. We randomize that value a bit so that ties will be broken in different ways on different runs of the heuristic. We then choose the best one and set it to one and repeat the exercise.

Implements CbcHeuristic.

virtual void CbcSerendipity::resetModel CbcModel model  )  [virtual]
 

Resets stuff if model changes.

Implements CbcHeuristic.

CbcSerendipity& CbcSerendipity::operator= const CbcSerendipity rhs  )  [private]
 

Illegal Assignment operator.


The documentation for this class was generated from the following file:
Generated on Sun Jun 11 02:01:18 2006 by  doxygen 1.3.9.1