Initializing help system before first use

problem.construct

problem.construct


Purpose
Create the full augmented SLP matrix and data structures, ready for optimization
Synopsis
problem.construct()
Example
The following example constructs the augmented matrix and then outputs the result in MPS format to a file called augment.mat
# creation and/or loading of data
# precedes this segment of code
p.construct()
p.write("augment","l")
The " l" flag causes output of the current linear problem (which is now the augmented structure and the current linearization) rather than the original nonlinear problem.
Further information

construct adds new rows and columns to the SLP matrix and calculates initial values for the non-linear coefficients. Which rows and columns are added will depend on the setting of xslp_augmentation. Names for the new rows and columns are generated automatically, based on the existing names and the string control variables xslp_xxxformat.

Once construct has been called, no new rows, columns or non-linear coefficients can be added to the problem. Any rows or columns which will be required must be added first. Non-linear coefficients must not be changed; constant matrix elements can generally be changed after construct, but not after problem.presolve if used.

construct is called automatically by the SLP optimization procedure, and so only needs to be called explicitly if changes need to be made between the augmentation and the optimization.


Related topics