add.SOS | R Documentation |
Add a Special Ordered Set (SOS) constraint to an lpSolve linear program model object.
add.SOS(lprec, name, type, priority, columns, weights)
lprec |
an lpSolve linear program model object. |
name |
a character string specifying a name for the SOS constraint. |
type |
a positive integer specifying the type of the SOS constraint. |
priority |
an integer specifying the priority of the SOS constraint. |
columns |
a numeric vector of unique values from the set |
weights |
a numeric vector the same length as |
If the operation was successful: a single integer value containing the list index of the new special ordered set. A return value of 0
indicates an error.
Kjell Konis kjell.konis@me.com
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.