nag_g02_opt_set (g02zkc) either initializes or resets the optional argument arrays or sets a single optional argument for supported problem solving functions in
Chapter g02. Currently, only
nag_regsn_quant_linear (g02qgc) is supported.
nag_g02_opt_set (g02zkc) has three purposes: to initialize optional argument arrays, to reset all optional arguments to their default values or to set a single optional argument to a user-supplied value.
Optional arguments and their values are, in general, presented as a character string,
optstr, of the form ‘
option ’; alphabetic characters can be supplied in either upper or lower case. Both
option and
may consist of one or more tokens separated by white space. The tokens that comprise
will normally be either an integer, real or character value as defined in the description of the specific optional argument. In addition all optional arguments can take an
DEFAULT which resets the optional argument to its default value.
It is imperative that optional argument arrays are initialized before any options are set, before the relevant problem solving function is called and before any options are queried using
nag_g02_opt_get (g02zlc). To initialize the optional argument arrays
iopts and
opts for a specific problem solving function, the option
Initialize is used with
identifying the problem solving function to be called, via its short name. For example, to initialize optional argument arrays to be passed to
nag_regsn_quant_linear (g02qgc), nag_g02_opt_set (g02zkc) is called as follows:
Information relating to available option names and their corresponding valid values is given in
Section 12 in nag_regsn_quant_linear (g02qgc).
None.
- NE_ALLOC_FAIL
-
Dynamic memory allocation failed.
- NE_BAD_PARAM
-
On entry, argument had an illegal value.
- NE_INT
-
On entry, .
Constraint: .
On entry, .
Constraint: .
- NE_INTERNAL_ERROR
-
An internal error has occurred in this function. Check the function call and any array sizes. If the call is correct then please contact
NAG for assistance.
- NE_INVALID_FORMAT
-
On entry, could not convert the specified optval to an integer: .
On entry, could not convert the specified optval to a real: .
On entry, the expected delimiter ‘
’ was not found in
optstr:
.
- NE_INVALID_OPTION
-
On entry, either the option arrays have not been initialized or they have been corrupted.
On entry, the
option supplied in
optstr was not recognized:
.
- NE_INVALID_VALUE
-
On entry, the optval supplied for the character optional argument is not valid.
.
On entry, the optval supplied for the integer optional argument is not valid.
.
On entry, the optval supplied for the real optional argument is not valid.
.
- NE_NOT_FUN_NAME
-
On entry, attempting to initialize the optional argument arrays but specified function name was not valid: .
Not applicable.
Not applicable.
Not applicable.
See the example programs associated with the problem solving function you wish to use for a demonstration of how to use nag_g02_opt_set (g02zkc) to initialize option arrays and set options.