emblem
LP random problem generator
Generates random data for an LP problem in standard form.
2026.Sep.30 00:23:59
Constraints, m Number of constraints, all of the '≤' type. •
Struct. var.s, 'nvar' Number of (non-negative) structural variables. •
vL, vU Lower and upper bounds for random values. •
.Seed Seed for RNG (iff ≥ 1, repeatable). •

Generates random data for a Linear Programming problem. The data are c, A and b, such that, as usual, the problem will be [max|min] z = cTx subject to Ax ≤ b. These data are meant to fit the revised simplex ⤤plate.

Only the case amenable to the (simple) standard form is considered, i.e., containing only slack variables and no artificial variables. The necessary identity sub-matrix is produced. Also, b will be converted to |b|, to avoid any negative generated values (which would lead to the need of artificials).

Examples: (a) with seed = 7531, z* = 45.25, in 8 iterations; (b) with (-100, +100) and seed = 7531, z = 3896.2 after 12 iterations and becomes unbounded.

References: Plate: LP_generator

• Wikipedia: Revised simplex method

• Google: "revised simplex method" (Unicode arrows)

• 1835-03-24: Stefan, Josef (1893-01-07)   (1538-03-25 Christopher Clavius, Pedro Nunes' student).

 
 
Valid HTML 4.01! IST http://web.tecnico.ulisboa.pt/~ist11038/compute/or/Fx-LP-generator.php
Created: 2015-03-25 — Last modified: 2015-03-25