lpSolveAPI (version 5.5.2.0-17.6)

set.basis: Set Basis

Description

Set the initial basis in an lpSolve linear program model object.

Usage

set.basis(lprec, basis, nonbasic = FALSE, default = FALSE)

Arguments

lprec

an lpSolve linear program model object.

basis

a numeric vector of unique values from the set {1, …, (m+n)} (where m is the number of constraints and n is the number of decision variables) specifying the initial basis. The values may be positive or negative where a negative value indicates that the variable is at its lower bound and positive value indicates that the variable is at its upper bound. If nonbasic is FALSE then the n basic variables must be provided. If nonbasic is TRUE then the nonbasic variables must be provided as well.

nonbasic

a logical value. If TRUE the nonbasic variables must be included in basis as well.

default

a logical value. If TRUE the default (all slack variable) basis is used. In this case, the value of basis and nonbasic are ignored.

Value

a NULL value is invisibly returned.

References

http://lpsolve.sourceforge.net/5.5/index.htm