- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# OsiSOS Class Reference

Define Special Ordered Sets of type 1 and 2. More...

`#include <OsiBranchingObject.hpp>`

Inheritance diagram for OsiSOS:

[legend]
Collaboration diagram for OsiSOS:

[legend]
List of all members.

## Public Member Functions
| OsiSOS ()
| OsiSOS (const OsiSolverInterface *solver, int numberMembers, const int *which, const double *weights, int type=1)
| Useful constructor - which are indices and weights are also given.
| OsiSOS (const OsiSOS &)
virtual OsiObject * | clone () const
| Clone.
OsiSOS & | operator= (const OsiSOS &rhs)
virtual | ~OsiSOS ()
virtual double | infeasibility (const OsiBranchingInformation *info, int &whichWay) const
| Infeasibility - large is 0.5.
virtual double | feasibleRegion (OsiSolverInterface *solver, const OsiBranchingInformation *info) const
| Set bounds to fix the variable at the current (integer) value.
virtual OsiBranchingObject * | createBranch (OsiSolverInterface *solver, const OsiBranchingInformation *info, int way) const
| Creates a branching object.
virtual double | upEstimate () const
| Return "up" estimate (default 1.0e-5).
virtual double | downEstimate () const
| Return "down" estimate (default 1.0e-5).
virtual void | resetSequenceEtc (int numberColumns, const int *originalColumns)
| Redoes data when sequence numbers change.
int | numberMembers () const
| Number of members.
const int * | members () const
| Members (indices in range 0 ... numberColumns-1).
int | sosType () const
| SOS type.
int | setType () const
| SOS type.
const double * | weights () const
| Array of weights.
virtual bool | canDoHeuristics () const
| Return true if object can take part in normal heuristics.
void | setIntegerValued (bool yesNo)
| Set whether set is integer valued or not.
virtual bool | canHandleShadowPrices () const
| Return true if knows how to deal with Pseudo Shadow Prices.
void | setNumberMembers (int value)
| Set number of members.
int * | mutableMembers () const
| Members (indices in range 0 ... numberColumns-1).
void | setSosType (int value)
| Set SOS type.
double * | mutableWeights () const
| Array of weights.
## Protected Attributes
int * | members_
| Members (indices in range 0 ... numberColumns-1).
double * | weights_
| Weights.
int | numberMembers_
| Number of members.
int | sosType_
| SOS type.
bool | integerValued_
| Whether integer valued.

## Detailed Description

Define Special Ordered Sets of type 1 and 2.

These do not have to be integer - so do not appear in lists of integers.

which_ points columns of matrix

Definition at line 663 of file OsiBranchingObject.hpp.

## Constructor & Destructor Documentation

OsiSOS::OsiSOS | ( |  | ) |

OsiSOS::OsiSOS | ( | const OsiSolverInterface * | solver,
|  | int | numberMembers,
|  | const int * | which,
|  | const double * | weights,
|  | int | type = `1` |
| ) |  |  |

Useful constructor - which are indices and weights are also given.

If null then 0,1,2.. type is SOS type

OsiSOS::OsiSOS | ( | const OsiSOS & |  | ) |

virtual OsiSOS::~OsiSOS | ( |  | ) | `[virtual]`

## Member Function Documentation

virtual OsiObject* OsiSOS::clone | ( |  | ) | const`[virtual]`

Clone.

Implements OsiObject.

OsiSOS& OsiSOS::operator= | ( | const OsiSOS & | rhs | ) |

virtual double OsiSOS::infeasibility | ( | const OsiBranchingInformation * | info,
|  | int & | whichWay |
| ) |  |  | const`[virtual]`

Infeasibility - large is 0.5.

Implements OsiObject.

virtual double OsiSOS::feasibleRegion | ( | OsiSolverInterface * | solver,
|  | const OsiBranchingInformation * | info |
| ) |  |  | const`[virtual]`

Set bounds to fix the variable at the current (integer) value.

Given an integer value, set the lower and upper bounds to fix the variable. Returns amount it had to move variable.

Implements OsiObject.

virtual OsiBranchingObject* OsiSOS::createBranch | ( | OsiSolverInterface * | solver,
|  | const OsiBranchingInformation * | info,
|  | int | way |
| ) |  |  | const`[virtual]`

