slack: Add Slack Variables

Description Usage Arguments Details

Description

From a coefficient matrix, add slack variables.

Usage

1
2
3
slack(A, rows)

slackdir(A, rows)

Arguments

A

Coefficient matrix.

rows

Index of rows which are _not_ equality constraints. If left blank, all are assumed to be inequality constraints.

Details

This operation comes in two flavors, goverened by functions slack() and slackdir(). For the former, given a coefficient matrix A and an index of rows rows, this will return the coefficient matrix with slack variables added appropriately. The latter does the same, but for extreme direction problems; in particular, it adds the constraint for the sum of the d's.


wrathematics/lptools documentation built on May 4, 2019, 10:52 a.m.