Difference between revisions of "OptWrite"
(2 intermediate revisions by one other user not shown) | |||
Line 2: | Line 2: | ||
[[Category:Doc Status D]] <!-- For Lumina use, do not change --> | [[Category:Doc Status D]] <!-- For Lumina use, do not change --> | ||
− | = OptWrite(opt,filename'', format) = | + | == OptWrite(opt, filename'', format) == |
− | Writes | + | Writes the definition of the linear program «opt» to a file. Three textual formats are supported, which can be selected using the optional «format» parameter: |
− | * "LP" (default) | + | * <code>"LP"</code> (default) |
− | * "[http://lpsolve.sourceforge.net/5.0/mps-format.htm | + | * <code>"MPS"</code> (see [http://lpsolve.sourceforge.net/5.0/mps-format.htm mps-format.mps] for details)" |
− | * "LPFML" | + | * <code>"LPFML</code>" |
− | The «filename» is interpreted relative to the [[ | + | The «filename» is interpreted relative to the [[CurrentDataFolder]]. |
When debugging an LP, to figure out if you defined your constraints and decision variables as intended, it can sometimes be helpful to view the file written by [[OptWrite]] in a text editor. | When debugging an LP, to figure out if you defined your constraints and decision variables as intended, it can sometimes be helpful to view the file written by [[OptWrite]] in a text editor. | ||
Line 17: | Line 17: | ||
[[OptWrite]] is not able to write textual specifications for quadratic (QP or QCP) or non-linear (NLP) problems. | [[OptWrite]] is not able to write textual specifications for quadratic (QP or QCP) or non-linear (NLP) problems. | ||
− | = See Also = | + | == See Also == |
− | |||
* [[OptRead]] | * [[OptRead]] | ||
* [[OptWriteIIS]] | * [[OptWriteIIS]] | ||
− | * [[ | + | * [[CurrentDataFolder]] |
Latest revision as of 23:39, 20 January 2016
OptWrite(opt, filename, format)
Writes the definition of the linear program «opt» to a file. Three textual formats are supported, which can be selected using the optional «format» parameter:
"LP"
(default)"MPS"
(see mps-format.mps for details)""LPFML
"
The «filename» is interpreted relative to the CurrentDataFolder.
When debugging an LP, to figure out if you defined your constraints and decision variables as intended, it can sometimes be helpful to view the file written by OptWrite in a text editor.
The file written by OptWrite can be read back in as an LP using OptRead.
OptWrite is not able to write textual specifications for quadratic (QP or QCP) or non-linear (NLP) problems.
See Also
Comments
Enable comment auto-refresher