Ignore:
Timestamp:
Dec 4, 2009 5:15:52 PM (10 years ago)
Author:
EdwinStraver
Message:

added Lou's comments

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/sandbox/Cbc/src/CbcSOS.hpp

    r1357 r1362  
    33#define CbcSOS_H
    44
    5 /** Define Special Ordered Sets of type 1 and 2.  These do not have to be
    6     integer - so do not appear in lists of integers.
    7 
    8     which_ points directly to columns of matrix
     5/** \brief Branching object for Special Ordered Sets of type 1 and 2.
     6
     7  SOS1 are an ordered set of variables where at most one variable can be
     8  non-zero. SOS1 are commonly defined with binary variables (interpreted as
     9  selection between alternatives) but this is not necessary.  An SOS1 with
     10  all binary variables is a special case of a clique (setting any one
     11  variable to 1 forces all others to 0).
     12
     13  In theory, the implementation makes no assumptions about integrality in
     14  Type 1 sets. In practice, there are places where the code seems to have been
     15  written with a binary SOS mindset. Current development of SOS branching
     16  objects is proceeding in OsiSOS.
     17
     18  SOS2 are an ordered set of variables in which at most two consecutive
     19  variables can be non-zero and must sum to 1 (interpreted as interpolation
     20  between two discrete values). By definition the variables are non-integer.
    921*/
    10 
    1122
    1223class CbcSOS : public CbcObject {
     
    1728    CbcSOS ();
    1829
    19     /** Useful constructor - which are indices
    20         and  weights are also given.  If null then 0,1,2..
    21         type is SOS type
    22     */
     30        /** \brief Constructor with SOS type and member information
     31
     32    Type specifies SOS 1 or 2. Identifier is an arbitrary value.
     33
     34    Which should be an array of variable indices with numberMembers entries.
     35    Weights can be used to assign arbitrary weights to variables, in the order
     36    they are specified in which. If no weights are provided, a default array of
     37    0, 1, 2, ... is generated.
     38        */
     39
    2340    CbcSOS (CbcModel * model, int numberMembers,
    2441            const int * which, const double * weights, int identifier,
     
    126143    /// Members (indices in range 0 ... numberColumns-1)
    127144    int * members_;
    128     /// Weights
     145  /** \brief Weights for individual members
     146
     147    Arbitrary weights for members. Can be used to attach meaning to variable
     148    values independent of objective coefficients. For example, if the SOS set
     149    comprises binary variables used to choose a facility of a given size, the
     150    weight could be the corresponding facilty size. Fractional values of the
     151    SOS variables can then be used to estimate ideal facility size.
     152
     153    Weights cannot be completely arbitrary. From the code, they must be
     154    differ by at least 1.0e-7
     155  */
     156
    129157    double * weights_;
    130158    /// Current pseudo-shadow price estimate down
Note: See TracChangeset for help on using the changeset viewer.