Creates a branching object.

The preferred direction is set by `way`, 0 for down, 1 for up.

Implements OsiObject.

virtual double OsiSOS::upEstimate | ( |  | ) | const`[virtual]`

Return "up" estimate (default 1.0e-5).

Reimplemented from OsiObject.

virtual double OsiSOS::downEstimate | ( |  | ) | const`[virtual]`

Return "down" estimate (default 1.0e-5).

Reimplemented from OsiObject.

virtual void OsiSOS::resetSequenceEtc | ( | int | numberColumns,
|  | const int * | originalColumns |
| ) |  |  | `[virtual]`

Redoes data when sequence numbers change.

Reimplemented from OsiObject.

int OsiSOS::numberMembers | ( |  | ) | const`[inline]`

Number of members.

Definition at line 715 of file OsiBranchingObject.hpp.

References numberMembers_.

const int* OsiSOS::members | ( |  | ) | const`[inline]`

Members (indices in range 0 ... numberColumns-1).

Definition at line 719 of file OsiBranchingObject.hpp.

References members_.

int OsiSOS::sosType | ( |  | ) | const`[inline]`

SOS type.

Definition at line 723 of file OsiBranchingObject.hpp.

References sosType_.

int OsiSOS::setType | ( |  | ) | const`[inline]`

SOS type.

Definition at line 727 of file OsiBranchingObject.hpp.

References sosType_.

const double* OsiSOS::weights | ( |  | ) | const`[inline]`

Array of weights.

Definition at line 731 of file OsiBranchingObject.hpp.

References weights_.

virtual bool OsiSOS::canDoHeuristics | ( |  | ) | const`[inline, virtual]`

Return true if object can take part in normal heuristics.

Reimplemented from OsiObject.

Definition at line 736 of file OsiBranchingObject.hpp.

References integerValued_, and sosType_.

void OsiSOS::setIntegerValued | ( | bool | yesNo | ) | `[inline]`

Set whether set is integer valued or not.

Definition at line 739 of file OsiBranchingObject.hpp.

References integerValued_.

virtual bool OsiSOS::canHandleShadowPrices | ( |  | ) | const`[inline, virtual]`

Return true if knows how to deal with Pseudo Shadow Prices.

Reimplemented from OsiObject.

Definition at line 742 of file OsiBranchingObject.hpp.

void OsiSOS::setNumberMembers | ( | int | value | ) | `[inline]`

Set number of members.

Definition at line 745 of file OsiBranchingObject.hpp.

References numberMembers_.

int* OsiSOS::mutableMembers | ( |  | ) | const`[inline]`

Members (indices in range 0 ... numberColumns-1).

Definition at line 749 of file OsiBranchingObject.hpp.

References members_.

void OsiSOS::setSosType | ( | int | value | ) | `[inline]`

Set SOS type.

Definition at line 753 of file OsiBranchingObject.hpp.

References sosType_.

double* OsiSOS::mutableWeights | ( |  | ) | const`[inline]`

Array of weights.

Definition at line 757 of file OsiBranchingObject.hpp.

References weights_.

## Member Data Documentation

int* OsiSOS::members_`[protected]`

Members (indices in range 0 ... numberColumns-1).

Definition at line 763 of file OsiBranchingObject.hpp.

Referenced by members(), and mutableMembers().

double* OsiSOS::weights_`[protected]`

Weights.

Definition at line 765 of file OsiBranchingObject.hpp.

Referenced by mutableWeights(), and weights().

int OsiSOS::numberMembers_`[protected]`

Number of members.

Definition at line 768 of file OsiBranchingObject.hpp.

Referenced by numberMembers(), and setNumberMembers().

int OsiSOS::sosType_`[protected]`

SOS type.

Definition at line 770 of file OsiBranchingObject.hpp.

Referenced by canDoHeuristics(), setSosType(), setType(), and sosType().

bool OsiSOS::integerValued_`[protected]`

Whether integer valued.

Definition at line 772 of file OsiBranchingObject.hpp.

Referenced by canDoHeuristics(), and setIntegerValued().

The documentation for this class was generated from the following file:

- /home/coin/SVN-release/Cgl-0.53.1/Osi/src/OsiBranchingObject.hpp