Osi 0.108.9
Loading...
Searching...
No Matches
opbdp_solve.hpp
Go to the documentation of this file.
1// Copyright (C) 2006, International Business Machines
2// Corporation and others. All Rights Reserved.
3#ifndef OsiOpbdpSolve_H
4#define OsiOpbdpSolve_H
5
6#include <string>
7
9
35unsigned int ** solveOpbdp(const OsiSolverInterface * model,int & numberFound);
36
37inline bool atOne(int i,unsigned int * array) {
38 return ((array[i>>5]>>(i&31))&1)!=0;
39}
40inline void setAtOne(int i,unsigned int * array,bool trueFalse) {
41 unsigned int & value = array[i>>5];
42 int bit = i&31;
43 if (trueFalse)
44 value |= (1<<bit);
45 else
46 value &= ~(1<<bit);
47}
48#endif
Abstract Base Class for describing an interface to a solver.
int solveOpbdp(OsiSolverInterface *model)
Solve pure 0-1 with integral coefficients etc (or can be made by scaling) using opdbp The solution wi...
bool atOne(int i, unsigned int *array)
void setAtOne(int i, unsigned int *array, bool trueFalse)