mmxnlp



The mmxnlp module provides access to nonlinear solvers, extending the capabilities provided by the mmxprs and mmnl modules. In particular, this module allows existing linear or mixed integer (MIP) models to be upgraded to include nonlinearities, without requiring unnecessary changes to the formulation. To use this module, the following line must be included in the header of the Mosel model file:

 uses 'mmxnlp'
Problem type and module hierarchy

Module mmxprs provides

Module mmnl adds support for Module mmxnlp adds support for

If the mmxnlp module is used for a model which does not require a general nonlinear solver, this should be equivalent to using the appropriate mmxprs or mmnl module directly.

New functionality for the Mosel language

The userfunc type

A nonlinear model may employ one or more black box evaluation functions, which can be used to provide function evaluations to the solver. These are represented in mmxnlp by the new userfunc type. The implementation of each userfunc must be described by calling one of:

Note that user functions returning multiple arguments are support by the mmxnlp module. The F construction allows a userfunc to be included in any nonlinear (nlctr) expression, and groups each occurrence of the userfunc with its parameters . During the solve, the parameters (which are of type nlctr themselves) will be evaluated at the current solution, and the real-valued results passed to the userfunc implementation. The function userfuncinfo can be used to find out which parameters the system has deduced it needs to pass to a particular userfunc.

The tolset type

The module provides a large number of configurable tolerances for users of Xpress-SLP. A tolset describes a convergence tolerance set, which can be used for those nonlinear solvers supporting variable-specific convergence tolerances. The elements of a tolerance set are defined by using settol, and assigned to a variable or list of variables using settolset. For more details on tolerance sets, please refer to the Xpress-SLP documentation.

The mpproblem.xprs.xnlp problem type

When using the mmxnlp module, the type of the active Mosel problem is changed from mpproblem.xprs to the extended type mpproblem.xprs.xnlp. This means that all of the routines presented in this section operate in the context of the current Mosel problem. This is in contrast to the older mmxslp module, which required a separate, explicit problem to work on.

mmxnlp and other the Mosel modules

mmxnlp is designed to provide seamless integration with other Mosel functionalities. However, the fundamentally different nature of non-linear problems makes some compromises necessary; these are listed in this section.

Overloaded functions

The following functionality is modified or extended by the mmxnlp module:

Module compatibility

The mmquad module is incompatible with the mmxnlp module, and should not be used together with it.

The mmxprs and mmnl modules are automatically loaded when using the mmxnlp module.

The mmnl module defines several discontinuous functions for use with decision variables (mpvar), which are not supported by the mmxnlp module. These constructions should instead be modelled with integer constraints. The functions are: round, ceil, floor, idiv and mod.

The following standard functionalities are not available for nonlinear problems:

Control parameters

When using mmxnlp, getparam and setparam are extended to additionally provide access to all the control and problem parameters of Xpress-SLP. The module also provides the following controls of its own:

XNLP_LOADASNL
When set to true, quadratic expressions will be treated as being of general nonlinear type. If they are known to be non-convex, the overhead of attempting to treat the expression as convex initially is avoided.
XNLP_LOADNAMES
When set to true, names from the Mosel file will be passed to the underlying solver to improve the readability of messages it generates. This is an alias for XPRS_LOADNAMES.
XNLP_NLPSTATUS
The solution status of the problem. For a detailed description of this value, please see the documentation for the XSLP_NLPSTATUS attribute in the Xpress-SLP reference manual.
XNLP_SOLVER
Solver selection when available.
XNLP_VERBOSE
When set to true, informative messages from any underlying nonlinear solver will be displayed. This is an alias for XPRS_VERBOSE.

Procedures and functions

This section lists in alphabetical order the functions and procedures that are provided by the mmxnlp module.

F
Include a user function in a nonlinear constraint.
printmodelmemory
Print a summary of the current memory usage of the nonlinear module.
printmodelscaling
Print a summary of the scaling of the model, as loaded into the solver.
setdelayedctr
Mark a constraint as delayed.
setdetrow
Set the determining row for a variable.
setenforcedctr
Mark a nonlinear constraint as enforced.
setinitsb
Provide the initial step bound for a variable.
settol
Define a particular tolerance in a tolerance set.
settolset
Assigns a tolerance set to a variable, or list of variables.
userfuncDLL
Create a user function implemented as a dynamic linked library.
userfuncExcel
Create a user function from a Microsoft Excel spreadsheet.
userfuncExcelMacro
Create a user function from a Microsoft Excel macro.
userfuncinfo
Print the inferred prototype of the given user function.
userfuncMosel
Create a user function from a Mosel function.
validate
Print a summary of the feasibility of the current solution.


If you have any comments or suggestions about these pages, please send mail to support@fico.com.

© Copyright 2001-2013 Fair Isaac Corporation. All rights reserved.