MpsReader Class

Reads a linear program in MPS format.

Definition

Namespace: Numerics.NET.Optimization
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
C#
public static class MpsReader
Inheritance
Object  →  MpsReader

Remarks

Use the MpsReader class to read a LinearProgram from a file in MPS format. The format was named after an early linear programming system from IBM. It has since emerged as a de facto standard ASCII medium among most of the commercial linear programming systems.

The MpsReader class has one static method, Read(StreamReader), which is overloaded. The first overload takes a string containing the path to an MPS file and returns a LinearProgram object that represents the linear program in the file. The second method does the same but gets its input from a StreamReader.

Several extensions of the MPS format have been defined over the years. The current implementation of MpsReader doesn't support these extensions. A FormatException is thrown when an unrecognized extension is found.

Methods

Read(StreamReader) Reads a linear programming model from a stream.
Read(String) Reads a linear programming model from an MPS file.
ReadQuadraticProgram(StreamReader) Reads a quadratic programming model from a stream.
ReadQuadraticProgram(String) Reads a quadratic programming model from an MPS file.

See Also